From 137a82ff06d2cfa90de33e32559642a5f547d7e7 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, 4 Feb 2024 13:02:54 +0800 Subject: [PATCH] =?UTF-8?q?1.=E6=A0=B9=E6=8D=AE=E6=95=B0=E6=8D=AE=E5=BA=93?= =?UTF-8?q?=E8=A1=A8=E7=BB=93=E6=9E=84=E5=8F=98=E5=8C=96=E4=BF=AE=E6=AD=A3?= =?UTF-8?q?=E4=BB=A3=E7=A0=81=E9=80=BB=E8=BE=91=202.=E4=BF=AE=E5=A4=8Dbug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/jhzxgl/ypp.js | 2 + src/views/jhzxgl/components/QfxqzxPrint.vue | 74 +++++++++------------ src/views/jhzxgl/components/Yppfk0.vue | 6 +- 3 files changed, 39 insertions(+), 43 deletions(-) diff --git a/src/api/jhzxgl/ypp.js b/src/api/jhzxgl/ypp.js index f57984a..5735410 100644 --- a/src/api/jhzxgl/ypp.js +++ b/src/api/jhzxgl/ypp.js @@ -31,3 +31,5 @@ export function checkBfwz(data) {return request({url: '/ypp/checkBfwz', method: export function yppZx(data) {return request({url: '/ypp/zx', method: 'post', data})} export function yppQr(data) {return request({url: '/ypp/qr', method: 'post', data})} + +export function yppQtcj(data) {return request({url: '/ypp/qtjc', method: 'post', data})} diff --git a/src/views/jhzxgl/components/QfxqzxPrint.vue b/src/views/jhzxgl/components/QfxqzxPrint.vue index ed617ed..228efab 100644 --- a/src/views/jhzxgl/components/QfxqzxPrint.vue +++ b/src/views/jhzxgl/components/QfxqzxPrint.vue @@ -4,34 +4,26 @@
大连船舶重工集团钢加有限公司
配送交接单
-
编号: {{ map.bh }}
+
船号: {{ map.dcCh }}
序号 船号 - 批号 - 托盘表号 - 附件名称 - 图号/规格 + 批量 + 图号 + 物品名称 + 规格 材质 - 数量 - 入库地点
- {{ item.jhxh }} - {{ item.czbh }} - {{ item.ph }} - {{ item.tpbh }} - {{ item.wpmc }} + {{ index+1 }} + {{ item.dcCh }} + {{ item.dcPl }} + {{ item.dcTh }} + {{ item.wpmc }} {{ item.wpgg }} {{ item.wpxh }} - {{ item.pssl }} - {{ item.ckh }}
- 交货人: {{ map.psry }} - - - 合计: {{ map.count }}
@@ -41,7 +33,7 @@ 收货人:
-
+
@@ -59,33 +51,33 @@ export default { show(_data){ //手动按行换页计算 //每页行数 - const pageSize=7; + const pageSize=30; const tmpData=[] + const groupData=this.group(_data,(item)=>{ + return item.dcCh + }) - // for (const item of _data) { - // if (item.list.length>pageSize){ - // const _arr=this.sliceToPage(item.list,pageSize); - // for (const _item of _arr) { - // const tmpItem=JSON.parse(JSON.stringify(item)) - // tmpItem.list=_item - // const o=pageSize-_item.length - // for(let i=0;i{ + const item=groupData[key] + const map={ + dcCh:key.replaceAll('"',''), + list:item, + count:item.length + } + tmpData.push(map) + }) this.data=tmpData this.$emit('showPrintComp') }, + group(list, fn){ + const groups = {}; + list.forEach(function (o) { + const group = JSON.stringify(fn(o)); + groups[group] = groups[group] || []; + groups[group].push(o); + }); + return groups; + }, sliceToPage(data,len){ let index=0,_newArr=[] while (index import {getQfxq} from "@/api/jhzx/qfxq"; -import {getBfwz, getList, getPpxx} from "@/api/jhzxgl/ypp"; +import {getBfwz, getList, getPpxx, yppQtcj} from "@/api/jhzxgl/ypp"; export default { name: "Yppfk0", @@ -276,7 +276,9 @@ export default { this.$message.warning("请先选择需要检查的数据") return; } - + yppQtcj(data).then(res=>{ + this.$message.success("检查成功") + }) }, getSelectQfxq(){ return this.$refs.xqjhTableRef.getCheckboxRecords();