Commit 0434d31a authored by dragondean@qq.com's avatar dragondean@qq.com

异常登记和费用登记的步骤适配海空

parent 95c648e8
......@@ -3,12 +3,12 @@
<el-form ref="costForm" :model="costObj" :rules="rules" label-width="80px">
<el-form-item :label="$t('操作步骤')" prop="opStepType">
<el-select v-if="flag=='sea'" v-model="costObj.opStepType" :placeholder="$t('请选择操作步骤')">
<el-option v-for="type in this.getDictDatas(DICT_TYPE.BOX_SHIPPING_PROCESS)" :key="type.value" :label="$l(type, 'label')" :value="type.value"></el-option>
<el-select v-model="costObj.opStepType" :placeholder="$t('请选择操作步骤')">
<el-option v-for="type in getDictDatas(DICT_TYPE[this.process])" :key="type.value" :label="$l(type, 'label')" :value="type.value"></el-option>
</el-select>
<el-select v-if="flag=='seaAir'" v-model="costObj.opStepType" :placeholder="$t('请选择操作步骤')">
<!--<el-select v-if="flag=='seaAir'" v-model="costObj.opStepType" :placeholder="$t('请选择操作步骤')">
<el-option v-for="type in this.getDictDatas(DICT_TYPE.BOX_SEA_AIR)" :key="type.value" :label="$l(type, 'label')" :value="type.value"></el-option>
</el-select>
</el-select>-->
</el-form-item>
<el-form-item :label="$t('费用类型')" prop="costType">
......@@ -51,6 +51,7 @@ import { getSupplierPage } from "@/api/ecw/supplier";
import { createCost } from "@/api/ecw/box";
import { serviceMsg } from "./shippingSea/utils";
import { getCurrencyList } from "@/api/ecw/currency";
import {getDictDatas} from "@/utils/dict";
export default {
name: "costForm",
......@@ -70,9 +71,21 @@ export default {
price: [{ required: true, message: this.$t("金额不能为空"), trigger: "blur" }],
priceUnit: [{ required: true, message: this.$t("金额单位不能为空"), trigger: "blur" }]
},
flag: 'sea'
// flag: 'sea'
};
},
computed:{
flag(){
return this.$attrs.flag || 'sea'
},
process(){
return {
'air': 'BOX_AIR_SHIPMENT_PROCESS',
'sea': 'BOX_SHIPPING_PROCESS',
'seaAir': 'BOX_SEA_AIR'
}[this.flag]
}
},
created() {
// 供应商
getSupplierPage({ pageNo: "1", pageSize: "10000" }).then((res) => {
......@@ -84,11 +97,12 @@ export default {
getCurrencyList().then((res) => {
this.currencyList = res.data ?? [];
});
if(this.$attrs.shipmentObj.bosType == 'seaAir'){
/*if(this.$attrs.shipmentObj.bosType == 'seaAir'){
this.flag = 'seaAir';
}
}*/
},
methods: {
getDictDatas,
submit() {
this.$refs["costForm"].validate((valid) => {
if (valid) {
......
......@@ -154,7 +154,7 @@
<editAirForm v-if="dialogCfg.open" @closeDialog="closeDialog" :shipmentObj="currRow" :warehouseList="warehouseList" :transportTypes="transportTypes" />
</template>
<template v-if="dialogCfg.dialogType === 'cost'">
<costForm v-if="dialogCfg.open" @closeDialog="closeDialog" :shipmentObj="currRow" />
<costForm v-if="dialogCfg.open" @closeDialog="closeDialog" :shipmentObj="currRow" flag="air" />
</template>
<template v-if="dialogCfg.dialogType === 'error'">
<regError v-if="dialogCfg.open" @closeDialog="closeDialog" :shipmentObj="currRow" :allUsers="allUsers" flag="air" />
......
......@@ -145,10 +145,10 @@
<editForm v-if="dialogCfg.open" @closeDialog="closeDialog" :shipmentObj="currRow" :warehouseList="warehouseList" :transportTypes="transportTypes" :cabinetList="cabinetList" />
</template>
<template v-if="dialogCfg.dialogType === 'cost'">
<costForm v-if="dialogCfg.open" @closeDialog="closeDialog" :shipmentObj="currRow" />
<costForm v-if="dialogCfg.open" @closeDialog="closeDialog" :shipmentObj="currRow" flag="seaAir" />
</template>
<template v-if="dialogCfg.dialogType === 'error'">
<regError v-if="dialogCfg.open" @closeDialog="closeDialog" :shipmentObj="currRow" :allUsers="allUsers" />
<regError v-if="dialogCfg.open" @closeDialog="closeDialog" :shipmentObj="currRow" :allUsers="allUsers" flag="seaAir" />
</template>
<template v-if="dialogCfg.dialogType === 'editLadingBill'">
<ladingBill v-if="dialogCfg.open" @closeDialog="closeDialog" :shipmentObj="currRow" :getCabinetName="getCabinetName" />
......
......@@ -192,10 +192,10 @@
<editForm v-if="dialogConfig.visible" @closeDialog="closeDialog" :shipmentObj="shipmentObj" :warehouseList="warehouseList" :transportTypes="transportTypes" :cabinetList="cabinetList" />
</template>
<template v-if="dialogConfig.type === 'cost'">
<costForm v-if="dialogConfig.visible" @closeDialog="closeDialog" :shipmentObj="shipmentObj" :costDetail="costDetail" />
<costForm v-if="dialogConfig.visible" @closeDialog="closeDialog" :shipmentObj="shipmentObj" :costDetail="costDetail" :flag="flag" />
</template>
<template v-if="dialogConfig.type === 'error'">
<regError v-if="dialogConfig.visible" @closeDialog="closeDialog" :shipmentObj="shipmentObj" :allUsers="allUsers" />
<regError v-if="dialogConfig.visible" @closeDialog="closeDialog" :shipmentObj="shipmentObj" :allUsers="allUsers" :flag="flag" />
</template>
<template v-if="dialogConfig.type === 'updateError'">
<updateError v-if="dialogConfig.visible" @closeDialog="closeDialog" :shipmentObj="shipmentObj" :errorInfo="errorInfo" />
......@@ -639,6 +639,11 @@ export default {
} else {
return getTotlContent(secStatistics);
}
},
// 异常登记和费用登记用到的标识
flag(){
// 地址中有seaAir则表示海空联运,否则就是海运
return this.$route.fullPath.toLowerCase().indexOf('seaair') > -1 ? 'seaAir' : 'air'
}
},
};
......
......@@ -195,7 +195,7 @@
<editForm v-if="dialogConfig.visible" @closeDialog="closeDialog" :shipmentObj="shipmentObj" :warehouseList="warehouseList" :transportTypes="transportTypes" :cabinetList="cabinetList" />
</template>
<template v-if="dialogConfig.type === 'cost'">
<costForm v-if="dialogConfig.visible" @closeDialog="closeDialog" :shipmentObj="shipmentObj" :costDetail="costDetail" />
<costForm v-if="dialogConfig.visible" @closeDialog="closeDialog" :shipmentObj="shipmentObj" :costDetail="costDetail" flag="air" />
</template>
<template v-if="dialogConfig.type === 'error'">
<regError v-if="dialogConfig.visible" @closeDialog="closeDialog" :shipmentObj="shipmentObj" :allUsers="allUsers" flag="air" />
......
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