File tree 1 file changed +13
-14
lines changed
packages/forklift-console-plugin/src/modules/Plans/views/list/components 1 file changed +13
-14
lines changed Original file line number Diff line number Diff line change @@ -30,7 +30,6 @@ export const PlanStatusCell: React.FC<CellProps> = ({ data }) => {
30
30
const { showModal } = useModal ( ) ;
31
31
const plan = data ?. obj ;
32
32
33
- const vms = plan ?. spec ?. vms ;
34
33
const vmStatuses = plan ?. status ?. migration ?. vms ;
35
34
const [ lastMigration ] = usePlanMigration ( plan ) ;
36
35
@@ -101,7 +100,7 @@ export const PlanStatusCell: React.FC<CellProps> = ({ data }) => {
101
100
) }
102
101
103
102
< Split hasGutter >
104
- { vmCount ? .success > 0 && (
103
+ { vmCount . success > 0 && (
105
104
< SplitItem >
106
105
< PlanStatusVmCount
107
106
count = { vmCount . success }
@@ -111,19 +110,19 @@ export const PlanStatusCell: React.FC<CellProps> = ({ data }) => {
111
110
</ SplitItem >
112
111
) }
113
112
114
- { phase !== PlanPhase . Running &&
115
- phase !== PlanPhase . NotReady &&
116
- vms ?. length &&
117
- ! vmCount ?. error &&
118
- ! vmCount . success && (
119
- < SplitItem >
120
- < PlanStatusVmCount count = { vms . length } status = "warning" linkPath = { vmCountLinkPath } />
121
- </ SplitItem >
122
- ) }
123
-
124
- { vmCount ?. error > 0 && (
113
+ { vmCount . canceled > 0 && (
125
114
< SplitItem >
126
- < PlanStatusVmCount count = { vmCount ?. error } status = "danger" linkPath = { vmCountLinkPath } />
115
+ < PlanStatusVmCount
116
+ count = { vmCount . canceled }
117
+ status = "warning"
118
+ linkPath = { vmCountLinkPath }
119
+ />
120
+ </ SplitItem >
121
+ ) }
122
+
123
+ { vmCount . error > 0 && (
124
+ < SplitItem >
125
+ < PlanStatusVmCount count = { vmCount . error } status = "danger" linkPath = { vmCountLinkPath } />
127
126
</ SplitItem >
128
127
) }
129
128
</ Split >
You can’t perform that action at this time.
0 commit comments