Commit 6d9de9f5 authored by 邓春圆's avatar 邓春圆

Merge remote-tracking branch 'origin/dev1.6' into dev1.6

parents 53a83095 9f380f9f
...@@ -359,7 +359,6 @@ ...@@ -359,7 +359,6 @@
</el-tab-pane> </el-tab-pane>
</el-tabs> </el-tabs>
<div v-if="edit"> <div v-if="edit">
<h2>{{ $t('审批流程') }}</h2> <h2>{{ $t('审批流程') }}</h2>
<work-flow xmlkey="free_apply" v-model="selectedUsers" /> <work-flow xmlkey="free_apply" v-model="selectedUsers" />
...@@ -420,7 +419,17 @@ export default { ...@@ -420,7 +419,17 @@ export default {
type: Boolean, type: Boolean,
default: false default: false
}, },
warehousing: { orderItemA: {
type: Object,
default: () => {
return {
material: undefined,
inTime: undefined,
orderWarehouseInBackItemDoList: []
}
}
},
orderItemB: {
type: Object, type: Object,
default: () => { default: () => {
return { return {
...@@ -433,6 +442,9 @@ export default { ...@@ -433,6 +442,9 @@ export default {
}, },
computed: { computed: {
warehousing(){
return {...this.orderItemA, ...this.orderItemB}
},
orderId(){ orderId(){
return this.order.orderId return this.order.orderId
}, },
...@@ -490,6 +502,7 @@ export default { ...@@ -490,6 +502,7 @@ export default {
if (val) { if (val) {
this.getProductBrandPage(this.warehousing.brandName) this.getProductBrandPage(this.warehousing.brandName)
this.handleBrandChange(parseInt(this.form.brand)) this.handleBrandChange(parseInt(this.form.brand))
this.init()
} else { } else {
this.$emit('close') this.$emit('close')
} }
...@@ -564,10 +577,6 @@ export default { ...@@ -564,10 +577,6 @@ export default {
} }
}, },
mounted() {
this.init()
},
methods: { methods: {
init(){ init(){
this.form.table = this.warehousing.orderWarehouseInBackItemDoList this.form.table = this.warehousing.orderWarehouseInBackItemDoList
......
...@@ -11,6 +11,7 @@ ...@@ -11,6 +11,7 @@
<h2>{{$t('货物信息')}}</h2> <h2>{{$t('货物信息')}}</h2>
<el-table <el-table
v-if="order.orderItemVOList && order.orderItemVOList.length > 0 && orderItemList && orderItemList.length > 0"
:data="order.orderItemVOList || []" :data="order.orderItemVOList || []"
style="width: 100%"> style="width: 100%">
<el-table-column <el-table-column
...@@ -81,16 +82,36 @@ ...@@ -81,16 +82,36 @@
prop="address" prop="address"
:label="$t('操作')"> :label="$t('操作')">
<template v-slot="{ row, column, $index }"> <template v-slot="{ row, column, $index }">
<warehouse v-if="isEdit" :warehousing="{...order.orderItemVOList[$index], ...orderItemList[$index]}" :title="$t('修改')" :order="order" @close="getList"></warehouse> <warehouse
v-if="isEdit"
:order-item-a="order.orderItemVOList[$index]"
:order-item-b="orderItemList[$index]"
:title="$t('修改')"
:order="order"
@close="getList"></warehouse>
<!-- <el-button v-if="isEdit" size="mini" type="text" @click="handleWarehousing(row)">{{$t('修改')}}</el-button>--> <!-- <el-button v-if="isEdit" size="mini" type="text" @click="handleWarehousing(row)">{{$t('修改')}}</el-button>-->
<template v-else-if="isAdd"> <template v-else-if="
wareItem(row.orderItemId)
&& wareItem(row.orderItemId).orderWarehouseInBackItemDoList
&& wareItem(row.orderItemId).orderWarehouseInBackItemDoList.length > 0">
<!-- <template v-if="!order.parentOrderId">--> <!-- <template v-if="!order.parentOrderId">-->
<warehouse :warehousing="{...order.orderItemVOList[$index], ...orderItemList[$index]}" :title="$t('追加')" :order="order" @close="getList"></warehouse> <warehouse
:order-item-a="order.orderItemVOList[$index]"
:order-item-b="orderItemList[$index]"
:title="$t('追加')"
:order="order"
@close="getList"></warehouse>
<!-- <el-button size="mini" type="text" @click="handleWarehousing(row)">{{$t('追加')}}</el-button>--> <!-- <el-button size="mini" type="text" @click="handleWarehousing(row)">{{$t('追加')}}</el-button>-->
<el-button size="mini" type="text" @click="handleWarehousingReturn(row)">{{$t('退仓')}}</el-button> <el-button size="mini" type="text" @click="handleWarehousingReturn(row)">{{$t('退仓')}}</el-button>
<!-- </template>--> <!-- </template>-->
</template> </template>
<warehouse v-else :warehousing="{...order.orderItemVOList[$index], ...orderItemList[$index]}" :title="$t('入仓')" :order="order" @close="getList"></warehouse> <warehouse
v-else
:order-item-a="order.orderItemVOList[$index]"
:order-item-b="orderItemList[$index]"
:title="$t('入仓')"
:order="order"
@close="getList"></warehouse>
<!-- <el-button v-else size="mini" type="text" @click="handleWarehousing(row)">{{$t('入仓')}}</el-button>--> <!-- <el-button v-else size="mini" type="text" @click="handleWarehousing(row)">{{$t('入仓')}}</el-button>-->
</template> </template>
</el-table-column> </el-table-column>
...@@ -233,7 +254,7 @@ export default { ...@@ -233,7 +254,7 @@ export default {
mounted() { mounted() {
if(this.$route.query.id){ if(this.$route.query.id){
this.orderId = parseInt(this.$route.query.id || undefined) this.orderId = parseInt(this.$route.query.id || undefined)
getOrderWarehouseIn(this.orderId).then(r => this.orderItemList = r.data) this.getOrderItemList()
getSpecialListByOrderId(this.orderId).then(r => this.specialList = r.data) getSpecialListByOrderId(this.orderId).then(r => this.specialList = r.data)
Promise.all([ Promise.all([
...@@ -291,9 +312,13 @@ export default { ...@@ -291,9 +312,13 @@ export default {
}, },
methods: { methods: {
getOrderItemList(){
this.orderItemList = []
return getOrderWarehouseIn(this.orderId).then(r => this.orderItemList = r.data)
},
getList(){ getList(){
this.getOrder() this.getOrder()
getOrderWarehouseIn(this.orderId).then(r => this.orderItemList = r.data) this.getOrderItemList()
}, },
getWarehousePictureList(){ getWarehousePictureList(){
return warehousePictureList({ return warehousePictureList({
...@@ -448,7 +473,7 @@ export default { ...@@ -448,7 +473,7 @@ export default {
message: this.$t('货物退仓成功!') message: this.$t('货物退仓成功!')
}); });
getOrderWarehouseIn(this.orderId).then(r => this.orderItemList = r.data) this.getOrderItemList()
this.getOrder() this.getOrder()
}) })
...@@ -461,7 +486,7 @@ export default { ...@@ -461,7 +486,7 @@ export default {
warehousingVisible(val) { warehousingVisible(val) {
if (!val){ if (!val){
this.getOrder() this.getOrder()
getOrderWarehouseIn(this.orderId).then(r => this.orderItemList = r.data) this.getOrderItemList()
} }
}, },
orderSpecialNeeds(val){ orderSpecialNeeds(val){
......
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