|
|
@@ -35,12 +35,38 @@
|
|
|
v-if="row.processInstanceId"
|
|
|
type="primary"
|
|
|
:underline="false"
|
|
|
- @click="bpmDetailOpen(row, 'detail')"
|
|
|
+ @click="bpmDetailOpen({ id: row.processInstanceId }, 'detail')"
|
|
|
>{{ reviewStatus[row.approvalStatus] }}
|
|
|
</el-link>
|
|
|
<span v-else> {{ reviewStatus[row.approvalStatus] }}</span>
|
|
|
</template>
|
|
|
+ <template v-slot:entrustedStatus="{ row }">
|
|
|
+ <el-link
|
|
|
+ v-if="row.entrustedProcessInstanceId"
|
|
|
+ type="primary"
|
|
|
+ :underline="false"
|
|
|
+ @click="
|
|
|
+ bpmDetailOpen({ id: row.entrustedProcessInstanceId }, 'detail')
|
|
|
+ "
|
|
|
+ >{{ reviewStatus[row.entrustedStatus] }}
|
|
|
+ </el-link>
|
|
|
+ <span v-else> {{ reviewStatus[row.entrustedStatus] }}</span>
|
|
|
+ </template>
|
|
|
|
|
|
+ <template v-slot:templateList="{ row }">
|
|
|
+ <div style="width: 250px; max-height: 60px; overflow: auto">
|
|
|
+ <el-tag
|
|
|
+ v-for="(item, index) in row.templateList"
|
|
|
+ :key="item.inspectionName + index"
|
|
|
+ effect="dark"
|
|
|
+ style="margin-top: 4px"
|
|
|
+ >
|
|
|
+ <span>
|
|
|
+ {{ item.inspectionName }}
|
|
|
+ </span>
|
|
|
+ </el-tag>
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
<!-- 操作列 -->
|
|
|
<template v-slot:action="{ row }">
|
|
|
<el-link
|
|
|
@@ -50,7 +76,8 @@
|
|
|
@click="openEdit(row)"
|
|
|
v-if="
|
|
|
[0, 3].includes(row.approvalStatus) &&
|
|
|
- pageName == 'inspectionProjectRequest'
|
|
|
+ pageName == 'inspectionProjectRequest' &&
|
|
|
+ [0, 3].includes(row.entrustedStatus)
|
|
|
"
|
|
|
>
|
|
|
编辑
|
|
|
@@ -60,7 +87,8 @@
|
|
|
:underline="false"
|
|
|
v-if="
|
|
|
[0, 3].includes(row.approvalStatus) &&
|
|
|
- pageName == 'inspectionProjectRequest'
|
|
|
+ pageName == 'inspectionProjectRequest' &&
|
|
|
+ [0, 3].includes(row.entrustedStatus)
|
|
|
"
|
|
|
@click="approvalSubmit(row)"
|
|
|
>提交</el-link
|
|
|
@@ -71,7 +99,8 @@
|
|
|
v-if="
|
|
|
[2].includes(row.approvalStatus) &&
|
|
|
pageName == 'inspectionProjectEntrusted' &&
|
|
|
- row.status == 1
|
|
|
+ row.status == 1 &&
|
|
|
+ [0, 3].includes(row.entrustedStatus)
|
|
|
"
|
|
|
@click="report(row, 'edit')"
|
|
|
>报工</el-link
|
|
|
@@ -82,7 +111,8 @@
|
|
|
v-if="
|
|
|
[2].includes(row.approvalStatus) &&
|
|
|
pageName == 'inspectionProjectEntrusted' &&
|
|
|
- row.status == 1
|
|
|
+ row.status == 1 &&
|
|
|
+ [0, 3].includes(row.entrustedStatus)
|
|
|
"
|
|
|
@click="openTransfer(row)"
|
|
|
>转派</el-link
|
|
|
@@ -152,6 +182,7 @@
|
|
|
@click="remove(row)"
|
|
|
v-if="
|
|
|
[0, 3].includes(row.approvalStatus) &&
|
|
|
+ [0, 3].includes(row.entrustedStatus) &&
|
|
|
pageName == 'inspectionProjectRequest'
|
|
|
"
|
|
|
>
|
|
|
@@ -290,7 +321,7 @@
|
|
|
methods: {
|
|
|
bpmDetailOpen(row) {
|
|
|
this.bpmDetailShow = true;
|
|
|
- this.processInstanceId = row.processInstanceId;
|
|
|
+ this.processInstanceId = row.id;
|
|
|
},
|
|
|
getColumns() {
|
|
|
this.columns = [
|
|
|
@@ -311,6 +342,13 @@
|
|
|
align: 'center',
|
|
|
minWidth: 130
|
|
|
},
|
|
|
+ {
|
|
|
+ label: '质检项目',
|
|
|
+ prop: 'templateList',
|
|
|
+ slot: 'templateList',
|
|
|
+ align: 'center',
|
|
|
+ width: 250
|
|
|
+ },
|
|
|
{
|
|
|
prop: 'name',
|
|
|
label: '任务名称',
|
|
|
@@ -486,6 +524,14 @@
|
|
|
minWidth: 110,
|
|
|
showOverflowTooltip: true
|
|
|
},
|
|
|
+ {
|
|
|
+ prop: 'entrustedStatus',
|
|
|
+ slot: 'entrustedStatus',
|
|
|
+ label: '报工审核状态',
|
|
|
+ align: 'center',
|
|
|
+ minWidth: 110,
|
|
|
+ showOverflowTooltip: true
|
|
|
+ },
|
|
|
{
|
|
|
prop: 'createUserName',
|
|
|
minWidth: 110,
|
|
|
@@ -595,7 +641,8 @@
|
|
|
}
|
|
|
|
|
|
const res = await getById(row.id);
|
|
|
- if (row.recordingMethod == 1) {
|
|
|
+
|
|
|
+ if (row.recordingMethod == 1 && !res.sampleTranscriptList?.length) {
|
|
|
this.$refs.inspectionProjectReportRef.open(
|
|
|
{
|
|
|
workData: {
|
|
|
@@ -609,6 +656,22 @@
|
|
|
'inspectionProjectRequest'
|
|
|
);
|
|
|
} else {
|
|
|
+ // if (res.sampleTranscriptList.length) {
|
|
|
+ // res.sampleList = res.sampleTranscriptList.map((item) => {
|
|
|
+ // return {
|
|
|
+ // ...item,
|
|
|
+ // qualitySampleTemplateList: item.selfCheckList.map(
|
|
|
+ // (selfCheck) => {
|
|
|
+ // return {
|
|
|
+ // ...selfCheck,
|
|
|
+ // qualityResultContent: selfCheck.selfCheckContent
|
|
|
+ // };
|
|
|
+ // }
|
|
|
+ // )
|
|
|
+ // };
|
|
|
+ // });
|
|
|
+ // }
|
|
|
+ console.log(res, 'res');
|
|
|
this.$refs.sampleReportRef.open(
|
|
|
res,
|
|
|
type,
|