修改箱信息

szh_zidingyibiaoti
lilu 2 years ago
parent d3062f561a
commit 5e30a689ef

@ -790,11 +790,8 @@ export default {
})
}
} else if (field[0] === 'edi') {
// type 1
const typeArr1 = ['WeiTuoFang', 'SendCode', 'ReceiveCode', 'NotifyCdoe', 'SalerCode', 'MasterBolIndicator', 'EmanifestHbl', 'ConsigneeEdiCode', 'ShipperEdiCode', 'OpEName', 'OpTel', 'OpEmail', 'GoodsName', 'MasterBolIndicatorName', 'SalerCodeName', 'OrderRemark', 'ExRemark1', 'ExRemark2', 'ExRemark3', 'ExRemark4', 'KingTareweight']
// type2 +
const typeArr2 = ['EDIAttn', 'EDIAttnTel', 'EDIAttnMail', 'AMSConsignee', 'AMSNotifyParty']
// type 3
const typeArr3 = ['ACIHBL', 'CKHI', 'CNCM', 'WNCM']
const typeArr4 = ['S0CC0C']
if (typeArr1.includes(field[1])) {
@ -946,8 +943,8 @@ export default {
})
},
setDeatilsFun(res) {
if (this.$route.query.isCopy) {
setDeatilsFun(res, overSet = false) {
if (this.$route.query.isCopy && !overSet) {
res.data.mblno = ''
delete res.data.id
this.isAdd = true
@ -958,7 +955,6 @@ export default {
if (!res.data.bookingEDIExt) {
res.data.bookingEDIExt = bookingEDIExt
}
//
if (res.data.ctnInputs.length > 0) {
res.data.ctnInputs.map((item, index) => {
if (item.weightype === '累加') {
@ -1011,6 +1007,9 @@ export default {
} else {
this.$refs.sedOrder.init([])
}
if (this.bookingDetails.ctnInputs.length > 0) {
this.$refs.goodsTable.init()
}
}, 1200)
this.$forceUpdate()
},
@ -1169,14 +1168,14 @@ export default {
mblno: res.data.mblno
}
})
this.setDeatilsFun(res)
this.setDeatilsFun(res, true)
setTimeout(() => {
this.inAddSave = false
}, 2000)
} else if (that.$route.query.mblno === that.bookingDetails.mblno) {
that.isCopy = false
that.isAdd = false
this.setDeatilsFun(res)
this.setDeatilsFun(res, true)
that.checkSaveFun({ type: 'hbList', hasChange: false })
that.checkSaveFun({ type: 'details', hasChange: false })
const newBookingList = JSON.parse(JSON.stringify(this.bookingList))
@ -1194,7 +1193,7 @@ export default {
that.isAdd = false
this.inAddSave = true
this.id = res.data.id
this.setDeatilsFun(res)
this.setDeatilsFun(res, true)
const newBookingList = JSON.parse(JSON.stringify(this.bookingList))
const newBookingGridOptions = JSON.parse(JSON.stringify(this.bookingGridOptions))
this.$set(newBookingList, res.data.id, res.data)

@ -990,7 +990,7 @@ export default {
watch: {
details: {
handler(nval, oval) {
// console.log('=== table ===', nval.ctnInputs, this.pType, this.inTableLoad)
console.log('=== 修改table内容 ===', nval.ctnInputs, this.pType, this.inTableLoad)
if (!this.inSave && !this.inTableLoad) {
this.$emit('changeDetail', {
detail: nval,
@ -1135,6 +1135,7 @@ export default {
this.$refs['tableRef'].setCellSelection({ rowKey, colKey });
},
init() {
console.log('== 箱信息 - init ==')
this.inTableLoad = true
if (Object.keys(this.details).length > 0) {
const arr = []

@ -74,7 +74,6 @@ let timer
Vue.directive('clickDown', {
inserted(el, binding, vnode) {
let clickTimer = null
//
el.addEventListener('click', () => {
if (clickTimer) {
window.clearTimeout(clickTimer);
@ -84,7 +83,6 @@ Vue.directive('clickDown', {
binding.value.clickFun()
}, 300);
})
//
el.addEventListener('dblclick', () => {
if (clickTimer) {
window.clearTimeout(clickTimer);
@ -365,7 +363,7 @@ export default {
}
},
filterOption(input, option) {
if (this.openSearch) { //
if (this.openSearch) {
return true
} else {
return option.componentOptions.children[1].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
@ -409,7 +407,6 @@ export default {
}
},
getSelectFirst (e, canClick = true) {
// console.log('', e, this.value)
if (canClick) {
this.$refs.selectView.$refs.vcSelect.$refs.arrow.click()
} else {
@ -429,13 +426,11 @@ export default {
return false
}
if (!e) {
console.log('首次搜索内容', e, this.type, this.bookingInitData)
if (!['vessel', 'lineName'].includes(this.type) && this.bookingInitData[`${this.type}InitList`].length > 0) {
console.log(this.bookingInitData[`${this.type}InitList`])
this.selectList = this.bookingInitData[`${this.type}InitList`]
return false
}
// -
if (this.openSearch && this.value && this.selectList.length > 0) {
return false
} else if (this.openSearch && this.value && this.selectList.length === 0) {
@ -495,7 +490,6 @@ export default {
},
openSelect(open) {
console.log('== 测试鼠标滑过 ==')
if (!this.open) {
this.getSelectFirst('', false)
} else {

@ -97,17 +97,13 @@
<div class="right BookTopButton">
<span class="tab-btn" @click="tableRefresh">
<a-icon type="redo" :style="{ fontSize: '14px', transform: 'rotate(278deg)' }" />
<!--刷新-->
</span>
<span class="tab-btn" @click="tableHeaderEdit">
<a-icon type="setting" :style="{ fontSize: '14px' }" />
<!--设置-->
</span>
</div>
</template>
</vxe-toolbar>
<!-- :scroll-x="{gt: 40}"
:scroll-y="{gt: 40}" -->
<vxe-grid
ref="xGrid"
v-bind="gridOptions"
@ -334,7 +330,6 @@
</template>
</template>
</div>
<!-- 运踪弹窗 start -->
<a-modal width="50vw" :maskClosable="false" v-model="traceModalVisible" title="运踪订阅">
<div class="trace-box">
<a-form>
@ -362,8 +357,6 @@
<a-button type="primary" @click="traceSend"></a-button>
</template>
</a-modal>
<!-- 运踪弹窗 end -->
<!-- 批量编辑 start -->
<a-modal
width="820px"
:maskClosable="false"
@ -544,7 +537,6 @@
</a-form>
</div>
</a-modal>
<!-- 批量编辑 end -->
</div>
</template>
<script>
@ -597,9 +589,7 @@ export default {
return {
ResetType: true,
tstyle: { 'padding-bottom': '0px', 'margin-bottom': '10px' },
// /
advanced: false,
//
formData: formInitData,
formRes: {},
searchData: {},
@ -607,7 +597,6 @@ export default {
formMoreData: null,
formBtnCol: 8,
formBtnLoading: false,
//
setVisible: false,
showColumns: null,
gridOptions: {
@ -637,11 +626,9 @@ export default {
// parentField: 'parentId',
// },
},
//
formTableData: JSON.parse(JSON.stringify(initData.columns)),
fromTableAllData: null,
formMoreTableData: null,
//
addVisible: false,
carrierRadio: 'CMA',
radioStyle: {
@ -649,14 +636,11 @@ export default {
height: '50px',
lineHeight: '50px'
},
//
moreNumVisible: false,
moreNumVal: '',
//
tableOrderLabel: '',
tableOrderType: '',
screenWidth: document.body.clientWidth,
//
remarkShow: false,
remarkScreenX: 0,
remarkScreenY: 0,
@ -670,12 +654,10 @@ export default {
traceValue: [],
addNum: 0,
tableHeight: 0,
//
goodStatusShow: false,
goodStatusScreenX: 0,
goodStatusScreenY: 0,
goodStatusData: null,
//
editingForm: this.$form.createForm(this),
vesselData: [],
WebVessel: '',
@ -759,7 +741,6 @@ export default {
return false
}
const newData = JSON.parse(JSON.stringify(this.bookingGridOptions))
// N
if (this.bookingGridOptions.data && this.bookingGridOptions.data.length > 0) {
setTimeout(() => {
const copyArr = JSON.parse(JSON.stringify(this.bookingGridOptions.data))
@ -773,7 +754,6 @@ export default {
}, 600)
}, 10)
}
//
// if (this.bookingGridOptions.data && this.bookingGridOptions.data.length > 0) {
// console.log(this.gridOptions.loading)
// const copyArr = JSON.parse(JSON.stringify(this.bookingGridOptions.data))
@ -892,9 +872,7 @@ export default {
this.gridOptions.data = []
this.getList(queryParam)
},
//
getConfigUser(isInit = false) {
//
const query = {
typeArr: ['booking_list_cond', 'booking_list_column', 'booking_list_page']
}
@ -915,7 +893,6 @@ export default {
break
}
})
console.log('==获取数据,表单 ==', $data.booking_list_cond)
if (Object.keys($data).includes('booking_list_cond')) {
this.setFormData($data.booking_list_cond, false, true)
} else {
@ -1091,7 +1068,6 @@ export default {
}
},
//
getFormData(isReset = false) {
DjyUserConfigGet({ type: 'booking_list_cond' }).then(res => {
this.setFormData(res.data)
@ -1111,7 +1087,6 @@ export default {
return Codeissuetypelist
}
},
//
getFromSelectData(func, ...args) {
return new Promise((resolve, reject) => {
func(...args).then(res => {
@ -1129,7 +1104,6 @@ export default {
}
this.gridOptions.pagerConfig.currentPage = currentPage
this.gridOptions.pagerConfig.pageSize = pageSize
console.log('== 当前搜索内容 ==', this.searchData)
this.getList(this.searchData)
},
@ -1145,7 +1119,6 @@ export default {
})
},
// form
toggleAdvanced() {
this.advanced = !this.advanced
if (!this.advanced) {
@ -1164,7 +1137,6 @@ export default {
tableRefresh() {
const data = { ...this.formRes }
this.searchData = JSON.parse(JSON.stringify(data))
console.log('查询 - 设置当前搜索', data)
this.init(this.searchData)
this.formRes = data
},
@ -1207,7 +1179,6 @@ export default {
this.formRes[item] = ''
})
this.searchData = JSON.parse(JSON.stringify(this.formRes))
console.log('== 重置表单内容 ==', this.searchData)
Object.keys(this.$refs).map((label, index) => {
if (label.includes('fromlabel-') && this.$refs[label].length > 0) {
this.$refs[label][0].$data.value = ''
@ -1229,7 +1200,6 @@ export default {
this.formRes = {}
this.searchData = {}
console.log('== 设置表头 ==', this.searchData)
DjyUserConfigAdd({
type: 'booking_list_cond',
configJson: JSON.stringify(arr)
@ -1260,7 +1230,6 @@ export default {
} else if (form.type === 'complete') {
this.formRes[form.label] = value
}
console.log('修改了表单内容', this.formRes)
this.$forceUpdate()
},
@ -1333,12 +1302,10 @@ export default {
query.MBLNO = arr.toString()
}
if (isInit) {
// -
query.firstFlag = true
}
BookingOrderPage(query)
.then(res => {
// if (isInit) { this.getList(this.formRes) }
if (res.success) {
let newBookingList = {}
if (query.PageNo !== 1) {
@ -1378,13 +1345,11 @@ export default {
this.$set(this.gridOptions.pagerConfig, 'columns', JSON.parse(JSON.stringify(initData.columns)))
// debugger
// this.$set(this.gridOptions, 'data', [..._data])
console.log('== 即将渲染列表 ==', isAdd)
this.$refs.xGrid.reloadData(_data).then(() => {
this.$set(this.gridOptions, 'loading', false)
})
this.$set(this.gridOptions.pagerConfig, 'total', res.data.totalCount)
this.setBookingList(newBookingList)
// console.log(this.gridOptions.data.length, Object.keys(newBookingList).length, this.gridOptions.data, newBookingList)
this.$forceUpdate()
} else {
this.$set(this.gridOptions, 'data', [...[]])
@ -1398,7 +1363,6 @@ export default {
})
},
//
addBooking() {
this.addVisible = !this.addVisible
},
@ -1425,10 +1389,6 @@ export default {
this.$message.error('请至少选择一条数据')
return false
}
//
// pkIdArr.map((item, index) => {
// this.$router.push({ name: 'BookingDetail', query: { id: item, isCopy: true } })
// })
},
addSubmit() {
let data = []
@ -1635,7 +1595,6 @@ export default {
console.log(err)
})
},
//
getCompleteListFun({ form, value }) {
let query = {}
if (

@ -1,7 +1,6 @@
<template>
<div class="from-label">
<template v-if="labelData.type == 'input'">
<!-- <a-input style="height:23px;margin-top:8px;" v-model="value" @change="changeInput" @pressEnter="$emit('pressEnter')"/> -->
<inputView ref="inputView" :type="labelData.label" :parentVal="value" @getInputChange="inputChange" />
</template>
<template v-else-if="labelData.type == 'date'">
@ -13,10 +12,8 @@
format="YYYY-MM-DD"
@dateChange="dateChangeFun"
></datePickerView>
<!-- <a-date-picker format="YYYY-MM-DD" @change="changeDate" v-model="value"/> -->
</template>
<template v-else-if="labelData.type == 'dateRange'">
<!-- <a-range-picker style="overflow: hidden;margin-top:3px;" format="YYYY-MM-DD" @change="changeRangeDate" @calendarChange="openChangeRangeDate" v-model="dateVal"/> -->
<div class="picker-box" style="display:flex;padding-right: 2px;">
<a-date-picker
style="min-width:30px; flex: 1;"
@ -131,7 +128,6 @@ export default {
},
watch: {
resetType (nval, oval) {
console.log('== 重置 ==', nval)
if (!nval) {
this.value = ''
this.dateVal = []
@ -157,14 +153,11 @@ export default {
},
data() {
return {
// input
value: '',
//
dateVal: [],
startValue: null,
endValue: null,
endOpen: false,
// select
dataList: this.labelData.dataList || [],
dataSourceList: []
}
@ -189,15 +182,6 @@ export default {
value: data.value
})
},
// start
// changeRangeDate(e, mode) {
// this.$emit('change', {
// form: this.labelData,
// value: mode
// })
// },
disabledStartDate(startValue) {
const endValue = this.endValue;
if (!startValue || !endValue) {
@ -216,21 +200,14 @@ export default {
if (!open) {
this.endOpen = true;
}
// if (this.startValue) {
// this.getDateRangeRes()
// }
},
handleEndOpenChange(open) {
this.endOpen = open;
// if (this.endValue) {
// this.getDateRangeRes()
// }
},
getDateRangeRes () {
const start = this.startValue ? this.formatDate(this.startValue._d).substr(0, 10) : ''
const end = this.endValue ? this.formatDate(this.endValue._d).substr(0, 10) : ''
const date = [start, end]
console.log('== 更新时间 ==', date)
this.$emit('change', {
form: this.labelData,
value: date
@ -238,44 +215,39 @@ export default {
},
formatDate (now) {
var date = new Date(now)
var y = date.getFullYear() //
var m = date.getMonth() + 1 // js1
var y = date.getFullYear()
var m = date.getMonth() + 1
if (m < 10) {
m = '0' + m;
}
var d = date.getDate() //
var d = date.getDate()
if (d < 10) {
d = '0' + d;
}
var h = date.getHours() //
var h = date.getHours()
if (h < 10) {
h = '0' + h;
}
var min = date.getMinutes() //
var min = date.getMinutes()
if (min < 10) {
min = '0' + min;
}
var s = date.getSeconds() //
var s = date.getSeconds()
if (s < 10) {
s = '0' + s;
}
//
return y + '-' + m + '-' + d + ' ' + h + ':' + min + ':' + s
},
// end
// == ==
filterOption(input, option) {
return option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
},
handleSelectChange (e) {
console.log('== 修改select ==', e, this.value)
this.$emit('change', {
form: this.labelData,
value: this.dataList[e][this.labelData.showLabel]
})
},
getSelectFirst (e) {
console.log('下拉选择 - 首次点击内容:', e)
if (!e) {
this.$emit('selectFirst', {
form: this.labelData,
@ -284,8 +256,6 @@ export default {
})
}
},
// == ==
completeSelect (value) {
this.$emit('change', {
form: this.labelData,
@ -311,11 +281,9 @@ export default {
})
},
inputChange (data) {
console.log('== 表单输入 ==', data)
this.changeInput(data)
},
dateChangeFun (data) {
console.log('== 表单时间 ==', data)
this.changeDate(data)
}
}

@ -70,7 +70,6 @@ export default {
{ field: 'reeferf', label: 'REEFERF', width: 160, title: '通风度', showHeaderOverflow: true, sortable: true },
{ field: 'shipagency', label: 'SHIPAGENCY', width: 160, title: '船代', showHeaderOverflow: true, sortable: true },
{ field: 'custno', label: 'CUSTNO', width: 160, title: '订舱编号', showHeaderOverflow: true, sortable: true },
// 以下为东胜没有,大简云有,目前保留的
// { field: 'vgm', label: 'VGM', width: 120, title: 'VGM', showHeaderOverflow: true },
{ field: 'forwarder', label: 'FORWARDER', width: 120, title: '订舱代理', showHeaderOverflow: true, sortable: true },
// { field: 'bookingStatus', label: 'BOOKINGSTATUS', width: 120, title: '订舱状态', showHeaderOverflow: true },
@ -82,7 +81,6 @@ export default {
{ field: 'dunno', label: 'DUNNO', width: 120, title: '危险品编号', showHeaderOverflow: true, sortable: true },
{ field: 'contractno', label: 'CONTRACTNO', width: 120, title: '合约号', showHeaderOverflow: true, sortable: true },
{ field: 'route', label: 'ROUTE', width: 120, title: '航线操作', showHeaderOverflow: true, sortable: true },
// 以下未核实台账字段里是否有该字段
{ field: 'lanecode', label: 'LANECODE', width: 120, title: '航线代码', showHeaderOverflow: true, sortable: true },
{ field: 'shipperid', label: 'SHIPPERID', width: 120, title: '发货人代码', showHeaderOverflow: true, sortable: true }, // 台账无字段
{ field: 'notifypartyid', label: 'NOTIFYPARTYID', width: 120, title: '通知人代码', showHeaderOverflow: true, sortable: true }, // 台账无字段
@ -131,7 +129,6 @@ export default {
{ title: '航线代码', align: 'center', width: 120, label: 'LANECODE', type: 'input' },
{ title: '内部航次', align: 'center', width: 120, label: 'VOYNOINNER', type: 'input' },
{ title: '海关航次', align: 'center', width: 120, label: 'VOYNO', type: 'input' },
// 未完成 - 以下为东胜没有的,大简云有的
{ title: '发货人', align: 'center', width: 120, label: 'SHIPPER', type: 'input' },
{ title: '发货人代码', align: 'center', width: 120, label: 'SHIPPERID', type: 'input' },
{ title: '通知人', align: 'center', width: 120, label: 'NOTIFYPARTY', type: 'input' },
@ -155,8 +152,6 @@ export default {
{ title: '卸货港代码', align: 'center', width: 120, label: 'PORTDISCHARGEID', type: 'input' },
{ title: '航线操作', align: 'center', width: 120, label: 'ROUTE', type: 'complete', showLabel: 'name' },
{ title: 'PO NO', align: 'center', width: 120, label: 'PONO', type: 'input' },
// 新增字段
{ title: '件数', align: 'center', width: 160, label: 'PKGS', type: 'input' },
{ title: '重量', align: 'center', width: 160, label: 'KGS', type: 'input' },
{ title: '尺码', align: 'center', width: 160, label: 'CBM', type: 'input' },
@ -167,14 +162,11 @@ export default {
{ title: '付款方', align: 'center', width: 160, label: 'FREIGHTPAYER', type: 'input' },
{ title: '唛头', align: 'center', width: 160, label: 'MARKS', type: 'input' },
{ title: '危险品编号', align: 'center', width: 160, label: 'DUNNO', type: 'input' },
// 东胜添加
{ title: '箱号', align: 'center', width: 160, label: 'CNTRNO', type: 'input' },
{ title: '封号', align: 'center', width: 160, label: 'SEALNO', type: 'input' },
{ title: '创建人', align: 'center', width: 160, label: 'CreatedUserName', type: 'input' },
{ title: '单证备注', align: 'center', width: 160, label: 'DZREMARK', type: 'input' },
{ title: '操作备注', align: 'center', width: 160, label: 'CZREMARK', type: 'input' },
// 以下需要加模糊搜索
{ title: '到付地点', align: 'center', width: 160, label: 'PAYABLEAT', type: 'complete', showLabel: 'enName' },
{ title: '付费方式', align: 'center', width: 160, label: 'BLFRT', type: 'complete', showLabel: 'enName' },
{ title: '签单地点', align: 'center', width: 160, label: 'ISSUEPLACE', type: 'complete', showLabel: 'enName' },
@ -183,8 +175,6 @@ export default {
{ title: '国外代理', align: 'center', width: 160, label: 'AGENTID', type: 'complete', showLabel: 'shortName' },
{ title: '车队', align: 'center', width: 160, label: 'TRUCKER', type: 'complete', showLabel: 'shortName' },
{ title: '船代', align: 'center', width: 160, label: 'SHIPAGENCY', type: 'complete', showLabel: 'name' },
// 以下为下拉加载
{ title: '箱型', align: 'center', width: 120, label: 'CNTRTOTAL', type: 'select', showLabel: 'name' },
{ title: '包装', align: 'center', width: 120, label: 'KINDPKGS', type: 'select', showLabel: 'name' },
{ title: '签单方式', align: 'center', width: 160, label: 'ISSUETYPE', type: 'select', showLabel: 'enName', showLabel2: 'cnName' },
@ -223,10 +213,6 @@ export default {
{ code: 'O', name: '超限箱' }
]
},
{ title: '签单日期', align: 'center', width: 160, label: 'ISSUEDATE', type: 'dateRange', resLabel: ['BISSUEDATE', 'EISSUEDATE'] },
// 以下为新增字段 - 台账文档中, 参数暂无
// { title: '单证备注', align: 'center', width: 160, label: 'DZREMARK', type: 'input' },
// { title: '操作备注', align: 'center', width: 160, label: 'CZREMARK', type: 'input' }
{ title: '签单日期', align: 'center', width: 160, label: 'ISSUEDATE', type: 'dateRange', resLabel: ['BISSUEDATE', 'EISSUEDATE'] }
]
}

Loading…
Cancel
Save