|
|
|
@ -83,12 +83,9 @@
|
|
|
|
|
<vxe-toolbar>
|
|
|
|
|
<template #buttons>
|
|
|
|
|
<div class="nav-box">
|
|
|
|
|
<div class="nav" @click="addBooking"
|
|
|
|
|
><i class="iconfont icon-jiahao2fill"></i>新建</div
|
|
|
|
|
>
|
|
|
|
|
<div class="nav" @click="addBooking2"
|
|
|
|
|
><i class="iconfont icon-jiahao2fill"></i>Test跳转</div
|
|
|
|
|
>
|
|
|
|
|
<div class="nav" @click="addBooking">
|
|
|
|
|
<i class="iconfont icon-jiahao2fill"></i>新建
|
|
|
|
|
</div>
|
|
|
|
|
<div class="nav" @click="copyBooking"
|
|
|
|
|
><i class="iconfont icon-fuzhi"></i>复制</div
|
|
|
|
|
>
|
|
|
|
@ -1082,45 +1079,6 @@
|
|
|
|
|
</a-spin>
|
|
|
|
|
</div>
|
|
|
|
|
</a-modal>
|
|
|
|
|
<a-modal
|
|
|
|
|
:maskClosable="false"
|
|
|
|
|
:width="1700"
|
|
|
|
|
:visible="addVisible"
|
|
|
|
|
@ok="addSubmit"
|
|
|
|
|
@cancel="addCancel"
|
|
|
|
|
>
|
|
|
|
|
<a-radio-group class="group-label-box" v-model="carrierRadio">
|
|
|
|
|
<p v-if="RecentlyCarrierData.length" class="Awrapper"
|
|
|
|
|
>最近使用 <span class="line"></span
|
|
|
|
|
></p>
|
|
|
|
|
<div class="group-label" v-if="RecentlyCarrierData.length">
|
|
|
|
|
<a-radio
|
|
|
|
|
:style="radioStyle"
|
|
|
|
|
:value="item.code"
|
|
|
|
|
v-for="item in RecentlyCarrierData"
|
|
|
|
|
:key="item.code"
|
|
|
|
|
>
|
|
|
|
|
<img class="radio-logo" :src="item.ImgSrc" />
|
|
|
|
|
{{ item.cnName }}
|
|
|
|
|
</a-radio>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div v-for="e in Object.keys(RcarrierData)" :key="e">
|
|
|
|
|
<p class="Awrapper">{{ e }}<span class="line"></span></p>
|
|
|
|
|
<div class="group-label">
|
|
|
|
|
<a-radio
|
|
|
|
|
:style="radioStyle"
|
|
|
|
|
:value="item.code"
|
|
|
|
|
v-for="item in RcarrierData[e]"
|
|
|
|
|
:key="item.code"
|
|
|
|
|
>
|
|
|
|
|
<img class="radio-logo" :src="item.ImgSrc" />
|
|
|
|
|
{{ item.cnName }}
|
|
|
|
|
</a-radio>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</a-radio-group>
|
|
|
|
|
</a-modal>
|
|
|
|
|
<a-modal
|
|
|
|
|
title="多提单号查询"
|
|
|
|
|
:maskClosable="false"
|
|
|
|
@ -1663,7 +1621,6 @@
|
|
|
|
|
})
|
|
|
|
|
const tableOrderLabel = ref('')
|
|
|
|
|
const tableOrderType = ref('')
|
|
|
|
|
const addVisible = ref(false)
|
|
|
|
|
const carrierRadio = ref('CMA')
|
|
|
|
|
const RecentlyCarrierData = ref([])
|
|
|
|
|
const addNum = ref(0)
|
|
|
|
@ -2036,6 +1993,10 @@
|
|
|
|
|
console.log(err)
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
function addBooking() {
|
|
|
|
|
addNum.value = Math.round(Math.random() * 1000)
|
|
|
|
|
go(`/BookingDetail?type=OOCL&addNum=${addNum.value}`)
|
|
|
|
|
}
|
|
|
|
|
// ====================================================
|
|
|
|
|
function getListByone(listId, listIndex) {
|
|
|
|
|
PageDataByBooking({ id: listId }).then((res) => {
|
|
|
|
@ -2139,7 +2100,6 @@
|
|
|
|
|
}
|
|
|
|
|
FnGetUserQuerySet()
|
|
|
|
|
getConfigUser(true)
|
|
|
|
|
getCarrier()
|
|
|
|
|
}
|
|
|
|
|
async function FnGetUserQuerySet() {
|
|
|
|
|
const res: API.DataResult = await GetUserQuerySet({
|
|
|
|
@ -2653,104 +2613,6 @@
|
|
|
|
|
return GetTenantLineList
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
function addBooking() {
|
|
|
|
|
addVisible.value = !addVisible.value
|
|
|
|
|
}
|
|
|
|
|
function addBooking2() {
|
|
|
|
|
go(`/BookingDetail?type=Add`)
|
|
|
|
|
}
|
|
|
|
|
function addSubmit() {
|
|
|
|
|
const data = []
|
|
|
|
|
data.push(carrierRadio.value)
|
|
|
|
|
if (RecentlyCarrierData.value.length) {
|
|
|
|
|
RecentlyCarrierData.value.forEach((item) => {
|
|
|
|
|
if (item.code != carrierRadio.value && data.length < 10) {
|
|
|
|
|
data.push(item.code)
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
DjyUserConfigAdd({
|
|
|
|
|
type: 'booking_memory',
|
|
|
|
|
configJson: JSON.stringify(data),
|
|
|
|
|
}).then((res) => {
|
|
|
|
|
getCarrier()
|
|
|
|
|
addVisible.value = false
|
|
|
|
|
addNum.value = Math.round(Math.random() * 1000)
|
|
|
|
|
go(`/BookingDetail?type=${carrierRadio.value}&addNum=${addNum.value}`)
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
function getCarrier() {
|
|
|
|
|
const Rdata = (data) => {
|
|
|
|
|
const RData = {}
|
|
|
|
|
for (var i = 0; i < 26; i++) {
|
|
|
|
|
RData[String.fromCharCode(65 + i)] = []
|
|
|
|
|
data.forEach((item) => {
|
|
|
|
|
if (String.fromCharCode(65 + i) == item.enName[0].toUpperCase()) {
|
|
|
|
|
RData[String.fromCharCode(65 + i)].push(item)
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
const Obj = {
|
|
|
|
|
'A-D': ['A', 'B', 'C', 'D'],
|
|
|
|
|
'E-L': ['E', 'F', 'G', 'H', 'I', 'J', 'K', 'L'],
|
|
|
|
|
'M-R': ['M', 'N', 'O', 'P', 'Q', 'R'],
|
|
|
|
|
'S-U': ['S', 'T', 'U'],
|
|
|
|
|
'V-Z': ['V', 'W', 'X', 'Y', 'Z'],
|
|
|
|
|
}
|
|
|
|
|
const Data = {
|
|
|
|
|
'A-D': [],
|
|
|
|
|
'E-L': [],
|
|
|
|
|
'M-R': [],
|
|
|
|
|
'S-U': [],
|
|
|
|
|
'V-Z': [],
|
|
|
|
|
}
|
|
|
|
|
Object.keys(Obj).forEach((e) => {
|
|
|
|
|
Obj[e].forEach((item) => {
|
|
|
|
|
RData[item].forEach((Ai, AiIndex) => {
|
|
|
|
|
let imgSrc = ''
|
|
|
|
|
try {
|
|
|
|
|
imgSrc = require(`@/assets/logo/${Ai.code}.png`)
|
|
|
|
|
} catch (error) {
|
|
|
|
|
// imgSrc = require('@/assets/logo/default.png')
|
|
|
|
|
}
|
|
|
|
|
RData[item][AiIndex].ImgSrc = imgSrc
|
|
|
|
|
})
|
|
|
|
|
Data[e].push(...RData[item])
|
|
|
|
|
})
|
|
|
|
|
})
|
|
|
|
|
RcarrierData.value = Data
|
|
|
|
|
}
|
|
|
|
|
GetCarrierlist()
|
|
|
|
|
.then((res) => {
|
|
|
|
|
if (res.code === 200) {
|
|
|
|
|
Rdata(res.data)
|
|
|
|
|
DjyUserConfigGet({ type: 'booking_memory' })
|
|
|
|
|
.then((e) => {
|
|
|
|
|
if (e.data) {
|
|
|
|
|
const data = []
|
|
|
|
|
JSON.parse(e.data.configJson).forEach((item) => {
|
|
|
|
|
res.data.forEach((item2) => {
|
|
|
|
|
if (item == item2.code) {
|
|
|
|
|
data.push(item2)
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
})
|
|
|
|
|
RecentlyCarrierData.value = data
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
.catch(() => {
|
|
|
|
|
Rdata(res.data)
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
.catch((err) => {
|
|
|
|
|
console.log(err)
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
function addCancel() {
|
|
|
|
|
addVisible.value = false
|
|
|
|
|
}
|
|
|
|
|
function copyBooking() {
|
|
|
|
|
const select = xGrid.value.getCheckboxRecords()
|
|
|
|
|
const pkIdArr = select.map((item, index) => {
|
|
|
|
|