mirror of
https://github.com/1Panel-dev/1Panel.git
synced 2024-12-18 19:39:29 +08:00
fix: 修改应用删除文字
This commit is contained in:
parent
e45f5e3369
commit
e5da0736a6
@ -725,7 +725,7 @@ export default {
|
|||||||
name: '名称',
|
name: '名称',
|
||||||
description: '描述',
|
description: '描述',
|
||||||
delete: '删除',
|
delete: '删除',
|
||||||
deleteWarn: '删除操作会把数据一并删除,此操作不可回滚,是否继续?',
|
deleteWarn: '删除操作会把所有数据和备份一并删除,此操作不可回滚,是否继续?',
|
||||||
syncSuccess: '同步成功',
|
syncSuccess: '同步成功',
|
||||||
canUpdate: '可升级',
|
canUpdate: '可升级',
|
||||||
backup: '备份',
|
backup: '备份',
|
||||||
|
@ -131,6 +131,7 @@ import { ElMessage, ElMessageBox } from 'element-plus';
|
|||||||
import Backups from './backups.vue';
|
import Backups from './backups.vue';
|
||||||
import AppResources from './check/index.vue';
|
import AppResources from './check/index.vue';
|
||||||
import { App } from '@/api/interface/app';
|
import { App } from '@/api/interface/app';
|
||||||
|
import { useDeleteData } from '@/hooks/use-delete-data';
|
||||||
|
|
||||||
let data = ref<any>();
|
let data = ref<any>();
|
||||||
let loading = ref(false);
|
let loading = ref(false);
|
||||||
@ -188,12 +189,12 @@ const openOperate = (row: any, op: string) => {
|
|||||||
open.value = true;
|
open.value = true;
|
||||||
});
|
});
|
||||||
} else if (op == 'delete') {
|
} else if (op == 'delete') {
|
||||||
AppInstalledDeleteCheck(row.id).then((res) => {
|
AppInstalledDeleteCheck(row.id).then(async (res) => {
|
||||||
const items = res.data;
|
const items = res.data;
|
||||||
if (res.data && res.data.length > 0) {
|
if (res.data && res.data.length > 0) {
|
||||||
checkRef.value.acceptParams({ items: items });
|
checkRef.value.acceptParams({ items: items });
|
||||||
} else {
|
} else {
|
||||||
onOperate(op);
|
await useDeleteData(InstalledOp, operateReq, 'app.deleteWarn');
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
@ -228,16 +229,7 @@ const onOperate = async (operation: string) => {
|
|||||||
type: 'info',
|
type: 'info',
|
||||||
},
|
},
|
||||||
).then(() => {
|
).then(() => {
|
||||||
open.value = false;
|
operate();
|
||||||
loading.value = true;
|
|
||||||
InstalledOp(operateReq)
|
|
||||||
.then(() => {
|
|
||||||
ElMessage.success(i18n.global.t('commons.msg.operationSuccess'));
|
|
||||||
search();
|
|
||||||
})
|
|
||||||
.finally(() => {
|
|
||||||
loading.value = false;
|
|
||||||
});
|
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user