jinhui.wang

维度页面跳转修正,导入错误提示修正

......@@ -74,7 +74,7 @@ export const constantRoutes = [
redirect: 'noredirect',
children: [
{
path: '/info/:handle/:fltNo-:fltDate',
path: '/info/:handle/:id~:routeStatus~:fltNo~:route~:fltDate',
component: (resolve) => require(['@/views/allocationConfig/flightAllocConfig/info'], resolve),
name: 'FlightAllocConfigInfo',
meta: { title: '航班配舱', icon: 'user' }
......@@ -85,6 +85,12 @@ export const constantRoutes = [
name: 'weatherTable',
meta: { title: '流水表', icon: 'user' }
},
{
path: '/upDateResult->:from',
component: (resolve) => require(['@/views/preMdeConfig/upDateResult'], resolve),
name: 'UpDateResult',
meta: { title: '导入信息', icon: 'user' }
},
]
}
]
......
......@@ -142,10 +142,11 @@ export default {
//跳转到查看,修改页面
handleClick(fltNo, handle, fltDate, status) {
let obj = {
id: ' ',
handle: handle,
fltNo: fltNo,
fltDate: fltDate != null ? fltDate : '',
route: null,
fltDate: fltDate != null ? fltDate : ' ',
route: ' ',
routeStatus: 'FlightAllocConfig',
status: status
}
......
......@@ -22,7 +22,7 @@
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="6" v-if="infoForm.route != null">
<el-col :span="6" v-if="infoForm.route != null && infoForm.route != ' ' && infoForm.route!=''">
<el-form-item label="航线">
<el-input v-model.tirm="infoForm.route" @change="getRoutes" disabled>
</el-input>
......@@ -189,7 +189,8 @@
<el-card shadow="never" style="width: 95%">
<el-checkbox-group v-model="val.puporpuxCode" @change="change">
<el-row>
<el-col :span="2" v-for="item in checkBoxItem.puporpux">
<el-col :span="2" v-for="item in checkBoxItem.puporpux"
:key="item.id">
<el-checkbox
v-if="item.status === 1 || val.puporpuxCode.includes(item.chineseName)"
:label="item.chineseName" :name="item.chineseName"
......@@ -543,49 +544,39 @@ export default {
this.infoForm.fltNo = this.$route.params.fltNo
this.infoForm.fltDate = this.$route.params.fltDate
this.infoForm.route = this.$route.params.route
if (this.routeSatus == 'dmLog') {
this.getIdDimension(this.$route.params.id)
} else {
this.getRouteDimension({ fltNo: this.$route.params.fltNo, fltDate: this.$route.params.fltDate, route: this.$route.params.route ? this.$route.params.route : '', status: this.$route.params.status })
if (this.$route.params.status) {
if (this.routeSatus == 'dmLog') {
this.getIdDimension(this.$route.params.id)
} else {
this.getRouteDimension({ fltNo: this.$route.params.fltNo, fltDate: this.$route.params.fltDate, route: this.$route.params.route ? this.$route.params.route : '', status: this.$route.params.status ? this.$route.params.status : '' })
}
}
} else {
this.infoForm.fltNo = ''
this.infoForm.fltDate = null
this.infoForm.route = null
}
},
mounted() {
this.loading = false
},
watch: {
$route: {
handler(to, from) {
let route = ''
if (from.name == 'FlightInformationMaintenance') {
this.routeSatus = 'flightInformationMaintenance'
if (this.infoForm.list.length > 0) {
route = this.infoForm.list[0].flightRoute
}
} else if (from.name == 'DmLog') {
this.routeSatus = 'dmLog'
if (this.infoForm.list.length > 0) {
route = this.infoForm.list[0].flightRoute
this.getIdDimension(this.infoForm.list[0].id)
}
} else {
this.routeSatus = null
}
if (to.name == 'FlightAllocConfigInfo' && from.name != 'DmLog') {
this.getRouteDimension({ fltNo: this.infoForm.fltNo, fltDate: this.infoForm.fltDate, route: route ? route : '', status: this.$route.params.status })
activated() {
this.routeSatus = this.$route.params.routeStatus
if (!this.$route.params.status) {
if (this.$route.params.handle == 'add') {
if (this.infoForm.fltNo && this.infoForm.fltNo != null && this.infoForm.fltNo != '') {
this.getRoutes(this.infoForm.fltNo)
}
if (this.$route.params.handle == 'add') {
if (this.infoForm.fltNo && this.infoForm.fltNo != null && this.infoForm.fltNo != '') {
this.getRoutes(this.infoForm.fltNo)
}
}
},
deep: true
},
}
if (this.routeSatus == 'dmLog') {
this.getIdDimension(this.$route.params.id)
} else {
this.getRouteDimension({ fltNo: this.$route.params.fltNo, fltDate: this.$route.params.fltDate, route: this.$route.params.route ? this.$route.params.route : '', status: '' })
}
}
},
watch: {
},
methods: {
//页面选项
......@@ -651,7 +642,7 @@ export default {
this.routeList = res.data.routeList
if (res.data.list.length > 0) {
//请求到数据
if (this.infoForm.route != null && this.infoForm.route != null) {
if (this.infoForm.route != null && this.infoForm.route != '' && this.infoForm.route != ' ') {
//航线不为空,对应到这条航线下的这条维度(直接处理插入数据)
if (this.routeSatus == 'flightInformationMaintenanceWhite Tail') {
//如果是从航班维护界面跳转且航班类型为White Tail则直接显示当前航线维度
......@@ -704,7 +695,7 @@ export default {
}
} else {
//未请求到数据
if (this.infoForm.route != null && this.infoForm.route != '') {
if (this.infoForm.route != null && this.infoForm.route != '' && this.infoForm.route != ' ') {
//航线不为空,获取该航线下无日期通用维度设置
findDestinationFltRuleByFlightNo({
purposeOfFlightNo: this.infoForm.fltNo,
......@@ -967,7 +958,6 @@ export default {
this.infoForm.list[val].serviceCode = []
this.infoForm.list[val].handlingCode = []
this.infoForm.list[val].subCategory = []
console.log(this.infoForm)
this.$forceUpdate()
},
//启用,停用
......
......@@ -785,10 +785,11 @@ export default {
//查看航班维度
goFlightAllocConfig(val) {
let obj = {
id: ' ',
handle: 'update',
fltNo: val.fltNo,
fltDate: val.fltDate ? val.fltDate : null,
route: val.flightKindName != 'Purple Tail' ? val.route : '',
route: val.flightKindName != 'Purple Tail' ? val.route : ' ',
routeStatus: 'flightInformationMaintenance' + val.flightKindName,
status: '1'
}
......
......@@ -69,7 +69,7 @@
</template>
<template v-slot:flightFltNo="scope">
<el-link v-if="scope.row.allocDimId" type="primary"
@click="$router.push({ name: 'FlightAllocConfigInfo', params: { id: scope.row.allocDimId, handle: 'detail', fltNo: scope.row.flightFltNo, fltDate: scope.row.flightFltDate ? scope.row.flightFltDate : ' ', routeStatus: 'dmLog', route: scope.row.currentFlightRoute } })">
@click="$router.push({ name: 'FlightAllocConfigInfo', params: { id: scope.row.allocDimId, handle: 'detail', fltNo: scope.row.flightFltNo, fltDate: scope.row.flightFltDate ? scope.row.flightFltDate : ' ', routeStatus: 'dmLog', route: scope.row.currentFlightRoute? scope.row.currentFlightRoute:' ' } })">
{{
scope.row.flightFltNo
}}<i class="el-icon-link"></i> </el-link>
......