mirror of
https://github.com/nasa/openmct.git
synced 2024-12-18 20:57:53 +00:00
Merge branch 'activity-state-display' of https://github.com/nasa/openmct into timelist-expanded-view
This commit is contained in:
commit
e5fd2d7440
@ -20,28 +20,26 @@
|
||||
at runtime from the About dialog for additional information.
|
||||
-->
|
||||
<template>
|
||||
<div>
|
||||
<plan-activity-time-view
|
||||
v-for="activity in activities"
|
||||
:key="activity.key"
|
||||
:activity="activity"
|
||||
:heading="heading"
|
||||
/>
|
||||
<plan-activity-properties-view
|
||||
v-for="activity in activities"
|
||||
:key="activity.key"
|
||||
heading="Properties"
|
||||
:activity="activity"
|
||||
/>
|
||||
<plan-activity-status-view
|
||||
v-if="canPersistState"
|
||||
:key="activities[0].key"
|
||||
:activity="activities[0]"
|
||||
:execution-state="activityExecutionState"
|
||||
:heading="Activity Status"
|
||||
@update-activity-state="persistActivityState"
|
||||
/>
|
||||
</div>
|
||||
<plan-activity-time-view
|
||||
v-for="activity in activities"
|
||||
:key="activity.key"
|
||||
:activity="activity"
|
||||
:heading="heading"
|
||||
/>
|
||||
<plan-activity-properties-view
|
||||
v-for="activity in activities"
|
||||
:key="activity.key"
|
||||
heading="Properties"
|
||||
:activity="activity"
|
||||
/>
|
||||
<plan-activity-status-view
|
||||
v-if="canPersistState"
|
||||
:key="activities[0].key"
|
||||
:activity="activities[0]"
|
||||
:execution-state="activityExecutionState"
|
||||
heading="Activity Status"
|
||||
@update-activity-state="persistActivityState"
|
||||
/>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
@ -110,9 +110,7 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
setActivityStatus() {
|
||||
let statusKeyIndex = Object.keys(activityStates).findIndex(
|
||||
(key) => key === this.executionState
|
||||
);
|
||||
let statusKeyIndex = activityStates.findIndex((state) => state.key === this.executionState);
|
||||
if (statusKeyIndex < 0) {
|
||||
statusKeyIndex = 0;
|
||||
}
|
||||
|
@ -490,9 +490,7 @@ export default {
|
||||
this.pastActivitiesCount = this.pastActivitiesCount + 1;
|
||||
}
|
||||
|
||||
if (activity.id) {
|
||||
activity.key = activity.id;
|
||||
} else if (!activity.key) {
|
||||
if (!activity.key) {
|
||||
activity.key = uuid();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user