修改输入清空

dev
lilu 2 years ago
parent 9746ca3f40
commit 7879bd3149

@ -285,7 +285,7 @@ export default {
},
beforeRouteUpdate(to, from, next) {
// console.log('fromId', from.query.id, '| toId', to.query.id)
console.log('Router 2.2 === beforeRouteUpdate ===', this.$route.query.id, this.isCopy)
// console.log('Router 2.2 === beforeRouteUpdate ===', this.$route.query.id, this.isCopy)
// if (!Object.keys(this.historyData).includes(this.$route.query.id)) {
// const hisData = {
// bookingDetails: this.bookingDetails,
@ -330,7 +330,7 @@ export default {
this.getRouterHis()
},
beforeRouteLeave(to, from, next) {
console.log('Router 2.1 === beforeRouteLeave ===', this.id, this.isCopy)
// console.log('Router 2.1 === beforeRouteLeave ===', this.id, this.isCopy)
// if (!Object.keys(this.historyData).includes(this.id)) {
// const hisData = {
// bookingDetails: this.bookingDetails,
@ -383,11 +383,11 @@ export default {
methods: {
...mapActions(['setNeedSavePages']),
getRouterHis() {
console.log(
'Router 2.3 === beforeRouteEnter - getRouterHis ===',
Object.keys(this.historyData),
this.$route.query.id
)
// console.log(
// 'Router 2.3 === beforeRouteEnter - getRouterHis ===',
// Object.keys(this.historyData),
// this.$route.query.id
// )
this.inChildLoading = true
const newId = this.$route.query.id
if (Object.keys(this.historyData).includes(`copy-${newId}`) && this.$route.query.isCopy === 'true') {

@ -530,7 +530,7 @@ export default {
editOption: {
// cell value change
cellValueChange: ({ row, column }) => {
console.log('编辑', row, column)
// console.log('', row, column)
}
},
checkboxOption: {
@ -615,7 +615,6 @@ export default {
style="width: 240px"
placeholder="请选择角色"
on-change={val => {
console.log(val, row['roleCode'])
row['roleCode'] = val
}}
>
@ -903,20 +902,20 @@ export default {
this.etdWeek = this.getWeek(this.details.etd)
}
this.ContactType = this.$options.filters['dictData']('booking_contact_type')
console.log(this.ContactType, 'this.ContactType')
},
// - start
getDjyCustomerpage(name = '', type, key) {
const _type = type === 'customer' ? 'consignor' : 'booking_agent'
DjyCustomerSuggest({
// SearchValue: name,
// PropString: key,
keyword: name
keyword: name,
type: _type
})
.then(res => {
if (res.code === 200) {
// this.customerData = res.data.rows
this[`${type}Data`] = res.data.rows
console.log(this[`${type}DataArr`])
this.$forceUpdate()
}
})
@ -931,6 +930,9 @@ export default {
},
customerChange(value) {
// this.getCustomer(value)
if (!value) {
this.details.customername = ''
}
this.getDjyCustomerpage(value, 'customer', 'consignor')
},
// - end
@ -940,6 +942,10 @@ export default {
this.details.forwarder = value
},
forwarderChange(value) {
console.log('订舱代理发生变化', value)
if (!value) {
this.details.forwarder = ''
}
this.getDjyCustomerpage(value, 'forwarder', 'booking_agent')
},
// - end
@ -1009,6 +1015,9 @@ export default {
this.details.shipagency = value
},
shipagencyChange(value) {
if (!value) {
this.details.shipagency = ''
}
this.getForwarderlist(value)
},
// - end
@ -1034,6 +1043,9 @@ export default {
this.details.vesselid = this.vesselData[index].code
},
vesselChange(value) {
if (!value) {
this.details.vessel = ''
}
this.getVessel(value)
},
// - end
@ -1046,6 +1058,9 @@ export default {
this.details.voynoinner = value
},
voynoinnerChange(value) {
if (!value) {
this.details.voynoinner = ''
}
this.getVoynoinner(value)
},
@ -1061,6 +1076,9 @@ export default {
this.details.lanecode = this.lanenameData[index].code
},
lanenameChange(value) {
if (!value) {
this.details.lanename = ''
}
this.getLanename(value)
},
@ -1096,6 +1114,9 @@ export default {
this.details.saleid = this.saleUserList[index].id
},
saleChange(value) {
if (!value) {
this.details.sale = ''
}
this.getUserList(value, 'sale')
},
@ -1106,6 +1127,9 @@ export default {
this.details.opid = this.opUserList[index].id
},
opChange(value) {
if (!value) {
this.details.op = ''
}
this.getUserList(value, 'op')
},
@ -1116,6 +1140,9 @@ export default {
this.details.docid = this.docUserList[index].id
},
docChange(value) {
if (!value) {
this.details.doc = ''
}
this.getUserList(value, 'doc')
},
@ -1126,6 +1153,9 @@ export default {
this.details.custserviceid = this.custserviceUserList[index].id
},
custserviceChange(value) {
if (!value) {
this.details.custservice = ''
}
this.getUserList(value, 'custservice')
},
@ -1141,7 +1171,6 @@ export default {
this.customerType = type
this.customerVisible = true
DjyCustomerdetail({ id: this.details.customerid }).then(res => {
console.log(res.data.contacts)
this.customerContactsData = res.data.contacts
})
BookingOrderContactPage({ id: this.details.customerid, BookingId: this.$route.query.id, pageSize: 999 }).then(res => {
@ -1302,7 +1331,7 @@ export default {
text-align: center;
}
/deep/ .date-box{
padding-top: 7px;
padding-top: 7px !important;
}
// .ant-calendar-picker-input{

@ -553,6 +553,9 @@ export default {
this.details.issueplaceid = this.issueplaceData[index].ediCode
},
issueplaceChange(value) {
if (!value) {
this.details.issueplace = ''
}
this.getPortloadlist(value, 'issueplace')
},
// - end
@ -564,6 +567,9 @@ export default {
this.details.prepardatid = this.prepardatData[index].ediCode
},
prepardatChange(value) {
if (!value) {
this.details.prepardat = ''
}
this.getPortloadlist(value, 'prepardat')
},
// - end
@ -589,6 +595,9 @@ export default {
this.details.payableatid = this.payableatData[index].ediCode
},
payableatChange(value) {
if (!value) {
this.details.payableat = ''
}
this.getPortlist(value, 'payableat')
},
// - end
@ -612,6 +621,9 @@ export default {
this.details.blfrt = value
},
blfrtChange(value) {
if (!value) {
this.details.blfrt = ''
}
this.getFrt(value)
},
// - end
@ -635,6 +647,9 @@ export default {
this.details.service = value
},
serviceChange(value) {
if (!value) {
this.details.service = ''
}
this.getService(value)
},
// - end

@ -447,7 +447,6 @@ export default {
changeValue = changeValue + ''
const valIndex = changeValue.indexOf('.') + 1
const valCount = changeValue.length - valIndex
console.log(valCount)
// 4
if (valCount > 4) {
const height = document.body.clientHeight - 100
@ -508,7 +507,6 @@ export default {
}
},
cellValueChange: ({ row, column }) => {
console.log('编辑', row, column)
}
},
editChildOption: {
@ -550,7 +548,6 @@ export default {
this.$forceUpdate()
},
cellValueChange: ({ row, column }) => {
console.log('编辑', row, column)
}
},
//
@ -818,7 +815,6 @@ export default {
rowKey: this.tableData.length > 0 ? Number(this.tableData[this.tableData.length - 1].rowKey) + 1 : 0
}
this.tableData.push(data)
console.log('== 新增 ==', this.tableData)
},
removeLine() {
this.selectArr.map((item, index) => {
@ -1039,9 +1035,9 @@ export default {
})
},
log({ data, selectionRangeIndexes, selectionRangeKeys }) {
console.log('data::', data)
console.log('selectionRangeIndexes::', selectionRangeIndexes)
console.log('selectionRangeKeys::', selectionRangeKeys)
// console.log('data::', data)
// console.log('selectionRangeIndexes::', selectionRangeIndexes)
// console.log('selectionRangeKeys::', selectionRangeKeys)
},
calc(num1, num2, calcStr) {
var str1; //
@ -1139,10 +1135,8 @@ export default {
}
val.split('').map((item, index) => {
if (index < 3 && !new RegExp(/^[a-zA-Z]+$/).test(item)) {
console.log('箱号前3位为字母')
str = '输入的箱号不符合规则'
} else if (index > 4 && !new RegExp(/^[0-9]+$/).test(item)) {
console.log('箱号后7位为数字')
str = '输入的箱号不符合规则'
}
})

@ -1098,6 +1098,9 @@ export default {
this.details.portloadid = this.portloadData[index].ediCode
},
portloadChange(value) {
if (!value) {
this.details.portloadid = ''
}
this.getPortloadlist(value, 'portload')
},
placereceiptSelect(value) {
@ -1106,6 +1109,9 @@ export default {
this.details.placereceiptid = this.placereceiptData[index].ediCode
},
placereceiptChange(value) {
if (!value) {
this.details.placereceiptid = ''
}
this.getPortloadlist(value, 'placereceipt')
},
// ( / ) - end
@ -1135,6 +1141,9 @@ export default {
this.details.portdischargeid = this.portdischargeData[index].ediCode
},
portdischargeChange(value) {
if (!value) {
this.details.portdischargeid = ''
}
this.getPortlist(value, 'portdischarge')
},
//
@ -1144,6 +1153,9 @@ export default {
this.details.destinationid = this.destinationData[index].ediCode
},
destinationChange(value) {
if (!value) {
this.details.destinationid = ''
}
this.getPortlist(value, 'destination')
},
//
@ -1153,6 +1165,9 @@ export default {
this.details.placedeliveryid = this.placedeliveryData[index].ediCode
},
placedeliveryChange(value) {
if (!value) {
this.details.placedeliveryid = ''
}
this.getPortlist(value, 'placedelivery')
},
//
@ -1162,6 +1177,9 @@ export default {
this.details.transportid = this.transportData[index].ediCode
},
transportChange(value) {
if (!value) {
this.details.transportid = ''
}
this.getPortlist(value, 'transport')
},
// ( / / / ) - end
@ -1185,6 +1203,9 @@ export default {
this.details.kindpkgs = value
},
kindpkgsChange(value) {
if (!value) {
this.details.kindpkgs = ''
}
this.getPackage(value)
},
// - end
@ -1209,6 +1230,9 @@ export default {
this.details.customser = value
},
customserChange(value) {
if (!value) {
this.details.customser = ''
}
this.getDjyCustomerpage(value, 'customser', 'customs_broker')
},
// - end
@ -1218,6 +1242,9 @@ export default {
this.details.trucker = value
},
truckerChange(value) {
if (!value) {
this.details.trucker = ''
}
this.getDjyCustomerpage(value, 'trucker', 'fleet')
},
// - end
@ -1227,6 +1254,9 @@ export default {
this.details.agentid = value
},
agentidChange(value) {
if (!value) {
this.details.agentid = ''
}
this.getDjyCustomerpage(value, 'agentid', 'out_agent')
},
// - end

@ -614,7 +614,6 @@ export default {
this.BCvData = [...this.CvData]
// this.templateType = this.$options.filters['dictData']('booking_template_type')
BookingOrderPrintTemplateList().then(res => {
console.log(res.data)
this.templateType = res.data
})
// if (this.id) {
@ -655,11 +654,11 @@ export default {
// } else {
// this.details[data.code] = this.details[data.code] + this.Rdata
// }
console.log(data)
console.log(data.code)
console.log(this.details)
console.log(this.details[data.code])
console.log(this.Rdata)
// console.log(data)
// console.log(data.code)
// console.log(this.details)
// console.log(this.details[data.code])
// console.log(this.Rdata)
this.details[data.code] = this.details[data.code] + this.Rdata
this.CvBoxType = false
this.BCvData.forEach((item, index) => {
@ -725,7 +724,7 @@ export default {
}
},
beforeUpload(file) {
console.log(this.details, 'this.details')
// console.log(this.details, 'this.details')
// this.$bus.$emit('WebTest001', { upFileList: file, attachCode: 'other', attachName: '' })
},
uploadFile(file) {
@ -733,7 +732,6 @@ export default {
formData.append('file', file.file)
// formData.append('bookingId', this.id)
const type = file.file.type
console.log(type)
BookingOrderOcrUpFile({ data: formData, parameter: { bookingId: this.id } }).then(res => {
this.fileName = res.data
BookingOrderOcrGetImg({ fileName: this.fileName, scale: this.scale }).then(res => {
@ -1092,7 +1090,7 @@ export default {
this.saveBookingLetteryard()
} else if (this.modelType === 'vgmlink') {
// VGM
console.log('暂无接口')
// console.log('')
} else {
//
this.saveBookingSampleBill()
@ -1106,10 +1104,10 @@ export default {
this.sendLetterYard()
} else if (this.modelType === 'vgmlink') {
// VGM
console.log('暂无接口')
// console.log('')
} else {
//
console.log('暂无接口')
// console.log('')
}
},
@ -1133,7 +1131,7 @@ export default {
})
} else if (this.modelType === 'vgmlink') {
// VGM
console.log('暂无接口')
// console.log('')
}
},

@ -391,7 +391,7 @@ export default {
})
},
editRemark (data) {
console.log('=== 暂无接口, 需要添加编辑备注 ===')
// console.log('=== ===')
this.remarkModelvisible = true
this.remarkVal = data.remark
this.editRemarkVal = data
@ -410,7 +410,6 @@ export default {
.then(res => {
if (res.success) {
this.fileList = res.data
console.log(this.fileList)
}
})
.catch(err => {
@ -444,7 +443,6 @@ export default {
return false
},
WebTest001(val) {
console.log(val.upFileList)
this.beforeUpload(val.upFileList)
// this.upFileList = this.upFileList.unshift(val.upFileList)
this.attachCode = val.attachCode
@ -453,7 +451,6 @@ export default {
},
handleUpload() {
const { upFileList, attachCode, attachName } = this
console.log(upFileList, attachCode, attachName)
if (upFileList.length === 0) {
this.$message.error('请上传文件')
return false

@ -64,7 +64,6 @@ export default {
},
mounted() {
BookingOrderPrintTemplateList().then(res => {
console.log(res.data)
this.templateType = res.data
})
},

@ -397,7 +397,6 @@ export default {
} else {
this.formBtnCol = 24 - len * 4
}
console.log('formBtnCol', this.formBtnCol)
this.$forceUpdate()
})
},
@ -417,7 +416,6 @@ export default {
})
this.formMoreTableData = moreTableArr
this.$forceUpdate()
console.log(this.gridOptions.columns)
} else {
const nowTableArr = this.formTableData.map((item, index) => {
return item.field
@ -431,10 +429,7 @@ export default {
this.formMoreTableData = moreTableArr
this.$forceUpdate()
}
console.log('== 表头 ==', this.gridOptions.columns)
})
// === ===
console.log('表格自定义数据 - 更多: ', this.formMoreTableData)
},
handlePageChange({ currentPage, pageSize }) {
this.gridOptions.pagerConfig.currentPage = currentPage
@ -553,7 +548,6 @@ export default {
resizableChange(e) {
this.gridOptions.columns[e.columnIndex].width = e.resizeWidth
console.log('==== 列宽拖动 =====', e.resizeWidth, this.gridOptions.columns[e.columnIndex])
this.editColumnsSave(this.gridOptions.columns)
},
editColumnsSave(data = {}) {
@ -561,7 +555,6 @@ export default {
type: 'booking_list_column',
configJson: JSON.stringify(data)
}).then(res => {
console.log('保存成功')
this.$refs.setForm.handleCancel()
})
},
@ -728,7 +721,6 @@ export default {
},
tableSortChange (e) {
const { property, order } = e
console.log(property, order)
this.tableOrderLabel = property || ''
this.tableOrderType = order || ''
this.getList(this.formRes)

Loading…
Cancel
Save