|
|
|
@ -11,31 +11,37 @@ |
|
|
|
</el-form-item> |
|
|
|
<el-form-item :label="''"> |
|
|
|
<el-button type="primary" @click="switchOperatorModal(0)" class="customer-bun-mid" |
|
|
|
:disabled="reportButton.normalReportButton" |
|
|
|
style="margin-left: 10px; margin-bottom: 5px;">报工 |
|
|
|
</el-button> |
|
|
|
</el-form-item> |
|
|
|
<el-form-item :label="''"> |
|
|
|
<el-button type="primary" @click="switchOperatorModal(1)" class="customer-bun-mid" |
|
|
|
:disabled="reportButton.fqcReportButton" |
|
|
|
style="margin-left: 10px; margin-bottom: 5px;">FQC报工 |
|
|
|
</el-button> |
|
|
|
</el-form-item> |
|
|
|
<el-form-item :label="''"> |
|
|
|
<el-button type="primary" @click="switchOperatorModal(2)" class="customer-bun-mid" |
|
|
|
:disabled="reportButton.reworkReportButton" |
|
|
|
style="margin-left: 10px; margin-bottom: 5px;">返工重检 |
|
|
|
</el-button> |
|
|
|
</el-form-item> |
|
|
|
<el-form-item :label="''"> |
|
|
|
<el-button type="primary" @click="switchOperatorModal(4)" class="customer-bun-mid" |
|
|
|
:disabled="reportButton.packReportButton" |
|
|
|
style="margin-left: 10px; margin-bottom: 5px;">换包装 |
|
|
|
</el-button> |
|
|
|
</el-form-item> |
|
|
|
<el-form-item :label="''"> |
|
|
|
<el-button type="primary" @click="switchOperatorModal(3)" class="customer-bun-mid" |
|
|
|
:disabled="reportButton.fqcSegmentReportButton" |
|
|
|
style="margin-left: 10px; margin-bottom: 5px;">FQC分卷 |
|
|
|
</el-button> |
|
|
|
</el-form-item> |
|
|
|
<el-form-item :label="''"> |
|
|
|
<el-button type="primary" class="customer-bun-mid" @click="switchOperatorModal(8)" |
|
|
|
:disabled="reportButton.slitReportButton" |
|
|
|
style="margin-left: 10px; width: 60px; margin-bottom: 5px;">分切报工 |
|
|
|
</el-button> |
|
|
|
</el-form-item> |
|
|
|
@ -218,7 +224,8 @@ import { |
|
|
|
manualProduceOrder, |
|
|
|
repairSOFlagProduceOrder, |
|
|
|
workbenchCancelallops, |
|
|
|
getShopOrder |
|
|
|
getShopOrder, |
|
|
|
getScheduleMultiReportSpecialAuth,/*获取派工单的特殊权限*/ |
|
|
|
} from '@/api/yieldReport/produce_order.js'; |
|
|
|
|
|
|
|
/*引入组件*/ |
|
|
|
@ -1090,6 +1097,14 @@ export default { |
|
|
|
}, |
|
|
|
|
|
|
|
], |
|
|
|
reportButton: { |
|
|
|
normalReportButton: true, |
|
|
|
fqcReportButton: true, |
|
|
|
reworkReportButton: true, |
|
|
|
packReportButton: true, |
|
|
|
fqcSegmentReportButton: true, |
|
|
|
slitReportButton: true, |
|
|
|
}, |
|
|
|
menuButton: { |
|
|
|
prdButton: true, |
|
|
|
openButton: true, |
|
|
|
@ -1105,7 +1120,7 @@ export default { |
|
|
|
canceledAllPrdButton: false, |
|
|
|
createRecheckButton: false, |
|
|
|
partStockFlag: true,/*查看物料库存*/ |
|
|
|
} |
|
|
|
}, |
|
|
|
} |
|
|
|
}, |
|
|
|
components: { |
|
|
|
@ -1781,6 +1796,13 @@ export default { |
|
|
|
} |
|
|
|
|
|
|
|
if (val == 0) { |
|
|
|
let orderType = this.currentRow.orderType; |
|
|
|
let workCenterNo = this.currentRow.workCenterNo; |
|
|
|
if(orderType != 'S' || workCenterNo === 'FQC'){ |
|
|
|
//验证通过 |
|
|
|
this.$message.error('当前派工单无法使用报工!'); |
|
|
|
return false; |
|
|
|
} |
|
|
|
let data = { |
|
|
|
site: this.currentRow.site, |
|
|
|
resourceId: this.currentRow.resourceId, |
|
|
|
@ -1823,6 +1845,16 @@ export default { |
|
|
|
this.$message.error('当前工单非分切工单!'); |
|
|
|
return false; |
|
|
|
} |
|
|
|
}else if(val == 1){//处理 FQC |
|
|
|
//判断订单类型和加工中心 |
|
|
|
let workCenterNo = this.currentRow.workCenterNo; |
|
|
|
if(workCenterNo === 'FQC'){ |
|
|
|
this.showOperatorFlag = true; |
|
|
|
this.$refs.comSwitchOperator.init(val); |
|
|
|
}else{ |
|
|
|
this.$message.error('当前派工单非FQC报工派工单!'); |
|
|
|
return false; |
|
|
|
} |
|
|
|
}else{ |
|
|
|
if (val == 4){ |
|
|
|
getShopOrder(this.currentRow).then(({data}) =>{ |
|
|
|
@ -1959,6 +1991,42 @@ export default { |
|
|
|
this.searchData.searchFlag = false; |
|
|
|
this.produceScheduleList = data.rows; |
|
|
|
}); |
|
|
|
|
|
|
|
/*获取报工的特殊权限*/ |
|
|
|
getScheduleMultiReportSpecialAuth(this.searchData).then(({data}) => { |
|
|
|
let authMap = data.authMap; |
|
|
|
//区分是否打开按钮 |
|
|
|
if(authMap.normalReportFlag === 'Y'){ |
|
|
|
this.reportButton.normalReportButton = false; |
|
|
|
}else { |
|
|
|
this.reportButton.normalReportButton = true; |
|
|
|
} |
|
|
|
if(authMap.fqcReportFlag === 'Y'){ |
|
|
|
this.reportButton.fqcReportButton = false; |
|
|
|
}else { |
|
|
|
this.reportButton.fqcReportButton = true; |
|
|
|
} |
|
|
|
if(authMap.reworkReportFlag === 'Y'){ |
|
|
|
this.reportButton.reworkReportButton = false; |
|
|
|
}else { |
|
|
|
this.reportButton.reworkReportButton = true; |
|
|
|
} |
|
|
|
if(authMap.packReportFlag === 'Y'){ |
|
|
|
this.reportButton.packReportButton = false; |
|
|
|
}else { |
|
|
|
this.reportButton.packReportButton = true; |
|
|
|
} |
|
|
|
if(authMap.fqcSegmentReportFlag === 'Y'){ |
|
|
|
this.reportButton.fqcSegmentReportButton = false; |
|
|
|
}else { |
|
|
|
this.reportButton.fqcSegmentReportButton = true; |
|
|
|
} |
|
|
|
if(authMap.slitReportFlag === 'Y'){ |
|
|
|
this.reportButton.slitReportButton = false; |
|
|
|
}else{ |
|
|
|
this.reportButton.slitReportButton = true; |
|
|
|
} |
|
|
|
}); |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|