fix: 修复删除之后模板依旧展示的问题

This commit is contained in:
Huangzhe
2025-03-22 18:49:48 +08:00
parent 71a51a5296
commit 40b1d7f267

View File

@@ -69,9 +69,9 @@ import png31 from '@/assets/img/home/31.png';
const router = useRouter();
const { info, marketItem } = defineProps({
info: {
type: Object,
type: Array,
required: true,
default: () => ({})
default: () => []
},
marketItem: {
type: Object,
@@ -102,6 +102,8 @@ const deleteItem = (item) => {
confirmButtonColor: '#03B03C'
})
.then(async () => {
info.splice(info.indexOf(item), 1);
const res = await deleteTemplate(item.sn);
if (res.data.code === 0) {
showSuccessToast('删除成功');