mirror of
https://github.com/harvester/harvester-ui-extension.git
synced 2026-10-01 03:36:04 +08:00
feat: Allow user to customize snapshot/backup deadline (#866)
* feat: Allow user to customize snapshot/backup deadline Related to: https://github.com/harvester/harvester/issues/4098 Related to: https://github.com/harvester/harvester/pull/10545 Signed-off-by: Volker Theile <vtheile@suse.com> * feat: Allow user to customize snapshot/backup deadline Related to: https://github.com/harvester/harvester/issues/4098 Related to: https://github.com/harvester/harvester/pull/10545 Signed-off-by: Volker Theile <vtheile@suse.com> --------- Signed-off-by: Volker Theile <vtheile@suse.com>
This commit is contained in:
@@ -0,0 +1,43 @@
|
||||
export const DEFAULT_FS_FREEZE_DEADLINE = '1s';
|
||||
|
||||
/**
|
||||
* Generate filesystem freeze deadline options with i18n translations
|
||||
* @param {Function} t - i18n translation function
|
||||
* @returns {Array} Array of deadline options
|
||||
*/
|
||||
export function getFsFreezeDeadlineOptions(t) {
|
||||
return [
|
||||
{
|
||||
label: t('generic.duration.infinite'),
|
||||
value: '0s'
|
||||
},
|
||||
{
|
||||
label: t('generic.duration.1s'),
|
||||
value: '1s'
|
||||
},
|
||||
{
|
||||
label: t('generic.duration.5s'),
|
||||
value: '5s'
|
||||
},
|
||||
{
|
||||
label: t('generic.duration.10s'),
|
||||
value: '10s'
|
||||
},
|
||||
{
|
||||
label: t('generic.duration.30s'),
|
||||
value: '30s'
|
||||
},
|
||||
{
|
||||
label: t('generic.duration.1m'),
|
||||
value: '1m'
|
||||
},
|
||||
{
|
||||
label: t('generic.duration.3m'),
|
||||
value: '3m'
|
||||
},
|
||||
{
|
||||
label: t('generic.duration.5m'),
|
||||
value: '5m'
|
||||
}
|
||||
];
|
||||
}
|
||||
Reference in New Issue
Block a user