Commit eb2b20b9 authored by huhaiqing's avatar huhaiqing

增加审核流程

parent 97ca3518
...@@ -24,12 +24,12 @@ ...@@ -24,12 +24,12 @@
<el-button type="primary" @click="showOrder">订单列表</el-button> <el-button type="primary" @click="showOrder">订单列表</el-button>
</el-row> </el-row>
<div v-if="boxBackVO.preInstallInfo && boxBackVO.preInstallInfo.applyReason"> <!-- <div v-if="boxBackVO.preInstallInfo && boxBackVO.preInstallInfo.applyReason">
<p>申请原因</p> <p>申请原因</p>
<div> <div>
{{boxBackVO.preInstallInfo.applyReason}} {{boxBackVO.preInstallInfo.applyReason}}
</div> </div>
</div> </div> -->
<el-dialog :title="dialogConfig.title" :visible.sync="dialogConfig.visible" fullscreen :modal-append-to-body=false append-to-body> <el-dialog :title="dialogConfig.title" :visible.sync="dialogConfig.visible" fullscreen :modal-append-to-body=false append-to-body>
<el-descriptions :column="6" border> <el-descriptions :column="6" border>
......
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
<!-- 开始装柜 --> <!-- 开始装柜 -->
<el-dialog title="开始装柜" :visible.sync="dialogVisible" fullscreen :modal-append-to-body=false append-to-body> <el-dialog title="开始装柜" :visible.sync="dialogVisible" fullscreen :modal-append-to-body=false append-to-body>
<startPacking v-bind="$attrs" v-if="dialogVisible" /> <startPacking v-bind="$attrs" v-if="dialogVisible" @closeDialog="closeDialog" />
</el-dialog> </el-dialog>
<!-- 操作 --> <!-- 操作 -->
...@@ -99,6 +99,10 @@ export default { ...@@ -99,6 +99,10 @@ export default {
} }
}); });
}, },
closeDialog(type) {
this.dialogVisible = false;
if (type) this.cancel(type);
},
/** 取消 */ /** 取消 */
cancel(type) { cancel(type) {
this.$emit("closeDialog", type); this.$emit("closeDialog", type);
......
...@@ -36,7 +36,7 @@ ...@@ -36,7 +36,7 @@
<!-- 表格 --> <!-- 表格 -->
<el-row class="table-content"> <el-row class="table-content">
<el-table :data="tableData.sectionOrderList" border> <el-table :data="tableData.sectionOrderList" border max-height="500px">
<el-table-column label="序号" type="index" align="center" width="50" /> <el-table-column label="序号" type="index" align="center" width="50" />
<el-table-column label="订单号" align="center" prop="orderNo"> <el-table-column label="订单号" align="center" prop="orderNo">
<template slot-scope="scope"> <template slot-scope="scope">
...@@ -104,12 +104,23 @@ ...@@ -104,12 +104,23 @@
</el-col> </el-col>
</el-row> </el-row>
<!-- 操作 --> <!-- 审核流程 -->
<el-row class="button-area"> <el-row class="process-area">
<el-button type="primary" @click="handlerClick('supplementOrder','补单')" v-if="!isUnderReview">补单</el-button> <div class="process">
<el-button type="primary" v-if="!isUnderReview" @click="applyCloseCabinet">申请封柜</el-button> <div>审批流程</div>
<el-button type="primary" @click="handlerClick('modifyCabinet','修改柜信息')" v-if="!isUnderReview">修改柜信息</el-button> <work-flow xmlkey="close_container" v-model="selectedUsers"></work-flow>
<el-button type="primary" v-if="isUnderReview">封柜审核中</el-button> </div>
<!-- 操作 -->
<div v-if="!isUnderReview">
<el-button type="primary" @click="handlerClick('supplementOrder','补单')">补单</el-button>
<el-button type="primary" @click="applyCloseCabinet">封柜申请</el-button>
<el-button type="primary" @click="handlerClick('modifyCabinet','修改柜信息')">修改柜信息</el-button>
</div>
<div v-if="isUnderReview">
<el-button type="primary" :disabled=true>封柜审核中</el-button>
<el-button plain type="primary" @click="canclAudit">取消审核</el-button>
<el-button plain type="primary" @click="$emit('closeDialog')">返回</el-button>
</div>
</el-row> </el-row>
<!-- 对话框 --> <!-- 对话框 -->
...@@ -202,6 +213,7 @@ import { ...@@ -202,6 +213,7 @@ import {
remove, remove,
boxUpdate, boxUpdate,
approvalCreate, approvalCreate,
approvalCancel,
} from "@/api/ecw/boxSea"; } from "@/api/ecw/boxSea";
import { import {
getTotlContent, getTotlContent,
...@@ -210,6 +222,7 @@ import { ...@@ -210,6 +222,7 @@ import {
sumStatistics, sumStatistics,
} from "../../utils"; } from "../../utils";
import splitOrder from "./splitOrder.vue"; import splitOrder from "./splitOrder.vue";
import WorkFlow from "@/components/WorkFlow";
/** /**
* 开始装柜 * 开始装柜
...@@ -220,6 +233,7 @@ export default { ...@@ -220,6 +233,7 @@ export default {
components: { components: {
supplementOrder, supplementOrder,
splitOrder, splitOrder,
WorkFlow,
}, },
props: { props: {
shipmentObj: Object, shipmentObj: Object,
...@@ -267,6 +281,7 @@ export default { ...@@ -267,6 +281,7 @@ export default {
}, },
// 当前行 // 当前行
currRow: {}, currRow: {},
selectedUsers: [],
}; };
}, },
created() { created() {
...@@ -408,6 +423,7 @@ export default { ...@@ -408,6 +423,7 @@ export default {
params.orderNumCode = this.qrCode; params.orderNumCode = this.qrCode;
singleCreate(params).then((res) => { singleCreate(params).then((res) => {
serviceMsg(res, this).then(() => { serviceMsg(res, this).then(() => {
this.qrCode = "";
this.getLoadSecGoodsList(); this.getLoadSecGoodsList();
}); });
}); });
...@@ -415,6 +431,7 @@ export default { ...@@ -415,6 +431,7 @@ export default {
params.orderNo = this.batchObj.qrCode; params.orderNo = this.batchObj.qrCode;
batchCreate(params).then((res) => { batchCreate(params).then((res) => {
serviceMsg(res, this).then(() => { serviceMsg(res, this).then(() => {
this.closeDialog();
this.getLoadSecGoodsList(); this.getLoadSecGoodsList();
}); });
}); });
...@@ -431,12 +448,14 @@ export default { ...@@ -431,12 +448,14 @@ export default {
if (type === "single") { if (type === "single") {
singleDelete(params).then((res) => { singleDelete(params).then((res) => {
serviceMsg(res, this).then(() => { serviceMsg(res, this).then(() => {
this.closeDialog();
this.getLoadSecGoodsList(); this.getLoadSecGoodsList();
}); });
}); });
} else { } else {
batchDelete(params).then((res) => { batchDelete(params).then((res) => {
serviceMsg(res, this).then(() => { serviceMsg(res, this).then(() => {
this.closeDialog();
this.getLoadSecGoodsList(); this.getLoadSecGoodsList();
}); });
}); });
...@@ -474,11 +493,15 @@ export default { ...@@ -474,11 +493,15 @@ export default {
/* 申请封柜 */ /* 申请封柜 */
applyCloseCabinet() { applyCloseCabinet() {
approvalCreate({ approvalCreate({
shipmentId: this.shipmentObj.id, applyReason: "封柜审核",
approvalStatus: 0, approvalStatus: 0,
approvalType: 2, // 封柜 approvalType: 2, // 封柜
copyUserId: this.selectedUsers,
shipmentId: this.shipmentObj.id,
}).then((res) => { }).then((res) => {
serviceMsg(res, this); serviceMsg(res, this).then(() => {
this.$emit("closeDialog", "submit");
});
}); });
}, },
/* 是否显示拆单 */ /* 是否显示拆单 */
...@@ -488,6 +511,20 @@ export default { ...@@ -488,6 +511,20 @@ export default {
} }
return false; return false;
}, },
/* 取消审核 */
canclAudit() {
const { currNode } = this.$attrs;
const { voName } = currNode;
approvalCancel({
applyReason: "取消审核",
id: this.shipmentObj[voName].id,
shipmentId: this.shipmentObj.id,
}).then((res) => {
serviceMsg(res, this).then(() => {
this.$emit("closeDialog", "submit");
});
});
},
}, },
watch: { watch: {
listData(val) { listData(val) {
...@@ -613,8 +650,19 @@ export default { ...@@ -613,8 +650,19 @@ export default {
} }
} }
} }
.button-area {
text-align: center; .process-area {
margin-top: 15px;
padding-bottom: 30px;
.process {
display: flex;
flex-direction: column;
> :first-child {
color: #606266;
font-weight: bolder;
font-size: 16px;
}
}
} }
} }
</style> </style>
...@@ -29,7 +29,7 @@ ...@@ -29,7 +29,7 @@
<el-form-item label="截关时间"> <el-form-item label="截关时间">
<el-date-picker type="date" placeholder="请选择日期" v-model="cusDeclarationObj.dcCutOffTime" value-format="yyyy-MM-dd"></el-date-picker> <el-date-picker type="date" placeholder="请选择日期" v-model="cusDeclarationObj.dcCutOffTime" value-format="yyyy-MM-dd"></el-date-picker>
</el-form-item> </el-form-item>
<el-form-item label="状态"> <el-form-item label="状态" prop="dcCustomsStatus">
<el-radio-group v-model="cusDeclarationObj.dcCustomsStatus"> <el-radio-group v-model="cusDeclarationObj.dcCustomsStatus">
<el-radio v-for="item in this.getDictDatas(DICT_TYPE.BOX_SHIPPING_DCCUSTOMS_STATUS)" :key="item.value" :label="item.value">{{item.label}}</el-radio> <el-radio v-for="item in this.getDictDatas(DICT_TYPE.BOX_SHIPPING_DCCUSTOMS_STATUS)" :key="item.value" :label="item.value">{{item.label}}</el-radio>
</el-radio-group> </el-radio-group>
...@@ -160,6 +160,7 @@ export default { ...@@ -160,6 +160,7 @@ export default {
dcBoxWgt: [{ required: true, message: "必填", trigger: "change" }], dcBoxWgt: [{ required: true, message: "必填", trigger: "change" }],
dcGoodsWgt: [{ required: true, message: "必填", trigger: "change" }], dcGoodsWgt: [{ required: true, message: "必填", trigger: "change" }],
dcCustomsType: [{ required: true, message: "必填", trigger: "change" }], dcCustomsType: [{ required: true, message: "必填", trigger: "change" }],
dcCustomsStatus: [{ required: true, message: "必填", trigger: "change" }],
}, },
// 弹窗配置 // 弹窗配置
dialogConfig: { dialogConfig: {
......
...@@ -268,23 +268,24 @@ ...@@ -268,23 +268,24 @@
</el-form-item> </el-form-item>
</el-form> </el-form>
</el-row> </el-row>
<el-row>
<el-button type="primary" @click="onSubmit">提交申请</el-button>
</el-row>
</el-row> </el-row>
<!-- 审核流程 --> <!-- 审核流程 -->
<el-row class="process-area" v-show="isAudit"> <el-row class="process-area">
<div class="process"> <div class="process">
<div>审批流程</div> <div>审批流程</div>
<work-flow xmlkey="shipment_preassemble" v-model="selectedUsers"></work-flow> <work-flow xmlkey="shipment_preassemble" v-model="selectedUsers"></work-flow>
</div> </div>
<div> <div v-show="isAudit">
<el-button type="primary" :disabled=true>审核中</el-button> <el-button type="primary" :disabled=true>审核中</el-button>
<el-button plain type="primary" @click="canclAudit">取消审核</el-button> <el-button plain type="primary" @click="canclAudit">取消审核</el-button>
<el-button plain type="primary" @click="closeDialog">返回</el-button> <el-button plain type="primary" @click="closeDialog">返回</el-button>
</div> </div>
<div v-show="!isAudit">
<el-button type="primary" @click="onSubmit">提交申请</el-button>
</div>
</el-row> </el-row>
</div> </div>
</template> </template>
...@@ -447,9 +448,11 @@ export default { ...@@ -447,9 +448,11 @@ export default {
if (valid) { if (valid) {
approvalCreate({ approvalCreate({
...this.operatorData, ...this.operatorData,
shipmentId: this.$attrs.shipmentObj.id, applyReason: "预装审核",
approvalStatus: 0, approvalStatus: 0,
approvalType: 1, // 预装 approvalType: 1, // 预装
copyUserId: this.selectedUsers,
shipmentId: this.$attrs.shipmentObj.id,
}).then((res) => { }).then((res) => {
serviceMsg(res, this).then(() => { serviceMsg(res, this).then(() => {
this.$emit("closeDialog", "submit"); this.$emit("closeDialog", "submit");
...@@ -599,9 +602,9 @@ export default { ...@@ -599,9 +602,9 @@ export default {
const { currNode, shipmentObj } = this.$attrs; const { currNode, shipmentObj } = this.$attrs;
const { voName } = currNode; const { voName } = currNode;
approvalCancel({ approvalCancel({
applyReason: "取消审核",
id: shipmentObj[voName].id, id: shipmentObj[voName].id,
shipmentId: shipmentObj.id, shipmentId: shipmentObj.id,
applyReason: "取消审核",
}).then((res) => { }).then((res) => {
serviceMsg(res, this).then(() => { serviceMsg(res, this).then(() => {
this.$emit("closeDialog", "submit"); this.$emit("closeDialog", "submit");
......
...@@ -83,8 +83,9 @@ export default { ...@@ -83,8 +83,9 @@ export default {
this.$emit("closeDialog", type); this.$emit("closeDialog", type);
}, },
/* 关闭弹窗 */ /* 关闭弹窗 */
closeStart() { closeStart(type) {
this.dialogVisible = false; this.dialogVisible = false;
if (type) this.cancel(type);
}, },
// 开始卸柜 // 开始卸柜
startUnloading() { startUnloading() {
......
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
<!-- 表格 --> <!-- 表格 -->
<el-row class="table-area"> <el-row class="table-area">
<el-table v-loading="loading" :data="pageData.sectionOrderList" border> <el-table v-loading="loading" :data="pageData.sectionOrderList" border max-height="500px">
<el-table-column label="序号" type="index" align="center" width="50" /> <el-table-column label="序号" type="index" align="center" width="50" />
<el-table-column label="订单号" align="center" prop="orderNo"> <el-table-column label="订单号" align="center" prop="orderNo">
<template slot-scope="scope"> <template slot-scope="scope">
...@@ -73,8 +73,22 @@ ...@@ -73,8 +73,22 @@
</div> </div>
</el-row> </el-row>
<el-row> <!-- 审核流程 -->
<el-button type="success" @click="onSubmit">卸柜完成</el-button> <el-row class="process-area">
<div class="process">
<div>审批流程</div>
<work-flow xmlkey="unload_container" v-model="selectedUsers"></work-flow>
</div>
<!-- 操作 -->
<div v-if="!isUnderReview">
<el-button type="success" @click="onSubmit">卸柜完成</el-button>
<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 plain type="primary" @click="canclAudit">取消审核</el-button>
<el-button plain type="primary" @click="$emit('closeStart')">返回</el-button>
</div>
</el-row> </el-row>
<!-- 对话框 --> <!-- 对话框 -->
...@@ -91,9 +105,11 @@ import { ...@@ -91,9 +105,11 @@ import {
batchUnload, batchUnload,
allUnload, allUnload,
approvalCreate, approvalCreate,
approvalCancel,
getSectionList, getSectionList,
} from "@/api/ecw/boxSea"; } from "@/api/ecw/boxSea";
import { serviceMsg, getTotlContent } from "../../utils"; import { serviceMsg, getTotlContent } from "../../utils";
import WorkFlow from "@/components/WorkFlow";
/** /**
* 开始卸柜 * 开始卸柜
...@@ -101,7 +117,7 @@ import { serviceMsg, getTotlContent } from "../../utils"; ...@@ -101,7 +117,7 @@ import { serviceMsg, getTotlContent } from "../../utils";
export default { export default {
name: "startUnloading", name: "startUnloading",
inheritAttrs: false, inheritAttrs: false,
components: { unloadingError }, components: { unloadingError, WorkFlow },
data() { data() {
return { return {
// 标签号 // 标签号
...@@ -128,6 +144,7 @@ export default { ...@@ -128,6 +144,7 @@ export default {
sectionOrderList: [], sectionOrderList: [],
totalStatistics: {}, totalStatistics: {},
}, },
selectedUsers: [],
}; };
}, },
created() { created() {
...@@ -168,6 +185,7 @@ export default { ...@@ -168,6 +185,7 @@ export default {
shipmentId: this.$attrs.shipmentObj.id, shipmentId: this.$attrs.shipmentObj.id,
}).then((res) => { }).then((res) => {
serviceMsg(res, this).then((res) => { serviceMsg(res, this).then((res) => {
this.labelNo = "";
this.getLoadGoodsList(); this.getLoadGoodsList();
}); });
}); });
...@@ -192,6 +210,7 @@ export default { ...@@ -192,6 +210,7 @@ export default {
shipmentId: this.$attrs.shipmentObj.id, shipmentId: this.$attrs.shipmentObj.id,
approvalStatus: 0, approvalStatus: 0,
approvalType: 3, // 卸柜 approvalType: 3, // 卸柜
copyUserId: this.selectedUsers,
}).then((res) => { }).then((res) => {
serviceMsg(res, this).then(() => { serviceMsg(res, this).then(() => {
this.cancel(); this.cancel();
...@@ -200,7 +219,7 @@ export default { ...@@ -200,7 +219,7 @@ export default {
}, },
/** 取消 */ /** 取消 */
cancel() { cancel() {
this.$emit("closeStart"); this.$emit("closeStart", "submit");
}, },
/* 关闭弹窗 */ /* 关闭弹窗 */
closeDialog(type) { closeDialog(type) {
...@@ -229,8 +248,27 @@ export default { ...@@ -229,8 +248,27 @@ export default {
sectionChange() { sectionChange() {
this.getLoadGoodsList(); this.getLoadGoodsList();
}, },
/* 取消审核 */
canclAudit() {
const { currNode, shipmentObj } = this.$attrs;
const { voName } = currNode;
approvalCancel({
applyReason: "取消审核",
id: shipmentObj[voName].id,
shipmentId: shipmentObj.id,
}).then((res) => {
serviceMsg(res, this).then(() => {
this.cancel();
});
});
},
}, },
computed: { computed: {
/* 是否审核中 */
isUnderReview() {
const { currNode, shipmentObj } = this.$attrs;
return shipmentObj[currNode.keyName] === 183 ? true : false;
},
// 部分信息 // 部分信息
getSectionInfo() { getSectionInfo() {
const { totalStatistics, secStatistics } = this.pageData; const { totalStatistics, secStatistics } = this.pageData;
......
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