Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Fedex
/
imac-vue
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
shanyunduo.cheng
2021-12-06 13:44:49 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
1836e51174b6f00ff964d807245faeee61d11c22
1836e511
1 parent
29baa166
航班名查询
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
62 additions
and
11 deletions
src/api/destinationFlight.js
src/views/allocationConfig/flightAllocConfig/index.vue
src/views/allocationConfig/flightAllocConfig/info.vue
src/api/destinationFlight.js
View file @
1836e51
...
...
@@ -11,7 +11,7 @@ export function findFlightNo(query) {
})
}
// id查询目的航班
列表
// id查询目的航班
export
function
findByFlightId
(
id
)
{
const
data
=
{
id
...
...
@@ -23,6 +23,19 @@ export function findByFlightId(id) {
})
}
//航班号查航班
export
function
findDestinationFltRuleByActualFlight
(
actualFlight
){
const
data
=
{
actualFlight
}
return
request
({
url
:
'/sourceFlight/findDestinationFltRuleByActualFlight'
,
method
:
'post'
,
data
:
data
})
}
export
function
updateOrAddFlight
(
form
){
//处理数据
form
.
typeOfGoods
=
form
.
typeOfGoods
.
join
(
';'
);
...
...
src/views/allocationConfig/flightAllocConfig/index.vue
View file @
1836e51
...
...
@@ -13,6 +13,12 @@
@keyup.enter.native="getList"
></el-input>
</el-form-item>
<el-form-item label="状态">
<el-select v-model="queryParams.status" placeholder="状态" clearable >
<el-option label="有效" value="1"></el-option>
<el-option label="停用" value="3"></el-option>
</el-select>
</el-form-item>
<el-form-item>
<el-button
type="primary"
...
...
@@ -128,6 +134,7 @@ export default {
return {
queryParams: {
purposeOfFlightNo: "",
status:"1",
start: 0,
limit: 10,
},
...
...
@@ -172,15 +179,15 @@ export default {
del(id, status) {
if (status == "1") {
this.$confirm("航班规则生效中,无法删除,请停用后再操作", "警告", {
confirmButtonText:
'确定'
,
showCancelButton:false,
confirmButtonText:
"确定"
,
showCancelButton:
false,
type: "warning",
});
} else {
this.$confirm("是否确认删除此航班规则?", "警告", {
confirmButtonText: "确定",
cancelButtonText: "取消",
showCancelButton:true,
showCancelButton:
true,
type: "warning",
})
.then(function () {
...
...
src/views/allocationConfig/flightAllocConfig/info.vue
View file @
1836e51
...
...
@@ -221,6 +221,7 @@ import {
findByFlightId,
updateOrAddFlight,
allDictData,
findDestinationFltRuleByActualFlight,
} from "@/api/destinationFlight";
export default {
...
...
@@ -307,10 +308,6 @@ export default {
},
},
created() {
let matched = this.$route.matched.filter(
(item) => item.meta && item.meta.title
);
let routers = this.$router.options.routes;
let handle = this.$route.params.handle;
allDictData().then((response) => {
...
...
@@ -335,6 +332,33 @@ export default {
if (handle != "add") {
let id = this.$route.params.id;
if (isNaN(Number(id))) {
findDestinationFltRuleByActualFlight(id).then((response) => {
if (response.code != 200) {
this.$message({
showClose: true,
message: response.msg,
type: "error",
});
reuturn;
}
let info = response.data;
info.typeOfGoods = info.typeOfGoods
? info.typeOfGoods.split(";")
: [];
info.declarationCategory = info.declarationCategory
? info.declarationCategory.split(";")
: [];
info.serviceCode = info.serviceCode
? info.serviceCode.split(";")
: [];
info.subCategory = info.subCategory
? info.subCategory.split(";")
: [];
this.form = info;
this.loading = false;
});
} else {
//货物信息
findByFlightId(id).then((response) => {
if (response.code != 200) {
...
...
@@ -346,15 +370,22 @@ export default {
reuturn;
}
let info = response.data.list;
info.typeOfGoods = info.typeOfGoods ? info.typeOfGoods.split(";") : [];
info.typeOfGoods = info.typeOfGoods
? info.typeOfGoods.split(";")
: [];
info.declarationCategory = info.declarationCategory
? info.declarationCategory.split(";")
: [];
info.serviceCode = info.serviceCode ? info.serviceCode.split(";") : [];
info.subCategory = info.subCategory ? info.subCategory.split(";") : [];
info.serviceCode = info.serviceCode
? info.serviceCode.split(";")
: [];
info.subCategory = info.subCategory
? info.subCategory.split(";")
: [];
this.form = info;
this.loading = false;
});
}
} else {
this.loading = false;
}
...
...
Please
register
or
login
to post a comment