From 76aa50cfb9725d0399212c3c8b9e001e82811aa8 Mon Sep 17 00:00:00 2001 From: gaoluyang <2820782392@qq.com> Date: 星期一, 07 七月 2025 18:09:47 +0800 Subject: [PATCH] 下单拆分为3个 --- src/views/business/inspectionTask/components/InspectionWord.vue | 51 +++++++++++++++++++++++++++++++++------------------ 1 files changed, 33 insertions(+), 18 deletions(-) diff --git a/src/views/business/inspectionTask/components/InspectionWord.vue b/src/views/business/inspectionTask/components/InspectionWord.vue index 3a169e1..7abe3b0 100644 --- a/src/views/business/inspectionTask/components/InspectionWord.vue +++ b/src/views/business/inspectionTask/components/InspectionWord.vue @@ -17,8 +17,8 @@ </el-radio-group> </div> <div style="display: flex;align-items: center;"> - <span v-if="typeSource == '1'"> 澶嶆祴娆℃暟锛�</span> - <el-select v-if="typeSource == '1'" v-model="retestTag" placeholder="璇烽�夋嫨" size="small" + <span> 澶嶆祴娆℃暟锛�</span> + <el-select v-model="retestTag" placeholder="璇烽�夋嫨" size="small" @change="m => handleChangeCableTag(currentSample.id, 4, 'cableTag', m)"> <el-option v-for="item in unPassNumList" :key="item.retestTag" :label="item.retestTag" :value="item.retestTag"> @@ -198,6 +198,11 @@ <td :rowspan="item.child.length">{{ item.faName }}</td> <td>{{ item.child[0].name }}</td> <td style="text-align: left;"> + <!-- <div v-for="(group, groupIndex) in groupByFive(item.child[0].arr)" :key="groupIndex"> + <el-checkbox-group v-model="getDataIndex" :max="item.child[0].maxNum"> + <el-checkbox v-for="(n, j) in group" :key="groupIndex * 5 + j" :label="groupIndex * 5 + j">{{ n }}</el-checkbox> + </el-checkbox-group> + </div> --> <el-checkbox-group v-model="getDataIndex" :max="item.child[0].maxNum"> <el-checkbox v-for="(n, j) in item.child[0].arr" :key="j" :label="j">{{ n }}</el-checkbox> </el-checkbox-group> @@ -206,8 +211,14 @@ <tr v-for="(m, i) in item.child" v-show="i > 0" :key="i + 'bbbbbbbbbbbbbb'"> <td>{{ m.name }}</td> <td style="text-align: left;"> + + <!-- <div v-for="(group, groupIndex) in groupByFive(m.arr)" :key="groupIndex"> + <el-checkbox-group v-model="getDataIndex" :max="m.maxNum"> + <el-checkbox v-for="(n, j) in group" :key="groupIndex * 5 + j" :label="groupIndex * 5 + j">{{ n }}</el-checkbox> + </el-checkbox-group> + </div> --> <el-checkbox-group v-model="getDataIndex" :max="m.maxNum"> - <el-checkbox v-for="(n, j) in m.arr" :key="j" :label="j">{{ n }}</el-checkbox> + <el-checkbox v-for="(n, j) in m.arr" :key="j" :label="j" >{{ n }}</el-checkbox> </el-checkbox-group> </td> </tr> @@ -241,8 +252,6 @@ </template> <script> -// import ValueTable from '../../tool/value-table.vue' -import file from '@/utils/file' import excelFunction from '@/utils/excelFountion' import UnPassDialog from "@/views/business/unpass/components/unPassDialog.vue"; import AddUnPass from "@/views/business/unpass/components/addUnPass.vue"; @@ -255,8 +264,10 @@ verifyPlan } from "@/api/business/inspectionTask"; import { getUserNow, saveUnqualifiedContext } from "@/api/business/rawMaterialOrder"; +import InspectionWorker from '@/workers/InspectionWorker.worker'; +import DataWorker from '@/workers/DataWorker.worker'; export default { - props: ['sonLaboratory', 'orderId', 'state', 'inspectorList', 'typeSource', 'unPassCheck', 'rawMaterialTag'], + props: ['sonLaboratory', 'orderId', 'state', 'inspectorList', 'typeSource', 'unPassCheck', 'rawMaterialTag','cableTag', 'repetitionTag'], components: { AddUnPass, UnPassDialog @@ -429,7 +440,7 @@ getDataTypeId: '', getDataType: null, unPassDialog: false, // 涓嶅悎鏍煎鐞嗗脊妗� - retestTag: '', // 澶嶆祴娆℃暟 + retestTag: '1', // 澶嶆祴娆℃暟 addCheck: false, // 鎸囧畾瀹℃牳浜哄憳寮规 checkUser: '', type: '', @@ -516,7 +527,7 @@ } } }) - await this.determineWhetherToCollectData()//鏄惁闇�瑕佹暟閲� + // await this.determineWhetherToCollectData()//鏄惁闇�瑕佹暟閲� if (this.currentSample.index == undefined) this.currentSample['index'] = 1 let bushing = this.currentSample.bushing this.getTableLists();//澶勭悊妯℃澘鍒楄〃淇℃伅 @@ -819,12 +830,12 @@ this.stopWorker(); // 纭繚涔嬪墠鐨� Worker 宸插仠姝� } // 鍒涘缓 Worker 瀹炰緥 - this.worker = new Worker('/static/js/worker.js'); + this.worker = new InspectionWorker(); if (this.worker0) { this.stopWorker(); // 纭繚涔嬪墠鐨� Worker 宸插仠姝� } // 鍒涘缓 Worker 瀹炰緥 - this.worker0 = new Worker('/static/js/worker0.js'); + this.worker0 = new DataWorker(); }, // 鍋滄澶氱嚎绋� stopWorker() { @@ -848,8 +859,11 @@ laboratory: this.sonLaboratory, retestTag: this.retestTag, rawMaterialTag: this.rawMaterialTag, + repetitionTag: this.repetitionTag, + cableTag: this.cableTag, } - let res = getInsProductUnqualifiedRetest(params) + let res = await getInsProductUnqualifiedRetest(params) + console.log('res---', res) if (res.code === 200 && res.data.length > 0) { this.tableLoading = false; this.scrollInit() @@ -1283,7 +1297,8 @@ } }) // 浠ヤ笅鏄牱寮忓鐞嗛�昏緫 - set = Array.sort(set) + // set = Array.sort(set) + set = [...set] set.forEach(b => { let arr = [] a.template.forEach(c => { @@ -1479,10 +1494,10 @@ }, 200) }, // 鏄惁闇�瑕佹暟閲� - async determineWhetherToCollectData() { - let res = determineWhetherToCollectData({ managementNumber: '' }) - this.isGet = res.data - }, + // async determineWhetherToCollectData() { + // let res = determineWhetherToCollectData({ managementNumber: '' }) + // this.isGet = res.data + // }, // 鏍规嵁鍚庣浼犲弬鏇存柊椤甸潰鏁版嵁 param => this.tableList[0].insProductResult getCurrentInsProduct(pId) { if (!this.tableList[0].insProductResult) { @@ -1921,7 +1936,7 @@ } }, getAuthorizedPerson() { - selectUserCondition({ type: 0 }).then((res) => { + selectUserCondition({ type: 1 }).then((res) => { let data = []; res.data.forEach((a) => { data.push({ @@ -2033,7 +2048,7 @@ downFile({ id: row.id, }).then(res => { - this.$download.downloadFileFromUrl(res.data.fileUrl, row.fileName); + this.$download.saveAs(res.data.fileUrl, row.fileName); }).catch(error => { }) -- Gitblit v1.9.3