Commit 273b9d47 authored by 我在何方's avatar 我在何方

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

parents 41d49146 fb194468
......@@ -63,6 +63,15 @@ export function exportPreloadGoodsList(query) {
});
}
// 导出海运预装单,上面的预装单是空运的
export function exportSeaPreloadGoodsList(query) {
return request({
url: "/ecw/box-preload-goods/downloadSeaPreloadGoodsList",
method: "get",
params: query
});
}
// 创建费用登记
export function createCost(data) {
if (data.id) {
......
......@@ -317,6 +317,21 @@ export function updateOrderArrival(data) {
});
}
/**
* 创建到港订单
*
* @export
* @param {*} data
* @return {*}
*/
export function createOrderArrival(data) {
return request({
url: `/ecw/box-arrival-air/create`,
method: "post",
data: data
});
}
/**
* 更新所有订单到港状态
*
......
......@@ -112,9 +112,9 @@ export function createSplitItem(data) {
}
// 删除订单拆单项
export function deleteSplitItem(id) {
export function deleteSplitItem(id, shipmentSplit = false) {
return request({
url: '/order/split-item/delete?id=' + id,
url: '/order/split-item/delete?id=' + id + '&shipmentSplit=' + shipmentSplit,
method: 'delete'
})
}
......
......@@ -26,7 +26,7 @@
</div>
</div>
<el-table :data="loadDetail.sectionOrderList" border class="mt-10">
<el-table :data="orders" border class="mt-10">
<el-table-column prop="orderNo" :label="$t('订单号')" align="center">
<template v-slot="{row}">
<el-button type="text" @click="jumpOrderDetail(row)">{{row.orderNo}}</el-button>
......@@ -152,6 +152,10 @@ export default {
},
},
computed: {
orders() {
if (!this.loadDetail) return [];
return this.loadDetail.sectionOrderList?.filter(item => this.details.orderIds?.indexOf(item.orderId) > -1)
},
/* 渠道 */
getShipChannelName() {
return (shippingChannelId) => {
......
......@@ -125,7 +125,10 @@
</el-dropdown-menu>
</el-dropdown>
<el-dropdown trigger="click" @command="(command)=>handleCommand(scope.row, command)" v-hasPermi="['shipment:box:download:downloadPreloadGoodsList','shipment:box:download:downloadLoadGoodsList','shipment:box:download:downloadReceivableList','shipment:box:download:downloadAgentListFiles','shipment:box:download:downloadSoncapFiles','shipment:box:download:zipDownload','shipment:box:download:downloadLadingCopy']">
<el-dropdown trigger="click" @command="(command)=>handleCommand(scope.row, command)" v-hasPermi="['shipment:air:download:downloadPreloadGoodsList',
'shipment:air:download:downloadLoadGoodsList','shipment:air:download:downloadReceivableList',
'shipment:air:download:downloadAgentListFiles','shipment:air:download:downloadSoncapFiles',
'shipment:air:download:zipDownload','shipment:air:download:downloadLadingCopy']">
<el-button type="primary">
{{$t('下载')}}<i class="el-icon-arrow-down el-icon--right"></i>
</el-button>
......
......@@ -213,7 +213,7 @@ import {
getbox,
getboxPage,
exportboxExcel,
getNoticeList, dealCustomsSplitNotify, exportPreloadGoodsList, zipDownload,
getNoticeList, dealCustomsSplitNotify, exportSeaPreloadGoodsList, zipDownload,
} from "@/api/ecw/box";
import {
downloadFile,
......@@ -495,7 +495,7 @@ export default {
// this.$t("预装单") + `(${row.selfNo}).xlsx`,
// "xlsx"
// );
this.exportExcel(exportPreloadGoodsList, { shipmentId: row.id }, this.$t("预装单") + `(${row.selfNo}).xlsx`)
this.exportExcel(exportSeaPreloadGoodsList, { shipmentId: row.id }, this.$t("预装单") + `(${row.selfNo}).xlsx`)
break;
case "downloadLoadGoodsList":
downloadFile(
......
......@@ -160,7 +160,7 @@ export default {
this.$set(this.airArrivalInfo, 'arriveOrderIdList', [])
this.arrivalOrderList = this.$attrs.shipmentObj.airArrivalInfo ? this.$attrs.shipmentObj.airArrivalInfo.arrivalOrderList : []
shipmentOrderList(this.$attrs.shipmentObj.id).then((r) => {
this.orderList = r.data
this.orderList = r.data ?? []
})
},
computed: {
......@@ -243,7 +243,9 @@ export default {
this.selectOrders = []
this.selectOrders.push(val)
let arr = this.arrivalOrderList.find((item) => item.orderId == val.orderId)
console.log(arr,'arr');
if (arr) {
console.log(formatDate(arr.actSecondTime),arr.actSecondTime);
this.$set(this.airArrivalInfo, 'actSecondTime', formatDate(arr.actSecondTime))
this.$set(this.airArrivalInfo, 'estTime', formatDate(arr.estTime))
this.$set(this.airArrivalInfo, 'actTime', formatDate(arr.actTime))
......
......@@ -638,7 +638,7 @@ export default {
removeShop(id) {
let that = this;
that.$confirm(this.$t("是否移除货物吗?")).then(function () {
deleteSplitItem(id).then((res) => {
deleteSplitItem(id, true).then((res) => {
that.$message.success(that.$t("移除成功"));
that.querySplitGoods();
});
......
......@@ -118,7 +118,7 @@ import dayjs from 'dayjs'
import { clearanceCreate } from '@/api/ecw/boxSea'
import { shipmentOrderList } from '@/api/ecw/boxAir'
import { formatDateStr, serviceMsg, formatDate } from '../utils'
import { updateOrderArrival } from '@/api/ecw/boxAir'
import { createOrderArrival } from '@/api/ecw/boxAir'
/**
* 清关
......@@ -173,7 +173,7 @@ export default {
if (typeof this.$attrs.shipmentObj.airArrivalInfo?.arrivalOrderList != 'undefined' && this.$attrs.shipmentObj.airArrivalInfo.arrivalOrderList) this.arrivalOrderList = this.$attrs.shipmentObj.airArrivalInfo.arrivalOrderList
if (typeof this.$attrs.shipmentObj.clearanceInfo?.clearanceOrderList != 'undefined' && this.$attrs.shipmentObj.clearanceInfo.clearanceOrderList) this.clearanceOrderList = this.$attrs.shipmentObj.clearanceInfo.clearanceOrderList
shipmentOrderList(this.$attrs.shipmentObj.id).then((r) => {
this.orderList = r.data
this.orderList = r.data ?? []
})
},
watch: {
......@@ -339,10 +339,12 @@ export default {
if (this.cusClearanceObj.clearanceType == 1) {
this.$refs['airArrivalForm'].validate((arrvalid) => {
if (arrvalid) {
updateOrderArrival({
createOrderArrival({
...this.airArrivalInfo,
shipmentId: this.$attrs.shipmentObj.id,
orderIdList: this.cusClearanceObj.clearanceOrderIdList
arriveOrderIdList: this.cusClearanceObj.clearanceOrderIdList,
arriveType: 1,
operateType: 2
}).then(() => {
clearanceCreate({
...this.cusClearanceObj,
......
......@@ -305,6 +305,16 @@ export default {
},
/** 提交 */
onSubmit() {
// let flag = false
// this.pageData.sectionOrderList.forEach(item=>{
// if(![118428,15].includes(item.status)){
// flag = true
// }
// })
// if(flag){
// this.$message.error(this.$t("存在未到港或未清关的订单"));
// return
// }
if(this.getUnLoadNumCount>0){
approvalCreate({
shipmentId: this.$attrs.shipmentObj.id,
......
......@@ -150,7 +150,7 @@ export default {
}
}
console.log(currIndex,this.currIndex)
if (currIndex > this.currIndex) {
if (currIndex > this.currIndex && !['cusClearance', 'unloading'].includes(node.type)) {
this.$message.error(this.errorMsg);
return;
}
......@@ -186,10 +186,6 @@ export default {
break;
// 清关
case "cusClearance":
if((!this.shipmentObj.airArrivalInfo || this.shipmentObj.airArrivalInfo.arriveType == 0) && this.shipmentObj.sapStatus != 152){
this.$message.error(this.$t("请先完成到港操作"));
return;
}
this.$set(this.dialogConfig, "width", "700px");
break;
// AGENT
......@@ -224,10 +220,6 @@ export default {
break;
// 卸柜
case "unloading":
if((!this.shipmentObj.clearanceInfo || this.shipmentObj.clearanceInfo.clearanceType == 0) && this.shipmentObj.clStatus != 132){
this.$message.error(this.$t("请先完成清关操作"));
return;
}
// 卸柜反审
const unStatus = this.shipmentObj[node.keyName];
if ([186].includes(unStatus)) {
......@@ -277,10 +269,6 @@ export default {
if (start.includes(val[keyName]) && val[voName]) {
node.currStatus = "wait";
if(type === "arrival" || type === "cusClearance"){
++nodeIndex;
continue;
}
}
if (wait.includes(val[keyName])) {
......
......@@ -860,8 +860,8 @@ export default {
},
removeShop(id) {
let that = this;
that.$confirm(this.$t("是否移除货物吗?")).then(function () {
deleteSplitItem(id).then((res) => {
that.$confirm(this.$t("确定移除货物吗?")).then(function () {
deleteSplitItem(id, true).then((res) => {
that.$message.success(that.$t("移除成功"));
that.querySplitGoods();
});
......
......@@ -49,12 +49,12 @@
</el-select>
</el-form-item>
<el-form-item :label="$t('始发仓')" prop="destinationId">
<el-select v-model="queryParams.originId" :placeholder="$t('请选择始发仓')" clearable>
<el-select v-model="queryParams.startWarehouseId" :placeholder="$t('请选择始发仓')" clearable>
<el-option v-for="item in exportWarehouseList" :label="$l(item, 'title')" :value="item.id" :key="item.id"></el-option>
</el-select>
</el-form-item>
<el-form-item :label="$t('目的仓')" prop="destinationId">
<el-select :multiple="true" v-model="queryParams.destinationId" multiple :placeholder="$t('请选择目的仓')" clearable>
<el-select :multiple="true" v-model="queryParams.destWarehouseIdArr" multiple :placeholder="$t('请选择目的仓')" clearable>
<el-option v-for="item in importWarehouseList" :label="$l(item, 'title')" :value="item.id" :key="item.id"></el-option>
</el-select>
</el-form-item>
......@@ -293,9 +293,14 @@
},
/** 查询列表 */
getList() {
this.loading = true;
this.loading = true;
let params = { ...this.queryParams}
if(params.destWarehouseIdArr?.length){
params.destWarehouseIds = params.destWarehouseIdArr?.join(',')
}
// 执行查询
allAchievementByPage(this.queryParams).then(response => {
allAchievementByPage(params).then(response => {
this.list = response.data.myAchievementDtos.list;
this.total = response.data.myAchievementDtos.total;
this.myAchievementData = response.data
......
......@@ -60,7 +60,7 @@
</td>
</tr>
</template>
<tr>
<tr style="border-top:2px solid #000">
<td style="text-align:center;width: 50px;" v-if="!preview">
</td>
......@@ -68,7 +68,7 @@
</td>
<td style="text-align:center;padding:0 0px;border:1px dashed #ccc;">
合计
</td>
<td style="text-align:center;padding:0 0px;border:1px dashed #ccc;">
{{calcTotal('cartonsNum')}}
......
......@@ -58,6 +58,11 @@
</image-display>
</template>
</el-table-column>
<el-table-column :label="$t('备注')" prop="remark" >
<template slot-scope="{row}">
{{row.remark}}
</template>
</el-table-column>
</el-table>
</el-dialog>
</template>
......
......@@ -192,6 +192,12 @@
<el-descriptions-item :label="$t('特殊要求备注')">
{{order.packageRemarks}}
</el-descriptions-item>
<el-descriptions-item :label="$t('目的港清关')">
{{['', $t('我司承接'), $t('客户自清')][order.portDestCustomsClear] || ''}}
</el-descriptions-item>
<el-descriptions-item :label="$t('发货方式')">
{{['', $t('多票'), $t('单票')][order.deliveryWay] || ''}}
</el-descriptions-item>
</el-descriptions>
</el-card>
<el-card class="card">
......
......@@ -223,7 +223,7 @@
{{$t('件数')}} <span class="red">*</span>
</template>
<template slot-scope="{row}">
<el-input v-model.number="row.num" @keyup.native="checkPositiveInterge(row, 'num')" :disabled="!canAddProduct || !productEditable" />
<el-input-number :min="0" :controls="false" style="width: 65px" v-model.number="row.num" :disabled="!canAddProduct || !productEditable" />
</template>
</el-table-column>
<el-table-column :label="$t('包装单位')" width="100px">
......@@ -236,7 +236,7 @@
</el-table-column>
<el-table-column :label="`${$t('数量')}(${$t('个')})`" width="120px">
<template slot-scope="{row}">
<el-input v-model="row.quantity" @keyup.native="checkPositiveInterge(row, 'quantity')" :disabled="!canAddProduct || !productEditable" />
<el-input-number :min="1" :step="1" style="width: 80px;" :controls="false" v-model="row.quantity" :disabled="!canAddProduct || !productEditable" />
</template>
</el-table-column>
<el-table-column :label="$t('总体积') + '(m³)'" width="120px">
......@@ -248,7 +248,7 @@
]"
class="mb-0 mr-0"
>
<el-input v-model="scope.row.volume" :disabled="!canAddProduct || !productEditable" />
<el-input-number :min="0" v-model="scope.row.volume" :disabled="!canAddProduct || !productEditable" :controls="false" style="width: 80px" />
</el-form-item>
</template>
</el-table-column>
......@@ -261,7 +261,7 @@
]"
class="mb-0 mr-0"
>
<el-input v-model="scope.row.weight" :disabled="!canAddProduct || !productEditable" />
<el-input-number :min="0" :controls="false" style="width: 80px" v-model="scope.row.weight" :disabled="!canAddProduct || !productEditable" />
</el-form-item>
</template>
</el-table-column>
......@@ -279,7 +279,7 @@
class="mb-0 mr-0"
>
<!--input事件在快速输入的时候,可能最后拿到的结果不是最后输入的参数,所以改成在blur的时候计算-->
<el-input v-model.number="scope.row.worth" :disabled="!canAddProduct" @blur="calculationPrice" type="number" />
<el-input-number :min="0" :controls="false" style="width: 80px" v-model.number="scope.row.worth" :disabled="!canAddProduct" @blur="calculationPrice" />
</el-form-item>
</template>
</el-table-column>
......@@ -1060,8 +1060,8 @@ export default {
},
activated(){
if(this.$route.query.id != this.form.id){
console.log("activated 加载订单数据")
this.getOrder()
console.log("activated 加载订单数据")
this.getOrder()
}
let transportType = undefined
if(this.$route.query.transportType){
......@@ -1075,19 +1075,22 @@ export default {
this.updateChannel = this.$route.query.updateChannel == 1
},
async created() {
// 初始化自定义付款人需要在前面,否则先执行activated里的getOrder,会被覆盖
this.getDictDatas(this.DICT_TYPE.ECW_CUSTOM_DRAWEE).forEach(item => {
this.customDraweeList.push({
label: item.label, // 显示文字
name: item.value, // key值
value: 2 // 1 发货人,2收货人,默认收货人,可修改
})
})
this.productAttrList = (await getProductAttrList()).data
this.channelList = (await getChannelList()).data
this.tradeCityList = (await getTradeCityList()).data
this.currencyList = (await getCurrencyList()).data
this.unitList = (await getUnitList()).data
this.transportList = this.getDictDatas(this.DICT_TYPE.ECW_TRANSPORT_TYPE)
this.getDictDatas(this.DICT_TYPE.ECW_CUSTOM_DRAWEE).forEach(item => {
this.customDraweeList.push({
label: item.label, // 显示文字
name: item.value, // key值
value: 2 // 1 发货人,2收货人,默认收货人,可修改
})
})
if(this.$route.query.transportType){
this.$set(this.form, 'transportId', +this.$route.query.transportType)
}
......@@ -1110,11 +1113,12 @@ export default {
onTableMounted(e){
// console.warn('onTableMounted', e)
},
getOrder(){
async getOrder(){
if(this.form.orderId == this.$route.query.id){
console.log('加载中或者已加载此订单数据,不重复加载', this.initing, this.form.orderId, this.$route.query.id)
return
}
this.$nextTick()
this.initing = true
getUpdateInfo(this.$route.query.id).then(res => {
this.form = Object.assign({}, {...res.data}, {orderItemVOList: []})
......@@ -1168,9 +1172,12 @@ export default {
// 如果是自定义付款人,则需要同步具体发货人信息
if(this.form.drawee == 3){
console.log('同步自定义付款人信息', JSON.stringify(this.customDraweeList))
this.customDraweeList.forEach(item => {
console.log(item.name, this.form.customDraweeVOList.find(it => it.name == item.name)?.value , item.value)
item.value = this.form.customDraweeVOList.find(it => it.name == item.name)?.value || item.value
})
console.log('同步自定义付款人信息', this.customDraweeList, this.form.customDraweeVOList)
}
// 如果已完成入仓,则需要监听必填内容,发生更改后需要填写审批表单
......
......@@ -396,7 +396,8 @@
'ecw:order:warehouse_exit',
'ecw:order:warehouse_adjustment',
'ecw:order:warehouse_transfer',
'ecw:order:warehouse_arrive'
'ecw:order:warehouse_arrive',
'ecw:order:stocking'
]">
<el-button type="text">{{$t('仓库')}}</el-button>
<el-dropdown-menu slot="dropdown">
......
......@@ -215,14 +215,20 @@
<template slot-scope="scope">
<template v-if="scope.row.charging != 1">
<div class="flex">
{{$t('运费')}}
<el-input v-model="scope.row.oneSeaFreight" @change="updateField(scope.row, 'oneSeaFreight')" size="mini" style="width: 80px"></el-input>
{{currencyMap[scope.row.seaFreightCurrency]}} / {{unitMap[scope.row.seaFreightVolume]}}
{{$t('运费')}}:
<template v-if="scope.row.oneSeaFreight">
<el-input v-model="scope.row.oneSeaFreight" @change="updateField(scope.row, 'oneSeaFreight')" size="mini" style="width: 80px"></el-input>
{{currencyMap[scope.row.seaFreightCurrency]}} / {{unitMap[scope.row.seaFreightVolume]}}
</template>
<template v-else>{{$t('未报价')}}</template>
</div>
<div class="flex">
{{$t('清关费')}}
<el-input v-model="scope.row.oneClearanceFreight" @change="updateField(scope.row, 'oneClearanceFreight')" size="mini" style="width: 80px"></el-input>
{{currencyMap[scope.row.clearanceFreightCurrency]}} / {{unitMap[scope.row.clearanceFreightVolume]}}
{{$t('清关费')}}:
<template v-if="scope.row.oneClearanceFreight">
<el-input v-model="scope.row.oneClearanceFreight" @change="updateField(scope.row, 'oneClearanceFreight')" size="mini" style="width: 80px"></el-input>
{{currencyMap[scope.row.clearanceFreightCurrency]}} / {{unitMap[scope.row.clearanceFreightVolume]}}
</template>
<template v-else>{{$t('未报价')}}</template>
</div>
</template>
<template v-else>
......
......@@ -54,7 +54,7 @@
/
<selector :disabled="index > 0" @input="syncAllUnit" v-model="item.weightUnit" :options="unitList" :label-field="$l('title')" value-field="id" defaultable2 class="w100" />
</el-form-item>
<el-form-item :label="$t('默认运费')" v-if="form.priceType != 1">
<el-form-item :label="$t('默认运费')" v-if="form.priceType != 1" :key="`transportPrice-${index}`">
<inputor default2="0" v-model.number="item.transportPrice" type="number" :placeholder="$t('整数或者两位小数')" class="w100 mr10" />
<selector :disabled="index > 0" @input="syncAllUnit" v-model="item.transportPriceUnit" :options="currencyList" :label-field="$l('title')" value-field="id" defaultable2 class="w100" />
/ <selector :disabled="index > 0" @input="syncAllUnit" v-model="item.transportVolumeUnit" :options="unitList" :label-field="$l('title')" value-field="id" defaultable2 class="w100" />
......@@ -65,7 +65,7 @@
/ <selector :disabled="index > 0" @input="syncAllUnit" v-model="item.clearanceVolumeUnit" :options="unitList" :label-field="$l('title')" value-field="id" defaultable2 class="w100" />
</el-form-item>
<el-form-item :label="$t('默认全包价')" v-if="form.priceType == 1">
<el-form-item :label="$t('默认全包价')" v-if="form.priceType == 1" :key="`allPrice-${index}`">
<inputor default2="0" v-model.number="item.allPrice" type="number" :placeholder="$t('整数或者两位小数')" class="w100 mr10" />
<selector :disabled="index > 0" @input="syncAllUnit" v-model="item.allPriceUnit" :options="currencyList" :label-field="$l('title')" value-field="id" defaultable2 class="w100" />
/ <selector :disabled="index > 0" @input="syncAllUnit" v-model="item.allVolumeUnit" :options="unitList" :label-field="$l('title')" value-field="id" defaultable2 class="w100" />
......@@ -278,9 +278,25 @@ export default {
// 判断阶梯价是否设置不完整
isStepPriceOk(){
return (stepPrice) => {
console.log({
stepPrice,
startNum: this.isEmpty(stepPrice.startNum),
endNum:this.isEmpty(stepPrice.endNum),
allPrice: this.isEmpty(stepPrice.allPrice),
allPriceUnit: this.isEmpty(stepPrice.allPriceUnit),
allVolumeUnit: this.isEmpty(stepPrice.allVolumeUnit),
transportPrice: this.isEmpty(stepPrice.transportPrice),
transportPriceUnit: this.isEmpty(stepPrice.transportPriceUnit),
transportVolumeUnit: this.isEmpty(stepPrice.transportVolumeUnit),
priceType: this.form.priceType
})
if(this.isEmpty(stepPrice.startNum) || this.isEmpty(stepPrice.endNum)) return false
if(this.form.priceType == 1 && (this.isEmpty(stepPrice.allPrice) || this.isEmpty(stepPrice.allPriceUnit) || this.isEmpty(stepPrice.allVolumeUnit))) return false
else if(this.isEmpty(stepPrice.transportPrice) || this.isEmpty(stepPrice.transportPriceUnit)){ // 清关费可能为0或者空
if(this.form.priceType == 1 && (this.isEmpty(stepPrice.allPrice) || this.isEmpty(stepPrice.allPriceUnit) || this.isEmpty(stepPrice.allVolumeUnit))){
console.log('全包价设置不完整')
return false
}
else if(this.form.priceType != 1 && (this.isEmpty(stepPrice.transportPrice) || this.isEmpty(stepPrice.transportPriceUnit) || this.isEmpty(stepPrice.transportVolumeUnit))){ // 清关费可能为0或者空
console.log('非全报价,未设置完整')
return false
}
return true
......@@ -323,7 +339,7 @@ export default {
'form.needBook'(val){
if(val) this.$set(this.form, 'dayLimit', 10000)
else delete this.form.dayLimit
}
},
},
async created() {
getCurrencyList().then(res => this.currencyList = res.data)
......
......@@ -724,6 +724,12 @@ export default {
console.log(this.queryParams,'this.queryParams')
// 处理查询参数
let params = {...this.queryParams};
if(this.type == 'sea'){
params.transportType = 1
}
if(this.type == 'air'){
params.transportType = 3
}
this.addBeginAndEndTime(params, this.dateRangeCreateTime, 'createTime');
// 执行查询
console.log(params,'params')
......
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