Commit 3d0bc626 authored by dragondean@qq.com's avatar dragondean@qq.com

Merge branch 'feature/order_edit' into test

# Conflicts:
#	src/views/ecw/order/index.vue
#	src/views/ecw/order/warehousing/components/Warehouse.vue
parents c6af7540 1c3c5c0c
...@@ -150,3 +150,21 @@ export function getGuojiaAndShiAndWarehouseList(params = {}) { ...@@ -150,3 +150,21 @@ export function getGuojiaAndShiAndWarehouseList(params = {}) {
params params
}) })
} }
// 出货阶段-追加申请
export function appendApplyWhenShipment(data) {
return request({
url: '/order/order-warehouse-in/append-apply-when-shipment',
method: 'post',
data
})
}
// 出货阶段-入仓修改申请
export function updateApplyWhenShipment(data) {
return request({
url: '/order/order-warehouse-in/update-apply-when-shipment',
method: 'post',
data
})
}
...@@ -357,10 +357,10 @@ ...@@ -357,10 +357,10 @@
</el-descriptions> </el-descriptions>
</el-card> </el-card>
<el-card class="mt-10"> <el-card class="mt-10 right-label">
<div class="card-title" slot="header">{{$t('通用')}}</div> <div class="card-title" slot="header">{{$t('通用')}}</div>
<div class="form-section"> <div class="form-section">
<el-form-item :label="$t('唛头')" prop="marks" class="w-500" > <el-form-item :label="$t('唛头')" prop="marks" class="w-500">
<el-input v-model="form.marks" ></el-input> <el-input v-model="form.marks" ></el-input>
</el-form-item> </el-form-item>
<el-form-item :label="$t('单证报关')" :span="2" prop="customsType"> <el-form-item :label="$t('单证报关')" :span="2" prop="customsType">
...@@ -380,8 +380,7 @@ ...@@ -380,8 +380,7 @@
<!--目的港清关:选择专线空运才显示,默认选中我司 <!--目的港清关:选择专线空运才显示,默认选中我司
我司选中后,按钮下方显示“多票”和“单票”的操作,默认选中多票。 我司选中后,按钮下方显示“多票”和“单票”的操作,默认选中多票。
客户选中后,按钮下方显示“单票”的操作,默认选中,无需点击--> 客户选中后,按钮下方显示“单票”的操作,默认选中,无需点击-->
<div class="form-section w-500"> <el-form-item :label="$t('目的港清关')" class="w-500">
<el-form-item :label="$t('目的港清关')">
<el-radio-group v-model="form.portDestCustomsClear"> <el-radio-group v-model="form.portDestCustomsClear">
<el-radio :label="1"> <el-radio :label="1">
{{$t('我司')}} {{$t('我司')}}
...@@ -397,8 +396,6 @@ ...@@ -397,8 +396,6 @@
</el-radio> </el-radio>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
</div>
<div class="form-section">
<el-form-item :label="$t('发货方式')"> <el-form-item :label="$t('发货方式')">
<el-radio-group v-model="form.deliveryWay"> <el-radio-group v-model="form.deliveryWay">
<el-radio :label="1" v-if="form.portDestCustomsClear == 1">{{$t('多票')}}</el-radio> <el-radio :label="1" v-if="form.portDestCustomsClear == 1">{{$t('多票')}}</el-radio>
...@@ -406,7 +403,6 @@ ...@@ -406,7 +403,6 @@
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
</div> </div>
</div>
<div class="form-section"> <div class="form-section">
<el-form-item :label="$t('是否控货')" prop="isCargoControl" class="w-500"> <el-form-item :label="$t('是否控货')" prop="isCargoControl" class="w-500">
<template #label> <template #label>
...@@ -454,7 +450,7 @@ ...@@ -454,7 +450,7 @@
</el-form-item> </el-form-item>
<div v-if="form.isExternalWarehouse"> <div v-if="form.isExternalWarehouse">
<div v-for="(item, index) in form.externalWarehouseDtoList" class="flex" :key="index"> <div v-for="(item, index) in form.externalWarehouseDtoList" class="flex" :key="index">
<div class="w-300"> <div class="w-380">
<el-form-item :label="$t('装货时间')" <el-form-item :label="$t('装货时间')"
:prop="'externalWarehouseDtoList.' + index + '.estLoadingTime'" :prop="'externalWarehouseDtoList.' + index + '.estLoadingTime'"
:rules="{ :rules="{
...@@ -1906,6 +1902,9 @@ export default { ...@@ -1906,6 +1902,9 @@ export default {
}; };
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.w-380{
width: 380px;
}
.card-title{ .card-title{
font-size: 18px; font-size: 18px;
display: flex; display: flex;
...@@ -1935,4 +1934,12 @@ export default { ...@@ -1935,4 +1934,12 @@ export default {
color: red; color: red;
} }
} }
::v-deep .right-label{
.el-form-item__label{
width: 150px;
display: inline-flex;
justify-content: flex-end;
align-items: center;
}
}
</style> </style>
...@@ -449,10 +449,28 @@ ...@@ -449,10 +449,28 @@
</el-dropdown-menu> </el-dropdown-menu>
</el-dropdown> </el-dropdown>
<template v-if="exclude(scope.row.status, [0, 11, 12, 13, 14, 15, 17, 18, 32]) && exclude(scope.row.inWarehouseState, [204, 205, 206])"> <template
v-if="
(exclude(scope.row.status,[0, 11, 12, 13, 14, 15, 17, 18, 32]) && exclude(scope.row.inWarehouseState, [204, 205, 206]))
||
(scope.row.shipmentState > 0 && scope.row.inWarehouseState == 0)
"
>
<!-- <el-divider direction="vertical"></el-divider> --> <!-- <el-divider direction="vertical"></el-divider> -->
<!--仓库相关的--> <!--仓库相关的-->
<el-dropdown v-hasPermi="['ecw:order:warehouse_add', 'ecw:order:warehouse_update', 'ecw:order:warehouse_exit', 'ecw:order:warehouse_adjustment', 'ecw:order:warehouse_transfer', 'ecw:order:warehouse_arrive', 'ecw:order:stocking']"> <el-dropdown
v-hasPermi="[
'ecw:order:warehouse_add',
'ecw:order:warehouse_update',
'ecw:order:warehouse_exit',
'ecw:order:warehouse_adjustment',
'ecw:order:warehouse_transfer',
'ecw:order:warehouse_arrive',
'ecw:order:stocking',
'ecw:order:shipment:warehouse_replenish',
'ecw:order:shipment:warehouse_update',
]"
>
<el-button type="text">{{ $t("仓库") }}</el-button> <el-button type="text">{{ $t("仓库") }}</el-button>
<el-dropdown-menu slot="dropdown"> <el-dropdown-menu slot="dropdown">
<!-- 入仓操作 --> <!-- 入仓操作 -->
...@@ -460,12 +478,66 @@ ...@@ -460,12 +478,66 @@
<el-dropdown-item @click.native="$router.push('/order/warehousing?id=' + scope.row.orderId)" v-hasPermi="['ecw:order:warehouse_add']">{{ $t("入仓操作") }}</el-dropdown-item> <el-dropdown-item @click.native="$router.push('/order/warehousing?id=' + scope.row.orderId)" v-hasPermi="['ecw:order:warehouse_add']">{{ $t("入仓操作") }}</el-dropdown-item>
</template> </template>
<!-- 入仓补充 --> <!-- 入仓补充 -->
<template v-if="include(scope.row.inWarehouseState, [201, 202, 202, 210, 202, 211, 202, 214, 215, 216]) && include(scope.row.status, [2, 3, 5, 10, 9, 8])"> <template
<el-dropdown-item @click.native="$router.push('/order/warehousing-add?id=' + scope.row.orderId)" v-hasPermi="['ecw:order:warehouse_replenish']">{{ $t("入仓补充") }}</el-dropdown-item> v-if="scope.row.shipmentState > 0 && scope.row.inWarehouseState == 0"
>
<el-dropdown-item
@click.native="$router.push('/order/warehousing-add?shipment=1&id=' + scope.row.orderId)"
v-hasPermi="['ecw:order:shipment:warehouse_replenish']"
>{{ $t("入仓补充") }}</el-dropdown-item
>
</template>
<template
v-else-if="
include(
scope.row.inWarehouseState,
[201, 202, 202, 210, 202, 211, 202, 214, 215, 216]
) && include(scope.row.status, [2, 3, 5, 10, 9, 8])
"
>
<el-dropdown-item
@click.native="
$router.push(
'/order/warehousing-add?id=' + scope.row.orderId
)
"
v-hasPermi="['ecw:order:warehouse_replenish']"
>{{ $t("入仓补充") }}</el-dropdown-item
>
</template> </template>
<!-- 入仓修改 --> <!-- 入仓修改 -->
<template v-if="include(scope.row.inWarehouseState, [201, 202, 207, 202, 209, 210, 202, 211, 202, 214, 215, 216, 204, 205]) && scope.row.status != 11 && exclude(scope.row.shipmentState, [314, 315, 317, 318])"> <template
<el-dropdown-item @click.native="$router.push('/order/warehousing-update?id=' + scope.row.orderId)" v-hasPermi="['ecw:order:warehouse_update']" :disabled2="scope.row.parentOrderId">{{ $t("入仓修改") }}</el-dropdown-item> v-if="scope.row.shipmentState > 0 && scope.row.inWarehouseState == 0"
>
<el-dropdown-item
@click.native="$router.push('/order/warehousing-update?shipment=1&id=' + scope.row.orderId)"
v-hasPermi="['ecw:order:shipment:warehouse_update']"
>{{ $t("入仓修改") }}</el-dropdown-item
>
</template>
<template
v-else-if="
include(
scope.row.inWarehouseState,
[
201, 202, 207, 202, 209, 210, 202, 211, 202, 214, 215,
216, 204, 205,
]
) &&
scope.row.status != 11 &&
exclude(scope.row.shipmentState, [305, 307, 407])
"
>
<el-dropdown-item
@click.native="
$router.push(
'/order/warehousing-update?id=' + scope.row.orderId
)
"
v-hasPermi="['ecw:order:warehouse_update']"
:disabled2="scope.row.parentOrderId"
>{{ $t("入仓修改") }}</el-dropdown-item
>
</template> </template>
<!-- 退仓 --> <!-- 退仓 -->
......
...@@ -407,8 +407,8 @@ ...@@ -407,8 +407,8 @@
</el-tab-pane> </el-tab-pane>
</el-tabs> </el-tabs>
<div v-if="edit && order.status !== 3"> <div v-if="(edit && order.status !== 3) || isShipment">
<h2>{{ $t("审批流程") }}</h2> <h2>{{ $t('审批流程') }}</h2>
<work-flow xmlkey="free_apply" v-model="selectedUsers" /> <work-flow xmlkey="free_apply" v-model="selectedUsers" />
<!-- <div>选择的用户:{{selectedUsers}}</div>--> <!-- <div>选择的用户:{{selectedUsers}}</div>-->
</div> </div>
...@@ -471,6 +471,7 @@ import { getProductTypeList } from "@/api/ecw/productType" ...@@ -471,6 +471,7 @@ import { getProductTypeList } from "@/api/ecw/productType"
import { addProduct } from "@/api/ecw/product" import { addProduct } from "@/api/ecw/product"
import ImageAndVideoUpload from "@/components/ImageAndVideoUpload/index.vue" import ImageAndVideoUpload from "@/components/ImageAndVideoUpload/index.vue"
import WarehouseRecordDetail from "@/views/ecw/order/warehousing/components/WarehouseRecordDetail.vue" import WarehouseRecordDetail from "@/views/ecw/order/warehousing/components/WarehouseRecordDetail.vue"
import { appendApplyWhenShipment, updateApplyWhenShipment } from '@/api/ecw/warehouse'
export default { export default {
name: "Warehouse", name: "Warehouse",
...@@ -520,6 +521,10 @@ export default { ...@@ -520,6 +521,10 @@ export default {
orderWarehouseInBackItemDoList: [] orderWarehouseInBackItemDoList: []
} }
} }
},
isShipment:{
type: Boolean,
default: false
} }
}, },
...@@ -803,7 +808,8 @@ export default { ...@@ -803,7 +808,8 @@ export default {
return return
} }
this.submitting = true this.submitting = true
return orderWarehouseIn({ const func = this.isShipment ? appendApplyWhenShipment : orderWarehouseIn
return func({
...this.form1, ...this.form1,
brandType: this.warehousing.brandType, brandType: this.warehousing.brandType,
orderId: this.warehousing.orderId, orderId: this.warehousing.orderId,
...@@ -849,7 +855,8 @@ export default { ...@@ -849,7 +855,8 @@ export default {
if (this.edit) { if (this.edit) {
// 入仓修改 // 入仓修改
this.submitting = true this.submitting = true
return orderWarehouseInUpdateApply({ const func = this.isShipment ? updateApplyWhenShipment : orderWarehouseInUpdateApply
return func({
...this.form, ...this.form,
brandType: this.warehousing.brandType, brandType: this.warehousing.brandType,
orderId: this.warehousing.orderId, orderId: this.warehousing.orderId,
......
...@@ -103,6 +103,7 @@ ...@@ -103,6 +103,7 @@
:order-item-b="orderItemList[$index]" :order-item-b="orderItemList[$index]"
:title="$t('修改')" :title="$t('修改')"
:order="order" :order="order"
:is-shipment="isShipment"
@close="getList" @close="getList"
></warehouse> ></warehouse>
<template <template
...@@ -120,9 +121,11 @@ ...@@ -120,9 +121,11 @@
:order-item-b="orderItemList[$index]" :order-item-b="orderItemList[$index]"
:title="$t('追加')" :title="$t('追加')"
:order="order" :order="order"
:is-shipment="isShipment"
@close="getList" @close="getList"
></warehouse> ></warehouse>
<el-button <el-button
v-if="!isShipment"
size="mini" size="mini"
type="text" type="text"
@click="handleWarehousingReturn(row)" @click="handleWarehousingReturn(row)"
...@@ -254,7 +257,7 @@ ...@@ -254,7 +257,7 @@
</el-card> </el-card>
<div <div
style="text-align: center; margin-top: 15px" style="text-align: center; margin-top: 15px"
v-if="!(order.status !== 3 && isEdit)" v-if="!(order.status !== 3 && isEdit) && !isShipment"
> >
<el-button @click="escapeBol = true" type="primary">{{ <el-button @click="escapeBol = true" type="primary">{{
$t("转异") $t("转异")
...@@ -696,6 +699,9 @@ export default { ...@@ -696,6 +699,9 @@ export default {
warehouseId() { warehouseId() {
return this.order?.logisticsInfoDto?.startWarehouseId; return this.order?.logisticsInfoDto?.startWarehouseId;
}, },
isShipment(){
return this.$route.query?.shipment==1
}
}, },
}; };
</script> </script>
......
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