|
@@ -1,7 +1,7 @@
|
|
|
<!--
|
|
|
* @Author: your name
|
|
|
* @Date: 2022-01-17 10:39:22
|
|
|
- * @LastEditTime: 2022-05-26 09:56:00
|
|
|
+ * @LastEditTime: 2022-05-26 18:09:10
|
|
|
* @LastEditors: your name
|
|
|
* @Description: 航班视图
|
|
|
-->
|
|
@@ -273,11 +273,11 @@
|
|
|
</div> -->
|
|
|
<TimeZoneSelector />
|
|
|
<img
|
|
|
- class="btn-square"
|
|
|
+ class="btn-square btn-shadow"
|
|
|
src="../../../../assets/baggage/ic_export.png"
|
|
|
>
|
|
|
<img
|
|
|
- class="btn-square"
|
|
|
+ class="btn-square btn-shadow"
|
|
|
src="../../../../assets/baggage/ic_setting.png"
|
|
|
@click="show"
|
|
|
>
|
|
@@ -367,6 +367,7 @@ import tableColsMixin from '../../mixins/tableCols'
|
|
|
import timeZoneMixin from '../../mixins/timeZone'
|
|
|
import TableHeaderCellWithFilter from '@/components/TableHeaderCellWithFilter'
|
|
|
import { setTableFilters } from '@/utils/table'
|
|
|
+import { mapGetters } from 'vuex'
|
|
|
|
|
|
// const arrivalBaggageTableColumn = [
|
|
|
// { name: '序号', prop: 'index' },
|
|
@@ -407,10 +408,10 @@ const departureBaggageTableColumn = [
|
|
|
{ name: '装载序号', prop: 'LoadSN' },
|
|
|
{ name: '值机', prop: 'checkIn', width: 140 },
|
|
|
{ name: '状态', prop: 'latestStatus' },
|
|
|
- { name: '安检', prop: 'security', width: 140 },
|
|
|
- { name: '分拣', prop: 'sorting', width: 140 },
|
|
|
- { name: '装车', prop: 'loading', width: 140 },
|
|
|
- { name: '装机', prop: 'installed', width: 140 },
|
|
|
+ { name: '安检', prop: 'DealInfo', width: 140 },
|
|
|
+ { name: '分拣', prop: 'sortLocationMark', width: 140 },
|
|
|
+ { name: '装车', prop: 'loadLocationMark', width: 140 },
|
|
|
+ { name: '装机', prop: 'inflLocationMark', width: 140 },
|
|
|
{ name: '中转标志', prop: 'transitFlag' },
|
|
|
{ name: '卷宗号', prop: 'fileNumber' }
|
|
|
]
|
|
@@ -424,11 +425,10 @@ export default {
|
|
|
mixins: [tableColsMixin, timeZoneMixin],
|
|
|
data() {
|
|
|
return {
|
|
|
+ fullscreenLoading: false,
|
|
|
queryData: {},
|
|
|
flightInfo: {},
|
|
|
keyWords: '',
|
|
|
- openUTC: true,
|
|
|
- props: { multiple: true },
|
|
|
// options: [
|
|
|
// { value: 0, label: 'VIP行李' },
|
|
|
// { value: 0, label: 'VIP行李' }
|
|
@@ -481,6 +481,7 @@ export default {
|
|
|
}
|
|
|
},
|
|
|
computed: {
|
|
|
+ ...mapGetters(['clickedCells']),
|
|
|
filteredTableData() {
|
|
|
return this.flightBaggageTableData.filter(item => {
|
|
|
let flag = true
|
|
@@ -493,11 +494,40 @@ export default {
|
|
|
})
|
|
|
}
|
|
|
},
|
|
|
- created() {
|
|
|
+ watch: {
|
|
|
+ '$route.query': {
|
|
|
+ handler(val) {
|
|
|
+ this.queryData = this._.cloneDeep(val)
|
|
|
+ const { FlightNO, FlightDate } = this.queryData
|
|
|
+ if (FlightNO && FlightDate) {
|
|
|
+ this.queryAll([FlightNO, FlightDate])
|
|
|
+ } else {
|
|
|
+ this.$router.push('/advance')
|
|
|
+ }
|
|
|
+ },
|
|
|
+ deep: true
|
|
|
+ },
|
|
|
+ fullscreenLoading(val) {
|
|
|
+ if (val) {
|
|
|
+ this.loading = this.$loading({
|
|
|
+ lock: true,
|
|
|
+ text: '加载中',
|
|
|
+ spinner: 'el-icon-loading',
|
|
|
+ background: 'rgba(0, 0, 0, 0.7)'
|
|
|
+ })
|
|
|
+ } else {
|
|
|
+ this.loading.close()
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
+ mounted() {
|
|
|
this.queryData = this._.cloneDeep(this.$route.query)
|
|
|
- // console.log(this.queryData)
|
|
|
- const queryData = [this.queryData.FlightNO, this.queryData.FlightDate]
|
|
|
- this.queryAll(queryData)
|
|
|
+ const { FlightNO, FlightDate } = this.queryData
|
|
|
+ if (FlightNO && FlightDate) {
|
|
|
+ this.queryAll([FlightNO, FlightDate])
|
|
|
+ } else {
|
|
|
+ this.$router.push('/advance')
|
|
|
+ }
|
|
|
},
|
|
|
updated() {
|
|
|
this.$nextTick(() => {
|
|
@@ -510,7 +540,9 @@ export default {
|
|
|
methods: {
|
|
|
cellClass({ row, column, rowIndex, columnIndex }) {
|
|
|
const classes = []
|
|
|
- if (['checkIn', 'security', 'sorting', 'loading', 'installed'].includes(column.property)) {
|
|
|
+ if (
|
|
|
+ ['checkIn', 'DealInfo', 'sortLocationMark', 'loadLocationMark', 'inflLocationMark'].includes(column.property)
|
|
|
+ ) {
|
|
|
classes.push('pre-line')
|
|
|
}
|
|
|
if (
|
|
@@ -519,6 +551,16 @@ export default {
|
|
|
)
|
|
|
) {
|
|
|
classes.push('cell-click')
|
|
|
+ if (
|
|
|
+ this.clickedCells.some(
|
|
|
+ cell =>
|
|
|
+ cell.pageName === this.$route.name &&
|
|
|
+ Object.entries(cell.row).every(([key, value]) => row[key] === value) &&
|
|
|
+ cell.columnProp === column.property
|
|
|
+ )
|
|
|
+ ) {
|
|
|
+ classes.push('cell-clicked')
|
|
|
+ }
|
|
|
}
|
|
|
if (
|
|
|
(column.property === 'latestStatus' && row[column.property] === '待翻减') ||
|
|
@@ -529,6 +571,17 @@ export default {
|
|
|
return classes.join(' ')
|
|
|
},
|
|
|
cellClickHandler(row, column, cell, event) {
|
|
|
+ if (
|
|
|
+ ['PreFlightNO', 'totalNumber', 'TransferFlightNO', 'transferNumber', 'PassengerNameUpcase', 'BagSN'].includes(
|
|
|
+ column.property
|
|
|
+ )
|
|
|
+ ) {
|
|
|
+ this.$store.dispatch('keepAlive/addClickedCell', {
|
|
|
+ row,
|
|
|
+ columnProp: column.property,
|
|
|
+ pageName: this.$route.name
|
|
|
+ })
|
|
|
+ }
|
|
|
switch (column.property) {
|
|
|
case 'PreFlightNO':
|
|
|
this.$router.push({
|
|
@@ -625,10 +678,6 @@ export default {
|
|
|
return ['合计', `共${num}件`]
|
|
|
}
|
|
|
},
|
|
|
- filterHandler(value, row, column) {
|
|
|
- const property = column['property']
|
|
|
- return row[property] === value
|
|
|
- },
|
|
|
containeClick(row) {
|
|
|
this.$router.push({
|
|
|
path: '/advance',
|
|
@@ -656,6 +705,7 @@ export default {
|
|
|
return myQuery(queryMap.baggageByFlightNO, ...dataContent)
|
|
|
},
|
|
|
async queryAll(dataContent) {
|
|
|
+ this.fullscreenLoading = true
|
|
|
try {
|
|
|
const [
|
|
|
flightInfo,
|
|
@@ -684,21 +734,14 @@ export default {
|
|
|
this.warningContainers = []
|
|
|
this.flightBaggageTableData = flightBaggageTableData.map((item, index) => {
|
|
|
item['latestStatus'] === '待翻减' && this.warningContainers.push(item['U_Device_ID'])
|
|
|
-
|
|
|
- item['checkIn'] = `${item['checkIn'] ?? ''}\n${item['checkInTime'] ?? ''}`
|
|
|
- // item['latestStatus'] = item['Status'] === 'DEL' ? '删除' : item['latestStatus']
|
|
|
- item['security'] = `${item['DealInfo'] ?? ''}\n${item['DealTime'] ?? ''}`
|
|
|
- item['sorting'] = `${item['sortLocationMark'] ?? ''}\n${item['sortDealTime'] ?? ''}`
|
|
|
- item['loading'] = `${item['loadLocationMark'] ?? ''}\n${item['loadDealTime'] ?? ''}`
|
|
|
- item['installed'] = `${item['inflLocationMark'] ?? ''}\n${item['inflLoadDealTime'] ?? ''}`
|
|
|
item['transitFlag'] = item['PreFlightNO'] ? '是' : '否'
|
|
|
return item
|
|
|
})
|
|
|
-
|
|
|
setTableFilters(this.flightBaggageTableData, this.flightBaggageTableFilters)
|
|
|
} catch (error) {
|
|
|
console.log('错误', error)
|
|
|
}
|
|
|
+ this.fullscreenLoading = false
|
|
|
}
|
|
|
}
|
|
|
}
|