作者 朱兆平

操作体验优化

... ... @@ -91,12 +91,9 @@ axios.interceptors.response.use(
// 下面是接口回调的satus ,因为我做了一些错误页面,所以都会指向对应的报错页面
if (error.response.status === 401) {
router.push({
path: "/login"
});
message({
// 饿了么的消息弹窗组件
message: '授权超时,或未授权,请重新登录',
message: '授权超时,或访问未授权,请重新登录',
type: "error"
});
}
... ...
... ... @@ -129,7 +129,6 @@
}).then(() => {
sessionStorage.removeItem('user');
sessionStorage.removeItem('menu');
//退出后初始化原来的路由
let sysRoutes = JSON.parse(sessionStorage.getItem('sysMenu'));
console.log(sysRoutes);
... ...
... ... @@ -3,12 +3,12 @@
<el-form :model="ruleForm2" :rules="rules2" ref="ruleForm2" label-position="left" label-width="0px" class="demo-ruleForm login-container" id="loginForm">
<h3 class="title">系统登录</h3>
<el-form-item prop="account">
<el-input type="text" v-model="ruleForm2.account" auto-complete="off" placeholder="账号"></el-input>
<el-input type="text" v-model="ruleForm2.account" autofocus placeholder="账号"></el-input>
</el-form-item>
<el-form-item prop="checkPass">
<el-input type="password" v-model="ruleForm2.checkPass" auto-complete="off" placeholder="密码"></el-input>
<el-input type="password" v-model="ruleForm2.checkPass" placeholder="密码" @keyup.enter.native="handleSubmit2"></el-input>
</el-form-item>
<el-checkbox v-model="checked" checked class="remember">记住密码</el-checkbox>
<el-checkbox v-model="checked" checked class="remeberme">记住密码</el-checkbox>
<el-form-item style="width:100%;">
<el-button type="primary" style="width:100%;" @click.native.prevent="handleSubmit2" :loading="logining" :plain="true">登录</el-button>
<!--<el-button @click.native.prevent="handleReset2">重置</el-button>-->
... ... @@ -42,8 +42,8 @@
fixStyle: '',
logining: false,
ruleForm2: {
account: 'admin',
checkPass: '123456'
account: '',
checkPass: ''
},
rules2: {
account: [
... ...
... ... @@ -32,7 +32,9 @@
</el-table-column>
<el-table-column prop="modelnamecn" label="操作模块" width="120" sortable>
</el-table-column>
<el-table-column prop="classname" label="系统类" show-overflow-tooltip="true" width="100" sortable>
<el-table-column prop="classname" label="系统类" show-overflow-tooltip width="100" sortable>
</el-table-column>
<el-table-column prop="parameters" label="参数" show-overflow-tooltip width="100" sortable>
</el-table-column>
<el-table-column prop="result" label="操作结果" min-width="200" sortable>
</el-table-column>
... ...
... ... @@ -126,7 +126,7 @@
<el-dialog title="新增" :visible.sync="addFormVisible" :close-on-click-modal="false">
<el-form :model="addForm" label-width="80px" :rules="addFormRules" ref="addForm">
<el-form-item label="账号" prop="username">
<el-input v-model="addForm.username"></el-input>
<el-input v-model="addForm.username" aria-placeholder="用户名长度在5-11位,支持英文和数字"></el-input>
</el-form-item>
<el-form-item label="密码" prop="password">
<el-input v-model="addForm.password" type="password"></el-input>
... ... @@ -230,7 +230,10 @@
addLoading: false,
addFormRules: {
username: [
{ required: true, message: '请输入姓名', trigger: 'blur' }
{ required: true, message: '请输入姓名,用户名长度在5-11位,支持英文和数字', trigger: 'blur' },
],
password: [
{ required: true, message: '请输入密码,用户名长度在6-18位,支持英文和数字和非空字符', trigger: 'blur'}
]
},
//用户角色配置
... ... @@ -432,7 +435,10 @@
this.getUsers();
}).catch(error => {
this.addLoading = false;
alert(error.message);
this.$message({
message: error.message,
type: 'error'
});
});
});
}
... ...
... ... @@ -433,6 +433,7 @@
:loading="listLoading"
v-model="shprcountyr"
filterable
allow-create
remote
placeholder="请选择" clearable>
<el-option
... ... @@ -511,6 +512,7 @@
:listLoading="listLoading"
v-model="cnscountyr"
filterable
allow-create
remote
placeholder="请选择" clearable>
<el-option
... ... @@ -651,7 +653,7 @@
import treeTable from '@/components/TreeTable'
import treeToArray from '@/utils/customEval'
import Pagination from '@/components/Pagination'
import util from '@/common/js/util'
import {getCountry, getByCountryCode, getByCountryCodeForName,getCustomCode,getAirportCode} from "@/api/country";
import {
getMt2201ListForParam,
... ... @@ -830,7 +832,7 @@
cargonm: undefined,
sairportid: undefined,
dest1city: undefined,
by1: undefined,
by1: '',
dest1: undefined,
by2: undefined,
dest2: undefined,
... ... @@ -1048,10 +1050,10 @@
},
by1: {
get: function () {
return this.preModel.awbinfo.by1
return util.checkNull(this.preModel.awbinfo.by1)?'':this.preModel.awbinfo.by1
},
set: function (val) {
this.preModel.awbinfo.by1 = val.toUpperCase().trim()
this.preModel.awbinfo.by1 = util.checkNull(val)?'':val.toUpperCase().trim()
}
},
dest1: {
... ...
... ... @@ -80,7 +80,7 @@
</el-table-column>
<el-table-column label="状态" width="100" align="center">
<template slot-scope="scope">
<span v-if="scope.row.status ==='01'">接受申报</span>
<span v-if="scope.row.status ==='01'">未发送</span>
<span v-if="scope.row.status ==='02'">待人工审核</span>
<span v-if="scope.row.status ==='03'">退单</span>
<span v-if="scope.row.status ==='05'">舱单报退单</span>
... ... @@ -349,6 +349,7 @@
import {getResponseForParam} from '@/api/responseDetail'
import {validAwb, validAlphabets, validAlphabetsAndNum, validAlphabetsAndSpanceKey,validatorNum} from "@/utils/validate"
import {getCustomCode,getAirportCode} from "@/api/country";
import util from "@/common/js/util.js";
export default {
name: "ExitTidy",
... ... @@ -398,7 +399,7 @@
airportCode:[],
tidyQuery: {
pageSize: 1,
limitSize: 100,
limitSize: 30,
awba: undefined,
carrier: undefined,
flightno: undefined,
... ... @@ -406,7 +407,7 @@
originstation: undefined,
destinationstation: undefined,
customcode: undefined,
messageType: undefined
rcfdep: "5202"
},
tidyRoles: {
awba: [{required: true, trigger: 'blur', validator: validatorAwb}],
... ... @@ -605,7 +606,7 @@
flightDate: row.flightdate,
awba: row.awba,
awbh: row.awbh,
messageType: 'MT5202'
rcfdep: 'MT5202'
}
this.dialogTableVisible = true
getResponseForParam(resQuery).then(res => {
... ... @@ -622,7 +623,6 @@
confirmButtonText: '发送',
cancelButtonText: '取消'
}).then(() => {
delete row.messageType
console.log(row)
sendCreateMt5202(row).then(res => {
if (res.data.count > 0) {
... ... @@ -872,13 +872,13 @@
// 新增理货弹框
handleAddTidy() {
const query = {
'messageType': 'MT5202'
'rcfdep': 'MT5202'
}
this.$router.push({name: '出港航班信息', params: {scopeRow: query}})
},
// 返回
handelBackStep() {
this.tidyQuery.messageType = 'MT5202'
this.tidyQuery.rcfdep = 'MT5202'
this.$router.push({name: '出港航班信息', params: {scopeRow: this.tidyQuery}})
}
}
... ...
... ... @@ -466,6 +466,7 @@
import {Message} from "element-ui";
import {validAwb, validFlightNo} from '@/utils/validate'
import util from '@/common/js/util'
export default {
name: 'OrgManifest',
... ... @@ -823,7 +824,7 @@
},
by1: {
get: function () {
return this.temp.awbinfo.by1
return util.checkNull(this.temp.awbinfo.by1)?'':this.temp.awbinfo.by1
},
set: function (val) {
this.temp.awbinfo.by1 = val.toUpperCase().trim()
... ...
... ... @@ -142,6 +142,7 @@
<el-button
size="mini"
type="primary"
:disabled="sendBtsStatus(scope.row.status)"
@click="handleSend(scope.$index, scope.row)">发送舱单报
</el-button>
<el-button
... ... @@ -827,6 +828,18 @@
:row.status=='21'?'可自动发送':row.status=='22'?'未发送':row.status=='23'?'已发送新增报'
:row.status=='24'?'已发送删除报':row.status=='25'?'已发送修改报':'';
},
//按钮禁用状态判定
sendBtsStatus:function(status){
switch (status) {
case '01':
return true;
case '22':
return false;
case '23':
return true;
}
},
/*多选框功能*/
handleSelectionChange(val) {
this.multipleSelection = val;
... ...