二次确认

This commit is contained in:
2025-10-14 10:52:52 +08:00
parent 2deaf048e7
commit 734fe88f14
9 changed files with 153 additions and 72 deletions

View File

@@ -74,6 +74,7 @@
<script>
import NavBar from '@/components/NavBar.vue'
import SearchBox from '@/components/SearchBox.vue'
import { confirmAction } from '@/utils/utils.js'
import {getNextRegions, selectMaterials, blanking} from '@/utils/getData4.js'
export default {
components: {
@@ -229,14 +230,22 @@
this.val1 = ''
this.index = ''
this.dataList = []
this.pkId = ''
this.pkObj = {}
this.currentData = {}
this.disabled = false
},
async handleConfirm() {
if (!this.val1 || !this.dataList.length || !this.index) {
return
}
const isConfirmed = await confirmAction("确认操作", "确定要执行此操作吗?")
if (isConfirmed) {
this._blanking()
}
},
async _blanking () {
this.disabled = true
if (!this.val1 || !this.dataList.length || !this.index) {
this.disabled = false
return
}
try {
let res = await blanking(this.val1, this.dataList, this.index)
if (res.code === '200') {