|
@@ -34,6 +34,7 @@
|
|
|
<script setup>
|
|
|
import { onActivated, ref } from 'vue'
|
|
|
import { deepClone, formValidate, getArrValue, isNullES } from 'js-fast-way'
|
|
|
+import { HcDelMsg } from 'hc-vue3-ui'
|
|
|
import mainApi from '~api/desk/test-collect'
|
|
|
|
|
|
//激活
|
|
@@ -109,6 +110,7 @@ const rowInfoSubmit = async () => {
|
|
|
if (!isRes) return
|
|
|
window.$message.success('操作成功')
|
|
|
rowInfoClose()
|
|
|
+ getTableData().then()
|
|
|
}
|
|
|
|
|
|
//关闭表单
|
|
@@ -120,7 +122,13 @@ const rowInfoClose = () => {
|
|
|
|
|
|
//删除
|
|
|
const delRowClick = (item) => {
|
|
|
- console.log(item)
|
|
|
+ HcDelMsg(async (resolve) => {
|
|
|
+ const { isRes } = await mainApi.del(item.id)
|
|
|
+ resolve() //关闭弹窗的回调
|
|
|
+ if (!isRes) return
|
|
|
+ window.$message.success('删除成功')
|
|
|
+ getTableData().then()
|
|
|
+ })
|
|
|
}
|
|
|
</script>
|
|
|
|