mirror of
https://github.com/nasa/openmct.git
synced 2024-12-22 06:27:48 +00:00
modified getOperationFormat
This commit is contained in:
parent
1a409afb03
commit
d2a45e46f1
@ -44,7 +44,7 @@
|
|||||||
{{ option.text }}
|
{{ option.text }}
|
||||||
</option>
|
</option>
|
||||||
</select>
|
</select>
|
||||||
<span v-for="(item, inputIndex) in Array, inputCount"
|
<span v-for="(item, inputIndex) in inputCount"
|
||||||
:key="inputIndex"
|
:key="inputIndex"
|
||||||
>
|
>
|
||||||
<input v-model="criterion.input[inputIndex]"
|
<input v-model="criterion.input[inputIndex]"
|
||||||
@ -108,17 +108,19 @@ export default {
|
|||||||
methods: {
|
methods: {
|
||||||
getOperationFormat() {
|
getOperationFormat() {
|
||||||
this.telemetryMetadata.valueMetadatas.forEach((value, index) => {
|
this.telemetryMetadata.valueMetadatas.forEach((value, index) => {
|
||||||
let valueMetadata = this.telemetryMetadataOptions[index];
|
if (value.key === this.criterion.metadata) {
|
||||||
if (valueMetadata.formatString) {
|
let valueMetadata = this.telemetryMetadataOptions[index];
|
||||||
this.operationFormat = 'number';
|
if (valueMetadata.enumerations !== undefined) {
|
||||||
} else if (valueMetadata.format) {
|
|
||||||
if (valueMetadata.format === 'utc') {
|
|
||||||
this.operationFormat = 'number';
|
|
||||||
} else if (valueMetadata.format === 'enum') {
|
|
||||||
this.operationFormat = 'enum';
|
this.operationFormat = 'enum';
|
||||||
|
} else if (valueMetadata.hints.hasOwnProperty('range')) {
|
||||||
|
this.operationFormat = 'number';
|
||||||
|
} else if (valueMetadata.hints.hasOwnProperty('domain')) {
|
||||||
|
this.operationFormat = 'number';
|
||||||
|
} else if (valueMetadata.key === 'name') {
|
||||||
|
this.operationFormat = 'string';
|
||||||
|
} else {
|
||||||
|
this.operationFormat = 'string';
|
||||||
}
|
}
|
||||||
} else {
|
|
||||||
this.operationFormat = 'string';
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user