|
|
@@ -852,6 +852,32 @@
|
|
|
</el-button>
|
|
|
</template>
|
|
|
</Dialog>
|
|
|
+
|
|
|
+ <CustomDialog
|
|
|
+ ref="customUnitDialogRef"
|
|
|
+ title="选择审核人"
|
|
|
+ v-model="approvalUserVisible"
|
|
|
+ width="650px"
|
|
|
+ :dialogAttrs="{ zIndex: 10006 }"
|
|
|
+ >
|
|
|
+ <el-form ref="formRef" :model="formData" :rules="formRules" label-width="150px">
|
|
|
+ <el-form-item label="意见通知书审核人" prop="inspectionAuditId">
|
|
|
+ <el-select v-model="formData.inspectionAuditId" clearable placeholder="请选择">
|
|
|
+ <el-option
|
|
|
+ v-for="item in optionList.schemeReviewerList.list"
|
|
|
+ :key="item.id"
|
|
|
+ :label="item.nickname"
|
|
|
+ :value="item.id"
|
|
|
+ />
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ </el-form>
|
|
|
+ <template #footer>
|
|
|
+ <el-button @click="approvalUserVisible = false">取消</el-button>
|
|
|
+ <el-button type="primary" @click="handleSubmitUser">确定</el-button>
|
|
|
+ </template>
|
|
|
+ </CustomDialog>
|
|
|
+
|
|
|
</template>
|
|
|
|
|
|
<script setup lang="tsx">
|
|
|
@@ -999,6 +1025,35 @@ const editData=ref<InitParams>(
|
|
|
opType: 0, // 0:excel,1: pdf
|
|
|
});
|
|
|
|
|
|
+// 选择检验意见审核人
|
|
|
+const formRef = ref<InstanceType<typeof ElForm>>()
|
|
|
+const optionList = reactive<{
|
|
|
+ schemeReviewerList: Recordable[]
|
|
|
+}>({
|
|
|
+ schemeReviewerList: []
|
|
|
+})
|
|
|
+const formData = ref<Recordable>({})
|
|
|
+const formRules = reactive({
|
|
|
+ inspectionAuditId: [{ required: true, message: '请选择审核人', trigger: 'change' }]
|
|
|
+})
|
|
|
+const approvalUserVisible = ref(false)
|
|
|
+const handleSubmitUser = () => {
|
|
|
+ formRef.value?.validate(async (valid) => {
|
|
|
+ if (valid) {
|
|
|
+ const submitResult = await PipeTaskOrderApi.submitOpinionNoticeApproval({
|
|
|
+ id: templateParams.value?.id,
|
|
|
+ auditUserIds: [formData.value.inspectionAuditId],
|
|
|
+ reportType: PressureReportType['SUGGUESTION']
|
|
|
+ })
|
|
|
+ if (submitResult) {
|
|
|
+ approvalUserVisible.value = false
|
|
|
+ // 这里可以做页面刷新
|
|
|
+ emit('template-confirm')
|
|
|
+ }
|
|
|
+ }
|
|
|
+ })
|
|
|
+}
|
|
|
+
|
|
|
const batchRecheckFormRef = ref()
|
|
|
// const isShowReportPdf = ref([PressureCheckerMyTaskStatus.REPORT_INPUT,PressureCheckerMyTaskStatus.REPORT_AUDIT,PressureCheckerMyTaskStatus.REPORT_APPROVE,PressureCheckerMyTaskStatus.REPORT_END].includes(props.selectedItem.taskStatus)
|
|
|
// && ![400,500,600,700].includes(props.selectedItem.reportType))
|
|
|
@@ -1737,11 +1792,7 @@ const handleSubmitAudit = async () => {
|
|
|
// }
|
|
|
|
|
|
// 检验意见通知书 && 重大问题线索通知 不需要选择审核人
|
|
|
- if (
|
|
|
- [PressureReportType['SUGGUESTION'], PressureReportType['MAINQUESTION']].includes(
|
|
|
- templateParams.value?.reportType
|
|
|
- )
|
|
|
- ) {
|
|
|
+ if ([PressureReportType['MAINQUESTION']].includes(templateParams.value?.reportType)) {
|
|
|
ElMessageBox.confirm(`确定提交【${templateParams.value?.reportName}】`, '提示', {
|
|
|
confirmButtonText: '确定',
|
|
|
cancelButtonText: '取消'
|
|
|
@@ -1758,7 +1809,14 @@ const handleSubmitAudit = async () => {
|
|
|
.catch(() => {
|
|
|
console.log('用户取消提交审核')
|
|
|
})
|
|
|
- } else {
|
|
|
+ } else if ([PressureReportType['SUGGUESTION']].includes(templateParams.value?.reportType)) {
|
|
|
+
|
|
|
+ optionList.schemeReviewerList = await PipeTaskOrderApi.getAuditList({
|
|
|
+ roleCode: 'Pipeline Director'
|
|
|
+ })
|
|
|
+ approvalUserVisible.value = true
|
|
|
+
|
|
|
+ } else {
|
|
|
let res = await UserApi.getApprovalDetail({}) // 判断是否有审批信息
|
|
|
|
|
|
if (res && res.approveUser) {
|