报工限制

master
zhaoxiaolin 12 months ago
parent 096fe84a27
commit c17426e454

@ -479,7 +479,8 @@
</el-tab-pane> </el-tab-pane>
</el-tabs> </el-tabs>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitReport"> </el-button> <el-button type="primary" @click="cancel" v-if="optType =='view'"></el-button>
<el-button type="primary" @click="submitReport" v-else> </el-button>
<el-button @click="cancel"> </el-button> <el-button @click="cancel"> </el-button>
</div> </div>
</el-dialog> </el-dialog>
@ -522,7 +523,9 @@
</el-tab-pane> </el-tab-pane>
</el-tabs> </el-tabs>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitConsume"> </el-button>
<el-button type="primary" @click="cancel" v-if="optType =='view'"></el-button>
<el-button type="primary" @click="submitConsume" v-else> </el-button>
<el-button @click="cancel"> </el-button> <el-button @click="cancel"> </el-button>
</div> </div>
</el-dialog> </el-dialog>
@ -919,7 +922,13 @@ export default {
}, },
/** 报工按钮操作 */ /** 报工按钮操作 */
handleReport(row) { handleReport(row) {
let sr = this.selectRow[0]; let sr = this.selectRow[0];
if(sr.uploadStatus =='sap报工成功'){
this.$modal.msgError(`上报sap已完成,不能重复报工`);
return
}
const code = sr.workorderCode; const code = sr.workorderCode;
this.$modal.confirm('是否确认工单"' + code + '"的数据项向sap报工').then(function() { this.$modal.confirm('是否确认工单"' + code + '"的数据项向sap报工').then(function() {
return reportSap(code); return reportSap(code);
@ -932,6 +941,13 @@ export default {
handleReportHz(row) { handleReportHz(row) {
this.reset(); this.reset();
let sr = this.selectRow[0]; let sr = this.selectRow[0];
if(sr.uploadStatus =='sap报工成功'){
this.optType = 'view'
}else{
this.optType = ''
}
this.queryParams.workorderCode = sr.workorderCode; this.queryParams.workorderCode = sr.workorderCode;
// //
this.queryParams.parentOrder = '0'; this.queryParams.parentOrder = '0';
@ -947,6 +963,7 @@ export default {
this.sOrderTableList = response; this.sOrderTableList = response;
this.openReport = true; this.openReport = true;
this.titleReport = "工单报工详情"; this.titleReport = "工单报工详情";
}); });
}, },
handleEdit(index, row) { handleEdit(index, row) {
@ -976,6 +993,13 @@ export default {
handleConsumeHz(row) { handleConsumeHz(row) {
this.reset(); this.reset();
let sr = this.selectRow[0]; let sr = this.selectRow[0];
if(sr.uploadStatus =='sap报工成功'){
this.optType = 'view'
}else{
this.optType = ''
}
this.queryParams.workorderCode = sr.workorderCode; this.queryParams.workorderCode = sr.workorderCode;
// //
this.queryParams.parentOrder = '0'; this.queryParams.parentOrder = '0';

Loading…
Cancel
Save