mirror of
https://github.com/nasa/openmct.git
synced 2025-02-07 19:40:28 +00:00
[Limits] Begin using limits from scrolling list view
WTD-1223.
This commit is contained in:
parent
dc6c43a4cd
commit
88f938b1b6
@ -36,19 +36,19 @@
|
|||||||
<!-- ng-class is temporarily hard-coded in next element -->
|
<!-- ng-class is temporarily hard-coded in next element -->
|
||||||
<div
|
<div
|
||||||
class="tr"
|
class="tr"
|
||||||
ng-repeat="row in rows"
|
ng-repeat="row in rows track by $index"
|
||||||
ng-class="{ 's-stale': $index%3==0 }"
|
ng-class="{ 's-stale': $index%3==0 }"
|
||||||
>
|
>
|
||||||
<!-- ng-class is temporarily hard-coded in next element -->
|
<!-- ng-class is temporarily hard-coded in next element -->
|
||||||
<div
|
<div
|
||||||
class="td"
|
class="td"
|
||||||
ng-class="{ 's-cell-type-value': $index > 1 }"
|
ng-class="{ 's-cell-type-value': $index > 1 }"
|
||||||
ng-repeat="cell in row"
|
ng-repeat="cell in row track by $index"
|
||||||
>
|
>
|
||||||
<!-- ng-class is temporarily hard-coded in next element -->
|
<!-- ng-class is temporarily hard-coded in next element -->
|
||||||
<span
|
<span
|
||||||
class="l-cell-contents"
|
class="l-cell-contents"
|
||||||
ng-class="{ 's-limit-upr-yellow': cell > 0 }"
|
ng-class="cell.cssClass"
|
||||||
>
|
>
|
||||||
{{cell}}
|
{{cell}}
|
||||||
</span>
|
</span>
|
||||||
|
@ -55,9 +55,17 @@ define(
|
|||||||
* @returns {string} the text to display
|
* @returns {string} the text to display
|
||||||
*/
|
*/
|
||||||
getValue: function (domainObject, data, index) {
|
getValue: function (domainObject, data, index) {
|
||||||
return telemetryFormatter.formatRangeValue(
|
var range = rangeMetadata.key,
|
||||||
data.getRangeValue(index, rangeMetadata.key)
|
limit = domainObject.getCapability('limit'),
|
||||||
);
|
value = data.getRangeValue(index, range),
|
||||||
|
cell = telemetryFormatter.formatRangeValue(value);
|
||||||
|
|
||||||
|
return {
|
||||||
|
cssClass: limit && limit.evaluate(value, range),
|
||||||
|
toString: function () {
|
||||||
|
return cell;
|
||||||
|
}
|
||||||
|
};
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
@ -142,7 +142,7 @@ define(
|
|||||||
// column object itself)
|
// column object itself)
|
||||||
return values.map(function (value) {
|
return values.map(function (value) {
|
||||||
return columns.map(function (column) {
|
return columns.map(function (column) {
|
||||||
return column.getValue(
|
column.getValue(
|
||||||
objects[value.objectIndex],
|
objects[value.objectIndex],
|
||||||
datas[value.objectIndex],
|
datas[value.objectIndex],
|
||||||
value.pointIndex
|
value.pointIndex
|
||||||
|
Loading…
x
Reference in New Issue
Block a user