|
|
@@ -1563,15 +1563,15 @@
|
|
|
</span>
|
|
|
<el-row>
|
|
|
<!-- <el-col :span="12"> -->
|
|
|
- <dic-select
|
|
|
- v-model="assemblyForm.cabinType"
|
|
|
- placeholder="舱位类型"
|
|
|
- key="id"
|
|
|
- label="dictValue"
|
|
|
- url="/blade-system/dict-biz/dictionary?code=cabinType"
|
|
|
- :disabled="detailData.seeDisabled"
|
|
|
- @selectChange="dicChange('cabinType', $event)"
|
|
|
- ></dic-select>
|
|
|
+ <dic-select
|
|
|
+ v-model="assemblyForm.cabinType"
|
|
|
+ placeholder="舱位类型"
|
|
|
+ key="id"
|
|
|
+ label="dictValue"
|
|
|
+ url="/blade-system/dict-biz/dictionary?code=cabinType"
|
|
|
+ :disabled="detailData.seeDisabled"
|
|
|
+ @selectChange="dicChange('cabinType', $event)"
|
|
|
+ ></dic-select>
|
|
|
<!-- </el-col> -->
|
|
|
<!-- <el-col :span="11" :offset="1">
|
|
|
<div>
|
|
|
@@ -1953,6 +1953,7 @@ import { selectListLos } from "@/api/approval/processConfig";
|
|
|
import _ from "lodash";
|
|
|
import dicSelect from "@/components/dicSelect/main";
|
|
|
import TreeSelect from "@/components/iosbasic-data/TreeSelect.vue";
|
|
|
+import { verifyData, updateVerifyData } from "@/api/iosBasicData/bills";
|
|
|
export default {
|
|
|
props: {
|
|
|
detailData: {
|
|
|
@@ -2024,7 +2025,7 @@ export default {
|
|
|
// return time.getTime() < Date.now() || time.getTime() > Date.parse(NdayDate(90))
|
|
|
// 获取前后的45天 Date.parse(NdayDate(45))
|
|
|
let timeDay = localStorage.getItem("timeFrame") ? localStorage.getItem("timeFrame") : 45;
|
|
|
- console.log(timeDay,time.getTime() < Date.parse(NdayDate(-timeDay)) || time.getTime() > Date.parse(NdayDate(timeDay - 1)))
|
|
|
+ console.log(timeDay, time.getTime() < Date.parse(NdayDate(-timeDay)) || time.getTime() > Date.parse(NdayDate(timeDay - 1)));
|
|
|
return time.getTime() < Date.parse(NdayDate(-timeDay)) || time.getTime() > Date.parse(NdayDate(timeDay - 1));
|
|
|
}
|
|
|
},
|
|
|
@@ -2308,30 +2309,75 @@ export default {
|
|
|
type: "warning"
|
|
|
})
|
|
|
.then(() => {
|
|
|
- let obj = {};
|
|
|
- obj = {
|
|
|
- date: this.assemblyForm.etd,
|
|
|
- type: 1,
|
|
|
- billId: this.assemblyForm.id
|
|
|
+ let obj = {
|
|
|
+ vesselId: this.assemblyForm.vesselId,
|
|
|
+ voyageNo: this.assemblyForm.voyageNo,
|
|
|
+ polId: this.assemblyForm.polId,
|
|
|
+ etd: this.assemblyForm.etd+" 00:00:00"
|
|
|
};
|
|
|
- console.log(obj);
|
|
|
- synchronizationExchangeRate(obj).then(res => {
|
|
|
- this.billsDetailfun();
|
|
|
+ verifyData(obj).then(res => {
|
|
|
+ if (res.data.data.etd != this.assemblyForm.etd) {
|
|
|
+ this.$confirm("系统检测到相同船名和航次的ETD和本单据的ETD不同,是否对ETD日期进行覆盖或更新?", "提示", {
|
|
|
+ confirmButtonText: "覆盖",
|
|
|
+ cancelButtonText: "更新",
|
|
|
+ type: "warning"
|
|
|
+ })
|
|
|
+ .then(() => {
|
|
|
+ this.assemblyForm.etd = res.data.data.etd;
|
|
|
+ this.etdSubmit(1);
|
|
|
+ })
|
|
|
+ .catch(() => {
|
|
|
+ updateVerifyData(obj).then(res => {
|
|
|
+ this.etdSubmit(1);
|
|
|
+ });
|
|
|
+ });
|
|
|
+ } else {
|
|
|
+ this.etdSubmit(1);
|
|
|
+ }
|
|
|
});
|
|
|
})
|
|
|
.catch(() => {
|
|
|
- let obj = {};
|
|
|
- obj = {
|
|
|
- date: this.assemblyForm.etd,
|
|
|
- type: 0,
|
|
|
- billId: this.assemblyForm.id
|
|
|
+ let obj = {
|
|
|
+ vesselId: this.assemblyForm.vesselId,
|
|
|
+ voyageNo: this.assemblyForm.voyageNo,
|
|
|
+ polId: this.assemblyForm.polId,
|
|
|
+ etd: this.assemblyForm.etd+" 00:00:00"
|
|
|
};
|
|
|
- synchronizationExchangeRate(obj).then(res => {
|
|
|
- this.billsDetailfun();
|
|
|
+ verifyData(obj).then(res => {
|
|
|
+ if (res.data.data.etd != this.assemblyForm.etd) {
|
|
|
+ this.$confirm("系统检测到相同船名和航次的ETD和本单据的ETD不同,是否对ETD日期进行覆盖或更新?", "提示", {
|
|
|
+ confirmButtonText: "覆盖",
|
|
|
+ cancelButtonText: "更新",
|
|
|
+ type: "warning"
|
|
|
+ })
|
|
|
+ .then(() => {
|
|
|
+ this.assemblyForm.etd = res.data.data.etd;
|
|
|
+ this.etdSubmit(0);
|
|
|
+ })
|
|
|
+ .catch(() => {
|
|
|
+ updateVerifyData(obj).then(res => {
|
|
|
+ this.etdSubmit(0);
|
|
|
+ });
|
|
|
+ });
|
|
|
+ } else {
|
|
|
+ this.etdSubmit(0);
|
|
|
+ }
|
|
|
});
|
|
|
});
|
|
|
}
|
|
|
},
|
|
|
+ etdSubmit(type) {
|
|
|
+ let obj = {};
|
|
|
+ obj = {
|
|
|
+ date: this.assemblyForm.etd,
|
|
|
+ type: type,
|
|
|
+ billId: this.assemblyForm.id
|
|
|
+ };
|
|
|
+ console.log(obj);
|
|
|
+ synchronizationExchangeRate(obj).then(res => {
|
|
|
+ this.billsDetailfun();
|
|
|
+ });
|
|
|
+ },
|
|
|
// 易燃易爆品闪点类型为数字
|
|
|
dgFlashPointInput(val) {
|
|
|
this.$set(this.assemblyForm, "dgFlashPoint", regularInteger(val));
|
|
|
@@ -3006,15 +3052,15 @@ export default {
|
|
|
// }
|
|
|
let arr = ["hshipperDetails", "hconsigneeDetails", "hnotifyDetails", "hnotify2Details", "foreignAgencyDetails"];
|
|
|
if (arr.indexOf(name) != -1) {
|
|
|
- this.assemblyForm.detail[name] = _.toUpper(this.assemblyForm.detail[name]).replace(/\n+/g, '\n');
|
|
|
+ this.assemblyForm.detail[name] = _.toUpper(this.assemblyForm.detail[name]).replace(/\n+/g, "\n");
|
|
|
}
|
|
|
let arr2 = ["marks", "commodityDescr", "bookingRemarks", "siRemarks", "forwarding", "remarks", "cyRemarks"];
|
|
|
if (arr2.indexOf(name) != -1) {
|
|
|
- this.assemblyForm[name] = _.toUpper(this.assemblyForm[name]).replace(/\n+/g, '\n');
|
|
|
+ this.assemblyForm[name] = _.toUpper(this.assemblyForm[name]).replace(/\n+/g, "\n");
|
|
|
}
|
|
|
let arr3 = "placeReceiptNamePrint,polNamePrint,podNamePrint,destinationNamePrint,placeDeliveryNamePrint,potNamePrint".split(",");
|
|
|
if (arr3.indexOf(name) != -1) {
|
|
|
- this.assemblyForm[name] = _.toUpper(this.assemblyForm[name]).replace(/\n+/g, '\n');
|
|
|
+ this.assemblyForm[name] = _.toUpper(this.assemblyForm[name]).replace(/\n+/g, "\n");
|
|
|
}
|
|
|
// this.assemblyForm[name] = textareaWrap(this.assemblyForm[name])
|
|
|
},
|