mirror of
https://github.com/harvester/harvester-ui-extension.git
synced 2026-10-01 03:36:04 +08:00
feat: display message from MIG status and change the state to match the case (#879)
Signed-off-by: Jack Yu <jack.yu@suse.com>
This commit is contained in:
@@ -63,13 +63,27 @@ export default class MIGCONFIGURATION extends HarvesterResource {
|
||||
}
|
||||
|
||||
get stateDisplay() {
|
||||
if (this.configStatus === 'out-of-sync') {
|
||||
return this.t('harvester.migconfiguration.status.outOfSync');
|
||||
}
|
||||
|
||||
return this.actualState;
|
||||
}
|
||||
|
||||
get stateColor() {
|
||||
const state = this.actualState;
|
||||
get stateDescription() {
|
||||
if (this.status?.message) {
|
||||
return this.status.message;
|
||||
}
|
||||
|
||||
return colorForState(state);
|
||||
return super.stateDescription;
|
||||
}
|
||||
|
||||
get stateColor() {
|
||||
if (this.configStatus === 'out-of-sync') {
|
||||
return 'text-warning';
|
||||
}
|
||||
|
||||
return colorForState(this.actualState);
|
||||
}
|
||||
|
||||
get isEnabled() {
|
||||
|
||||
Reference in New Issue
Block a user