Commit 181f0f7b authored by houjn@hikoon.cn's avatar houjn@hikoon.cn

Merge branch 'release' of...

Merge branch 'release' of http://gitlab.jdshangmen.com/jiedao-app/jiedao-app-operator into release2.2

 Conflicts:
	src/views/ecw/box/shippingSea/nodePage/cabinet/splitOrder.vue
parents 65d8dc0c 9e85c6c5
...@@ -343,3 +343,10 @@ export function updateUrl(data) { ...@@ -343,3 +343,10 @@ export function updateUrl(data) {
data, data,
}); });
} }
export function dealCustomsSplitNotify(notifyId){
return request({
url: `/shipment/box/dealCustomsSplitNotify?notifyId=${notifyId}`,
method: "get",
})
}
...@@ -210,7 +210,7 @@ import { ...@@ -210,7 +210,7 @@ import {
getbox, getbox,
getboxPage, getboxPage,
exportboxExcel, exportboxExcel,
getNoticeList, getNoticeList, dealCustomsSplitNotify,
} from "@/api/ecw/box"; } from "@/api/ecw/box";
import { import {
downloadFile, downloadFile,
...@@ -443,7 +443,7 @@ export default { ...@@ -443,7 +443,7 @@ export default {
} }
}, },
/** 查看按钮操作 */ /** 查看按钮操作 */
handleCommand(row, command) { async handleCommand(row, command) {
this.$set(this.dialogCfg, "fullscreen", false); this.$set(this.dialogCfg, "fullscreen", false);
switch (command) { switch (command) {
...@@ -530,6 +530,9 @@ export default { ...@@ -530,6 +530,9 @@ export default {
if ([5, 6, 7].includes(noticeType)) { if ([5, 6, 7].includes(noticeType)) {
this.$router.push("/boxSea/query/" + row.id); this.$router.push("/boxSea/query/" + row.id);
} }
if([9].includes(noticeType)){
await dealCustomsSplitNotify(row.notifyId)
}
this.closeDialog(); this.closeDialog();
break; break;
} }
......
...@@ -828,8 +828,8 @@ export default { ...@@ -828,8 +828,8 @@ export default {
remarks: this.shopForm.remarks, remarks: this.shopForm.remarks,
volume: this.putin.volume, volume: this.putin.volume,
weight: this.putin.weight, weight: this.putin.weight,
chargeWeight: this.putin.chargeWeight, chargeWeight: this.shopForm.chargeWeight,
chargeVolume: this.putin.chargeVolume, chargeVolume: this.shopForm.chargeVolume,
worth: this.shopForm.worth || 0, worth: this.shopForm.worth || 0,
specsRecordVOList:this.shopForm.specsRecordVOList, specsRecordVOList:this.shopForm.specsRecordVOList,
shipmentSplit: true shipmentSplit: true
...@@ -962,8 +962,17 @@ export default { ...@@ -962,8 +962,17 @@ export default {
// 根据比例计算默认的收费方数和收费重量 // 根据比例计算默认的收费方数和收费重量
const orderItem = this.orderData.orderItemVOList.find(item => item.orderItemId == this.shopForm.orderItemId) const orderItem = this.orderData.orderItemVOList.find(item => item.orderItemId == this.shopForm.orderItemId)
const rate = this.putin.num / orderItem.warehouseInInfoVO.cartonsNum const rate = this.putin.num / orderItem.warehouseInInfoVO.cartonsNum
this.$set(this.shopForm, 'chargeVolume', (orderItem.chargeVolume*rate).toFixed(2))
this.$set(this.shopForm, 'chargeWeight', (orderItem.chargeWeight*rate).toFixed(2)) /*
* 1 普货 2 重货 3 泡货
* 普货 收费数据=入仓数据
* 泡货 收费方数=入仓方数 收费重量 = 品名收费重量*比例
* 重货 收费方数=品名收费方数*比例 收费重量 = 入仓重量
* */
const chargeVolume = orderItem.itemType === 2 ? (orderItem.chargeVolume*rate).toFixed(2) : this.putin.volume
const chargeWeight = orderItem.itemType === 3 ? (orderItem.chargeWeight*rate).toFixed(2) : this.putin.weight
this.$set(this.shopForm, 'chargeVolume', chargeVolume)
this.$set(this.shopForm, 'chargeWeight', chargeWeight)
this.$set(this.shopForm, 'worth', (orderItem.worth*rate).toFixed(2)) this.$set(this.shopForm, 'worth', (orderItem.worth*rate).toFixed(2))
} }
}, },
......
...@@ -360,17 +360,23 @@ export default { ...@@ -360,17 +360,23 @@ export default {
this.$confirm(res.msg+this.$t('是否需要一起预装?'), this.$t("提示"), { this.$confirm(res.msg+this.$t('是否需要一起预装?'), this.$t("提示"), {
dangerouslyUseHTMLString: true, dangerouslyUseHTMLString: true,
type: "warning", type: "warning",
confirmButtonText: '预装关联单',
cancelButtonText: '仅当前订单'
}) })
.then((_) => { .then((_) => {
createGoods({ ...params, relationStatus: 2 }).then((res) => { createGoods({ ...params, relationStatus: 2, singleLoad: false }).then((res) => {
serviceMsg(res, this).then(() => { serviceMsg(res, this).then(() => {
this.queryAllData(); this.queryAllData();
}); });
}); });
}) })
.catch((_) => { .catch((_) => {
createGoods({ ...params, relationStatus: 2, singleLoad: true }).then((res) => {
serviceMsg(res, this).then(() => {
this.queryAllData(); this.queryAllData();
}); });
});
});
} }
}); });
}, },
......
...@@ -264,6 +264,7 @@ export default { ...@@ -264,6 +264,7 @@ export default {
}, },
methods: { methods: {
getCustomsOrderList(dcCustomsType) { getCustomsOrderList(dcCustomsType) {
if(dcCustomsType) dcCustomsType = ''
customsOrderList({ customsOrderList({
shipmentId: this.shipmentObj.id, shipmentId: this.shipmentObj.id,
customsTypes: dcCustomsType === "3" ? "2,3" : dcCustomsType, customsTypes: dcCustomsType === "3" ? "2,3" : dcCustomsType,
......
...@@ -699,7 +699,7 @@ export default { ...@@ -699,7 +699,7 @@ export default {
type: "warning", type: "warning",
}) })
.then((_) => { .then((_) => {
createGoods({ ...params, relationStatus: 1 }).then((res) => { createGoods({ ...params, relationStatus: 1, singleLoad: true }).then((res) => {
serviceMsg(res, this).then(() => { serviceMsg(res, this).then(() => {
this.queryAllData(); this.queryAllData();
}); });
...@@ -714,17 +714,23 @@ export default { ...@@ -714,17 +714,23 @@ export default {
this.$confirm(res.msg+this.$t('是否需要一起预装?'), this.$t("提示"), { this.$confirm(res.msg+this.$t('是否需要一起预装?'), this.$t("提示"), {
dangerouslyUseHTMLString: true, dangerouslyUseHTMLString: true,
type: "warning", type: "warning",
confirmButtonText: '预装关联单',
cancelButtonText: '仅当前订单'
}) })
.then((_) => { .then((_) => {
createGoods({ ...params, relationStatus: 2 }).then((res) => { createGoods({ ...params, relationStatus: 2, singleLoad: false }).then((res) => {
serviceMsg(res, this).then(() => { serviceMsg(res, this).then(() => {
this.queryAllData(); this.queryAllData();
}); });
}); });
}) })
.catch((_) => { .catch((_) => {
createGoods({ ...params, relationStatus: 2, singleLoad: true }).then((res) => {
serviceMsg(res, this).then(() => {
this.queryAllData(); this.queryAllData();
}); });
});
});
} }
}); });
} else { } else {
......
...@@ -94,7 +94,8 @@ ...@@ -94,7 +94,8 @@
</template> </template>
<template v-slot="{row,$index}"> <template v-slot="{row,$index}">
<el-form-item label-width="0"> <el-form-item label-width="0">
<el-input-number controls-position="right" :min="0" class="w-100 tight" v-model="row.boxGauge1" @blur="calcVolume(row)"/> <input class="input" v-model="row.boxGauge1" type="number" @keyup="calcVolume(row)" @change="calcVolume(row)" :min="0"></input>
<!--<el-input-number controls-position="right" :min="0" class="w-100 tight" v-model="row.boxGauge1" @blur="calcVolume(row)"/>-->
</el-form-item> </el-form-item>
</template> </template>
</el-table-column> </el-table-column>
...@@ -104,7 +105,8 @@ ...@@ -104,7 +105,8 @@
</template> </template>
<template v-slot="{row,$index}"> <template v-slot="{row,$index}">
<el-form-item label-width="0"> <el-form-item label-width="0">
<el-input-number controls-position="right" :min="0" class="w-100 tight" v-model="row.boxGauge2" @blur="calcVolume(row)" /> <input class="input" v-model="row.boxGauge2" type="number" @keyup="calcVolume(row)" @change="calcVolume(row)" :min="0"></input>
<!--<el-input-number controls-position="right" :min="0" class="w-100 tight" v-model="row.boxGauge2" @blur="calcVolume(row)" />-->
</el-form-item> </el-form-item>
</template> </template>
</el-table-column> </el-table-column>
...@@ -114,7 +116,8 @@ ...@@ -114,7 +116,8 @@
</template> </template>
<template v-slot="{row,$index}"> <template v-slot="{row,$index}">
<el-form-item label-width="0"> <el-form-item label-width="0">
<el-input-number controls-position="right" :min="0" class="w-100 tight" v-model="row.boxGauge3" @blur="calcVolume(row)"/> <input class="input" v-model="row.boxGauge3" type="number" @keyup="calcVolume(row)" @change="calcVolume(row)" :min="0"></input>
<!--<el-input-number controls-position="right" :min="0" class="w-100 tight" v-model="row.boxGauge3" @blur="calcVolume(row)"/>-->
</el-form-item> </el-form-item>
</template> </template>
</el-table-column> </el-table-column>
...@@ -338,12 +341,15 @@ export default { ...@@ -338,12 +341,15 @@ export default {
}, },
// 计算体积 // 计算体积
calcVolume(row){ calcVolume(row){
// 改了规格后按照规格计算体积
this.$set(row, 'calcVolumeByBoxGauge', 1)
let volume = Decimal(row.boxGauge1 || 0) let volume = Decimal(row.boxGauge1 || 0)
.times(Decimal(row.boxGauge2 || 0)) .times(Decimal(row.boxGauge2 || 0))
.times(Decimal(row.boxGauge3 || 0)).div(1000000) .times(Decimal(row.boxGauge3 || 0)).div(1000000)
// 如果是箱的单位要乘以箱数 // 如果是箱的单位要乘以箱数
if(row.specificationType === 1) { if(+row.specificationType === 1) {
row.volume = volume.times(Decimal(row.num || 0)) volume = volume.times(Decimal(row.num || 0))
} }
// 最低0.01 // 最低0.01
...@@ -355,16 +361,22 @@ export default { ...@@ -355,16 +361,22 @@ export default {
if(!locationArr || !locationArr.length) return '' if(!locationArr || !locationArr.length) return ''
let arr = [] let arr = []
locationArr.forEach(item => { locationArr.forEach(item => {
arr.push(`${item.areaName}${item.locationName || ''}`) arr.push(`${item.areaName || ''}${item.locationName || ''}`)
}) })
return Array.from(new Set(arr)).join(",") return Array.from(new Set(arr)).join(",")
}, },
// 根据箱数计算体积,重量,数量 // 根据箱数计算体积,重量,数量
calc(row){ calc(row){
const rate = row.num / this.warehouseRecord.cartonsNum const rate = row.num / this.warehouseRecord.cartonsNum
row.volume = (this.warehouseRecord.volume * rate).toFixed(2) row.volume = (this.warehouseRecord.volume * rate).toFixed(2)
row.weight = (this.warehouseRecord.weight * rate).toFixed(2) row.weight = (this.warehouseRecord.weight * rate).toFixed(2)
row.quantity = (this.warehouseRecord.quantityAll * rate).toFixed(0) row.quantity = (this.warehouseRecord.quantityAll * rate).toFixed(0)
// 如果是按照规格计算体积,则重新计算
if(row.calcVolumeByBoxGauge){
this.calcVolume(row)
}
}, },
closeDialog(){ closeDialog(){
this.show = false this.show = false
......
...@@ -33,9 +33,9 @@ ...@@ -33,9 +33,9 @@
<el-table-column :label="$t('重量') + '(kg)'" prop="weight" /> <el-table-column :label="$t('重量') + '(kg)'" prop="weight" />
<el-table-column :label="$t('数量(个)')" prop="quantity" /> <el-table-column :label="$t('数量(个)')" prop="quantity" />
<el-table-column :label="$t('入仓快递单号')" prop="expressNo" /> <el-table-column :label="$t('入仓快递单号')" prop="expressNo" />
<!--<el-table-column :label="$t('首次入仓时间')" prop="inTime" > <el-table-column :label="$t('首次入仓时间')" prop="inTime" >
<template slot-scope="{row}">{{row.inTime|parseTime}}</template> <template slot-scope="{row}">{{row.inTime|parseTime}}</template>
</el-table-column>--> </el-table-column>
<el-table-column :label="$t('储位')" prop="orderLocationBackVOList" > <el-table-column :label="$t('储位')" prop="orderLocationBackVOList" >
<template slot-scope="{row}"> <template slot-scope="{row}">
<!--{{getLocationName(row.orderLocationList)}}--> <!--{{getLocationName(row.orderLocationList)}}-->
...@@ -52,10 +52,12 @@ ...@@ -52,10 +52,12 @@
<script> <script>
import WarehouseAreaSelect from "@/components/WarehouseAreaSelect/index.vue"; import WarehouseAreaSelect from "@/components/WarehouseAreaSelect/index.vue";
import {parseTime} from "@/utils/ruoyi";
export default { export default {
name: "WarehouseRecord", name: "WarehouseRecord",
components: {WarehouseAreaSelect}, components: {WarehouseAreaSelect},
filters: {parseTime},
props:{ props:{
list:{ list:{
type: Array, type: Array,
...@@ -73,6 +75,7 @@ export default { ...@@ -73,6 +75,7 @@ export default {
this.show = true this.show = true
}, },
methods:{ methods:{
parseTime,
// 获取储位名称 // 获取储位名称
getLocationName(locationArr){ getLocationName(locationArr){
if(!locationArr || !locationArr.length) return '' if(!locationArr || !locationArr.length) return ''
......
...@@ -920,21 +920,6 @@ export default { ...@@ -920,21 +920,6 @@ export default {
} }
this.open = true this.open = true
}, },
/*changeProdTitleZh(val){
var list = []
list = this.splitData[0].orderSplitItemBackVOList.filter(item=>item.id == val)
this.shopForm.sum = list[0].num
this.quantitySum = list[0].quantity
this.shopForm.orderItemId = list[0].orderItemId
this.shopForm.prodTitleEn = list[0].prodTitleEn
this.shopForm.prodTitleZh = list[0].prodTitleZh
// 默认给一个
if(!this.shopForm.specsRecordVOList || !this.shopForm.specsRecordVOList.length){
this.addRow()
}
this.numcheck()
},*/
// 查询数量是否必填 // 查询数量是否必填
numcheck(){ numcheck(){
quantityRequired(this.orderData.lineId).then(res=>{ quantityRequired(this.orderData.lineId).then(res=>{
......
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