mirror of
https://github.com/nasa/openmct.git
synced 2025-06-17 06:38:17 +00:00
[Telemetry Tables][Plots] Display units where applicable (#3198)
* added unit columns in telemetry tables * added unit column hiding in telemetry tables, added units to lad tables and sets * added units to plots and plot legends
This commit is contained in:
@ -58,6 +58,12 @@
|
||||
>
|
||||
<div class="c-telemetry-view__value-text">
|
||||
{{ telemetryValue }}
|
||||
<span
|
||||
v-if="unit && item.showUnits"
|
||||
class="c-telemetry-view__value-text__unit"
|
||||
>
|
||||
{{ unit }}
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -137,6 +143,12 @@ export default {
|
||||
|
||||
return displayMode === 'all' || displayMode === 'value';
|
||||
},
|
||||
unit() {
|
||||
let value = this.item.value,
|
||||
unit = this.metadata.value(value).unit;
|
||||
|
||||
return unit;
|
||||
},
|
||||
styleObject() {
|
||||
return Object.assign({}, {
|
||||
fontSize: this.item.size
|
||||
@ -257,7 +269,9 @@ export default {
|
||||
item: domainObject,
|
||||
layoutItem: this.item,
|
||||
index: this.index,
|
||||
updateTelemetryFormat: this.updateTelemetryFormat
|
||||
updateTelemetryFormat: this.updateTelemetryFormat,
|
||||
toggleUnits: this.toggleUnits,
|
||||
showUnits: this.showUnits
|
||||
};
|
||||
this.removeSelectable = this.openmct.selection.selectable(
|
||||
this.$el, this.context, this.immediatelySelect || this.initSelect);
|
||||
|
Reference in New Issue
Block a user