Commit 2441bced authored by 赵伟庚's avatar 赵伟庚

fix:启禁用失败时恢复初始状态

parent 4f3d7fc4
......@@ -34,7 +34,7 @@
v-if="isIndex"
type="index"
:label="indexLabel"
width="80"
width="54"
align="left"
>
<!-- 序号 -->
......
......@@ -378,6 +378,7 @@ const changeUseRow = (row) => {
changePage(1)
}else {
ElMessage.error(res.data.data)
row.state = row.state == 0 ? 1 : 0
}
})
} // 启用禁用
......
......@@ -387,9 +387,11 @@ import CryptoJS from "crypto-js";
)
.then((res) => {
if (res.data.code == 200) {
$message.success(res.data.msg)
getTableRows()
}else {
$message.error(res.data.data)
row.state = row.state == 0 ? 1 : 0
}
})
}
......
......@@ -741,9 +741,11 @@ import { downloadFileFormatNew } from '@/services/helper'
)
.then((res) => {
if (res.data.code == 200) {
$message.success(res.data.msg)
getTableRows()
}else {
$message.error(res.data.data)
row.state = row.state == 0 ? 1 : 0
}
})
}
......
......@@ -350,6 +350,7 @@ const changeUseRow = (row) => {
changePage(1)
}else {
ElMessage.error(res.data.data)
row.state = row.state == 0 ? 1 : 0
}
})
} // 更改启用禁用状态
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment