+
@@ -336,15 +355,17 @@ import {getToken} from '@/utils/auth'
import ScrollPane from "@/layout/components/TagsView/ScrollPane.vue";
import {排产, 生成三月滚动, 获取排产结果,} from "@/api/jhzx/pc";
import Gcrl from '@/components/Gcrl';
-import Sbcnwh from '@/views/jhzx/components/sygdpc/Sbcn.vue';
import Sbwxjh from '@/views/sjzx/sbwxjhWH.vue';
import Sbjgry from '@/views/sjzx/sbjgryWH.vue';
+import Sbcnwh from '@/views/jhzx/components/sygdpc/Sbcn.vue';
import GxCD from '@/views/jhzx/components/sygdpc/GxCD.vue';
+import Dhjh from '@/views/jhzx/components/sygdpc/Dhjh.vue';
export default {
name: 'SymxCX',
- components: {ScrollPane,Gcrl,Sbcnwh,Sbwxjh,Sbjgry,GxCD},
+ components: {ScrollPane,Gcrl,Sbcnwh,Sbwxjh,Sbjgry,GxCD,Dhjh},
data() {
return {
+ active: 0,
isUser:false,
gcrl:[],
dialogVisible: false,
@@ -352,8 +373,7 @@ export default {
dialogVisible2: false,
title: '选择目标船只',
title1: '修改明细信息',
- title2: '修改工厂日历(1/5)',
- modalShow:1,
+ title2: '请确认或修改排产依据',
selectMbch: [],
mxList: [],
haveTltBoms: [],
@@ -2711,6 +2731,7 @@ export default {
filterRender: { name: 'FilterCombination', },
},
{ field: 'tzbh', title: '套料图号', width: 120,
+ slots: { default: "tzbh_err" },
filters: [{ data: { checks: [], sVal: '', sMenu: '', fType1: '', fVal1: '', fMode: 'and', fType2: '', fVal2: '' } }],
filterRender: { name: 'FilterCombination', },
},
@@ -2763,6 +2784,9 @@ export default {
}
},
methods: {
+ next() {
+ if (this.active++ > 2) this.active = 0;
+ },
rowClassName({row, rowIndex}) {
if (row.dcCh === '合计') {
return {
@@ -2772,6 +2796,52 @@ export default {
}
return null
},
+ //异常数据颜色
+ rowStyle1({row, rowIndex}){
+ if (row.errors.length > 0) {
+ return {
+ backgroundColor: '#FF0000FF',
+ color: '#fff',
+ cursor: 'pointer'
+ }
+ }
+ return null
+ },
+ showErr({ type, column, row, items, _columnIndex }){
+ const { field } = column
+ // 重写默认的提示内容
+ if (type === 'body'){
+ if (row.errors.length > 0) { var err='';
+ for (const e of row.errors) {
+ err=err+e+'\n';
+ }
+ return err;
+
+ }else {return ''}
+
+ // if (field === 'dlzh' || field === 'employeeNumber') {
+ // if (type === 'body') {
+ // console.log('type',type)
+ // console.log('column',column)
+ // console.log('row',row.zt)
+ // console.log('items',items)
+ // console.log('_columnIndex',_columnIndex)
+ // return column.title ? '自定义标题提示内容:' + column.title : ''
+ // }
+ // else if (type === 'footer') {
+ // return items[_columnIndex] ? '自定义表尾提示内容,\n并且自定义换行:\n' + items[_columnIndex] : ''
+ // }
+ // return row[field] ? '自定义提示内容:' + row[field] : ''
+ }else {
+ return ''
+ }
+ // else if (field === 'rate') {
+ // // 返回空字符串,控制单元格不显示提示内容
+ // return ''
+ // }
+ // 其余的单元格使用默认行为
+ return null
+ },
//汇总
symxhz() {
@@ -2964,8 +3034,9 @@ export default {
getList(this.queryParam).then((res) => {
this.list = res.data.list
})
- this.activeName = 'first'
+ // this.activeName = 'first'
},
+
formatDate({cellValue}) {
return XEUtils.toDateString(cellValue, 'yyyy/MM/dd')
},
@@ -2991,32 +3062,12 @@ export default {
},
confirmModal(){
this.dialogVisible2 = true
-
},
nextModal(){
- this.modalShow=this.modalShow+1
- this.changeTitle2()
+ if (this.active++ > 5) this.active = 0;
},
preModal(){
- this.modalShow=this.modalShow-1
- this.changeTitle2()
- },
- changeTitle2(){
- if (this.modalShow==1){
- this.title2='修改工厂日历(1/5)'
- }
- if (this.modalShow==2){
- this.title2='工序间隔周期(2/5)'
- }
- if (this.modalShow==3){
- this.title2='修改设备产能(3/5)'
- }
- if (this.modalShow==4){
- this.title2='设备维护/维修(4/5)'
- }
- if (this.modalShow==5){
- this.title2='人员出勤情况(5/5)'
- }
+ if (this.active-- < 1) this.active = 0;
},
jgcx(flag=true){
const data={from:this.queryParam.beginTime,to:this.queryParam.endTime}
@@ -3064,6 +3115,7 @@ export default {
data.wpcz=bom.wpcz
data.ljsl=bom.ljsl
data._degs=bom.degs
+ data.errors=bom.errors
list.push(data)
}
}