Commit 7b846879 authored by dragondean@qq.com's avatar dragondean@qq.com

更新拆单数量是否必填接口

parent 07ea6e83
...@@ -134,4 +134,10 @@ export function serviceConfig(data) { ...@@ -134,4 +134,10 @@ export function serviceConfig(data) {
}) })
} }
// 数量是否必填
export function quantityRequired(lineId) {
return request({
url: '/ecw/warehouse/quantity/required/' + lineId,
method: 'get'
})
}
...@@ -96,7 +96,8 @@ ...@@ -96,7 +96,8 @@
</el-row> </el-row>
<el-row v-if="scope.row.warehouseInInfoVO"> <el-row v-if="scope.row.warehouseInInfoVO">
<span>{{$t('品牌')}} <span>{{$t('品牌')}}
<dict-tag :type="DICT_TYPE.ECW_IS_BRAND" :value="scope.row.feeType" /> <template v-if="scope.row.brandName">{{scope.row.brandName}}</template>
<dict-tag v-else :type="DICT_TYPE.ECW_IS_BRAND" :value="scope.row.feeType" />
</span> </span>
<span style="margin-left: 10px;">{{$t('箱数')}}:{{!scope.row.warehouseInInfoVO?0:scope.row.warehouseInInfoVO.cartonsNum}}</span> <span style="margin-left: 10px;">{{$t('箱数')}}:{{!scope.row.warehouseInInfoVO?0:scope.row.warehouseInInfoVO.cartonsNum}}</span>
<span style="margin-left: 10px;">{{$t('体积')}}:{{!scope.row.warehouseInInfoVO?0:scope.row.warehouseInInfoVO.volume}}m³</span> <span style="margin-left: 10px;">{{$t('体积')}}:{{!scope.row.warehouseInInfoVO?0:scope.row.warehouseInInfoVO.volume}}m³</span>
...@@ -137,8 +138,8 @@ ...@@ -137,8 +138,8 @@
<div> <div>
<el-button v-if="index==0" disabled type="primary" @click="addShop(index)">{{$t('放入')}}</el-button> <el-button v-if="index==0" disabled type="primary" @click="addShop(index)">{{$t('放入')}}</el-button>
<el-button v-if="index!=0" type="primary" @click="addShop(index)">{{$t('放入')}}</el-button> <el-button v-if="index!=0" type="primary" @click="addShop(index)">{{$t('放入')}}</el-button>
<el-button v-if="index==0" disabled type="primary" plain @click="deleteSplit(item.id)">{{$t('删除')}}</el-button> <!--<el-button v-if="index==0" disabled type="primary" plain @click="deleteSplit(item.id)">{{$t('删除')}}</el-button>-->
<el-button v-if="index!=0" type="primary" plain @click="deleteSplit(item.id)">{{$t('删除')}}</el-button> <el-button :disabled="index < splitData.length - 1" type="primary" plain @click="deleteSplit(item.id)">{{$t('删除')}}</el-button>
</div> </div>
</div> </div>
<el-table v-if="item.orderSplitItemBackVOList" border :data="item.orderSplitItemBackVOList"> <el-table v-if="item.orderSplitItemBackVOList" border :data="item.orderSplitItemBackVOList">
...@@ -151,7 +152,8 @@ ...@@ -151,7 +152,8 @@
<el-table-column :label="$t('英文名')" align="center" prop="prodTitleEn" /> <el-table-column :label="$t('英文名')" align="center" prop="prodTitleEn" />
<el-table-column :label="$t('品牌')" align="center"> <el-table-column :label="$t('品牌')" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :type="DICT_TYPE.ECW_IS_BRAND" :value="scope.row.brandType" /> <template v-if="scope.row.brandName">{{scope.row.brandName}}</template>
<dict-tag v-else :type="DICT_TYPE.ECW_IS_BRAND" :value="scope.row.feeType" />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="$t('入仓体积')" align="center" > <el-table-column :label="$t('入仓体积')" align="center" >
...@@ -310,10 +312,9 @@ import { ...@@ -310,10 +312,9 @@ import {
createSplitItem, createSplitItem,
deleteSplitItem, deleteSplitItem,
deleteSplit, deleteSplit,
quantitycheck,
deleteAllSplit deleteAllSplit
} from "@/api/ecw/orderHandle" } from "@/api/ecw/orderHandle"
import {getWarehouseList} from '@/api/ecw/warehouse' import {getWarehouseList, quantityRequired} from '@/api/ecw/warehouse'
import {getChannelList} from '@/api/ecw/channel' import {getChannelList} from '@/api/ecw/channel'
import WorkFlow from '@/components/WorkFlow' import WorkFlow from '@/components/WorkFlow'
import {getOrder, splitItemUpdate} from '@/api/ecw/order' import {getOrder, splitItemUpdate} from '@/api/ecw/order'
...@@ -378,17 +379,18 @@ export default { ...@@ -378,17 +379,18 @@ export default {
if (this.$route.query.orderId) { if (this.$route.query.orderId) {
this.queryParams.orderId = this.$route.query.orderId this.queryParams.orderId = this.$route.query.orderId
} }
await this.getList() Promise.all([this.getList(), this.getOrder()]).then(res => {
this.getOrder() console.log("拆单数据", this.splitData, this.splitData.length)
console.log("拆单数据", this.splitData, this.splitData.length) if(this.orderData.inWarehouseState != 207 && this.splitData.length){
if(this.splitData.length){ this.$confirm(this.$t('已有拆单数据,是否要重置?')).then(res => {
this.$confirm(this.$t('已有拆单数据,是否要重置?')).then(res => { return deleteAllSplit(this.queryParams.orderId)
return deleteAllSplit(this.queryParams.orderId) }).then(res => {
}).then(res => { this.getList()
this.getList() this.$message.success("重置成功")
this.$message.success("重置成功") })
}) }
} })
}, },
watch: { watch: {
//监听table这个对象 //监听table这个对象
...@@ -467,7 +469,7 @@ export default { ...@@ -467,7 +469,7 @@ export default {
}, },
getOrder(){ getOrder(){
this.loading = true; this.loading = true;
getOrder(this.queryParams.orderId).then(response => { return getOrder(this.queryParams.orderId).then(response => {
this.orderData = response.data this.orderData = response.data
this.query.destWarehouseId = response.data.logisticsInfoDto.startWarehouseId this.query.destWarehouseId = response.data.logisticsInfoDto.startWarehouseId
this.loading = false this.loading = false
...@@ -612,15 +614,15 @@ export default { ...@@ -612,15 +614,15 @@ export default {
this.shopForm.prodTitleEn = list[0].prodTitleEn this.shopForm.prodTitleEn = list[0].prodTitleEn
this.shopForm.prodTitleZh = list[0].prodTitleZh this.shopForm.prodTitleZh = list[0].prodTitleZh
var orderItemData = this.orderData.orderItemVOList.find(item=>item.orderItemId==this.shopForm.orderItemId) var orderItemData = this.orderData.orderItemVOList.find(item=>item.orderItemId==this.shopForm.orderItemId)
var params = { /*var params = {
'seaFreightVolume':orderItemData.seaFreightVolume, 'seaFreightVolume':orderItemData.seaFreightVolume,
'clearanceFreightVolume':orderItemData.clearanceFreightVolume 'clearanceFreightVolume':orderItemData.clearanceFreightVolume
} }
console.log(orderItemData) console.log(orderItemData)*/
this.numcheck(params) this.numcheck()
}, },
numcheck(params){ numcheck(){
quantitycheck(params).then(res=>{ quantityRequired(this.orderData.lineId).then(res=>{
this.quantityshow = res.data this.quantityshow = res.data
}) })
}, },
......
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