md
This commit is contained in:
parent
c4de100f95
commit
4fc51f69ac
@ -22,11 +22,7 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="8">
|
|
||||||
<el-form-item :label="$t('目的国家')" prop="destCountry">
|
|
||||||
<CountryPicker :placeholder="$t('选择国家')" v-model="coData.destCountry" ></CountryPicker>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
<el-col :span="8">
|
<el-col :span="8">
|
||||||
<el-form-item :label="$t('起始网点')" prop="startSiteCode">
|
<el-form-item :label="$t('起始网点')" prop="startSiteCode">
|
||||||
<EmisSiteSimplePicker :placeholder="$t('请选择')" @change="onSiteSelect" v-model="coData.startSiteCode" :disabled="$store.getters.ownerSiteCode != '88888'" ></EmisSiteSimplePicker>
|
<EmisSiteSimplePicker :placeholder="$t('请选择')" @change="onSiteSelect" v-model="coData.startSiteCode" :disabled="$store.getters.ownerSiteCode != '88888'" ></EmisSiteSimplePicker>
|
||||||
@ -61,7 +57,8 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="8" v-if="coData.transType == 2">
|
|
||||||
|
<!-- <el-col :span="8" v-if="coData.transType == 2">
|
||||||
<el-form-item :label="$t('航空单号')" prop="airBilllNo">
|
<el-form-item :label="$t('航空单号')" prop="airBilllNo">
|
||||||
<el-input v-model="coData.airBilllNo" />
|
<el-input v-model="coData.airBilllNo" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
@ -90,22 +87,34 @@
|
|||||||
placeholder="请选择开船时间">
|
placeholder="请选择开船时间">
|
||||||
</el-date-picker>
|
</el-date-picker>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col> -->
|
||||||
<el-col :span="8" v-if="['1','3','5'].indexOf(coData.transType) > -1">
|
|
||||||
<el-form-item :label="$t('车牌号')" prop="carNo">
|
<!-- v-if="['1','3','5'].indexOf(coData.transType) > -1" -->
|
||||||
|
<!-- v-if="['1','3','5'].indexOf(coData.transType) > -1" -->
|
||||||
|
|
||||||
|
<el-col :span="8" >
|
||||||
|
<el-form-item :label="$t('运输号')" prop="carNo">
|
||||||
<el-input v-model="coData.carNo" clearable="" placeholder=""></el-input>
|
<el-input v-model="coData.carNo" clearable="" placeholder=""></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="8" v-if="['1','3','5'].indexOf(coData.transType) > -1">
|
<el-col :span="8" >
|
||||||
<el-form-item label="发车时间" prop="carTime">
|
<el-form-item label="发出时间" prop="carTime">
|
||||||
<el-date-picker clearable
|
<el-date-picker clearable
|
||||||
v-model="coData.carTime"
|
v-model="coData.carTime"
|
||||||
type="date"
|
type="date"
|
||||||
value-format="yyyy-MM-dd"
|
value-format="yyyy-MM-dd"
|
||||||
placeholder="请选择发车时间">
|
placeholder="请选择发出时间"
|
||||||
|
style="width:100%"
|
||||||
|
|
||||||
|
>
|
||||||
</el-date-picker>
|
</el-date-picker>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item :label="$t('目的国')" prop="destCountry">
|
||||||
|
<CountryPicker :placeholder="$t('选择国')" v-model="coData.destCountry" ></CountryPicker>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
|
||||||
@ -553,9 +562,9 @@ export default {
|
|||||||
batchName: [
|
batchName: [
|
||||||
{ required: true, message: "批次名称不能为空", trigger: ["blur","change"] },
|
{ required: true, message: "批次名称不能为空", trigger: ["blur","change"] },
|
||||||
],
|
],
|
||||||
destCountry: [
|
// destCountry: [
|
||||||
{ required: true, message: "目的国不能为空", trigger: ["blur","change"] },
|
// { required: true, message: "目的国不能为空", trigger: ["blur","change"] },
|
||||||
],
|
// ],
|
||||||
startSiteCode: [
|
startSiteCode: [
|
||||||
{ required: true, message: "起始网点不能为空", trigger: ["blur","change"] },
|
{ required: true, message: "起始网点不能为空", trigger: ["blur","change"] },
|
||||||
],
|
],
|
||||||
@ -1010,14 +1019,14 @@ export default {
|
|||||||
this.wayBillData.dateTimeRange=value;
|
this.wayBillData.dateTimeRange=value;
|
||||||
},
|
},
|
||||||
async handleAddCoPack(){
|
async handleAddCoPack(){
|
||||||
if(!this.coData.batchName || !this.coData.destCountry || !this.coData.nextSiteCode || !this.coData.startSiteCode || !this.coData.transType
|
// if(!this.coData.batchName || !this.coData.destCountry || !this.coData.nextSiteCode || !this.coData.startSiteCode || !this.coData.transType
|
||||||
|| (this.coData.transType == "2" && (!this.coData.airBilllNo || !this.coData.airTime))
|
// || (this.coData.transType == "2" && (!this.coData.airBilllNo || !this.coData.airTime))
|
||||||
|| (this.coData.transType == "4" && (!this.coData.shipNo || !this.coData.shipTime))
|
// || (this.coData.transType == "4" && (!this.coData.shipNo || !this.coData.shipTime))
|
||||||
|| ((this.coData.transType == "1" || this.coData.transType == "3" || this.coData.transType == "5") && (!this.coData.carNo || !this.coData.carTime))
|
// || ((this.coData.transType == "1" || this.coData.transType == "3" || this.coData.transType == "5") && (!this.coData.carNo || !this.coData.carTime))
|
||||||
){
|
// ){
|
||||||
this.$modal.msgError("请先选择必填项")
|
// this.$modal.msgError("请先选择必填项")
|
||||||
return;
|
// return;
|
||||||
}
|
// }
|
||||||
if(this.emisCoPackDetail.length == 0){
|
if(this.emisCoPackDetail.length == 0){
|
||||||
this.$modal.msgError("请先选择至少一条运单信息")
|
this.$modal.msgError("请先选择至少一条运单信息")
|
||||||
return;
|
return;
|
||||||
@ -1055,16 +1064,18 @@ export default {
|
|||||||
totalVolume: this.coData.totalVolume || null,
|
totalVolume: this.coData.totalVolume || null,
|
||||||
totalWeight: this.coData.totalWeight || null,
|
totalWeight: this.coData.totalWeight || null,
|
||||||
}
|
}
|
||||||
if(this.coData.transType == 2){
|
// if(this.coData.transType == 2){
|
||||||
coPackItem.etd = parseTime(this.coData.airTime, '{y}-{m}-{d} {h}:{i}:{s}');
|
// coPackItem.etd = parseTime(this.coData.airTime, '{y}-{m}-{d} {h}:{i}:{s}');
|
||||||
this.coData.etd = parseTime(this.coData.airTime, '{y}-{m}-{d} {h}:{i}:{s}');
|
// this.coData.etd = parseTime(this.coData.airTime, '{y}-{m}-{d} {h}:{i}:{s}');
|
||||||
}else if(this.coData.transType == 4){
|
// }else if(this.coData.transType == 4){
|
||||||
coPackItem.etd = parseTime(this.coData.shipTime, '{y}-{m}-{d} {h}:{i}:{s}');
|
// coPackItem.etd = parseTime(this.coData.shipTime, '{y}-{m}-{d} {h}:{i}:{s}');
|
||||||
this.coData.etd = parseTime(this.coData.shipTime, '{y}-{m}-{d} {h}:{i}:{s}');
|
// this.coData.etd = parseTime(this.coData.shipTime, '{y}-{m}-{d} {h}:{i}:{s}');
|
||||||
}else{
|
// }else{
|
||||||
coPackItem.etd = parseTime(this.coData.carTime, '{y}-{m}-{d} {h}:{i}:{s}');
|
// }
|
||||||
this.coData.etd = parseTime(this.coData.carTime, '{y}-{m}-{d} {h}:{i}:{s}');
|
|
||||||
}
|
coPackItem.etd = parseTime(this.coData.carTime, '{y}-{m}-{d} {h}:{i}:{s}');
|
||||||
|
this.coData.etd = parseTime(this.coData.carTime, '{y}-{m}-{d} {h}:{i}:{s}');
|
||||||
|
|
||||||
if(this.coPackType == "add"){// 新增
|
if(this.coPackType == "add"){// 新增
|
||||||
let resPack = await getTmsGroupBatchNo();
|
let resPack = await getTmsGroupBatchNo();
|
||||||
if(!resPack || resPack.code != 200){
|
if(!resPack || resPack.code != 200){
|
||||||
@ -1421,14 +1432,14 @@ export default {
|
|||||||
this.wayBillotal=0;
|
this.wayBillotal=0;
|
||||||
},
|
},
|
||||||
handleCoPackListDelete(){
|
handleCoPackListDelete(){
|
||||||
if(!this.coData.batchName || !this.coData.destCountry || !this.coData.nextSiteCode || !this.coData.startSiteCode || !this.coData.transType
|
// if(!this.coData.batchName || !this.coData.destCountry || !this.coData.nextSiteCode || !this.coData.startSiteCode || !this.coData.transType
|
||||||
|| (this.coData.transType == "2" && (!this.coData.airBilllNo || !this.coData.airTime))
|
// || (this.coData.transType == "2" && (!this.coData.airBilllNo || !this.coData.airTime))
|
||||||
|| (this.coData.transType == "4" && (!this.coData.shipNo || !this.coData.shipTime))
|
// || (this.coData.transType == "4" && (!this.coData.shipNo || !this.coData.shipTime))
|
||||||
|| ((this.coData.transType == "1" || this.coData.transType == "3" || this.coData.transType == "5") && (!this.coData.carNo || !this.coData.carTime))
|
// || ((this.coData.transType == "1" || this.coData.transType == "3" || this.coData.transType == "5") && (!this.coData.carNo || !this.coData.carTime))
|
||||||
){
|
// ){
|
||||||
this.$modal.msgError("请先选择必填项")
|
// this.$modal.msgError("请先选择必填项")
|
||||||
return;
|
// return;
|
||||||
}
|
// }
|
||||||
|
|
||||||
if(this.coPackType == "edit"){
|
if(this.coPackType == "edit"){
|
||||||
this.$confirm('确认删除该条数据吗?', '确认信息')
|
this.$confirm('确认删除该条数据吗?', '确认信息')
|
||||||
@ -1555,80 +1566,17 @@ export default {
|
|||||||
/** 新增按钮操作 */
|
/** 新增按钮操作 */
|
||||||
handleAdd() {
|
handleAdd() {
|
||||||
|
|
||||||
|
|
||||||
},
|
},
|
||||||
async handleAdd_old() {
|
|
||||||
this.coPackType="add";
|
|
||||||
this.coData = {};
|
|
||||||
if(this.activeName=="first"){
|
|
||||||
let firstItemCountry = this.waitPackList.length > 0 ? this.waitPackList[0].receiveCountry : '';
|
|
||||||
// 将选中的“待组批次”的运单 置为 追加的运单号
|
|
||||||
for(let p = 0; p < this.waitPackList.length;p++){
|
|
||||||
if(this.waitPackList[p].receiveCountry != firstItemCountry){
|
|
||||||
this.$modal.msgError("存在了不同的目的国家!");
|
|
||||||
this.emisCoPackDetail=[];
|
|
||||||
return ;
|
|
||||||
}
|
|
||||||
this.emisCoPackDetail.push(this.waitPackList[p]);
|
|
||||||
}
|
|
||||||
}else if(this.activeName=="fourth"){
|
|
||||||
// let firstItemCountry = this.waitPackList.length > 0 ? this.waitPackList[0].receiveCountry : '';
|
|
||||||
// // 将选中的“待组批次”的运单 置为 追加的运单号
|
|
||||||
// for(let p = 0; p < this.waitPackList.length;p++){
|
|
||||||
// if(this.waitPackList[p].receiveCountry != firstItemCountry){
|
|
||||||
// this.$modal.msgError("存在了不同的目的国家!");
|
|
||||||
// this.emisCoPackDetail=[];
|
|
||||||
// return ;
|
|
||||||
// }
|
|
||||||
// this.emisCoPackDetail.push(this.waitPackList[p]);
|
|
||||||
// }
|
|
||||||
let res = await this.$refs.packListView.getPackBillList();
|
|
||||||
if(res.code == -1){
|
|
||||||
this.$modal.msgError(res.message);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
this.emisCoPackDetail = [...res.list];
|
|
||||||
}
|
|
||||||
this.tempExistCoPackWayBillList = [];// 清空临时保存的已有运单号
|
|
||||||
this.tempCoPackInfo={};
|
|
||||||
this.coData.createTime = parseTime(new Date());
|
|
||||||
this.coData.destCountry = null;
|
|
||||||
this.coData.destCountryName = null;
|
|
||||||
// this.coData.sendSiteCode = null;
|
|
||||||
this.coData.nextSiteCode = null;
|
|
||||||
this.coData.nextSiteName = null;
|
|
||||||
this.coData.nextStation = null;
|
|
||||||
// this.blUnpack = "1";
|
|
||||||
|
|
||||||
this.tableData = [
|
|
||||||
{ 1: '', 2: '', 3: '', 4: '', 5: '', 6: '' },
|
|
||||||
{ 1: '', 2: '', 3: '', 4: '', 5: '', 6: '' },
|
|
||||||
{ 1: '', 2: '', 3: '', 4: '', 5: '', 6: '' }
|
|
||||||
];
|
|
||||||
this.tableDataId=[
|
|
||||||
{ 1: '', 2: '', 3: '', 4: '', 5: '', 6: '' },
|
|
||||||
{ 1: '', 2: '', 3: '', 4: '', 5: '', 6: '' },
|
|
||||||
{ 1: '', 2: '', 3: '', 4: '', 5: '', 6: '' }
|
|
||||||
];
|
|
||||||
|
|
||||||
this.coData.startSiteCode = this.$store.getters.ownerSiteCode;
|
|
||||||
this.coData.startSiteName=this.$store.getters.ownerSiteName;
|
|
||||||
|
|
||||||
this.computeTotal();
|
|
||||||
|
|
||||||
this.currentId=null;
|
|
||||||
this.openForm= true;
|
|
||||||
this.titleForm = "新增组批次";
|
|
||||||
},
|
|
||||||
handleAddWayBill(){
|
handleAddWayBill(){
|
||||||
if(!this.coData.batchName || !this.coData.destCountry || !this.coData.nextSiteCode || !this.coData.startSiteCode || !this.coData.transType
|
// if(!this.coData.batchName || !this.coData.destCountry || !this.coData.nextSiteCode || !this.coData.startSiteCode || !this.coData.transType
|
||||||
|| (this.coData.transType == "2" && (!this.coData.airBilllNo || !this.coData.airTime))
|
// || (this.coData.transType == "2" && (!this.coData.airBilllNo || !this.coData.airTime))
|
||||||
|| (this.coData.transType == "4" && (!this.coData.shipNo || !this.coData.shipTime))
|
// || (this.coData.transType == "4" && (!this.coData.shipNo || !this.coData.shipTime))
|
||||||
|| ((this.coData.transType == "1" || this.coData.transType == "3" || this.coData.transType == "5") && (!this.coData.carNo || !this.coData.carTime))
|
// || ((this.coData.transType == "1" || this.coData.transType == "3" || this.coData.transType == "5") && (!this.coData.carNo || !this.coData.carTime))
|
||||||
){
|
// ){
|
||||||
this.$modal.msgError("请先选择必填项")
|
// this.$modal.msgError("请先选择必填项")
|
||||||
return;
|
// return;
|
||||||
}
|
// }
|
||||||
// this.openWayBillForm= true;
|
// this.openWayBillForm= true;
|
||||||
// this.titleWayBill = "运单列表";
|
// this.titleWayBill = "运单列表";
|
||||||
this.openBatch = true;
|
this.openBatch = true;
|
||||||
@ -1654,13 +1602,15 @@ export default {
|
|||||||
}
|
}
|
||||||
let resData = response.data;
|
let resData = response.data;
|
||||||
let time = {};
|
let time = {};
|
||||||
if(resData.transType == 2){
|
// if(resData.transType == 2){
|
||||||
time.airTime = resData.etd;
|
// time.airTime = resData.etd;
|
||||||
}else if(resData.transType == 4){
|
// }else if(resData.transType == 4){
|
||||||
time.shipTime = resData.etd;
|
// time.shipTime = resData.etd;
|
||||||
}else{
|
// }else{
|
||||||
time.carTime = resData.etd;
|
// time.carTime = resData.etd;
|
||||||
}
|
// }
|
||||||
|
|
||||||
|
time.carTime = resData.etd;
|
||||||
this.coData = {...resData, ...{batchDate:resData.createTime}, ...time};
|
this.coData = {...resData, ...{batchDate:resData.createTime}, ...time};
|
||||||
// this.coData.batchNo = resData.batchNo;
|
// this.coData.batchNo = resData.batchNo;
|
||||||
// this.coData.destCountry = resData.destCountry;
|
// this.coData.destCountry = resData.destCountry;
|
||||||
|
|||||||
@ -361,6 +361,7 @@
|
|||||||
<el-input v-model="form.billWeight" @blur="handleCalcSettlementWeight" @keyup.enter.native="handleCalcSettlementWeight" style="text-align: right;min-width: 80px" placeholder="" >
|
<el-input v-model="form.billWeight" @blur="handleCalcSettlementWeight" @keyup.enter.native="handleCalcSettlementWeight" style="text-align: right;min-width: 80px" placeholder="" >
|
||||||
<span slot="suffix">(kg)</span>
|
<span slot="suffix">(kg)</span>
|
||||||
</el-input>
|
</el-input>
|
||||||
|
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user