新页面

master
sunzehua 1 year ago
parent 0f86b41846
commit ff5427827e

@ -1239,8 +1239,7 @@ export default {
return false
}
}
if ((!basicFrom || !mailingFrom || !cargoFrom || !billFrom || !remarksFrom) &&
(Object.keys(basicObject)[0] !== 'zhanCangFlag' && Object.keys(basicObject).length !== 1)) {
if (!basicFrom || !mailingFrom || !cargoFrom || !billFrom || !remarksFrom) {
this.$message.error('保存失败,请检查必填项')
return false
}

@ -81,6 +81,7 @@
isParent="child"
@changeDetail="changeDetailFun"
@pkgsEnCapital="pkgsEnCapitalFun"
@spliceMore="spliceMorefun"
></mailingInfo>
<!-- 货物信息 -->
<cargoInfo
@ -89,10 +90,11 @@
:rules="cargoRules"
:inSave="inSave"
isParent="child"
@pkgsEnCapital="pkgsEnCapitalFun"
@changeDetail="changeDetailFun"
></cargoInfo>
<!-- 签单信息 -->
<billInfo
<!-- <billInfo
ref="billInfo"
:details="editDetails"
:rules="billRules"
@ -100,7 +102,6 @@
isParent="child"
@changeDetail="changeDetailFun"
></billInfo>
<!-- 备注信息 -->
<remarksInfo
ref="remarksInfo"
:details="editDetails"
@ -108,17 +109,17 @@
:inSave="inSave"
isParent="child"
@changeDetail="changeDetailFun"
></remarksInfo>
></remarksInfo> -->
<!-- 箱型 -->
<goodsTable
ref="goodsTable"
:details="editDetails"
:rules="tableRules"
:inSave="inSave"
isParent="child"
pType="secOrder"
isParent="parent"
@changeDetail="changeDetailFun"
></goodsTable>
@changeTotal="changeTotalFun"
@changeCtnInfo="changeCtnInfoFun">
</goodsTable>
</div>
</div>
<div id="tab-content2" class="tab-content" v-show="mainOrderActiveKey === '2'">
@ -432,8 +433,8 @@ export default {
this.$refs.basicInfo.$refs.basicFrom.clearValidate()
this.$refs.mailingInfo.$refs.mailingFrom.clearValidate()
this.$refs.cargoInfo.$refs.cargoFrom.clearValidate()
this.$refs.billInfo.$refs.billFrom.clearValidate()
this.$refs.remarksInfo.$refs.remarkFrom.clearValidate()
// this.$refs.billInfo.$refs.billFrom.clearValidate()
// this.$refs.remarksInfo.$refs.remarkFrom.clearValidate()
}
}
},
@ -476,6 +477,12 @@ export default {
}, 2000)
}
},
spliceMorefun(str) {
this.moreStr = str
},
pkgsEnCapitalFun(data) {
this.bookingDetails.totalno = data
},
checkFromInit() {
Object.keys(this.basicRules).map((item, index) => {
@ -587,6 +594,21 @@ export default {
saveFun() {
this.bookingOrderSave()
},
changeTotalFun(data) {
const { type, val } = data
if (type === 'totalKgs') {
this.editDetails.kgs = val || this.editDetails.kgs
} else if (type === 'totalPkgs') {
this.editDetails.pkgs = val || this.editDetails.pkgs
} else if (type === 'totalCbm') {
this.editDetails.cbm = val || this.editDetails.cbm
}
},
changeCtnInfoFun({ type, val }) {
if (type === 'kindpkgs') {
this.editDetails.kindpkgs = val
}
},
bookingOrderSave() {
if (!this.editDetails.hblno) {
this.$message.error('请输入分提单号')
@ -605,16 +627,16 @@ export default {
this.$refs.cargoInfo.$refs.cargoFrom.validate(valid => {
cargoFrom = valid
})
let billFrom = true
this.$refs.billInfo.$refs.billFrom.validate(valid => {
billFrom = valid
})
let remarksFrom = true
this.$refs.remarksInfo.$refs.remarkFrom.validate(valid => {
remarksFrom = valid
})
// let billFrom = true
// this.$refs.billInfo.$refs.billFrom.validate(valid => {
// billFrom = valid
// })
// let remarksFrom = true
// this.$refs.remarksInfo.$refs.remarkFrom.validate(valid => {
// remarksFrom = valid
// })
console.log(this.editDetails)
if (!basicFrom || !mailingFrom || !cargoFrom || !billFrom || !remarksFrom) {
if (!basicFrom || !mailingFrom || !cargoFrom) {
this.$message.error('保存失败,请检查必填项')
return false
}

Loading…
Cancel
Save