mirror of
https://github.com/nasa/openmct.git
synced 2025-02-12 21:56:13 +00:00
[Search] Results list displayed
After searching, a results list is displayed. The list is composed of grid-items.
This commit is contained in:
parent
6d1cb85a07
commit
2e7f23a766
@ -19,11 +19,9 @@
|
|||||||
this source code distribution or the Licensing information page available
|
this source code distribution or the Licensing information page available
|
||||||
at runtime from the About dialog for additional information.
|
at runtime from the About dialog for additional information.
|
||||||
-->
|
-->
|
||||||
<!-- Based on grid-item -->
|
<!-- Same as grid-item -->
|
||||||
<!-- For selected, add class 'selected' to outer div -->
|
<div class='item grid-item' ng-click='action.perform("navigate")'>
|
||||||
<div class='item' ng-click='action.perform("navigate")'>
|
<div class="contents abs">
|
||||||
ITEM
|
|
||||||
<!--div class="contents abs">
|
|
||||||
<div class='top-bar bar abs'>
|
<div class='top-bar bar abs'>
|
||||||
<div class='left abs'>
|
<div class='left abs'>
|
||||||
<mct-include key="_checkbox"></mct-include>
|
<mct-include key="_checkbox"></mct-include>
|
||||||
@ -45,5 +43,5 @@
|
|||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div-->
|
</div>
|
||||||
</div>
|
</div>
|
@ -32,10 +32,11 @@
|
|||||||
<input type="text" id="searchinput" />
|
<input type="text" id="searchinput" />
|
||||||
</div>
|
</div>
|
||||||
-->
|
-->
|
||||||
Search: <br>
|
<div style="height: 30px">Search:</div>
|
||||||
<input type="text"
|
<input type="text"
|
||||||
id="searchinput"
|
id="searchinput"
|
||||||
name="searchform" />
|
name="searchform"
|
||||||
|
value="input search term here"/>
|
||||||
<!--
|
<!--
|
||||||
<div class="button">
|
<div class="button">
|
||||||
<button type="submit">Search</button>
|
<button type="submit">Search</button>
|
||||||
@ -46,26 +47,20 @@
|
|||||||
-->
|
-->
|
||||||
<span class="button">
|
<span class="button">
|
||||||
<button type="button"
|
<button type="button"
|
||||||
ng-click="controller.search()">Go</button>
|
ng-click="controller.search('')">Go</button>
|
||||||
</span>
|
</span>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- some spacing -->
|
<!-- some spacing -->
|
||||||
<div style="height: 20px"></div>
|
<div style="height: 30px"></div>
|
||||||
|
|
||||||
<!-- Results list -->
|
<!-- Results list -->
|
||||||
<ul>
|
<div ng-if="controller.areResults()"
|
||||||
<li>
|
style="height: 30px">
|
||||||
<mct-representation key="'search-item'"><!--
|
Results:
|
||||||
ng-repeat="childObject in composition"
|
</div>
|
||||||
mct-object="childObject"--></mct-representation>
|
|
||||||
</li>
|
|
||||||
<li>
|
|
||||||
<mct-representation key="'search-item'"
|
<mct-representation key="'search-item'"
|
||||||
ng-repeat="result in results"
|
ng-repeat="result in results"
|
||||||
mct-object="result"></mct-representation>
|
mct-object="result"></mct-representation>
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
|
|
||||||
</div>
|
</div>
|
@ -118,7 +118,13 @@ define(function () {
|
|||||||
$scope.results = search();
|
$scope.results = search();
|
||||||
|
|
||||||
return {
|
return {
|
||||||
search: search
|
search: search,
|
||||||
|
/**
|
||||||
|
* Check to see if there are any search results to display.
|
||||||
|
*/
|
||||||
|
areResults: function () {
|
||||||
|
return $scope.results.length !== 0;
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
return SearchController;
|
return SearchController;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user