|
|
@@ -1509,7 +1509,8 @@ const isCanSubmitRecheck = computed(() => {
|
|
|
else
|
|
|
return (
|
|
|
props.selectedItem &&
|
|
|
- props.selectedItem.taskStatus === PressureCheckerMyTaskStatus['RECORD_INPUT']
|
|
|
+ props.selectedItem.taskStatus === PressureCheckerMyTaskStatus['RECORD_INPUT'] &&
|
|
|
+ !isSingleReportWithoutInstruction.value
|
|
|
// && props.selectedItem.reportUrl
|
|
|
)
|
|
|
})
|
|
|
@@ -1540,19 +1541,28 @@ const isCanSubmitToAudit = computed(() => {
|
|
|
)
|
|
|
})
|
|
|
|
|
|
+// 独审报告未关联操作指导书时不可编辑
|
|
|
+const isSingleReportWithoutInstruction = computed(
|
|
|
+ () =>
|
|
|
+ props.selectedItem?.reportType === PressureReportType.SINGLE &&
|
|
|
+ !props.selectedItem?.instructionId
|
|
|
+)
|
|
|
+
|
|
|
// 判断“填写记录”按钮是否显示
|
|
|
const isCanEditTestRecord = computed(
|
|
|
() =>
|
|
|
props.selectedItem &&
|
|
|
(props.selectedItem.taskStatus === PressureCheckerMyTaskStatus['RECORD_INPUT'] ||
|
|
|
- props.selectedItem.taskStatus === PressureCheckerMyTaskStatus['CONFIRMED']) && props.selectedItem.reportType !== PressureReportType['SUBCONTRACT']
|
|
|
+ props.selectedItem.taskStatus === PressureCheckerMyTaskStatus['CONFIRMED']) && props.selectedItem.reportType !== PressureReportType['SUBCONTRACT'] &&
|
|
|
+ !isSingleReportWithoutInstruction.value
|
|
|
)
|
|
|
|
|
|
// 判断“编制报告”按钮是否显示
|
|
|
const isCanEditReport = computed(
|
|
|
() =>
|
|
|
props.selectedItem &&
|
|
|
- props.selectedItem.taskStatus === PressureCheckerMyTaskStatus['REPORT_INPUT']
|
|
|
+ props.selectedItem.taskStatus === PressureCheckerMyTaskStatus['REPORT_INPUT'] &&
|
|
|
+ !isSingleReportWithoutInstruction.value
|
|
|
)
|
|
|
|
|
|
// 判断"撤销流程"按钮是否显示:报告审核或审批阶段,且有OA流程ID,且当前用户是发起人
|
|
|
@@ -2583,7 +2593,7 @@ const initPreview=()=>{
|
|
|
initData.value.templateId = templateId;
|
|
|
initData.value.refId = refId;
|
|
|
initData.value.refName = props.selectedItem?.reportName;
|
|
|
- initData.value.opType = (props.selectedItem.taskStatus == 510 || props.selectedItem.taskStatus >= 600 || (showReportPdfType.value === 'record' && props.selectedItem.taskStatus > 500) || props?.selectedItem?.checkUsers?.[0]?.id != userStore?.user?.id) ? 1 : 0;
|
|
|
+ initData.value.opType = (props.selectedItem.taskStatus == 510 || props.selectedItem.taskStatus >= 600 || (showReportPdfType.value === 'record' && props.selectedItem.taskStatus > 500) || props?.selectedItem?.checkUsers?.[0]?.id != userStore?.user?.id || isSingleReportWithoutInstruction.value) ? 1 : 0;
|
|
|
if (props.selectedItem.reportType === PressureReportType['INSPECTIONPLAN'] && props.selectedItem.manualUrl){
|
|
|
initData.value.manualUrl = props.selectedItem.manualUrl;
|
|
|
}else{
|