Commit 39890aec authored by Smile's avatar Smile

需求 后台-集运-追加包裹

parent 87867671
This diff is collapsed.
...@@ -386,6 +386,14 @@ ...@@ -386,6 +386,14 @@
v-hasPermi="['ecw:order:warehouse_exit']" v-hasPermi="['ecw:order:warehouse_exit']"
>{{ $t("处理退仓") }} >{{ $t("处理退仓") }}
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item
@click.native="
openAdd = true
addForm.consNum = scope.row.consNum
"
v-hasPermi="['ecw:order:warehouse_exit']"
>{{ $t("包裹追加") }}
</el-dropdown-item>
</el-dropdown-menu> </el-dropdown-menu>
</el-dropdown> </el-dropdown>
</template> </template>
...@@ -411,6 +419,24 @@ ...@@ -411,6 +419,24 @@
<el-button @click="openInspectExit = false">取 消</el-button> <el-button @click="openInspectExit = false">取 消</el-button>
</div> </div>
</el-dialog> </el-dialog>
<!--订单追加-->
<el-dialog :title="$t('包裹追加申请')" :visible.sync="openAdd" width="500px" append-to-body>
<el-form ref="addForm" :model="addForm" :rules="rules" label-width="80px">
<el-form-item label="包裹编号:">
<template>
{{addForm.consNum}}
</template>
</el-form-item>
<el-form-item label="订单编号:">
<el-input style="width: 70%;margin-right: 5px" v-model="addForm.orderId"></el-input><el-button type="primary" @click="showAddForOrder = true">添加</el-button>
</el-form-item>
<el-form-item label="订单状态:">
<template slot-scope="scope">
<dict-tag :type="DICT_TYPE.ORDER_STATUS" :value="addForm.orderStatus"/>
</template>
</el-form-item>
</el-form>
</el-dialog>
<!-- 对话框(添加 / 修改) --> <!-- 对话框(添加 / 修改) -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body> <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px"> <el-form ref="form" :model="form" :rules="rules" label-width="80px">
...@@ -508,12 +534,14 @@ ...@@ -508,12 +534,14 @@
<cons-withdrawal v-if="show" :dialog-visible="show" :consId="consId"></cons-withdrawal> <cons-withdrawal v-if="show" :dialog-visible="show" :consId="consId"></cons-withdrawal>
<cons-withdrawal-exit v-if="showExit" :dialog-visible="showExit" :consId="consId"></cons-withdrawal-exit> <cons-withdrawal-exit v-if="showExit" :dialog-visible="showExit" :consId="consId"></cons-withdrawal-exit>
<cons-withdrawal-deal v-if="showReturnWarehouse" :dialog-visible="showReturnWarehouse" :consId="consId" ></cons-withdrawal-deal> <cons-withdrawal-deal v-if="showReturnWarehouse" :dialog-visible="showReturnWarehouse" :consId="consId" ></cons-withdrawal-deal>
<add-for-order v-if="showAddForOrder" :dialog-visible="showAddForOrder" :consId="consId"></add-for-order>
</div> </div>
</template> </template>
<script> <script>
import {createCons, deleteCons, exportConsExcel, getCons, getConsPage, updateCons, updateInspect} from "@/api/ecw/cons"; import {createCons, deleteCons, exportConsExcel, getCons, getConsPage, updateCons, updateInspect} from "@/api/ecw/cons";
import Transmutation from "@/views/ecw/cons/components/Transmutation.vue" import Transmutation from "@/views/ecw/cons/components/Transmutation.vue"
import addForOrder from "@/views/ecw/cons/addForOrder.vue"
import Template from "@/views/cms/template/index.vue"; import Template from "@/views/cms/template/index.vue";
import UserSelector from "@/components/UserSelector/index.vue"; import UserSelector from "@/components/UserSelector/index.vue";
import {getWarehouseList} from "@/api/ecw/warehouse"; import {getWarehouseList} from "@/api/ecw/warehouse";
...@@ -539,6 +567,7 @@ import ImageAndVideoUpload from "@/components/ImageAndVideoUpload/index.vue"; ...@@ -539,6 +567,7 @@ import ImageAndVideoUpload from "@/components/ImageAndVideoUpload/index.vue";
export default { export default {
name: "Cons", name: "Cons",
components: { components: {
addForOrder,
ImageAndVideoUpload, ImageAndVideoUpload,
Label, Label,
Selector, Selector,
...@@ -571,6 +600,7 @@ export default { ...@@ -571,6 +600,7 @@ export default {
showExit: false, showExit: false,
showAdd: false, showAdd: false,
showReturnWarehouse: false, showReturnWarehouse: false,
showAddForOrder: false,
consId: undefined, consId: undefined,
// 总条数 // 总条数
total: 0, total: 0,
...@@ -581,6 +611,7 @@ export default { ...@@ -581,6 +611,7 @@ export default {
title: "", title: "",
// 是否显示弹出层 // 是否显示弹出层
open: false, open: false,
openAdd: false,
// 编号搜索条件 // 编号搜索条件
noParam: { noParam: {
key: "numberKey", key: "numberKey",
...@@ -626,6 +657,11 @@ export default { ...@@ -626,6 +657,11 @@ export default {
form: { form: {
transportId: null, transportId: null,
}, },
// 追加表单参数
addForm: {
orderId: null,
orderStatus: null,
},
// 表单校验 // 表单校验
rules: { rules: {
signed: [{required: true, message: "是否被签收,0未签收,1已签收不能为空", trigger: "blur"}], signed: [{required: true, message: "是否被签收,0未签收,1已签收不能为空", trigger: "blur"}],
...@@ -921,7 +957,7 @@ export default { ...@@ -921,7 +957,7 @@ export default {
// 查找第一个不符合条件的包裹 // 查找第一个不符合条件的包裹
const invalidItem = this.consList.find(item => const invalidItem = this.consList.find(item =>
// 条件逻辑:允许转运的条件(取反后检测非法项) // 条件逻辑:允许转运的条件(取反后检测非法项)
!(item.status === 2 && !item.hasReturnStatus && !item.hasExitApproval && !item.hasAddApproval) !(item.status === 1 && !item.hasReturnStatus && !item.hasExitApproval && !item.hasAddApproval)
); );
if (invalidItem) { if (invalidItem) {
return this.$message.error( return this.$message.error(
......
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