修改报错

dev
lilu 2 years ago
parent a40ca2231f
commit 8b5956ad19

@ -35,6 +35,7 @@
<a-textarea <a-textarea
id="shipper-scroll" id="shipper-scroll"
:defaultValue="details.shipper" :defaultValue="details.shipper"
v-model="showShipper"
:auto-size="{ minRows: 2, maxRows: 5 }" :auto-size="{ minRows: 2, maxRows: 5 }"
style="height: 100px" style="height: 100px"
@blur="textareaChange($event, 'shipper')" @blur="textareaChange($event, 'shipper')"
@ -74,6 +75,7 @@
<a-textarea <a-textarea
id="consignee-scroll" id="consignee-scroll"
:defaultValue="details.consignee" :defaultValue="details.consignee"
v-model="showConsignee"
:auto-size="{ minRows: 2, maxRows: 5 }" :auto-size="{ minRows: 2, maxRows: 5 }"
style="height: 100px" style="height: 100px"
@blur="textareaChange($event, 'consignee')" @blur="textareaChange($event, 'consignee')"
@ -113,6 +115,7 @@
:defaultValue="details.notifyparty" :defaultValue="details.notifyparty"
:auto-size="{ minRows: 2, maxRows: 5 }" :auto-size="{ minRows: 2, maxRows: 5 }"
style="height: 100px" style="height: 100px"
v-model="showNotifier"
@blur="textareaChange($event, 'notifyparty')" @blur="textareaChange($event, 'notifyparty')"
/> />
<div <div
@ -702,7 +705,10 @@ export default {
modelName: '', modelName: '',
yardType: '', yardType: '',
yardVisible: false, yardVisible: false,
customerModelconfirm: false customerModelconfirm: false,
showShipper: '',
showConsignee: '',
showNotifier: ''
} }
}, },
watch: { watch: {
@ -727,7 +733,7 @@ export default {
if (this.shipperData) { if (this.shipperData) {
const arr = [] const arr = []
this.shipperData.map((item, index) => { this.shipperData.map((item, index) => {
if (!arr.includes(item.title)) { if (item.title && !arr.includes(item.title)) {
arr.push(item.title) arr.push(item.title)
} }
}) })
@ -740,7 +746,7 @@ export default {
if (this.consigneeData) { if (this.consigneeData) {
const arr = [] const arr = []
this.consigneeData.map((item, index) => { this.consigneeData.map((item, index) => {
if (!arr.includes(item.title)) { if (item.title && !arr.includes(item.title)) {
arr.push(item.title) arr.push(item.title)
} }
}) })
@ -753,7 +759,7 @@ export default {
if (this.notifyData) { if (this.notifyData) {
const arr = [] const arr = []
this.notifyData.map((item, index) => { this.notifyData.map((item, index) => {
if (!arr.includes(item.title)) { if (item.title && !arr.includes(item.title)) {
arr.push(item.title) arr.push(item.title)
} }
}) })
@ -983,6 +989,8 @@ export default {
this.shippername = value this.shippername = value
const index = this.shipperDataArr.indexOf(value) const index = this.shipperDataArr.indexOf(value)
this.details.shipper = this.shipperData[index].content this.details.shipper = this.shipperData[index].content
this.showShipper = this.details.shipper
this.$forceUpdate()
}, },
shipperChange(value) { shipperChange(value) {
this.getTemplate(value, 'shipper') this.getTemplate(value, 'shipper')
@ -992,6 +1000,7 @@ export default {
this.consigneename = value this.consigneename = value
const index = this.consigneeDataArr.indexOf(value) const index = this.consigneeDataArr.indexOf(value)
this.details.consignee = this.consigneeData[index].content this.details.consignee = this.consigneeData[index].content
this.showConsignee = this.details.consignee
}, },
consigneeChange(value) { consigneeChange(value) {
this.getTemplate(value, 'consignee') this.getTemplate(value, 'consignee')
@ -1001,6 +1010,7 @@ export default {
this.notifypartyname = value this.notifypartyname = value
const index = this.notifyDataArr.indexOf(value) const index = this.notifyDataArr.indexOf(value)
this.details.notifyparty = this.notifyData[index].content this.details.notifyparty = this.notifyData[index].content
this.showNotifier = this.details.notifyparty
}, },
notifyChange(value) { notifyChange(value) {
this.getTemplate(value, 'notify') this.getTemplate(value, 'notify')

Loading…
Cancel
Save