added "dire" mode to warning dialog and use it with license erase db

This commit is contained in:
2022-03-11 19:32:11 +00:00
parent b585edad6b
commit e1b146d1f2
3 changed files with 20 additions and 3 deletions

View File

@@ -25,6 +25,9 @@
<template v-if="options.type == 'error'">
<v-icon large color="error">$ayiExclamationTriangle</v-icon>
</template>
<template v-if="options.type == 'dire'">
<v-icon large color="error">$ayiSkullCrossbones</v-icon>
</template>
<span v-if="options.title" class="ml-5"> {{ options.title }} </span>
</v-card-title>
<!-- eslint-disable vue/no-v-html -->
@@ -52,7 +55,21 @@
@click.native="cancel"
>{{ options.noButtonText }}</v-btn
>
<v-btn
v-if="options.type == 'dire'"
class="ml-4"
color="error"
data-cy="gzconfirm:yesbutton"
@click.native="agree"
>
<v-icon left>$ayiSkullCrossbones</v-icon
>{{ options.yesButtonText }}
<v-icon right>$ayiSkullCrossbones</v-icon></v-btn
>
<v-btn
v-else
color="primary"
text
data-cy="gzconfirm:yesbutton"

View File

@@ -464,7 +464,7 @@ export default {
if (this.dbIsEmpty != true) {
let dialogResult = await window.$gz.dialog.confirmGeneric(
"AdminEraseDatabaseWarning",
"warning"
"dire"
);
if (dialogResult == false) {
return;
@@ -472,7 +472,7 @@ export default {
dialogResult = await window.$gz.dialog.confirmGeneric(
"AdminEraseDatabaseLastWarning",
"error"
"dire"
);
if (dialogResult == false) {
return;