各种问题

master
sunzehua 3 months ago
parent f4ec40cb5f
commit 2fb67070fa

12
.env

@ -1,14 +1,14 @@
NODE_ENV=production
VUE_APP_PREVIEW=true
# VUE_APP_TYPE = 'customer'
# VUE_APP_TYPE = 'hechuan'
VUE_APP_TYPE = 'hechuan'
# VUE_APP_TYPE = 'yunyingduan'
VUE_APP_TYPE = 'gangjie'
# VUE_APP_TYPE = 'gangjie'
# 打包部署的三个端 客户端customer 和川端hechuan 运营端djy
# 和川大简云正式
# VUE_APP_API_BASE_URL=http://47.104.85.216:12345/api
# VUE_APP_SOCKET_BASE_URL=http://47.104.85.216:12345
VUE_APP_API_BASE_URL=http://47.104.85.216:12345/api
VUE_APP_SOCKET_BASE_URL=http://47.104.85.216:12345
# 和川大简云测试
# VUE_APP_API_BASE_URL=http://60.209.125.238:35100
@ -23,8 +23,8 @@ VUE_APP_TYPE = 'gangjie'
# VUE_APP_SOCKET_BASE_URL=http://60.209.125.238:30814
# 港捷
VUE_APP_API_BASE_URL=http://118.190.144.189:5001
VUE_APP_SOCKET_BASE_URL=http://118.190.144.189:5001
# VUE_APP_API_BASE_URL=http://118.190.144.189:5001
# VUE_APP_SOCKET_BASE_URL=http://118.190.144.189:5001
# 客户端正式
# VUE_APP_API_BASE_URL=http://118.190.144.189:6001

@ -1,14 +1,14 @@
NODE_ENV=development
VUE_APP_PREVIEW=true
# VUE_APP_TYPE = 'customer'
# VUE_APP_TYPE = 'hechuan'
VUE_APP_TYPE = 'hechuan'
# VUE_APP_TYPE = 'yunyingduan'
VUE_APP_TYPE = 'gangjie'
# VUE_APP_TYPE = 'gangjie'
# 打包部署的三个端 客户端customer 和川端hechuan 运营端yunyingduan
# 和川大简云正式
# VUE_APP_API_BASE_URL=http://47.104.85.216:12345/api
# VUE_APP_SOCKET_BASE_URL=http://47.104.85.216:12345
VUE_APP_API_BASE_URL=http://47.104.85.216:12345/api
VUE_APP_SOCKET_BASE_URL=http://47.104.85.216:12345
# 和川大简云测试
# VUE_APP_API_BASE_URL=http://60.209.125.238:35100
@ -26,8 +26,8 @@ VUE_APP_TYPE = 'gangjie'
# VUE_APP_SOCKET_BASE_URL=http://192.168.0.80:7373/
# 港捷
VUE_APP_API_BASE_URL=http://118.190.144.189:5001
VUE_APP_SOCKET_BASE_URL=http://118.190.144.189:5001
# VUE_APP_API_BASE_URL=http://118.190.144.189:5001
# VUE_APP_SOCKET_BASE_URL=http://118.190.144.189:5001
# 运营端正式
# VUE_APP_API_BASE_URL=http://118.190.144.189:6002

@ -2,7 +2,7 @@
<div class="select-content">
<div class="select-input">
<a-select
size="small"
:size="size"
ref="selectView"
:class="`select-input-${type}`"
v-model="value"
@ -127,6 +127,10 @@ export default {
disabled: {
type: Boolean,
default: false
},
size: {
type: String,
default: 'small'
}
},
data() {

@ -148,7 +148,7 @@ export default {
this.loading = true
getDjyTenantConfig({ type: 'booking_default_value' }).then(res => {
if (res.code == 200) {
this.loadData = JSON.parse(res.data.configJson)
this.loadData = res.data.configJson ? JSON.parse(res.data.configJson) : ''
this.DisplayLoadData = this.loadData
} else {
this.loadData = []

@ -12,91 +12,121 @@
<a-form class="Editing">
<a-row>
<a-col :span="14">
<a-form-item label="提单号:" :label-col="formItemLayout.labelCol1"
<a-form-item
label="提单号:"
:label-col="formItemLayout.labelCol1"
:wrapper-col="formItemLayout.wrapperCol1">{{ form.mblNo }}
<a-icon @click="copyText(form.mblNo)" style="cursor: pointer;" type="copy" />
</a-form-item>
</a-col>
<a-col :span="10">
<a-form-item label="船名/航次:" :label-col="formItemLayout.labelCol2"
<a-form-item
label="船名/航次:"
:label-col="formItemLayout.labelCol2"
:wrapper-col="formItemLayout.wrapperCol2">
{{ form.vessel }}/{{ form.voyNo }}
</a-form-item>
</a-col>
<a-col :span="14">
<a-form-item label="收货地:" :label-col="formItemLayout.labelCol1"
<a-form-item
label="收货地:"
:label-col="formItemLayout.labelCol1"
:wrapper-col="formItemLayout.wrapperCol1">
{{ form.placeReceipt }}
</a-form-item>
</a-col>
<a-col :span="10">
<a-form-item label="ETD" :label-col="formItemLayout.labelCol2"
<a-form-item
label="ETD"
:label-col="formItemLayout.labelCol2"
:wrapper-col="formItemLayout.wrapperCol2">
{{ form.etd ? form.etd.substring(0, 11) : '-' }}
</a-form-item>
</a-col>
<a-col :span="14">
<a-form-item label="交货地:" :label-col="formItemLayout.labelCol1"
<a-form-item
label="交货地:"
:label-col="formItemLayout.labelCol1"
:wrapper-col="formItemLayout.wrapperCol1">
{{ form.placeDelivery }}
</a-form-item>
</a-col>
<a-col :span="10">
<a-form-item label="ETA" :label-col="formItemLayout.labelCol2"
<a-form-item
label="ETA"
:label-col="formItemLayout.labelCol2"
:wrapper-col="formItemLayout.wrapperCol2">
{{ form.eta ? form.eta.substring(0, 11) : '-' }}
</a-form-item>
</a-col>
<a-col :span="14">
<a-form-item label="订舱人:" :label-col="formItemLayout.labelCol1"
<a-form-item
label="订舱人:"
:label-col="formItemLayout.labelCol1"
:wrapper-col="formItemLayout.wrapperCol1">
{{ form.bookingParty }}
</a-form-item>
</a-col>
<a-col :span="10">
<a-form-item label="合约号:" :label-col="formItemLayout.labelCol2"
<a-form-item
label="合约号:"
:label-col="formItemLayout.labelCol2"
:wrapper-col="formItemLayout.wrapperCol2">
{{ form.contractNo }}
</a-form-item>
</a-col>
<a-col :span="14">
<a-form-item label="样单截止时间:" :label-col="formItemLayout.labelCol1"
<a-form-item
label="样单截止时间:"
:label-col="formItemLayout.labelCol1"
:wrapper-col="formItemLayout.wrapperCol1">
{{ form.siCutDate }}
</a-form-item>
</a-col>
<a-col :span="10">
<a-form-item label="箱使天数:" :label-col="formItemLayout.labelCol2"
<a-form-item
label="箱使天数:"
:label-col="formItemLayout.labelCol2"
:wrapper-col="formItemLayout.wrapperCol2">
{{ form.detensionFreeDays }}
</a-form-item>
</a-col>
<a-col :span="14">
<a-form-item label="舱单截止时间:" :label-col="formItemLayout.labelCol1"
<a-form-item
label="舱单截止时间:"
:label-col="formItemLayout.labelCol1"
:wrapper-col="formItemLayout.wrapperCol1">
{{ form.manifestCutDate }}
</a-form-item>
</a-col>
<a-col :span="10">
<a-form-item label="截港时间:" :label-col="formItemLayout.labelCol2"
<a-form-item
label="截港时间:"
:label-col="formItemLayout.labelCol2"
:wrapper-col="formItemLayout.wrapperCol2">
{{ form.cyCutoffTime }}
</a-form-item>
</a-col>
<a-col :span="14">
<a-form-item label="MDGF截止时间" :label-col="formItemLayout.labelCol1"
<a-form-item
label="MDGF截止时间"
:label-col="formItemLayout.labelCol1"
:wrapper-col="formItemLayout.wrapperCol1">
{{ form.mdgfCutDate }}
</a-form-item>
</a-col>
<a-col :span="10">
<a-form-item label="VGM截止时间" :label-col="formItemLayout.labelCol2"
<a-form-item
label="VGM截止时间"
:label-col="formItemLayout.labelCol2"
:wrapper-col="formItemLayout.wrapperCol2">
{{ form.vgmCutoffTime }}
</a-form-item>
</a-col>
<a-col :span="14">
<a-form-item label="箱型箱量:" :label-col="formItemLayout.labelCol1"
<a-form-item
label="箱型箱量:"
:label-col="formItemLayout.labelCol1"
:wrapper-col="formItemLayout.wrapperCol1">
{{ form.ctnStat }}
</a-form-item>
@ -105,31 +135,41 @@
<p class="title"><i class="iconfont icon-chuanfanguanli-chuanfanshenqing"></i>一程</p>
</a-col>
<a-col :span="16">
<a-form-item label="船名/航次:" :label-col="formItemLayout.labelCol3"
<a-form-item
label="船名/航次:"
:label-col="formItemLayout.labelCol3"
:wrapper-col="formItemLayout.wrapperCol3">
{{ form.vessel }}/{{ form.voyNo }}
</a-form-item>
</a-col>
<a-col :span="8">
<a-form-item label="ETD" :label-col="formItemLayout.labelCol4"
<a-form-item
label="ETD"
:label-col="formItemLayout.labelCol4"
:wrapper-col="formItemLayout.wrapperCol4">
{{ form.etd ? form.etd.substring(0, 11) : '-' }}
</a-form-item>
</a-col>
<a-col :span="16">
<a-form-item label="装货港:" :label-col="formItemLayout.labelCol3"
<a-form-item
label="装货港:"
:label-col="formItemLayout.labelCol3"
:wrapper-col="formItemLayout.wrapperCol3">
{{ form.portload }}
</a-form-item>
</a-col>
<a-col :span="8">
<a-form-item label="ETA" :label-col="formItemLayout.labelCol4"
<a-form-item
label="ETA"
:label-col="formItemLayout.labelCol4"
:wrapper-col="formItemLayout.wrapperCol4">
{{ form.eta ? form.eta.substring(0, 11) : '-' }}
</a-form-item>
</a-col>
<a-col :span="16">
<a-form-item label="卸货港:" :label-col="formItemLayout.labelCol3"
<a-form-item
label="卸货港:"
:label-col="formItemLayout.labelCol3"
:wrapper-col="formItemLayout.wrapperCol3">
{{ form.portDischarge }}
</a-form-item>
@ -140,31 +180,41 @@
<p class="title"><i class="iconfont icon-chuanfanguanli-chuanfanshenqing"></i>二程</p>
</a-col>
<a-col :span="16">
<a-form-item label="船名/航次:" :label-col="formItemLayout.labelCol3"
<a-form-item
label="船名/航次:"
:label-col="formItemLayout.labelCol3"
:wrapper-col="formItemLayout.wrapperCol3">
{{ form.secondVessel }}/{{ form.secondVoyno }}
</a-form-item>
</a-col>
<a-col :span="8">
<a-form-item label="ETD" :label-col="formItemLayout.labelCol4"
<a-form-item
label="ETD"
:label-col="formItemLayout.labelCol4"
:wrapper-col="formItemLayout.wrapperCol4">
{{ form.secondETD ? form.secondETD.substring(0, 11) : '-' }}
</a-form-item>
</a-col>
<a-col :span="16">
<a-form-item label="装货港:" :label-col="formItemLayout.labelCol3"
<a-form-item
label="装货港:"
:label-col="formItemLayout.labelCol3"
:wrapper-col="formItemLayout.wrapperCol3">
{{ form.transferPort1 }}
</a-form-item>
</a-col>
<a-col :span="8">
<a-form-item label="ETA" :label-col="formItemLayout.labelCol4"
<a-form-item
label="ETA"
:label-col="formItemLayout.labelCol4"
:wrapper-col="formItemLayout.wrapperCol4">
{{ form.secondETA ? form.secondETA.substring(0, 11) : '-' }}
</a-form-item>
</a-col>
<a-col :span="16">
<a-form-item label="卸货港:" :label-col="formItemLayout.labelCol3"
<a-form-item
label="卸货港:"
:label-col="formItemLayout.labelCol3"
:wrapper-col="formItemLayout.wrapperCol3">
{{ form.portDischarge }}
</a-form-item>
@ -178,7 +228,9 @@
</a-row>
<a-row>
<a-col :span="5">
<a-form-item label="已生成舱位:" :label-col="formItemLayout.labelCol5"
<a-form-item
label="已生成舱位:"
:label-col="formItemLayout.labelCol5"
:wrapper-col="formItemLayout.wrapperCol5">
{{ form.bookingSlotId ? '是' : '否' }}
</a-form-item>
@ -187,7 +239,9 @@
<span class="CsSee" v-if="form.bookingSlotId" @click="FnSee1"></span>
</a-col>
<a-col :span="5">
<a-form-item label="已生成订舱:" :label-col="formItemLayout.labelCol5"
<a-form-item
label="已生成订舱:"
:label-col="formItemLayout.labelCol5"
:wrapper-col="formItemLayout.wrapperCol5">
{{ form.bookingOrderId ? '是' : '否' }}
</a-form-item>
@ -196,7 +250,9 @@
<span class="CsSee" v-if="form.bookingOrderId" @click="FnSee"></span>
</a-col>
<a-col :span="5">
<a-form-item label="任务状态:" :label-col="formItemLayout.labelCol5"
<a-form-item
label="任务状态:"
:label-col="formItemLayout.labelCol5"
:wrapper-col="formItemLayout.wrapperCol5">
{{ form.taskStatus == 'Complete' ? '已完成' : '-' }}
</a-form-item>
@ -208,7 +264,11 @@
<p class="title">关键信息</p>
</a-col>
<div class="unitBox">
<p v-for="(item, index) in form.keywords" :key="index" class="unit" :style="{
<p
v-for="(item, index) in form.keywords"
:key="index"
class="unit"
:style="{
background: item.background,
color: Rcolor(item.background),
border: `1px solid ${Rcolor(item.background)}`
@ -221,7 +281,8 @@
<div
style="height: 30px;border: 1px solid red;padding: 0 10px;color: black;font-size: 13px;line-height: 30px;width: 45%;margin-left: 7px;margin-bottom: 10px;">
<a-icon type="info-circle" theme="filled" style="font-size: 15px;color: red;margin-right: 20px;" />
<span @click="compareResultFlag = true"
<span
@click="compareResultFlag = true"
style="cursor: pointer;text-decoration: underline;">订舱变更比对BC存在差异</span>
差异总数:{{ compareResultList.length }}
</div>
@ -303,10 +364,18 @@
<a-form class="Editing">
<a-row>
<a-col :span="16">
<a-form-item label="委托单位:" :label-col="formItemLayout.labelCol3"
<a-form-item
label="委托单位:"
:label-col="formItemLayout.labelCol3"
:wrapper-col="formItemLayout.wrapperCol3">
<a-select show-search v-model="CreateData.customerId" :default-active-first-option="false"
:show-arrow="false" :filter-option="false" :not-found-content="null" @search="SearchCustomer"
<a-select
show-search
v-model="CreateData.customerId"
:default-active-first-option="false"
:show-arrow="false"
:filter-option="false"
:not-found-content="null"
@search="SearchCustomer"
@change="ChangeCustomer">
<a-select-option v-for="(item, index) in CustomerList" :key="index" :value="item.id">
{{ item.shortName }}
@ -316,11 +385,20 @@
</a-col>
<a-col :span="8">
<a-spin :spinning="fetching">
<a-form-item label="联系人:" :label-col="formItemLayout.labelCol2"
<a-form-item
label="联系人:"
:label-col="formItemLayout.labelCol2"
:wrapper-col="formItemLayout.wrapperCol2">
<a-select show-search mode="multiple" v-model="CreateData.customerList"
:default-active-first-option="false" :show-arrow="false" :filter-option="false"
:not-found-content="null" @change="handleChangeUser" @search="SearchUser">
<a-select
show-search
mode="multiple"
v-model="CreateData.customerList"
:default-active-first-option="false"
:show-arrow="false"
:filter-option="false"
:not-found-content="null"
@change="handleChangeUser"
@search="SearchUser">
<a-select-option v-for="item in customerByList" :key="item.id" :value="item.id">
{{ item.name }}
</a-select-option>
@ -337,8 +415,15 @@
<a-row>
<a-col :span="8">
<a-form-item label="销售:" :label-col="formItemLayout.labelCol2" :wrapper-col="formItemLayout.wrapperCol2">
<a-select show-search v-model="CreateData.saleId" :default-active-first-option="false"
:show-arrow="false" :filter-option="false" :not-found-content="null" @search="SearchUser" @change="e => {
<a-select
show-search
v-model="CreateData.saleId"
:default-active-first-option="false"
:show-arrow="false"
:filter-option="false"
:not-found-content="null"
@search="SearchUser"
@change="e => {
ChangeUser(e, 'saleName')
}
">
@ -350,8 +435,15 @@
</a-col>
<a-col :span="8">
<a-form-item label="操作:" :label-col="formItemLayout.labelCol2" :wrapper-col="formItemLayout.wrapperCol2">
<a-select show-search v-model="CreateData.opId" :default-active-first-option="false" :show-arrow="false"
:filter-option="false" :not-found-content="null" @search="SearchUser" @change="e => {
<a-select
show-search
v-model="CreateData.opId"
:default-active-first-option="false"
:show-arrow="false"
:filter-option="false"
:not-found-content="null"
@search="SearchUser"
@change="e => {
ChangeUser(e, 'opName')
}
">
@ -363,8 +455,15 @@
</a-col>
<a-col :span="8">
<a-form-item label="单证:" :label-col="formItemLayout.labelCol2" :wrapper-col="formItemLayout.wrapperCol2">
<a-select show-search v-model="CreateData.docId" :default-active-first-option="false"
:show-arrow="false" :filter-option="false" :not-found-content="null" @search="SearchUser" @change="e => {
<a-select
show-search
v-model="CreateData.docId"
:default-active-first-option="false"
:show-arrow="false"
:filter-option="false"
:not-found-content="null"
@search="SearchUser"
@change="e => {
ChangeUser(e, 'docName')
}
">
@ -378,8 +477,15 @@
<a-row>
<a-col :span="8">
<a-form-item label="客服:" :label-col="formItemLayout.labelCol2" :wrapper-col="formItemLayout.wrapperCol2">
<a-select show-search v-model="CreateData.custServiceId" :default-active-first-option="false"
:show-arrow="false" :filter-option="false" :not-found-content="null" @search="SearchUser" @change="e => {
<a-select
show-search
v-model="CreateData.custServiceId"
:default-active-first-option="false"
:show-arrow="false"
:filter-option="false"
:not-found-content="null"
@search="SearchUser"
@change="e => {
ChangeUser(e, 'custServiceName')
}
">
@ -390,10 +496,19 @@
</a-form-item>
</a-col>
<a-col :span="8">
<a-form-item label="航线操作:" :label-col="formItemLayout.labelCol2"
<a-form-item
label="航线操作:"
:label-col="formItemLayout.labelCol2"
:wrapper-col="formItemLayout.wrapperCol2">
<a-select show-search v-model="CreateData.routeID" :default-active-first-option="false"
:show-arrow="false" :filter-option="false" :not-found-content="null" @search="SearchUser" @change="e => {
<a-select
show-search
v-model="CreateData.routeID"
:default-active-first-option="false"
:show-arrow="false"
:filter-option="false"
:not-found-content="null"
@search="SearchUser"
@change="e => {
ChangeUser(e, 'route')
}
">
@ -404,10 +519,19 @@
</a-form-item>
</a-col>
<a-col :span="8">
<a-form-item label="航线管理:" :label-col="formItemLayout.labelCol2"
<a-form-item
label="航线管理:"
:label-col="formItemLayout.labelCol2"
:wrapper-col="formItemLayout.wrapperCol2">
<a-select show-search v-model="CreateData.lineManageID" :default-active-first-option="false"
:show-arrow="false" :filter-option="false" :not-found-content="null" @search="SearchUser" @change="e => {
<a-select
show-search
v-model="CreateData.lineManageID"
:default-active-first-option="false"
:show-arrow="false"
:filter-option="false"
:not-found-content="null"
@search="SearchUser"
@change="e => {
ChangeUser(e, 'lineManage')
}
">
@ -420,7 +544,9 @@
</a-row>
<a-row>
<a-col :span="16">
<a-form-item label="操作备注:" :label-col="formItemLayout.labelCol3"
<a-form-item
label="操作备注:"
:label-col="formItemLayout.labelCol3"
:wrapper-col="formItemLayout.wrapperCol3">
<a-input v-model="CreateData.czRemark" />
</a-form-item>
@ -428,7 +554,9 @@
</a-row>
<a-row>
<a-col :span="16">
<a-form-item label="申请箱使:" :label-col="formItemLayout.labelCol3"
<a-form-item
label="申请箱使:"
:label-col="formItemLayout.labelCol3"
:wrapper-col="formItemLayout.wrapperCol3">
<a-input v-model="CreateData.shenQingXiangShi" />
</a-form-item>
@ -436,11 +564,17 @@
</a-row>
<a-row>
<a-col :span="16">
<a-form-item label="服务项目:" :label-col="formItemLayout.labelCol3"
<a-form-item
label="服务项目:"
:label-col="formItemLayout.labelCol3"
:wrapper-col="formItemLayout.wrapperCol3">
<div class="content">
<div class="items" v-for="(serive, sindex) in bookingServiceItem" :key="sindex"
:class="{ active: serive.isYield }" @click="saveService(serive)">
<div
class="items"
v-for="(serive, sindex) in bookingServiceItem"
:key="sindex"
:class="{ active: serive.isYield }"
@click="saveService(serive)">
{{ serive.serviceProjectName }}
</div>
</div>
@ -453,8 +587,14 @@
<a-modal v-model="UserVisible" title="转移任务" @ok="UserhandleOk">
<a-form>
<a-form-item label="接收人:" :label-col="formItemLayout.labelCol1" :wrapper-col="formItemLayout.wrapperCol1">
<a-select show-search v-model="UserId" :default-active-first-option="false" :show-arrow="false"
:filter-option="false" :not-found-content="null" @search="SearchUser">
<a-select
show-search
v-model="UserId"
:default-active-first-option="false"
:show-arrow="false"
:filter-option="false"
:not-found-content="null"
@search="SearchUser">
<a-select-option v-for="item in UserList" :key="item.id" :value="item.id">
{{ item.name }}
</a-select-option>
@ -841,8 +981,6 @@ export default {
}
this.ChangeFileRadio()
})
},
OpenUser() {
this.UserId = ''

@ -149,7 +149,7 @@
:filter-option="false"
:not-found-content="null"
>
<a-select-option v-for="item in portLoadingData" :key="item.code" :value="item.code">
<a-select-option v-for="item in portLoadingData" :key="item.code" :value="item.ediCode">
{{ item.enName }}
</a-select-option>
</a-select>
@ -168,7 +168,7 @@
:filter-option="false"
:not-found-content="null"
>
<a-select-option v-for="item in portTransitData" :key="item.code" :value="item.code">
<a-select-option v-for="item in portTransitData" :key="item.code" :value="item.ediCode">
{{ item.enName }}
</a-select-option>
</a-select>
@ -187,7 +187,7 @@
:filter-option="false"
:not-found-content="null"
>
<a-select-option v-for="item in portDischargeData" :key="item.code" :value="item.code">
<a-select-option v-for="item in portDischargeData" :key="item.code" :value="item.ediCode">
{{ item.enName }}
</a-select-option>
</a-select>
@ -331,21 +331,21 @@ export default {
}
if (this.portLoadingData.length) {
this.portLoadingData.forEach(item => {
if (item.code == values.portLoadingId) {
if (item.ediCode == values.portLoadingId) {
values.portLoading = item.enName
}
})
}
if (this.portTransitData.length) {
this.portTransitData.forEach(item => {
if (item.code == values.portTransitId) {
if (item.ediCode == values.portTransitId) {
values.portTransit = item.enName
}
})
}
if (this.portDischargeData.length) {
this.portDischargeData.forEach(item => {
if (item.code == values.portDischargeId) {
if (item.ediCode == values.portDischargeId) {
values.portDischarge = item.enName
}
})
@ -429,21 +429,21 @@ export default {
}
if (this.portLoadingData.length) {
this.portLoadingData.forEach(item => {
if (item.code == values.portLoadingId) {
if (item.ediCode == values.portLoadingId) {
values.portLoading = item.enName
}
})
}
if (this.portTransitData.length) {
this.portTransitData.forEach(item => {
if (item.code == values.portTransitId) {
if (item.ediCode == values.portTransitId) {
values.portTransit = item.enName
}
})
}
if (this.portDischargeData.length) {
this.portDischargeData.forEach(item => {
if (item.code == values.portDischargeId) {
if (item.ediCode == values.portDischargeId) {
values.portDischarge = item.enName
}
})

@ -7,32 +7,13 @@
@cancel="handleCancel"
>
<a-spin :spinning="confirmLoading">
<a-form :form="form">
<a-form-model ref="ruleForm" :model="form" :rules="rules" >
<a-row>
<!-- <a-col :span="12">
<a-form-item label="租户" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-select
placeholder="请选择租户"
v-decorator="['tenantId', { rules: [{ required: true, message: '请选择租户!' }] }]"
show-search
@focus="tenantSearch"
@search="tenantSearch"
:default-active-first-option="false"
:show-arrow="false"
:filter-option="false"
:not-found-content="null"
>
<a-select-option v-for="item in tenantData" :key="item.id" :value="item.id">
{{ item.name }}
</a-select-option>
</a-select>
</a-form-item>
</a-col> -->
<a-col :span="12">
<a-form-item label="船名" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-form-model-item label="船名" prop="vessel" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-select
placeholder="请选择船名"
v-decorator="['vessel', { rules: [{ required: true, message: '请选择船名!' }] }]"
v-model="form.vessel"
show-search
@focus="vesselSearch"
@search="vesselSearch"
@ -45,14 +26,15 @@
{{ item.name }}
</a-select-option>
</a-select>
</a-form-item>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-item label="船公司" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-form-model-item label="船公司" prop="carrierid" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-select
placeholder="请选择船公司"
v-decorator="['carrierid', { rules: [{ required: true, message: '请选择船公司!' }] }]"
show-search
v-model="form.carrierid"
@focus="carrierSearch"
@search="carrierSearch"
:default-active-first-option="false"
@ -64,141 +46,129 @@
{{ item.cnName }}
</a-select-option>
</a-select>
</a-form-item>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-item label="内部航次" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-form-model-item label="内部航次" prop="voynoInside" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-input
placeholder="请输入内部航次"
v-model="form.voynoInside"
v-decorator="['voynoInside', { rules: [{ required: true, message: '请输入内部航次!' }] }]"
/>
</a-form-item>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-item label="航次" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-form-model-item label="航次" prop="voyno" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-input
placeholder="请输入航次"
v-model="form.voyno"
v-decorator="['voyno', { rules: [{ required: true, message: '请输入航次!' }] }]"
/>
</a-form-item>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-item label="云港通ETD" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-form-model-item label="云港通ETD" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-date-picker
show-time
:style="{ width: '100%' }"
v-model="form.ygtETD"
placeholder="请选择云港通ETD"
v-decorator="['ygtETD']"
valueFormat="YYYY-MM-DD HH:mm:ss"
/>
</a-form-item>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-item label="开船日期" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-form-model-item label="开船日期" prop="etd" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-date-picker
:style="{ width: '100%' }"
v-model="form.etd"
placeholder="请选择开船日期"
v-decorator="['etd', { rules: [{ required: true, message: '请选择开船日期!' }] }]"
valueFormat="YYYY-MM-DD HH:mm:ss"
/>
</a-form-item>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-item label="截港时间" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-form-model-item label="截港时间" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-date-picker
show-time
:style="{ width: '100%' }"
placeholder="请选择截港时间"
v-decorator="['closingDate']"
v-model="form.closingDate"
valueFormat="YYYY-MM-DD HH:mm:ss"
/>
</a-form-item>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-item label="截单时间" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-form-model-item label="截单时间" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-date-picker
:style="{ width: '100%' }"
v-model="form.closeDocTime"
placeholder="请选择截单时间"
show-time
v-decorator="['closeDocTime']"
valueFormat="YYYY-MM-DD HH:mm:ss"
/>
</a-form-item>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-item label="实际开船" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-form-model-item label="实际开船" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-date-picker
show-time
:style="{ width: '100%' }"
v-model="form.atd"
placeholder="请选择实际开船时间"
v-decorator="['atd']"
valueFormat="YYYY-MM-DD HH:mm:ss"
/>
</a-form-item>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-item label="装货港" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-select
placeholder="请选择装货港"
v-decorator="['portLoadingId']"
show-search
@focus="portLoadingSearch"
@search="portLoadingSearch"
:default-active-first-option="false"
:show-arrow="false"
:filter-option="false"
:not-found-content="null"
>
<a-select-option v-for="item in portLoadingData" :key="item.code" :value="item.code">
{{ item.enName }}
</a-select-option>
</a-select>
</a-form-item>
<a-form-model-item label="装货港" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<selectView
type="portloadid"
:defaultVal="form.portLoading"
searchApi="GetPortloadlist"
size="default"
:searchQuery="{ KeyWord: '' }"
:isCopy="false"
:showLabel="['ediCode', 'enName']"
:openSearch="true"
@change="getSelectViewRes"></selectView>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-item label="中转港" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-select
placeholder="请选择中转港"
v-decorator="['portTransitId']"
show-search
@focus="portTransitSearch"
@search="portTransitSearch"
:default-active-first-option="false"
:show-arrow="false"
:filter-option="false"
:not-found-content="null"
>
<a-select-option v-for="item in portTransitData" :key="item.code" :value="item.code">
{{ item.enName }}
</a-select-option>
</a-select>
</a-form-item>
<a-form-model-item label="中转港" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<selectView
type="transportid"
:defaultVal="form.portTransit"
searchApi="GetPortlist"
:searchQuery="{ KeyWord: '' }"
:showLabel="['ediCode', 'enName']"
size="default"
:openSearch="true"
:isCopy="false"
@change="getSelectViewRes"></selectView>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-item label="卸货港" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-select
placeholder="请选择卸货港"
v-decorator="['portDischargeId']"
show-search
@focus="portDischargeSearch"
@search="portDischargeSearch"
:default-active-first-option="false"
:show-arrow="false"
:filter-option="false"
:not-found-content="null"
>
<a-select-option v-for="item in portDischargeData" :key="item.code" :value="item.code">
{{ item.enName }}
</a-select-option>
</a-select>
</a-form-item>
<a-form-model-item label="卸货港" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<selectView
type="portdischargeid"
:defaultVal="form.portDischarge"
searchApi="GetPortlist"
:searchQuery="{ KeyWord: '' }"
:showLabel="['ediCode', 'enName']"
size="default"
:openSearch="true"
:isCopy="false"
@change="getSelectViewRes"></selectView>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-item label="默认场站" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-form-model-item label="默认场站" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-select
placeholder="请选择默认场站"
v-decorator="['yardCode']"
v-model="form.yardCode"
show-search
@focus="yardSearch"
@search="yardSearch"
@ -211,25 +181,25 @@
{{ item.name }}
</a-select-option>
</a-select>
</a-form-item>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-item label="预抵日期" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-form-model-item label="预抵日期" :labelCol="labelCol2" :wrapperCol="wrapperCol2" has-feedback>
<a-date-picker
:style="{ width: '100%' }"
placeholder="请选择预抵日期"
v-decorator="['eta']"
v-model="form.eta"
valueFormat="YYYY-MM-DD HH:mm:ss"
/>
</a-form-item>
</a-form-model-item>
</a-col>
</a-row>
</a-form>
</a-form-model>
</a-spin>
<template slot="footer">
<a-button type="danger" @click="handleCancel"></a-button>
<a-button type="primary" @click="handleCopySave"></a-button>
<a-button type="primary" @click="handleSubmit"></a-button>
<a-button type="primary" @click="handleSubmit(true)"></a-button>
<a-button type="primary" @click="handleSubmit(false)"></a-button>
</template>
</a-modal>
</template>
@ -244,10 +214,18 @@ import {
GetVessellist,
GetYardlist
} from '@/api/modular/main/vesselinfo'
import selectView from '../BookingLedger/detail/components/selectView.vue'
export default {
data() {
return {
TypeData: [],
rules: {
voynoInside: [{ required: true, message: '请输入内部航次!', trigger: 'blur' }],
etd: [{ required: true, message: '请选择开船日期', trigger: 'blur' }],
voyno: [{ required: true, message: '请输入航次', trigger: 'blur' }],
carrierid: [{ required: true, message: '请选择船公司', trigger: 'blur' }],
vessel: [{ required: true, message: '请选择船名', trigger: 'blur' }]
},
labelCol: {
xs: { span: 24 },
sm: { span: 6 }
@ -276,114 +254,36 @@ export default {
yardData: []
}
},
components: {
selectView
},
mounted() {},
methods: {
//
edit(record) {
this.data = record
console.log(record)
this.visible = true
setTimeout(() => {
this.form.setFieldsValue({
tenantId: record.tenantId,
vessel: record.vessel,
voyno: record.voyno,
portLoadingId: record.portLoadingId,
portTransitId: record.portTransitId,
portDischargeId: record.portDischargeId,
portLoading: record.portLoading,
portTransit: record.portTransit,
portDischarge: record.portDischarge,
etd: record.etd,
closingDate: record.closingDate,
eta: record.eta,
yard: record.yard,
ygtETD: record.ygtETD,
yardCode: record.yardCode,
atd: record.atd,
carrierid: record.carrierid,
voynoInside: record.voynoInside,
closeDocTime: record.closeDocTime
})
console.log(this.form.getFieldsValue())
this.form = record
this.$forceUpdate()
}, 100)
},
handleCopySave() {
const {
form: { validateFields }
} = this
this.confirmLoading = true
validateFields((errors, values) => {
console.log(errors, values)
if (!errors) {
for (const key in values) {
console.log(key, 1)
if (typeof values[key] === 'object' && !(values[key] === null)) {
values[key] = JSON.stringify(values[key])
}
}
if (!values.carrier) {
values.carrier = this.data.carrier
}
values.id = this.data.id
if (this.portLoadingData.length) {
this.portLoadingData.forEach(item => {
if (item.code == values.portLoadingId) {
values.portLoading = item.enName
}
})
}
if (this.portTransitData.length) {
this.portTransitData.forEach(item => {
if (item.code == values.portTransitId) {
values.portTransit = item.enName
}
})
getSelectViewRes({ type, res }) {
if (type === 'portloadid') {
this.form.portLoadingId = res.ediCode
}
if (this.portDischargeData.length) {
this.portDischargeData.forEach(item => {
if (item.code == values.portDischargeId) {
values.portDischarge = item.enName
}
})
}
if (this.carrierData.length) {
this.carrierData.forEach(item => {
if (item.code == values.carrierid) {
values.carrier = item.cnName
if (type === 'portdischargeid') {
this.form.portDischargeId = res.ediCode
}
})
}
if (this.yardData.length) {
this.yardData.forEach(item => {
if (item.code == values.yardCode) {
values.yard = item.name
if (type === 'transportid') {
this.form.portTransitId = res.ediCode
}
})
}
DjyVesselInfoServiceAddOrUpdate(values)
.then(res => {
if (res.success) {
this.$message.success('编辑成功')
this.confirmLoading = false
this.$emit('ok', values)
this.editRow(values)
} else {
this.$message.error(`编辑失败,${res.message}`)
}
})
.finally(res => {
this.confirmLoading = false
})
} else {
this.confirmLoading = false
}
})
},
editRow(record) {
this.data = record
setTimeout(() => {
this.form.setFieldsValue({
this.form = {
vessel: record.vessel,
voyno: record.voyno,
portTransitId: record.portTransitId,
@ -402,14 +302,10 @@ export default {
carrierid: record.carrierid,
voynoInside: record.voynoInside,
closeDocTime: record.closeDocTime
})
}
this.$forceUpdate()
}, 100)
},
// tenantSearch(data) {
// SysTenantPage({ Name: data }).then(res => {
// this.tenantData = res.data.rows
// })
// },
portLoadingSearch(data) {
GetPortloadlist({ KeyWord: data }).then(res => {
this.portLoadingData = res.data
@ -440,80 +336,74 @@ export default {
this.yardData = res.data
})
},
handleSubmit() {
const {
form: { validateFields }
} = this
this.confirmLoading = true
validateFields((errors, values) => {
console.log(errors, values)
if (!errors) {
for (const key in values) {
console.log(key, 1)
if (typeof values[key] === 'object' && !(values[key] === null)) {
values[key] = JSON.stringify(values[key])
handleSubmit(isCopy) {
this.$refs.ruleForm.validate(valid => {
if (valid) {
if (!this.form.carrier) {
this.form.carrier = this.data.carrier
}
}
if (!values.carrier) {
values.carrier = this.data.carrier
}
values.id = this.data.id
if (this.portLoadingData.length) {
this.portLoadingData.forEach(item => {
if (item.code == values.portLoadingId) {
values.portLoading = item.enName
if (item.ediCode == this.form.portLoadingId) {
this.form.portLoading = item.enName
}
})
}
if (this.portTransitData.length) {
this.portTransitData.forEach(item => {
if (item.code == values.portTransitId) {
values.portTransit = item.enName
if (item.ediCode == this.form.portTransitId) {
this.form.portTransit = item.enName
}
})
}
if (this.portDischargeData.length) {
this.portDischargeData.forEach(item => {
if (item.code == values.portDischargeId) {
values.portDischarge = item.enName
if (item.ediCode == this.form.portDischargeId) {
this.form.portDischarge = item.enName
}
})
}
if (this.carrierData.length) {
this.carrierData.forEach(item => {
if (item.code == values.carrierid) {
values.carrier = item.cnName
if (item.code == this.form.carrierid) {
this.form.carrier = item.cnName
}
})
}
if (this.yardData.length) {
this.yardData.forEach(item => {
if (item.code == values.yardCode) {
values.yard = item.name
if (item.code == this.form.yardCode) {
this.form.yard = item.name
}
})
}
DjyVesselInfoServiceAddOrUpdate(values)
if (!isCopy) {
this.form.id = this.data.id
}
this.confirmLoading = true
DjyVesselInfoServiceAddOrUpdate(this.form)
.then(res => {
if (res.success) {
this.$message.success('编辑成功')
this.confirmLoading = false
this.$emit('ok', values)
this.$emit('ok', this.form)
if (isCopy) {
this.editRow(this.form)
} else {
this.handleCancel()
}
} else {
this.$message.error(`编辑失败,${res.message}`)
}
this.confirmLoading = false
})
.finally(res => {
this.confirmLoading = false
})
} else {
this.confirmLoading = false
}
})
},
handleCancel() {
this.form.resetFields()
this.visible = false
}
}

@ -276,6 +276,12 @@ export default {
field: 'portLoading',
width: 150
},
{
title: '装货港代码',
align: 'center',
field: 'portLoadingId',
width: 150
},
{
title: '中转港',
align: 'center',
@ -374,7 +380,6 @@ export default {
})
},
confirm(e) {
this.FnDel(e)
},

Loading…
Cancel
Save