Commit 707619d0 authored by huhaiqing's avatar huhaiqing

审核中点击跳转审核详情

parent c0651547
......@@ -117,7 +117,7 @@
<el-button type="primary" @click="handlerClick('modifyCabinet','修改柜信息')">修改柜信息</el-button>
</div>
<div v-if="isUnderReview">
<el-button type="primary" :disabled=true>封柜审核中</el-button>
<el-button type="primary" @click="jumpReviewDetail">封柜审核中</el-button>
<el-button plain type="primary" @click="canclAudit">取消审核</el-button>
<el-button plain type="primary" @click="$emit('closeDialog')">返回</el-button>
</div>
......@@ -220,6 +220,7 @@ import {
serviceMsg,
getCapacity,
sumStatistics,
toReviewDetail,
} from "../../utils";
import splitOrder from "./splitOrder.vue";
import WorkFlow from "@/components/WorkFlow";
......@@ -519,6 +520,11 @@ export default {
});
});
},
jumpReviewDetail() {
const { cabinetApprovalInfo } = this.shipmentObj;
toReviewDetail.apply(this, [cabinetApprovalInfo.bpmProcessId]);
this.$emit("closeDialog", "close");
},
},
computed: {
/* 是否审核中 */
......
......@@ -277,7 +277,7 @@
<work-flow xmlkey="shipment_preassemble" v-model="selectedUsers"></work-flow>
</div>
<div v-show="isAudit">
<el-button type="primary" :disabled=true>审核中</el-button>
<el-button type="primary" @click="jumpReviewDetail">审核中</el-button>
<el-button plain type="primary" @click="canclAudit">取消审核</el-button>
<el-button plain type="primary" @click="closeDialog">返回</el-button>
</div>
......@@ -302,7 +302,13 @@ import {
approvalCancel,
} from "@/api/ecw/boxSea";
import userSelect from "./common/userSelect.vue";
import { formatDate, getTotlContent, serviceMsg, getCapacity } from "../utils";
import {
formatDate,
getTotlContent,
serviceMsg,
getCapacity,
toReviewDetail,
} from "../utils";
import dayjs from "dayjs";
import WorkFlow from "@/components/WorkFlow";
......@@ -613,6 +619,11 @@ export default {
});
});
},
jumpReviewDetail() {
const { currNode, shipmentObj } = this.$attrs;
toReviewDetail.apply(this, [shipmentObj[currNode.voName].bpmProcessId]);
this.$emit("closeDialog");
},
},
};
</script>
......
......@@ -100,7 +100,7 @@
<el-button plain type="primary" @click="$emit('closeStart')">返回</el-button>
</div>
<div v-if="isUnderReview">
<el-button type="primary" :disabled=true>卸柜审核中</el-button>
<el-button type="primary" @click="jumpReviewDetail">卸柜审核中</el-button>
<el-button plain type="primary" @click="canclAudit">取消审核</el-button>
<el-button plain type="primary" @click="$emit('closeStart')">返回</el-button>
</div>
......@@ -123,7 +123,7 @@ import {
approvalCancel,
getSectionList,
} from "@/api/ecw/boxSea";
import { serviceMsg, getTotlContent } from "../../utils";
import { serviceMsg, getTotlContent, toReviewDetail } from "../../utils";
import WorkFlow from "@/components/WorkFlow";
/**
......@@ -302,6 +302,11 @@ export default {
path: `/order/pending?id=${row.orderId}`,
});
},
jumpReviewDetail() {
const { cabinetUnloadApprovalInfo } = this.$attrs.shipmentObj;
toReviewDetail.apply(this, [cabinetUnloadApprovalInfo.bpmProcessId]);
this.$emit("closeStart", "close");
},
},
computed: {
/* 是否审核中 */
......
......@@ -20,7 +20,7 @@
<!-- 弹窗 -->
<el-dialog custom-class="shipping-dialog" :title="dialogConfig.title" :visible.sync="dialogConfig.dialogVisible" :width="dialogConfig.width" :fullscreen="dialogConfig.fullscreen" :close-on-click-modal=false :modal-append-to-body=false append-to-body>
<component v-bind:is="currentComponent" v-if="dialogConfig.dialogVisible" @closeDialog="closeDialog" v-bind="$attrs" :shipmentObj="shipmentObj" :currNode="currNode"></component>
<component v-bind:is="currentComponent" v-if="dialogConfig.dialogVisible" @closeDialog="closeDialog" v-bind="$attrs" v-on="$listeners" :shipmentObj="shipmentObj" :currNode="currNode"></component>
</el-dialog>
</div>
</template>
......@@ -178,7 +178,8 @@ export default {
watch: {
/* 监听发货对象 */
shipmentObj(val) {
let newNodes = [];
let newNodes = [],
finish = 0;
// 迭代每个节点
for (let i = 0; i < this.seaBaseData.length; i++) {
const nodes = this.seaBaseData[i];
......@@ -187,6 +188,7 @@ export default {
const node = nodes[j];
const { keyName, voName, status, type } = node;
// agent
if (!keyName && type === "agent") {
if (val[voName]) {
// 已完成agent节点
......@@ -212,6 +214,20 @@ export default {
if (end.includes(val[keyName])) {
node.currStatus = "end";
// 报关
if (type === "cusDeclaration") {
const { dcCustomsStatus, dcCheckStatus } = val;
// 查验状态并且是退场/部分退场
if (dcCustomsStatus === 3 && [1, 2].includes(dcCheckStatus)) {
// 只有审核通过并且已处理才算完成
if (val.checkExamineStatus === 2 && val.checkDealStatus === 1) {
// 已完成节点个数
++nodeIndex;
} else {
continue;
}
}
}
// 已完成节点个数
++nodeIndex;
}
......@@ -219,10 +235,11 @@ export default {
// 如果相等标识该步骤已完成
if (nodeIndex === nodes.length) {
// 加1表示为已完成步骤后一步
this.currIndex = i + 1;
finish = finish + 1;
}
newNodes.push(nodes);
}
this.currIndex = finish;
this.processData = newNodes;
},
},
......
......@@ -1030,6 +1030,18 @@ function serviceMsg(result, _vue) {
});
}
/**
* 跳转审核详情
*
* @param {*} bpmProcessId
*/
function toReviewDetail(bpmProcessId) {
this.$router.push({
path: "/bpm/process-instance/detail",
query: { id: bpmProcessId },
});
}
export {
getStatusName,
getColmnMapping,
......@@ -1044,4 +1056,5 @@ export {
getCapacity,
sumStatistics,
serviceMsg,
toReviewDetail,
};
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment