From ddc1f15431955e7b4e5b61d76830efb96fc3ed5e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=91=A3=E5=93=B2=E5=A5=87?= <13840175730@139.com> Date: Sun, 1 Dec 2024 21:44:43 +0800 Subject: [PATCH] =?UTF-8?q?1.=E6=8A=9B=E4=B8=B8=E5=8F=8D=E9=A6=88=E5=A2=9E?= =?UTF-8?q?=E5=8A=A0excle=E5=AF=BC=E5=85=A5=E6=96=B9=E5=BC=8F=E5=8F=8D?= =?UTF-8?q?=E9=A6=88=E5=8A=9F=E8=83=BD=202.=E5=A2=9E=E5=8A=A0=E7=89=A9?= =?UTF-8?q?=E6=96=99=E5=8F=B7=E5=92=8C=E5=86=85=E7=A0=81=E5=AF=BC=E5=87=BA?= =?UTF-8?q?=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/jhzxgl/pwjhD.vue | 53 ++++++++++++++------ src/views/zyjhzx/pwanpgong/comps/PwanPgd.vue | 1 - src/views/zyjhzx/pwanpgong/comps/PwanSgd.vue | 4 +- src/views/zyjhzx/pwanpgong/comps/pgdTable.js | 4 +- src/views/zyjhzx/sliao/index.vue | 2 + 5 files changed, 45 insertions(+), 19 deletions(-) diff --git a/src/views/jhzxgl/pwjhD.vue b/src/views/jhzxgl/pwjhD.vue index 0da62a4..90cd2ae 100644 --- a/src/views/jhzxgl/pwjhD.vue +++ b/src/views/jhzxgl/pwjhD.vue @@ -80,14 +80,7 @@ - - - - - - - 作业区: 批量--> - + 派工 报工 - - + + + + excel报工 + + @@ -236,7 +238,8 @@ export default { }, list: [], heads: { token: getToken() }, - uploadAction: process.env.VUE_APP_BASE_API + '/dmCzplpNew/uploadPl', + uploadAction: process.env.VUE_APP_BASE_API + '/zyjh/pwdr', + fileList: {}, dictData:{}, height: '500px', projectData:[], @@ -388,12 +391,32 @@ export default { window.addEventListener('resize', this.getHeight) this.getHeight() this.initBase() - - - - }, methods: { + uploadExcel() { + + }, + beforeAvatarUpload(file) { + // 文件类型 + console.debug(file.type) + const isType = file.type === 'application/vnd.ms-excel' + const isTypeComputer = file.type === 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet' + const fileType = isType || isTypeComputer + startLoading() + return fileType + }, + handleAvatarSuccess(res, file) { + endLoading() + if (res.success) { + this.$message({ message: '导入成功', type: 'success' }) + } else { + Message({ + message: res.message || 'Error', + type: 'error', + duration: 5 * 1000 + }) + } + }, headerCellStyle ({ column, columnIndex }) { if (['pwry','pwpgrq','pwpgry','pwfkry','pwfkrq'].includes(column.property)) { return { diff --git a/src/views/zyjhzx/pwanpgong/comps/PwanPgd.vue b/src/views/zyjhzx/pwanpgong/comps/PwanPgd.vue index e78ada3..3dcdfc6 100644 --- a/src/views/zyjhzx/pwanpgong/comps/PwanPgd.vue +++ b/src/views/zyjhzx/pwanpgong/comps/PwanPgd.vue @@ -127,7 +127,6 @@ export default { } }, checkboxChange({checked,row}){ - console.log(row) if (!this.privateCheck(checked)){ this.$refs.vxeGrid.setAllCheckboxRow(!checked); return diff --git a/src/views/zyjhzx/pwanpgong/comps/PwanSgd.vue b/src/views/zyjhzx/pwanpgong/comps/PwanSgd.vue index 36646b1..01a5f41 100644 --- a/src/views/zyjhzx/pwanpgong/comps/PwanSgd.vue +++ b/src/views/zyjhzx/pwanpgong/comps/PwanSgd.vue @@ -94,8 +94,8 @@ export default { _item[fields[i]]=item[i] } _item.序号=index+1 - _item.分段=item.fd - _item.套料图号=item.tlth + // _item.分段=item.fd + // _item.套料图号=item.tlth for (const dw of this.gridOptions.ycldw) { if (item.dwId===dw.id){ _item.垛位=dw.name diff --git a/src/views/zyjhzx/pwanpgong/comps/pgdTable.js b/src/views/zyjhzx/pwanpgong/comps/pgdTable.js index 66dd82c..0bdfd5b 100644 --- a/src/views/zyjhzx/pwanpgong/comps/pgdTable.js +++ b/src/views/zyjhzx/pwanpgong/comps/pgdTable.js @@ -58,7 +58,9 @@ export default function (_height=0) { {field: 'fd', title: '分段',visible:false}, {field: 'tlth', title: '套料图号',visible:false}, {field: 'wpgg', title: '物品规格', }, - {field: '', title: '抛丸',visible:false }, + {field: 'wlh', title: '物料号', }, + {field: 'nm', title: '内码',visible:false }, + {field: '', title: '备注',visible:false }, ] return { diff --git a/src/views/zyjhzx/sliao/index.vue b/src/views/zyjhzx/sliao/index.vue index 3df6c22..f2fe0fc 100644 --- a/src/views/zyjhzx/sliao/index.vue +++ b/src/views/zyjhzx/sliao/index.vue @@ -389,6 +389,8 @@ export default { wpgg:item.wpgg, sljhrq:item.sljhrq, qgjhrq:item.qgjhrq, + wlh:item.slwlh, + nm:item.nm, bfr:that.getCurrentWorker()?.userCode, type:'YCL' }