|
|
@@ -47,9 +47,16 @@
|
|
|
@selectChange="dicChange('branchName', $event)" :default="true"
|
|
|
:disabled="editDisabled || roleName.includes('secondaryAdmin')"></dic-select>
|
|
|
</tempalte>
|
|
|
- <dic-select v-model="form.operatorName" placeholder="OP" :key="form.branchId" label="realName"
|
|
|
- :url="'/blade-user/userListAll?roleAlias=操作员&deptId=' + form.branchId" :filterable="true"
|
|
|
- dataName="realName" @selectChange="dicChange('operatorName', $event)" :disabled="editDisabled"></dic-select>
|
|
|
+ <tempalte slot="operatorName">
|
|
|
+ <dic-select v-model="form.operatorName" placeholder="OP" :key="form.branchId" label="realName"
|
|
|
+ :url="'/blade-user/userListAll?roleAlias=操作员&deptId=' + form.branchId" :filterable="true"
|
|
|
+ @selectChange="dicChange('operatorName', $event)" :disabled="editDisabled"></dic-select>
|
|
|
+ </tempalte>
|
|
|
+ <tempalte slot="accDeptName">
|
|
|
+ <dic-select v-model="form.accDeptName" placeholder="客服" :key="form.branchId" label="realName"
|
|
|
+ :url="'/blade-user/userListAll?roleAlias=客服&deptId=' + form.branchId" :filterable="true"
|
|
|
+ @selectChange="dicChange('accDeptName', $event)" :disabled="editDisabled"></dic-select>
|
|
|
+ </tempalte>
|
|
|
<tempalte slot="polCnName">
|
|
|
<dic-select v-model="form.polCnName" placeholder="起运港" key="id" label="cnName" res="records"
|
|
|
url="/blade-los/bports/list?current=1&size=5" :filterable="true" :remote="true" dataName="cnName"
|
|
|
@@ -73,10 +80,10 @@
|
|
|
dataName="shortName" @selectChange="dicChange('carrierCnName', $event)" :disabled="editDisabled"
|
|
|
:slotRight="true" rightLabel="code"></dic-select>
|
|
|
</tempalte>
|
|
|
- <tempalte slot="shippingCompanyCname">
|
|
|
- <dic-select v-model="form.shippingCompanyCname" placeholder="承运人" key="id" label="shortName" res="records"
|
|
|
+ <tempalte slot="actualShippingCompanyCname">
|
|
|
+ <dic-select v-model="form.actualShippingCompanyCname" placeholder="承运人" key="id" label="shortName" res="records"
|
|
|
url="/blade-los/bcorps/selectList?current=1&size=5&corpTypeName=船公司" :filterable="true" :remote="true"
|
|
|
- dataName="shortName" @selectChange="dicChange('shippingCompanyCname', $event)" :slotRight="true"
|
|
|
+ dataName="shortName" @selectChange="dicChange('actualShippingCompanyCname', $event)" :slotRight="true"
|
|
|
rightLabel="code" :disabled="editDisabled"></dic-select>
|
|
|
</tempalte>
|
|
|
<tempalte slot="hpaymode">
|
|
|
@@ -84,33 +91,37 @@
|
|
|
url="/blade-system/dict-biz/dictionary?code=payment_method_los" :filterable="true"
|
|
|
:disabled="editDisabled"></dic-select>
|
|
|
</tempalte>
|
|
|
- <tempalte slot="transportationTerms">
|
|
|
- <dic-select v-model="form.transportationTerms" placeholder="运输条款" key="id" label="cnName" res="records"
|
|
|
+ <tempalte slot="serviceTerms">
|
|
|
+ <dic-select v-model="form.serviceTerms" placeholder="运输条款" key="id" label="cnName" res="records"
|
|
|
url="/blade-los/bserviceterms/list?status=0¤t=1&size=20" :filterable="true" :remote="true"
|
|
|
- dataName="cnName" @selectChange="dicChange('transportationTerms', $event)"
|
|
|
- :disabled="editDisabled"></dic-select>
|
|
|
+ dataName="cnName" @selectChange="dicChange('serviceTerms', $event)" :disabled="editDisabled"></dic-select>
|
|
|
</tempalte>
|
|
|
<tempalte slot="packingUnit">
|
|
|
<dic-select v-model="form.packingUnit" placeholder="目的港" key="id" label="cnName" res="records"
|
|
|
- url="/blade-los/bpackages/list?current=1&size=5&status=0&whetherDg=0" :filterable="true" :remote="true" dataName="cnName"
|
|
|
- @selectChange="dicChange('packingUnit', $event)" :disabled="editDisabled" :slotRight="true"
|
|
|
- rightLabel="code"></dic-select>
|
|
|
+ url="/blade-los/bpackages/list?current=1&size=5&status=0&whetherDg=0" :filterable="true" :remote="true"
|
|
|
+ dataName="cnName" @selectChange="dicChange('packingUnit', $event)" :disabled="editDisabled"
|
|
|
+ :slotRight="true" rightLabel="code"></dic-select>
|
|
|
+ </tempalte>
|
|
|
+ <tempalte slot="vesselCnName">
|
|
|
+ <dic-select v-model="form.vesselCnName" placeholder="船名" key="id" label="cnName" res="records"
|
|
|
+ url="/blade-los/bvessels/list" :filterable="true" :remote="true" dataName="cnName"
|
|
|
+ @selectChange="dicChange('vesselCnName', $event)" :disabled="editDisabled"></dic-select>
|
|
|
</tempalte>
|
|
|
</avue-form>
|
|
|
</trade-card>
|
|
|
<trade-card title="箱明细">
|
|
|
- <avue-crud :option="option" :data="form.costItemList" id="out-table" ref="crud"
|
|
|
+ <avue-crud :option="option" :data="form.preContainersList" id="out-table" ref="crud"
|
|
|
:header-cell-class-name="headerClassName" :row-style="{ height: '20px', padding: '0px' }"
|
|
|
:cell-style="{ height: '20px', padding: '0px' }" @selection-change="selectionChange" @select="selectHandle"
|
|
|
@row-update="rowUpdate" @resetColumn="resetColumn('crud', 'option', 'optionBack', 499)"
|
|
|
@saveColumn="saveColumn('crud', 'option', 'optionBack', 499)">
|
|
|
<template slot="menuLeft">
|
|
|
- <el-button type="info" plain size="small" :disabled="editDisabled"
|
|
|
+ <!-- <el-button type="info" plain size="small" :disabled="editDisabled"
|
|
|
@click="allClick('一键保存')">一键保存</el-button>
|
|
|
<el-button type="info" plain size="small" :disabled="editDisabled"
|
|
|
@click="allClick('一键编辑')">一键编辑</el-button>
|
|
|
<el-button type="danger" plain size="small" :disabled="editDisabled || selectionList.length == 0"
|
|
|
- @click="allClick('批量删除')">批量删除</el-button>
|
|
|
+ @click="allClick('批量删除')">批量删除</el-button> -->
|
|
|
</template>
|
|
|
<template slot="indexHeader" slot-scope="{row,index}">
|
|
|
<el-button type="primary" size="mini" icon="el-icon-plus" :disabled="editDisabled" circle @click="addRow()">
|
|
|
@@ -136,7 +147,7 @@
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
-import { submit, submitItemList, submitFeeList, getDetail, removeItem, feeRemove, checkAgent, revokeCheckAgent, copyAgent } from "@/api/iosBasicData/costcenter/coc";
|
|
|
+import { submit, getDetail, submitItemList, copyAgent, itemRemove, pleaseCheck, repealCancel } from "@/api/iosBasicData/businessCenter/bookingCabin.js";
|
|
|
import { losbfeestemplateGetListTemplate } from "@/api/iosBasicData/bills";
|
|
|
import { losbfeestemplateDetail } from "@/api/iosBasicData/losbfeestemplate";
|
|
|
import dicSelect from "@/components/dicSelect/main";
|
|
|
@@ -216,7 +227,7 @@ export default {
|
|
|
branchName: JSON.parse(localStorage.getItem('sysitemData')).deptName,
|
|
|
operatorName: JSON.parse(localStorage.getItem('saber-userInfo')).content.user_name, // OP 默认登录人
|
|
|
operatorId: JSON.parse(localStorage.getItem('saber-userInfo')).content.user_id,
|
|
|
- costItemList: [],
|
|
|
+ preContainersList: [],
|
|
|
},
|
|
|
polFeeList: [],
|
|
|
podFeeList: [],
|
|
|
@@ -242,14 +253,14 @@ export default {
|
|
|
prop: "operatorName",
|
|
|
disabled: false,
|
|
|
},
|
|
|
- {
|
|
|
+ {
|
|
|
label: '客服',
|
|
|
prop: "accDeptName",
|
|
|
disabled: false,
|
|
|
},
|
|
|
{
|
|
|
label: '承运人',
|
|
|
- prop: "shippingCompanyCname",
|
|
|
+ prop: "actualShippingCompanyCname",
|
|
|
disabled: false,
|
|
|
rules: [{
|
|
|
required: true,
|
|
|
@@ -293,8 +304,8 @@ export default {
|
|
|
}]
|
|
|
},
|
|
|
{
|
|
|
- label: '订舱约号',
|
|
|
- prop: "airlineCname",
|
|
|
+ label: 'booking NO',
|
|
|
+ prop: "bookingNo",
|
|
|
disabled: false,
|
|
|
},
|
|
|
{
|
|
|
@@ -317,11 +328,17 @@ export default {
|
|
|
},
|
|
|
{
|
|
|
label: "运输条款",
|
|
|
- prop: "transportationTerms",
|
|
|
+ prop: "serviceTerms",
|
|
|
width: "80",
|
|
|
overHidden: true,
|
|
|
},
|
|
|
{
|
|
|
+ label: '总TEU',
|
|
|
+ prop: "teu",
|
|
|
+ disabled: false,
|
|
|
+ },
|
|
|
+
|
|
|
+ {
|
|
|
label: '件数',
|
|
|
prop: "quantity",
|
|
|
disabled: false,
|
|
|
@@ -343,11 +360,55 @@ export default {
|
|
|
disabled: false,
|
|
|
},
|
|
|
{
|
|
|
+ label: '订舱代理',
|
|
|
+ prop: "bookingAgentCnName",
|
|
|
+ disabled: false,
|
|
|
+ span: 4
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '',
|
|
|
+ labelWidth: 0,
|
|
|
+ prop: "bookingAgentEnName",
|
|
|
+ disabled: false,
|
|
|
+ span: 2
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: 'MB/L NO',
|
|
|
+ prop: "mblno",
|
|
|
+ disabled: false,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '船名',
|
|
|
+ prop: "vesselCnName",
|
|
|
+ disabled: false,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '航次',
|
|
|
+ prop: "voyageNo",
|
|
|
+ disabled: false,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '截单日期',
|
|
|
+ prop: "cyTrailerTime",
|
|
|
+ disabled: false,
|
|
|
+ type: "date",
|
|
|
+ format: "yyyy-MM-dd",
|
|
|
+ valueFormat: "yyyy-MM-dd HH:mm:ss",
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '截港日期',
|
|
|
+ prop: "cyReturnTime",
|
|
|
+ disabled: false,
|
|
|
+ type: "date",
|
|
|
+ format: "yyyy-MM-dd",
|
|
|
+ valueFormat: "yyyy-MM-dd HH:mm:ss",
|
|
|
+ },
|
|
|
+ {
|
|
|
label: '订舱备注',
|
|
|
prop: "remarks",
|
|
|
type: 'textarea',
|
|
|
disabled: false,
|
|
|
- span: 12,
|
|
|
+ span: 24,
|
|
|
minRows: 2,
|
|
|
},
|
|
|
]
|
|
|
@@ -358,11 +419,11 @@ export default {
|
|
|
disabled: false,
|
|
|
labelWidth: 100,
|
|
|
column: [
|
|
|
- {
|
|
|
- label: '系统号',
|
|
|
- prop: "businessNo",
|
|
|
- disabled: true,
|
|
|
- },
|
|
|
+ // {
|
|
|
+ // label: '系统号',
|
|
|
+ // prop: "businessNo",
|
|
|
+ // disabled: true,
|
|
|
+ // },
|
|
|
{
|
|
|
label: '制单人',
|
|
|
prop: "createUserName",
|
|
|
@@ -421,7 +482,7 @@ export default {
|
|
|
}
|
|
|
]
|
|
|
},
|
|
|
- {
|
|
|
+ {
|
|
|
label: "箱量",
|
|
|
prop: "quantity",
|
|
|
overHidden: true,
|
|
|
@@ -460,7 +521,7 @@ export default {
|
|
|
this.roleName = localStorage.getItem('roleName').split(',')
|
|
|
this.option = await this.getColumnData(this.getColumnName(499), this.optionBack);
|
|
|
this.saveLocalCurrency(JSON.parse(localStorage.getItem('sysitemData')).deptId)
|
|
|
- if (this.detailData.id) {
|
|
|
+ if (this.detailData && this.detailData.id) {
|
|
|
// this.editButton = true
|
|
|
// this.editDisabled = true
|
|
|
// this.optionForm.disabled = true
|
|
|
@@ -474,11 +535,10 @@ export default {
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
|
- async dicChange(name, row) {
|
|
|
+ dicChange(name, row) {
|
|
|
if (name == 'branchName') {
|
|
|
if (row) {
|
|
|
this.form.branchId = row.id
|
|
|
- this.saveLocalCurrency(row.id)
|
|
|
} else {
|
|
|
this.form.branchId = null
|
|
|
this.form.branchName = null
|
|
|
@@ -543,18 +603,28 @@ export default {
|
|
|
this.form.carrierShortName = null
|
|
|
}
|
|
|
}
|
|
|
- if (name == 'shippingCompanyCname') {
|
|
|
+ if (name == 'actualShippingCompanyCname') {
|
|
|
+ if (row) {
|
|
|
+ this.form.actualShippingCompanyId = row.id
|
|
|
+ this.form.actualShippingCompanyCode = row.code
|
|
|
+ this.form.actualShippingCompanyEname = row.enName
|
|
|
+ this.form.actualShippingCompanyAbbreviation = row.shortName
|
|
|
+ } else {
|
|
|
+ this.form.actualShippingCompanyId = null
|
|
|
+ this.form.actualShippingCompanyCode = null
|
|
|
+ this.form.actualShippingCompanyEname = null
|
|
|
+ this.form.actualShippingCompanyCname = null
|
|
|
+ this.form.actualShippingCompanyAbbreviation = null
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if (name == 'vesselCnName') {
|
|
|
if (row) {
|
|
|
- this.form.shippingCompanyId = row.id
|
|
|
- this.form.shippingCompanyCode = row.code
|
|
|
- this.form.shippingCompanyEname = row.enName
|
|
|
- this.form.shippingCompanyAbbreviation = row.shortName
|
|
|
+ this.form.vesselId = row.id
|
|
|
+ this.form.vesselEnName = row.enName
|
|
|
} else {
|
|
|
- this.form.shippingCompanyId = null
|
|
|
- this.form.shippingCompanyCode = null
|
|
|
- this.form.shippingCompanyEname = null
|
|
|
- this.form.shippingCompanyCname = null
|
|
|
- this.form.shippingCompanyAbbreviation = null
|
|
|
+ this.form.vesselId = null
|
|
|
+ this.form.vesselEnName = null
|
|
|
+ this.form.vesselCnName = null
|
|
|
}
|
|
|
}
|
|
|
},
|
|
|
@@ -564,7 +634,7 @@ export default {
|
|
|
if (!this.form.id) {
|
|
|
return this.$message.error("请保存数据");
|
|
|
}
|
|
|
- this.form.costItemList.push({
|
|
|
+ this.form.preContainersList.push({
|
|
|
pid: this.form.id,
|
|
|
$cellEdit: true
|
|
|
})
|
|
|
@@ -583,15 +653,12 @@ export default {
|
|
|
background: 'rgba(255,255,255,0.7)'
|
|
|
});
|
|
|
getDetail({ id: id }).then(res => {
|
|
|
- this.polFeeList = res.data.data.costFeeList.filter(item => item.busType == 'POL')
|
|
|
- this.podFeeList = res.data.data.costFeeList.filter(item => item.busType == 'POD')
|
|
|
- this.saveLocalCurrency(res.data.data.branchId)
|
|
|
this.form = res.data.data
|
|
|
- if (res.data.data.status != '录入') {
|
|
|
- this.editButton = true
|
|
|
- this.editDisabled = true
|
|
|
- this.optionForm.disabled = true
|
|
|
- }
|
|
|
+ // if (res.data.data.status != '录入') {
|
|
|
+ // this.editButton = true
|
|
|
+ // this.editDisabled = true
|
|
|
+ // this.optionForm.disabled = true
|
|
|
+ // }
|
|
|
}).finally(() => {
|
|
|
loading.close()
|
|
|
})
|
|
|
@@ -604,8 +671,6 @@ export default {
|
|
|
background: 'rgba(255,255,255,0.7)'
|
|
|
});
|
|
|
copyAgent({ id: id }).then(res => {
|
|
|
- this.polFeeList = res.data.data.costFeeList.filter(item => item.busType == 'POL')
|
|
|
- this.podFeeList = res.data.data.costFeeList.filter(item => item.busType == 'POD')
|
|
|
this.form = res.data.data
|
|
|
}).finally(() => {
|
|
|
loading.close()
|
|
|
@@ -620,10 +685,10 @@ export default {
|
|
|
},
|
|
|
allClick(name) {
|
|
|
if (name == '一键保存') {
|
|
|
- if (!this.form.costItemList.length) {
|
|
|
+ if (!this.form.preContainersList.length) {
|
|
|
return this.$message.error("请添加数据");
|
|
|
}
|
|
|
- for (let row of this.form.costItemList) {
|
|
|
+ for (let row of this.form.preContainersList) {
|
|
|
if (!row.cntrTypeCode || !row.quantity) {
|
|
|
this.$refs.crud.rowCell(row, row.$index)
|
|
|
return this.$message.error("请完善明细信息");
|
|
|
@@ -635,15 +700,15 @@ export default {
|
|
|
spinner: 'el-icon-loading',
|
|
|
background: 'rgba(255,255,255,0.7)'
|
|
|
});
|
|
|
- submitItemList(this.form.costItemList).then(res => {
|
|
|
+ submitItemList(this.form.preContainersList).then(res => {
|
|
|
this.$message.success("保存成功");
|
|
|
- this.form.costItemList = res.data.data
|
|
|
+ this.form.preContainersList = res.data.data
|
|
|
}).finally(() => {
|
|
|
loading.close();
|
|
|
})
|
|
|
}
|
|
|
if (name == '一键编辑') {
|
|
|
- for (let row of this.form.costItemList) {
|
|
|
+ for (let row of this.form.preContainersList) {
|
|
|
this.$set(row, "$cellEdit", true);
|
|
|
}
|
|
|
}
|
|
|
@@ -656,7 +721,7 @@ export default {
|
|
|
type: "warning"
|
|
|
}).then(() => {
|
|
|
multiList = this.selectionList
|
|
|
- arr = this.form.costItemList
|
|
|
+ arr = this.form.preContainersList
|
|
|
// 获取有id 的数据
|
|
|
const itemsWithId = multiList.filter(item => item.id != null);
|
|
|
let arrIds = itemsWithId.map(item => item.id) // 获取id 数据
|
|
|
@@ -675,7 +740,7 @@ export default {
|
|
|
spinner: 'el-icon-loading',
|
|
|
background: 'rgba(255,255,255,0.7)'
|
|
|
});
|
|
|
- removeItem({ ids: arrIds.join(',') }).then(res => {
|
|
|
+ itemRemove({ ids: arrIds.join(',') }).then(res => {
|
|
|
this.$message.success("删除成功");
|
|
|
}).finally(() => {
|
|
|
loading.close();
|
|
|
@@ -684,18 +749,12 @@ export default {
|
|
|
})
|
|
|
}
|
|
|
},
|
|
|
- // 左侧选择
|
|
|
- nodeClick(e) {
|
|
|
- losbfeestemplateDetail(e.id).then(res => {
|
|
|
- this.templateList = res.data.data.feesTemplateItemsList
|
|
|
- })
|
|
|
- },
|
|
|
submit(type) {
|
|
|
this.$refs["form"].validate((valid, done) => {
|
|
|
done();
|
|
|
if (valid) {
|
|
|
- for (let row of this.form.costItemList) {
|
|
|
- if (!row.cntrTypeCode || !row.quantity) {
|
|
|
+ for (let row of this.form.preContainersList) {
|
|
|
+ if (!row.cntrTypeCode || !row.quantity) {
|
|
|
this.$refs.crud.rowCell(row, row.$index)
|
|
|
return this.$message.error("请完善明细信息");
|
|
|
}
|
|
|
@@ -753,7 +812,7 @@ export default {
|
|
|
spinner: 'el-icon-loading',
|
|
|
background: 'rgba(255,255,255,0.7)'
|
|
|
});
|
|
|
- checkAgent(obj).then(res => {
|
|
|
+ pleaseCheck(obj).then(res => {
|
|
|
this.$message.success("请核成功");
|
|
|
this.getDetails(res.data.data.id)
|
|
|
}).finally(() => {
|
|
|
@@ -777,7 +836,7 @@ export default {
|
|
|
spinner: 'el-icon-loading',
|
|
|
background: 'rgba(255,255,255,0.7)'
|
|
|
});
|
|
|
- revokeCheckAgent(obj).then(res => {
|
|
|
+ repealCancel(obj).then(res => {
|
|
|
this.$message.success("撤销请核成功");
|
|
|
this.getDetails(res.data.data.id)
|
|
|
this.editDisabled = false
|