diff --git a/src/views/zyjhzx/components/Drawer.vue b/src/views/zyjhzx/components/Drawer.vue index 7f6c120..e77dfd4 100644 --- a/src/views/zyjhzx/components/Drawer.vue +++ b/src/views/zyjhzx/components/Drawer.vue @@ -29,16 +29,16 @@ export default { handleSelect(key){ switch (key){ case '抛丸': - this.$router.push(`/pwpg?zyq=${this.$route.query.zyq}&zyType=${this.$route.query.zyType}&deviceId=${this.$route.query.deviceId}`) + this.$router.push(`/pwpg?zyq=${this.$route.query.zyq}&zyType=0&deviceId=${this.$route.query.deviceId}`) break; case '理料': - this.$router.push(`/llfk?zyq=${this.$route.query.zyq}&zyType=${this.$route.query.zyType}&deviceId=${this.$route.query.deviceId}`) + this.$router.push(`/llfk?zyq=${this.$route.query.zyq}&zyType=0&deviceId=${this.$route.query.deviceId}`) break; case '划线': - this.$router.push(`/hxpg?zyq=${this.$route.query.zyq}&zyType=${this.$route.query.zyType}&deviceId=${this.$route.query.deviceId}`) + this.$router.push(`/hxpg?zyq=${this.$route.query.zyq}&zyType=0&deviceId=${this.$route.query.deviceId}`) break; case '切割': - this.$router.push(`/qgpg?zyq=${this.$route.query.zyq}&zyType=${this.$route.query.zyType}&deviceId=${this.$route.query.deviceId}`) + this.$router.push(`/qgpg?zyq=${this.$route.query.zyq}&zyType=0&deviceId=${this.$route.query.deviceId}`) break; } } diff --git a/src/views/zyjhzx/hxianfkui/comps/HxianPgd.vue b/src/views/zyjhzx/hxianfkui/comps/HxianPgd.vue index e905d61..8e63320 100644 --- a/src/views/zyjhzx/hxianfkui/comps/HxianPgd.vue +++ b/src/views/zyjhzx/hxianfkui/comps/HxianPgd.vue @@ -60,7 +60,7 @@ export default { let ycldwInfo=null for (const dw of this.dw) { for (const info of dw.list) { - if (data.dcCh===info.czbh&&data.dcPl!==info.pl&&data.dcFd!==info.fd&&data.tzbh!==info.tlth){ + if (data.dcCh===info.czbh&&data.dcPl===info.pl&&data.dcFd===info.fd&&data.tzbh===info.tlth){ ycldwInfo=info break } @@ -78,18 +78,18 @@ export default { }).then(res=>{ if (res.success){ window.localStorage.removeItem('zyjh') - this.initData(data.pwry,'41') + this.initData(data.pwry,'51') } }) }, initData(worker,zt){ getDw({type:'llj'}).then(res=>{ this.gridOptions.ycldw=res.data - }) - getPgd2({user:worker}).then(res=>{ - this.list=res.data - this.gridOptions.data=res.data - this.setExt('workers',this.$props.workers) + getPgd({user:worker,zt:zt,field:'hxry'}).then(res=>{ + this.list=res.data + this.gridOptions.data=res.data + this.setExt('workers',this.$props.workers) + }) }) }, getCurrentData(){ diff --git a/src/views/zyjhzx/hxianfkui/comps/baifang.js b/src/views/zyjhzx/hxianfkui/comps/baifang.js index 290d1f9..f92d7ff 100644 --- a/src/views/zyjhzx/hxianfkui/comps/baifang.js +++ b/src/views/zyjhzx/hxianfkui/comps/baifang.js @@ -67,10 +67,16 @@ const baifang=function (option={}) { }) let _index=0 let touchingFlag=false; - group.on('mousedown touchstart',function (evt){ + group.on('mousedown touchstart',function ({evt}){ const layer=this.parent.parent.parent + + const {clientX:_x,clientY:_y}=evt + let x=_x,y=_y + if (evt.type==='touchstart'){ + x=evt.targetTouches[0].clientX + y=evt.targetTouches[0].clientY + } touchingFlag=true - const {x,y}=evt.evt setTimeout(()=>{ const moving=this.isDragging() if (!moving){ diff --git a/src/views/zyjhzx/hxianfkui/comps/dw.js b/src/views/zyjhzx/hxianfkui/comps/dw.js index cb5efc9..7e37b51 100644 --- a/src/views/zyjhzx/hxianfkui/comps/dw.js +++ b/src/views/zyjhzx/hxianfkui/comps/dw.js @@ -129,7 +129,7 @@ export default function (width,height,callback){ y:0, width: width, height: height, - fill:'black', + fill:'white', text:`${formatName()}\n${item.list.length}张`, align:'center', verticalAlign:'middle', diff --git a/src/views/zyjhzx/hxianfkui/comps/pgdTable.js b/src/views/zyjhzx/hxianfkui/comps/pgdTable.js index 07615b5..fad3bff 100644 --- a/src/views/zyjhzx/hxianfkui/comps/pgdTable.js +++ b/src/views/zyjhzx/hxianfkui/comps/pgdTable.js @@ -33,8 +33,6 @@ export default function () { return '' } const dwFormat=function ({cellValue}){ - console.log(cellValue) - console.log(options.ycldw) for (const item of options.ycldw) { if (cellValue===(item.id+"")){ for (const it of ycldw){ diff --git a/src/views/zyjhzx/hxianfkui/index.vue b/src/views/zyjhzx/hxianfkui/index.vue index ea2764c..be783e2 100644 --- a/src/views/zyjhzx/hxianfkui/index.vue +++ b/src/views/zyjhzx/hxianfkui/index.vue @@ -185,7 +185,7 @@ export default { const titel=drawTitle(this.width,this.height,this.title) const that=this - titel.on('click touch',function (){ + titel.on('click tap',function (){ console.log(111) that.$refs.drawer.show() }) diff --git a/src/views/zyjhzx/hxianpgong/comps/HxianPgd.vue b/src/views/zyjhzx/hxianpgong/comps/HxianPgd.vue index 50457e7..4cab718 100644 --- a/src/views/zyjhzx/hxianpgong/comps/HxianPgd.vue +++ b/src/views/zyjhzx/hxianpgong/comps/HxianPgd.vue @@ -80,7 +80,7 @@ export default { this.initData() }, checkboxAll({checked}) { - const worker = this.$props.worker + const worker = this.$props.worker() if (!worker) { this.$message.warning('请选择操作人') return; diff --git a/src/views/zyjhzx/hxianpgong/comps/dw.js b/src/views/zyjhzx/hxianpgong/comps/dw.js index 6444a33..df7cf7c 100644 --- a/src/views/zyjhzx/hxianpgong/comps/dw.js +++ b/src/views/zyjhzx/hxianpgong/comps/dw.js @@ -88,7 +88,7 @@ export default function (width,height){ y:0, width: width, height: height, - fill:'black', + fill:'white', text:`${formatName()}\n${item.list.length}张`, align:'center', verticalAlign:'middle', diff --git a/src/views/zyjhzx/hxianpgong/index.vue b/src/views/zyjhzx/hxianpgong/index.vue index a8abcb3..999812f 100644 --- a/src/views/zyjhzx/hxianpgong/index.vue +++ b/src/views/zyjhzx/hxianpgong/index.vue @@ -119,7 +119,7 @@ export default { const titel=drawTitle(this.width,this.height,this.title) const that=this - titel.on('click touch',function (){ + titel.on('click tap',function (){ console.log(111) that.$refs.drawer.show() }) diff --git a/src/views/zyjhzx/lliaofkui/comps/dw.js b/src/views/zyjhzx/lliaofkui/comps/dw.js index 1d0df9d..e2dd131 100644 --- a/src/views/zyjhzx/lliaofkui/comps/dw.js +++ b/src/views/zyjhzx/lliaofkui/comps/dw.js @@ -122,7 +122,7 @@ export default function (width,height,callback){ y:0, width: width, height: height, - fill:'black', + fill:'white', text:`${formatName()}\n${item.list.length}张`, align:'center', verticalAlign:'middle', diff --git a/src/views/zyjhzx/lliaofkui/index.vue b/src/views/zyjhzx/lliaofkui/index.vue index df8464a..b5255e8 100644 --- a/src/views/zyjhzx/lliaofkui/index.vue +++ b/src/views/zyjhzx/lliaofkui/index.vue @@ -85,20 +85,21 @@ export default { this.$message.warning('短号有重复,请使用全工单号重新派工!!!') return } + let index=0 for (const item of this.sljhItemList) { if (item.djh===data.djh||item.djh.slice(-djhWhLengh)===data.msg.orderNumber){ if (!!this.currentDw.tzbh&&item.kw===this.currentDw.tzbh){ const tmpZxData={ id:item.id, lldw:this.currentDw.id, - llcs:this.dw[that.currentDwIndex].list.length+1, + llcs:this.dw[this.currentDwIndex].list.length+1, llfkry:this.getCurrentWorker()?.userCode } const data={ ydjh:tmpZxData, ydid:item.id, dwId:this.currentDw.id, - ceng:this.dw[that.currentDwIndex].list.length+1, + ceng:this.dw[this.currentDwIndex].list.length+1, czbh:item.dcCh, pl:item.dcPl, fd:item.dcFd, @@ -115,14 +116,15 @@ export default { shangLiao(data).then(res=>{}) - this.sljhItemList.splice(this.getAttr('index'),1) + this.sljhItemList.splice(index,1) this.sljhGroup.destroyChildren() - this.drawSljhItem(that.sljhItemList) + this.drawSljhItem(this.sljhItemList) }else{ - that.$message.warning(`理料垛位错误,请放入${that.kwNameFormat(item.kw)}所在垛位`) + this.$message.warning(`理料垛位错误,请放入${this.kwNameFormat(item.kw)}所在垛位`) } break } + index++ } } }, @@ -209,8 +211,6 @@ export default { that.initPgd(list[i]) }) qyGroup.on('mousedown touchstart',function ({evt}){ - console.log(111) - console.log(evt) const worker=that.currentWorker; if (!that.canSl||!worker){ return @@ -373,8 +373,7 @@ export default { const titel=drawTitle(this.width,this.height,this.title) const that=this - titel.on('click touch',function (){ - console.log(111) + titel.on('click tap',function (){ that.$refs.drawer.show() }) this.layer.add(titel) diff --git a/src/views/zyjhzx/lliaopgong/comps/dw.js b/src/views/zyjhzx/lliaopgong/comps/dw.js index 7729d51..3018130 100644 --- a/src/views/zyjhzx/lliaopgong/comps/dw.js +++ b/src/views/zyjhzx/lliaopgong/comps/dw.js @@ -88,7 +88,7 @@ export default function (width,height){ y:0, width: width, height: height, - fill:'black', + fill:'white', text:`${formatName()}\n${item.list.length}张`, align:'center', verticalAlign:'middle', diff --git a/src/views/zyjhzx/pwanfkui/comps/PwanPgd.vue b/src/views/zyjhzx/pwanfkui/comps/PwanPgd.vue index 69e161f..bf280fa 100644 --- a/src/views/zyjhzx/pwanfkui/comps/PwanPgd.vue +++ b/src/views/zyjhzx/pwanfkui/comps/PwanPgd.vue @@ -60,9 +60,11 @@ export default { methods:{ baogong(tmpArr,data){ let ycldwInfo=null + console.log(data) + console.log(this.dw) for (const dw of this.dw) { for (const info of dw.list) { - if (data.dcCh===info.czbh&&data.dcPl!==info.pl&&data.dcFd!==info.fd&&data.tzbh!==info.tlth){ + if (data.dcCh===info.czbh&&data.dcPl===info.pl&&data.dcFd===info.fd&&data.tzbh===info.tlth){ ycldwInfo=info break } diff --git a/src/views/zyjhzx/pwanfkui/comps/baifang.js b/src/views/zyjhzx/pwanfkui/comps/baifang.js index a6417ab..e86e306 100644 --- a/src/views/zyjhzx/pwanfkui/comps/baifang.js +++ b/src/views/zyjhzx/pwanfkui/comps/baifang.js @@ -68,10 +68,16 @@ const baifang=function (option={}) { }) let _index=0 let touchingFlag=false; - group.on('mousedown touchstart',function (evt){ + group.on('mousedown touchstart',function ({evt}){ const layer=this.parent.parent.parent + + const {clientX:_x,clientY:_y}=evt + let x=_x,y=_y + if (evt.type==='touchstart'){ + x=evt.targetTouches[0].clientX + y=evt.targetTouches[0].clientY + } touchingFlag=true - const {x,y}=evt.evt setTimeout(()=>{ const moving=this.isDragging() if (!moving){ diff --git a/src/views/zyjhzx/pwanfkui/index.vue b/src/views/zyjhzx/pwanfkui/index.vue index 6c8e561..078f566 100644 --- a/src/views/zyjhzx/pwanfkui/index.vue +++ b/src/views/zyjhzx/pwanfkui/index.vue @@ -185,8 +185,7 @@ export default { const titel=drawTitle(this.width,this.height,this.title) const that=this - titel.on('click touch',function (){ - console.log(111) + titel.on('click tap',function (){ that.$refs.drawer.show() }) this.layer.add(titel) diff --git a/src/views/zyjhzx/pwanpgong/comps/dw.js b/src/views/zyjhzx/pwanpgong/comps/dw.js index 733ce05..1191133 100644 --- a/src/views/zyjhzx/pwanpgong/comps/dw.js +++ b/src/views/zyjhzx/pwanpgong/comps/dw.js @@ -80,7 +80,7 @@ export default function (width,height){ y:0, width: width, height: height, - fill:'black', + fill:'white', text:`${item.name}\n${item.list.length}张`, align:'center', verticalAlign:'middle', diff --git a/src/views/zyjhzx/pwanpgong/index.vue b/src/views/zyjhzx/pwanpgong/index.vue index f9d420c..a12977f 100644 --- a/src/views/zyjhzx/pwanpgong/index.vue +++ b/src/views/zyjhzx/pwanpgong/index.vue @@ -105,8 +105,7 @@ export default { const titel=drawTitle(this.width,this.height,this.title) const that=this - titel.on('click touch',function (){ - console.log(111) + titel.on('click tap',function (){ that.$refs.drawer.show() }) this.layer.add(titel) diff --git a/src/views/zyjhzx/qgefkui/comps/QgePgd.vue b/src/views/zyjhzx/qgefkui/comps/QgePgd.vue index aa58bad..978c2fc 100644 --- a/src/views/zyjhzx/qgefkui/comps/QgePgd.vue +++ b/src/views/zyjhzx/qgefkui/comps/QgePgd.vue @@ -65,18 +65,18 @@ export default { }, methods: { baogong(tmpArr,data){ + console.log(data) let ycldwInfo=null for (const dw of this.dw) { for (const info of dw.list) { - if (data.dcCh===info.czbh&&data.dcPl!==info.pl&&data.dcFd!==info.fd&&data.tzbh!==info.tlth){ + if (data.dcCh===info.czbh&&data.dcPl===info.pl&&data.dcFd===info.fd&&data.tzbh===info.tlth){ ycldwInfo=info break } } } if (!ycldwInfo){ - this.$message.warning(`理料垛位上板材与记录不符,需查验后再进行报工!`) - return; + ycldwInfo={} } zx({ field:'qgfkrq', @@ -86,20 +86,20 @@ export default { }).then(res=>{ if (res.success){ window.localStorage.removeItem('zyjh') - this.initData(data.pwry,'51') + this.initData(data.qgry,'61') } }) }, initData(worker, zt) { - getDw({type:'llj'}).then(res=>{ - this.gridOptions.ycldw=res.data - }) this.currentWorker=worker this.zt=zt - getPgd2({user: worker}).then(res => { - this.list=res.data - this.gridOptions.data = res.data - this.setExt('workers',this.$props.workers) + getDw({type:'llj'}).then(res=>{ + this.gridOptions.ycldw=res.data + getPgd({user:worker,zt:zt,field:'qgry'}).then(res => { + this.list=res.data + this.gridOptions.data = res.data + this.setExt('workers',this.$props.workers) + }) }) }, getCurrentData() { diff --git a/src/views/zyjhzx/qgefkui/comps/baifang.js b/src/views/zyjhzx/qgefkui/comps/baifang.js index 61f5c80..adf4482 100644 --- a/src/views/zyjhzx/qgefkui/comps/baifang.js +++ b/src/views/zyjhzx/qgefkui/comps/baifang.js @@ -67,10 +67,16 @@ const baifang=function (option={}) { }) let _index=0 let touchingFlag=false; - group.on('mousedown touchstart',function (evt){ + group.on('mousedown touchstart',function ({evt}){ const layer=this.parent.parent.parent + + const {clientX:_x,clientY:_y}=evt + let x=_x,y=_y + if (evt.type==='touchstart'){ + x=evt.targetTouches[0].clientX + y=evt.targetTouches[0].clientY + } touchingFlag=true - const {x,y}=evt.evt setTimeout(()=>{ const moving=this.isDragging() if (!moving){ diff --git a/src/views/zyjhzx/qgefkui/comps/dw.js b/src/views/zyjhzx/qgefkui/comps/dw.js index 2ff355d..50f6c27 100644 --- a/src/views/zyjhzx/qgefkui/comps/dw.js +++ b/src/views/zyjhzx/qgefkui/comps/dw.js @@ -130,7 +130,7 @@ export default function (width,height,callback){ y:0, width: width, height: height, - fill:'black', + fill:'white', text:`${formatName()}\n${item.list.length}张`, align:'center', verticalAlign:'middle', diff --git a/src/views/zyjhzx/qgefkui/comps/pgdTable.js b/src/views/zyjhzx/qgefkui/comps/pgdTable.js index 460f8c4..5a1ba47 100644 --- a/src/views/zyjhzx/qgefkui/comps/pgdTable.js +++ b/src/views/zyjhzx/qgefkui/comps/pgdTable.js @@ -19,7 +19,6 @@ export default function () { } const nameFormat=function ({cellValue}){ - console.log(ext) const workers=ext.workers for (const item of workers) { if(item.userCode===cellValue){ diff --git a/src/views/zyjhzx/qgefkui/index.vue b/src/views/zyjhzx/qgefkui/index.vue index e4a5fb0..29e7665 100644 --- a/src/views/zyjhzx/qgefkui/index.vue +++ b/src/views/zyjhzx/qgefkui/index.vue @@ -190,7 +190,7 @@ export default { const titel = drawTitle(this.width, this.height, this.title) const that=this - titel.on('click touch',function (){ + titel.on('click tap',function (){ console.log(111) that.$refs.drawer.show() }) diff --git a/src/views/zyjhzx/qgepgong/comps/QgePgd.vue b/src/views/zyjhzx/qgepgong/comps/QgePgd.vue index d89f509..6b8468d 100644 --- a/src/views/zyjhzx/qgepgong/comps/QgePgd.vue +++ b/src/views/zyjhzx/qgepgong/comps/QgePgd.vue @@ -105,7 +105,7 @@ export default { this.initData() }, checkboxAll({checked}) { - const worker = this.$props.worker + const worker = this.$props.worker() if (!worker) { this.$message.warning('请选择操作人') return; diff --git a/src/views/zyjhzx/qgepgong/comps/dw.js b/src/views/zyjhzx/qgepgong/comps/dw.js index 6444a33..df7cf7c 100644 --- a/src/views/zyjhzx/qgepgong/comps/dw.js +++ b/src/views/zyjhzx/qgepgong/comps/dw.js @@ -88,7 +88,7 @@ export default function (width,height){ y:0, width: width, height: height, - fill:'black', + fill:'white', text:`${formatName()}\n${item.list.length}张`, align:'center', verticalAlign:'middle', diff --git a/src/views/zyjhzx/qgepgong/index.vue b/src/views/zyjhzx/qgepgong/index.vue index 9bc6abf..66eab26 100644 --- a/src/views/zyjhzx/qgepgong/index.vue +++ b/src/views/zyjhzx/qgepgong/index.vue @@ -120,7 +120,7 @@ export default { const titel = drawTitle(this.width, this.height, this.title) const that=this - titel.on('click touch',function (){ + titel.on('click tap',function (){ console.log(111) that.$refs.drawer.show() })