|
|
@ -1012,9 +1012,6 @@ import { |
|
|
import { |
|
|
import { |
|
|
getUserSpecialSecurity, |
|
|
getUserSpecialSecurity, |
|
|
} from '@/api/yieldReport/produce_order.js' |
|
|
} from '@/api/yieldReport/produce_order.js' |
|
|
import { |
|
|
|
|
|
getSplitRuleLockStatus |
|
|
|
|
|
} from '@/api/yieldReport/com_separate_roll.js' |
|
|
|
|
|
import { sopListSearch, downloadSopFile } from '@/api/qc/qc.js' |
|
|
import { sopListSearch, downloadSopFile } from '@/api/qc/qc.js' |
|
|
/*打印标签专用的js*/ |
|
|
/*打印标签专用的js*/ |
|
|
import { |
|
|
import { |
|
|
@ -1091,7 +1088,6 @@ export default { |
|
|
showOperatorFlag: false, |
|
|
showOperatorFlag: false, |
|
|
showSwitchFlag: false, |
|
|
showSwitchFlag: false, |
|
|
showSeparateFlag: false, |
|
|
showSeparateFlag: false, |
|
|
exceptionRuleForceLock: false, |
|
|
|
|
|
showFinishFlag: false, |
|
|
showFinishFlag: false, |
|
|
showFinishPartFlag: false, |
|
|
showFinishPartFlag: false, |
|
|
showMergeFlag: false, |
|
|
showMergeFlag: false, |
|
|
@ -4660,11 +4656,6 @@ export default { |
|
|
|
|
|
|
|
|
//刷新当前页面的菜单 |
|
|
//刷新当前页面的菜单 |
|
|
async refreshPageButtons() { |
|
|
async refreshPageButtons() { |
|
|
await this.syncSeparateRuleForceLockStatus() |
|
|
|
|
|
if (this.exceptionRuleForceLock) { |
|
|
|
|
|
this.lockWorkbenchButtonsByRule() |
|
|
|
|
|
return |
|
|
|
|
|
} |
|
|
|
|
|
//判断是否存在人员 |
|
|
//判断是否存在人员 |
|
|
if (this.operatorData.operatorId == null || this.operatorData.operatorId == '') { |
|
|
if (this.operatorData.operatorId == null || this.operatorData.operatorId == '') { |
|
|
this.buttonTags.createNewRollFlag = true; |
|
|
this.buttonTags.createNewRollFlag = true; |
|
|
@ -4788,32 +4779,6 @@ export default { |
|
|
this.checkProcessInspectionPendingCount(); |
|
|
this.checkProcessInspectionPendingCount(); |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
async syncSeparateRuleForceLockStatus () { |
|
|
|
|
|
if (!this.scheduleData.site || !this.scheduleData.buNo || !this.scheduleData.orderNo || !this.scheduleData.seqNo) { |
|
|
|
|
|
this.exceptionRuleForceLock = false |
|
|
|
|
|
return |
|
|
|
|
|
} |
|
|
|
|
|
try { |
|
|
|
|
|
const { data } = await getSplitRuleLockStatus({ |
|
|
|
|
|
site: this.scheduleData.site, |
|
|
|
|
|
buNo: this.scheduleData.buNo, |
|
|
|
|
|
orderNo: this.scheduleData.orderNo, |
|
|
|
|
|
seqNo: this.scheduleData.seqNo |
|
|
|
|
|
}) |
|
|
|
|
|
if (!data || data.code === 500) { |
|
|
|
|
|
return |
|
|
|
|
|
} |
|
|
|
|
|
const resultMap = data.resultMap || {} |
|
|
|
|
|
const wasLocked = this.exceptionRuleForceLock |
|
|
|
|
|
this.exceptionRuleForceLock = !!resultMap.locked |
|
|
|
|
|
if (wasLocked && !this.exceptionRuleForceLock && resultMap.bypassByAudit) { |
|
|
|
|
|
this.$message.success('QC已审核,已解除锁定,可继续操作。') |
|
|
|
|
|
} |
|
|
|
|
|
} catch (error) { |
|
|
|
|
|
console.error('同步创建分卷规则锁定状态失败:', error) |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
//设置参数 |
|
|
//设置参数 |
|
|
initOperatorData(operatorData) { |
|
|
initOperatorData(operatorData) { |
|
|
this.showOperatorFlag = false; |
|
|
this.showOperatorFlag = false; |
|
|
@ -4911,12 +4876,6 @@ export default { |
|
|
}); |
|
|
}); |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
lockWorkbenchButtonsByRule () { |
|
|
|
|
|
Object.keys(this.buttonTags || {}).forEach(key => { |
|
|
|
|
|
this.buttonTags[key] = true |
|
|
|
|
|
}) |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
onSeparateRuleOpenDefect () { |
|
|
onSeparateRuleOpenDefect () { |
|
|
this.showSeparateFlag = false |
|
|
this.showSeparateFlag = false |
|
|
this.$nextTick(() => { |
|
|
this.$nextTick(() => { |
|
|
@ -4932,22 +4891,13 @@ export default { |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
onSeparateRuleLockPage (resultMap) { |
|
|
onSeparateRuleLockPage (resultMap) { |
|
|
const wasLocked = this.exceptionRuleForceLock |
|
|
|
|
|
this.exceptionRuleForceLock = true |
|
|
|
|
|
this.lockWorkbenchButtonsByRule() |
|
|
|
|
|
if (!wasLocked) { |
|
|
|
|
|
this.$alert((resultMap && resultMap.message) || '触发强制异常规则,当前页面已锁定。', '提示', { |
|
|
|
|
|
confirmButtonText: '确定', |
|
|
|
|
|
type: 'warning' |
|
|
|
|
|
}) |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
this.$alert((resultMap && resultMap.message) || '触发强制异常规则,当前页面已锁定。', '提示', { |
|
|
|
|
|
confirmButtonText: '确定', |
|
|
|
|
|
type: 'warning' |
|
|
|
|
|
}) |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
onSeparateRuleUnlockPage () { |
|
|
onSeparateRuleUnlockPage () { |
|
|
if (!this.exceptionRuleForceLock) { |
|
|
|
|
|
return |
|
|
|
|
|
} |
|
|
|
|
|
this.exceptionRuleForceLock = false |
|
|
|
|
|
this.refreshPageButtons() |
|
|
this.refreshPageButtons() |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|