Commit b07cd6fb authored by 我在何方's avatar 我在何方

拆单应收款bug修复

parent 60ece7c1
...@@ -127,4 +127,13 @@ export function getMergeListByMergeId(params){ ...@@ -127,4 +127,13 @@ export function getMergeListByMergeId(params){
method: 'get', method: 'get',
params params
}) })
} }
\ No newline at end of file
// 计价单位的数量参数是否必传
export function quantitycheck(query) {
return request({
url: '/order/split-item/quantity/check',
method: 'get',
params: query
})
}
...@@ -59,7 +59,7 @@ export default { ...@@ -59,7 +59,7 @@ export default {
params.searchKey = keyword params.searchKey = keyword
this.loading = true this.loading = true
getCustomerSelect(params) getCustomerSelect(params)
.then(res => this.list = res.data) .then(res => this.list = res.data.list)
.finally(() => this.loading = false) .finally(() => this.loading = false)
} }
} }
......
...@@ -112,7 +112,11 @@ ...@@ -112,7 +112,11 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="$t('箱数')" align="center" prop="num" /> <el-table-column :label="$t('箱数')" align="center" prop="num" />
<el-table-column :label="$t('体积/重量')" align="center" prop="weight" /> <el-table-column :label="$t('体积/重量')" align="center" prop="weight">
<template slot-scope="scope">
{{ scope.row.volume}}/{{ scope.row.weight}}
</template>
</el-table-column>
<el-table-column :label="$t('收入类型')" align="center" prop="feeType"> <el-table-column :label="$t('收入类型')" align="center" prop="feeType">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag <dict-tag
...@@ -510,7 +514,11 @@ ...@@ -510,7 +514,11 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="$t('箱数')" align="center" prop="num" /> <el-table-column :label="$t('箱数')" align="center" prop="num" />
<el-table-column :label="$t('体积/重量')" align="center" prop="weight" /> <el-table-column :label="$t('体积/重量')" align="center" prop="weight">
<template slot-scope="scope">
{{ scope.row.volume}}/{{ scope.row.weight}}
</template>
</el-table-column>
<el-table-column :label="$t('发货人')" align="center" prop="consignorName" /> <el-table-column :label="$t('发货人')" align="center" prop="consignorName" />
<el-table-column :label="$t('收货人')" align="center" prop="consigneeName" /> <el-table-column :label="$t('收货人')" align="center" prop="consigneeName" />
<el-table-column :label="$t('订单状态')" align="center" prop="status"> <el-table-column :label="$t('订单状态')" align="center" prop="status">
...@@ -571,7 +579,11 @@ ...@@ -571,7 +579,11 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="$t('箱数')" align="center" prop="num" /> <el-table-column :label="$t('箱数')" align="center" prop="num" />
<el-table-column :label="$t('体积/重量')" align="center" prop="weight" /> <el-table-column :label="$t('体积/重量')" align="center" prop="weight">
<template slot-scope="scope">
{{ scope.row.volume}}/{{ scope.row.weight}}
</template>
</el-table-column>
<el-table-column :label="$t('收入类型')" align="center" prop="feeType"> <el-table-column :label="$t('收入类型')" align="center" prop="feeType">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag <dict-tag
......
This diff is collapsed.
...@@ -214,26 +214,29 @@ ...@@ -214,26 +214,29 @@
</div> </div>
</el-dialog> </el-dialog>
<!-- 对话框(添加 / 修改) --> <!-- 对话框(添加 / 修改) -->
<el-dialog :title="$t('放入品名')" :visible.sync="shopOpen" width="400px" append-to-body> <el-dialog :title="$t('放入品名')" :visible.sync="shopOpen" width="500px" append-to-body>
<el-form ref="shopForm" :model="shopForm" :rules="shopRules" label-width="80px"> <el-form ref="shopForm" :model="shopForm" :rules="shopRules" label-width="120px">
<el-row> <el-row>
<el-form-item :label="$t('中文品名')+':'" v-if="splitData.length>0"> <el-form-item :label="$t('中文品名')+':'" v-if="splitData.length>0">
<el-select v-model="shopForm.prodTitleZh" :placeholder="$t('请选择中文品名')" @change="changeProdTitleZh" clearable> <el-select v-model="shopForm.pordid" :placeholder="$t('请选择中文品名')" @change="changeProdTitleZh" clearable>
<el-option v-for="item in splitData[0].orderSplitItemBackVOList" :label="item.prodTitleZh" :value="item.prodTitleZh" :key="item.prodTitleZh" ></el-option> <el-option v-for="item in splitData[0].orderSplitItemBackVOList" :label="item.prodTitleZh" :value="item.id" :key="item.prodTitleZh" ></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-row> </el-row>
<el-row> <el-row>
<el-form-item :label="$t('英文品名')+':'" v-if="splitData.length>0"> <el-form-item :label="$t('英文品名')+':'" v-if="splitData.length>0">
<el-select v-model="shopForm.prodTitleEn" :placeholder="$t('请选择英文品名')" @change="changeProdTitleEn" clearable> <el-select v-model="shopForm.pordid" :placeholder="$t('请选择英文品名')" @change="changeProdTitleZh" clearable>
<el-option v-for="item in splitData[0].orderSplitItemBackVOList" :label="item.prodTitleEn" :value="item.prodTitleEn" :key="item.prodTitleEn" ></el-option> <el-option v-for="item in splitData[0].orderSplitItemBackVOList" :label="item.prodTitleEn" :value="item.id" :key="item.prodTitleEn" ></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item :label="$t('剩余箱数')+':'"> <el-form-item :label="$t('剩余箱数')+':'">
{{shopForm.sum||0}} {{shopForm.sum||0}}
</el-form-item> </el-form-item>
<el-form-item :label="$t('放入箱数')+':'"> <el-form-item :label="$t('放入箱数')+':'">
<el-input-number v-model="shopForm.num" controls-position="right" :min="1" :max="shopForm.sum"></el-input-number> <el-input-number v-model="shopForm.num" @change="numChange" controls-position="right" :min="1" :max="shopForm.sum"></el-input-number>
</el-form-item>
<el-form-item v-if="quantityshow" :label="$t('放入数量')+'('+$t('个')+')'+':'">
<el-input-number v-model="shopForm.quantity" controls-position="right" :min="1" :max="quantitySum"></el-input-number>
</el-form-item> </el-form-item>
<el-form-item :label="$t('备注信息')+':'"> <el-form-item :label="$t('备注信息')+':'">
<el-input v-model="shopForm.remarks"></el-input> <el-input v-model="shopForm.remarks"></el-input>
...@@ -265,7 +268,7 @@ ...@@ -265,7 +268,7 @@
<script> <script>
import {getDictData, getDictDatas,DICT_TYPE} from '@/utils/dict' import {getDictData, getDictDatas,DICT_TYPE} from '@/utils/dict'
import {getSplitList,splitApply,createSplit,cancelApply,createSplitItem,deleteSplitItem,deleteSplit} from "@/api/ecw/orderHandle" import {getSplitList,splitApply,createSplit,cancelApply,createSplitItem,deleteSplitItem,deleteSplit,quantitycheck} from "@/api/ecw/orderHandle"
import {getWarehouseList} from '@/api/ecw/warehouse' import {getWarehouseList} 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'
...@@ -297,7 +300,7 @@ export default { ...@@ -297,7 +300,7 @@ export default {
importCityList:[], importCityList:[],
selectedUsers:[], selectedUsers:[],
shopOpen:false, shopOpen:false,
quantityshow:false,
shopForm:{}, shopForm:{},
// 表单校验 // 表单校验
rules: { rules: {
...@@ -318,7 +321,8 @@ export default { ...@@ -318,7 +321,8 @@ export default {
page:1, page:1,
rows:20 rows:20
}, },
splitItemIndex:0 splitItemIndex:0,
quantitySum:0
}; };
}, },
created() { created() {
...@@ -457,6 +461,7 @@ export default { ...@@ -457,6 +461,7 @@ export default {
addShop(index){ addShop(index){
this.splitItemIndex = index this.splitItemIndex = index
this.shopOpen = true this.shopOpen = true
}, },
addSplit(){ addSplit(){
this.form.transportId = this.orderData.transportId this.form.transportId = this.orderData.transportId
...@@ -466,22 +471,38 @@ export default { ...@@ -466,22 +471,38 @@ export default {
if(this.orderData.logisticsInfoDto&&this.orderData.logisticsInfoDto.channelId){ if(this.orderData.logisticsInfoDto&&this.orderData.logisticsInfoDto.channelId){
this.form.channelId = this.orderData.logisticsInfoDto.channelId this.form.channelId = this.orderData.logisticsInfoDto.channelId
} }
} }
this.open = true this.open = true
}, },
changeProdTitleZh(){ changeProdTitleZh(val){
var list = [] var list = []
list = this.splitData[0].orderSplitItemBackVOList.filter(item=>item.prodTitleZh == this.shopForm.prodTitleZh) list = this.splitData[0].orderSplitItemBackVOList.filter(item=>item.id == val)
this.shopForm.sum = list[0].num this.shopForm.sum = list[0].num
this.quantitySum = list[0].quantity
this.shopForm.orderItemId = list[0].orderItemId this.shopForm.orderItemId = list[0].orderItemId
this.shopForm.prodTitleEn = list[0].prodTitleEn this.shopForm.prodTitleEn = list[0].prodTitleEn
this.shopForm.prodTitleZh = list[0].prodTitleZh
var params = {
'seaFreightVolume':list[0].seaFreightVolume,
'clearanceFreightVolume':list[0].clearanceFreightVolume
}
console.log(params)
this.numcheck(params)
},
numcheck(params){
quantitycheck(params).then(res=>{
this.quantityshow = res.data
})
},
numChange(){
var sum = parseInt(this.quantitySum/this.shopForm.num)
this.$set(this.shopForm,'quantity',sum)
}, },
changeProdTitleEn(){ changeProdTitleEn(){
var list = [] var list = []
list = this.splitData[0].orderSplitItemBackVOList.filter(item=>item.prodTitleEn == this.shopForm.prodTitleEn) list = this.splitData[0].orderSplitItemBackVOList.filter(item=>item.prodTitleEn == this.shopForm.prodTitleEn)
this.shopForm.sum = list[0].num this.shopForm.sum = list[0].num
this.quantitySum = list[0].quantity
this.shopForm.prodTitleZh = list[0].prodTitleZh this.shopForm.prodTitleZh = list[0].prodTitleZh
}, },
haddleAdd(){ haddleAdd(){
......
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