1.修正看板数据

2.二跨T型材腹板对应四区,二跨T型材面板对应三区
3.在作业计划查询页面增加作业区变更肝功能
4.报工设备信息修正
5.启用作业区报工页面登录限制
master
董哲奇 3 months ago
parent 4a76f38f4c
commit 178c52803e

@ -8,8 +8,8 @@ import getPageTitle from '@/utils/get-page-title'
NProgress.configure({ showSpinner: false }) // NProgress Configuration
const whiteList = ['/menu','/login', '/auth-redirect','/kban','/sliao','/pwpg','/pwfk','/llpg','/llfk','/hxpg','/hxfk','/qgpg','/qgfk','/ljian','/baogong'] // no redirect whitelist
// const whiteList = ['/menu','/login', '/auth-redirect','/kban','/ljian','/baogong']
// const whiteList = ['/menu','/login', '/auth-redirect','/kban','/sliao','/pwpg','/pwfk','/llpg','/llfk','/hxpg','/hxfk','/qgpg','/qgfk','/ljian','/baogong'] // no redirect whitelist
const whiteList = ['/menu','/login', '/auth-redirect','/kban','/ljian','/baogong']
const checkBmList=['/sliao','/pwpg','/pwfk','/llpg','/llfk','/hxpg','/hxfk','/qgpg','/qgfk']
export function flatRoutes(routes) {

@ -4,7 +4,7 @@
<el-header style="width: 100%; height: 50px;font-size: 12px">
<el-form :inline="true" label-width="65px" label-position="left">
<el-row>
<el-col :span="15">
<el-col :span="10">
<el-form-item label="月份:">
<el-date-picker v-model="queryParam.yf" value-format="yyyy/MM/dd" type="month" style="width: 80%;" />
</el-form-item>
@ -20,15 +20,30 @@
</el-select>
</el-form-item>
</el-col>
<el-col :span="5">
<el-form-item>
<el-select v-model="plParam.zyq" filterable placeholder="作业区">
<el-option
v-for="(item,index) in zyqList"
:key="index"
:label="item.label"
:value="item.value">
</el-option>
</el-select>
</el-form-item>
<el-form-item>
<el-button type="success" @click="plsr"></el-button>
</el-form-item>
</el-col>
<el-col :span="9">
<el-form-item style="float: right" >
<el-button type="success" @click="initList"></el-button>
<el-button type="success" @click="exportExcel()"></el-button>
<el-button type="success" :disabled="activeName==='first'" @click="save"></el-button>
</el-form-item>
</el-col>
</el-row>
</el-form>
</el-header>
<el-container style="padding-top: 0px">
@ -74,6 +89,7 @@
highlight-current-row
highlight-hover-row
show-overflow
:edit-config="{trigger: 'click',mode: 'row',showStatus: true,}"
:scroll-y="{enabled: true}"
>
</vxe-grid>
@ -88,12 +104,13 @@
<script>
import { getCzxx} from '@/api/jhzx/qfxq'
import {getYdjh, tjydjh, getCnsb, hz, getListhz, getListhzBymx} from '@/api/jhzx/sygd'
import {getYdjh, tjydjh, getCnsb, hz, getListhz, getListhzBymx, saveData} from '@/api/jhzx/sygd'
import { mapGetters } from 'vuex'
import XEUtils from 'xe-utils'
import { getToken } from '@/utils/auth'
import ScrollPane from "@/layout/components/TagsView/ScrollPane.vue";
import {exportByExcel} from "@/utils/rpkj";
import {editZyq} from "@/api/jhzxgl/ydjh";
export default {
name:'YdjhzxCX',
components: {ScrollPane},
@ -106,6 +123,9 @@ export default {
mxList:[],
haveTltBoms:[],
activeName: 'first',
plParam:{
zyq:'',
},
queryParam: {
dcch:'',
yf:'',
@ -211,6 +231,11 @@ export default {
{ field: 'tzbh', title: '套料图号',width: 90,
filters: [{ data: { checks: [], sVal: '', sMenu: '', fType1: '', fVal1: '', fMode: 'and', fType2: '', fVal2: '' } }],
filterRender: { name: 'FilterCombination', }},
{ field: 'zyq', title: '作业区',width: 100,
filters: [{ data: { checks: [], sVal: '', sMenu: '', fType1: '', fVal1: '', fMode: 'and', fType2: '', fVal2: '' } }],
filterRender: { name: 'FilterCombination', },
editRender:{ name: '$select', options:[],events:{change:this.zyqChange,}},
},
{ field: 'ylbs', title: '余料',width: 90,
filters: [{ data: { checks: [], sVal: '', sMenu: '', fType1: '', fVal1: '', fMode: 'and', fType2: '', fVal2: '' } }],
filterRender: { name: 'FilterCombination', }},
@ -688,6 +713,12 @@ export default {
filterRender: { name: 'FilterCombination' }
},
],
zyqList:[
{label:'二区',value:'FP2Q'},
{label:'三区',value:'FP3Q'},
{label:'四区',value:'FP4Q'},
],
tmpQuery:{dcCh:'',dcPl:''},
}
},
computed: {
@ -700,7 +731,44 @@ export default {
this.initgxList()
},
methods: {
save(){
const data=this.$refs.xGrid.getCheckboxRecords()
if (data.length===0){
this.$message.warning('请选择要保存的数据')
return
}
saveData(data).then(res=>{
this.$message.success('保存成功')
this.getListhzBymx1()
})
},
plsr(){
const data=this.$refs.xGrid.getCheckboxRecords()
if (data.length===0){
this.$message.warning('请选择要调整的数据')
return
}
for (const item of data) {
item.zyq=this.plParam.zyq||item.zyq
}
},
zyqChange({row}){
for (const item of this.zyqList) {
if(item.value===row.zyq){
row.zyq1=item.label
const data={
id:row.id,
zyq:row.zyq,
zyq1:item.label
}
editZyq(data).then(res=>{
this.$message.success('处理成功')
this.getListhzBymx1()
})
break
}
}
},
exportExcel(){
exportByExcel(this.tableColumn,this.$refs.xGrid.getTableData().visibleData,1,'作业计划.xlsx')
},
@ -765,17 +833,23 @@ export default {
return XEUtils.toDateString(cellValue, 'yyyy/MM/dd')
},
getHeight() {
this.height = window.innerHeight - 160
this.height = window.innerHeight - 185
},
getListhzBymx1({row}){
console.log(row)
console.log(row.dcCh)
getListhzBymx1({row}={}){
if(!row){
row={dcCh:this.tmpQuery.dcCh,dcPl:this.tmpQuery.dcPl}
}else{
this.tmpQuery={dcCh: row.dcCh,dcPl:row.dcPl}
}
const quer={'dcch': row.dcCh,'dcpl':row.dcPl}
console.log(quer)
getListhzBymx(
quer
).then(res => {
this.activeName = 'second'
const zyqColumn=this.$refs.xGrid.getColumnByField('zyq')
zyqColumn.editRender.options=this.zyqList
this.list = res.data
})
},

@ -1,15 +1,29 @@
import Konva from "konva";
export default function (width,height){
export default function (width,height,zyq){
const x=width*0.495,y=260,_width=width*0.186,_height=height*0.713
const container=new Konva.Group({
id:'sb',
const bg=new Konva.Group({
x:x,
y:y,
width:_width,
height:_height
})
const container=new Konva.Group({
id:'sb',
x:0,
y:5,
width:_width,
height:_height,
draggable:true,
dragBoundFunc:function (pos){
return {
x:x,
y:pos.y
}
},
})
const imageObj = new Image();
imageObj.src = require('@/assets/sliao/personbg.png');
imageObj.onload = function () {
@ -20,22 +34,41 @@ export default function (width,height){
height:_height,
image: this,
});
container.add(shape)
bg.add(shape)
shape.zIndex(0)
}
const sbList=[
{name:"划线设备1",sbbm:'1'},
{name:"划线设备2",sbbm:'2'},
{name:"划线设备3",sbbm:'3'},
{name:"划线设备4",sbbm:'4'},
]
bg.add(container)
bg.clipFunc(function(ctx) {
ctx.rect(0, 5, _width, _height-10);
});
const sbList={
二区:[
{name:"一跨\n数控划线机",sbbm:'583020006'},
{name:"三跨\n划线机",sbbm:'042014080111000007'},
],
三区:[
{name:"二跨东\n数控划线机",sbbm:'052001080111018532'},
],
四区:[
{name:"四跨\n数控划线机",sbbm:'583020001'},
{name:"五跨\n数控划线机",sbbm:'583020003'},
{name:"五跨\n数控划线机",sbbm:'583020005'},
{name:"六跨\n数控划线机",sbbm:'583020002'},
{name:"六跨\n数控划线机",sbbm:'583020004'},
],
}
let selectedShape=null;
let selectSbbm=null;
const getSelectSbbm=function (){
return selectSbbm
}
sbList.forEach((item,index)=>{
sbList[zyq].forEach((item,index)=>{
const sbGroup=new Konva.Group({
x: 5,
y: 5+index*_height/4-10,
@ -105,5 +138,5 @@ export default function (width,height){
}
})
return {container,getSelectSbbm}
return {bg,container,getSelectSbbm}
}

@ -193,7 +193,6 @@ export default {
const titel=drawTitle(this.width,this.height,this.title)
const that=this
titel.on('click tap',function (){
console.log(111)
that.$refs.drawer.show()
})
this.layer.add(titel)
@ -208,9 +207,9 @@ export default {
this.pgdGroup=pgdContainer()
this.layer.add(this.pgdGroup)
const {container:csdGroup,getSelectSbbm} = drawSb(this.width, this.height)
const {bg:bgGroup,container:csdGroup,getSelectSbbm} = drawSb(this.width, this.height,this.$route.query.zyq)
this.getSelectSbbm=getSelectSbbm
this.layer.add(csdGroup)
this.layer.add(bgGroup)
this.initBaiFang()
},

@ -1,15 +1,30 @@
import Konva from "konva";
export default function (width,height){
export default function (width,height,zyq){
const x=width*0.455,y=260,_width=width*0.227,_height=height*0.713
const container=new Konva.Group({
id:'sb',
const bg=new Konva.Group({
x:x,
y:y,
width:_width,
height:_height
})
const container=new Konva.Group({
id:'sb',
x:0,
y:5,
width:_width,
height:_height,
draggable:true,
dragBoundFunc:function (pos){
return {
x:x,
y:pos.y
}
},
})
const imageObj = new Image();
imageObj.src = require('@/assets/sliao/personbg.png');
imageObj.onload = function () {
@ -20,22 +35,53 @@ export default function (width,height){
height:_height,
image: this,
});
container.add(shape)
bg.add(shape)
shape.zIndex(0)
}
const sbList=[
{name:"切割设备1",sbbm:'1'},
{name:"切割设备2",sbbm:'2'},
{name:"切割设备3",sbbm:'3'},
{name:"切割设备4",sbbm:'4'},
]
bg.add(container)
bg.clipFunc(function(ctx) {
ctx.rect(0, 5, _width, _height-10);
});
const sbList={
二区:[
{name:"一跨北\n高精度门式切割机",sbbm:'582520003'},
{name:"一跨南\n等离子切割机",sbbm:'582920018'},
{name:"一跨中\n高精度门式切割机",sbbm:'582520002'},
{name:"三跨\n门式切割机",sbbm:'582520011'},
{name:"三跨\n高精度门式切割机-火焰(双头)",sbbm:'582920013'},
],
三区:[
{name:"二跨\n门式切割机",sbbm:'042014050812000006'},
{name:"二跨南\n激光切割机",sbbm:'052001050844089002'},
{name:"二跨南\n数控等离子火焰切割机",sbbm:'582920020'},
{name:"二跨北\n数控等离子火焰切割机",sbbm:'582920021'},
],
四区:[
{name:"四跨\n干式NC等离子切割机",sbbm:'582920001'},
{name:"四跨\n干式NC等离子切割机",sbbm:'582920002'},
{name:"四跨\n干式NC等离子切割机",sbbm:'582920003'},
{name:"四跨\n干式NC等离子切割机",sbbm:'582920004'},
{name:"五跨\n激光切割机",sbbm:'F10347'},
{name:"五跨\n干式NC等离子切割机",sbbm:'582920006'},
{name:"五跨\n干式NC等离子切割机",sbbm:'582920007'},
{name:"五跨\n激光切割机",sbbm:'F10366'},
{name:"六跨\n干式NC等离子切割机",sbbm:'582920009'},
{name:"六跨\n干式NC等离子切割机",sbbm:'582920010'},
{name:"六跨\n干式NC等离子切割机",sbbm:'582920011'},
{name:"六跨\n干式NC等离子切割机",sbbm:'582920012'},
],
}
let selectedShape=null;
let selectSbbm=null;
const getSelectSbbm=function (){
return selectSbbm
}
sbList.forEach((item,index)=>{
sbList[zyq]?.forEach((item,index)=>{
const sbGroup=new Konva.Group({
x: 5,
y: 5+index*_height/4-10,
@ -105,5 +151,5 @@ export default function (width,height){
}
})
return {container,getSelectSbbm}
return {bg,container,getSelectSbbm}
}

@ -209,9 +209,9 @@ export default {
this.pgdGroup = pgdContainer()
this.layer.add(this.pgdGroup)
const {container:csdGroup,getSelectSbbm} = drawSb(this.width, this.height)
const {bg:bgGroup,container:csdGroup,getSelectSbbm} = drawSb(this.width, this.height,this.$route.query.zyq)
this.getSelectSbbm=getSelectSbbm
this.layer.add(csdGroup)
this.layer.add(bgGroup)
this.initBaiFang()

Loading…
Cancel
Save