forked from kubev2v/forklift-console-plugin
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactoring: replace plan phases strigs with const enums
Reference: kubev2v#1395 (comment) Signed-off-by: Sharon Gratch <[email protected]>
- Loading branch information
Showing
14 changed files
with
94 additions
and
113 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 0 additions & 30 deletions
30
packages/forklift-console-plugin/src/modules/Plans/utils/helpers/getPhaseLabel.ts
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 0 additions & 1 deletion
1
packages/forklift-console-plugin/src/modules/Plans/utils/helpers/index.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,6 @@ | ||
// @index(['./*', /style/g], f => `export * from '${f.path}';`) | ||
export * from './getMigrationPhase'; | ||
export * from './getMigrationVmsCounts'; | ||
export * from './getPhaseLabel'; | ||
export * from './getPlanPhase'; | ||
export * from './getPlanProgressVariant'; | ||
// @endindex |
39 changes: 26 additions & 13 deletions
39
packages/forklift-console-plugin/src/modules/Plans/utils/types/PlanPhase.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,26 @@ | ||
export type PlanPhase = | ||
| 'Error' | ||
| 'vmError' | ||
| 'Unknown' | ||
| 'Archiving' | ||
| 'Archived' | ||
| 'Failed' | ||
| 'Canceled' | ||
| 'Succeeded' | ||
| 'Running' | ||
| 'Ready' | ||
| 'Warning' | ||
| 'NotReady'; | ||
export enum PlanPhase { | ||
// t('Error') | ||
Error = 'Error', | ||
// t('Some VMs Failed') | ||
vmError = 'Some VMs Failed', | ||
// t('Unknown') | ||
Unknown = 'Unknown', | ||
// t('Archiving') | ||
Archiving = 'Archiving', | ||
// t('Archived') | ||
Archived = 'Archived', | ||
// t('Failed') | ||
Failed = 'Failed', | ||
// t('Canceled') | ||
Canceled = 'Canceled', | ||
// t('Succeeded') | ||
Succeeded = 'Succeeded', | ||
// t('Running') | ||
Running = 'Running', | ||
// t('Ready') | ||
Ready = 'Ready', | ||
// t('Warning') | ||
Warning = 'Warning', | ||
// t('Not Ready') | ||
NotReady = 'Not Ready', | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.