Elements-SY

Merge branch test into uat

Showing 64 changed files with 1457 additions and 227 deletions
...@@ -39,8 +39,10 @@ ...@@ -39,8 +39,10 @@
39 "axios": "0.21.1", 39 "axios": "0.21.1",
40 "core-js": "3.8.3", 40 "core-js": "3.8.3",
41 "element-ui": "2.15.3", 41 "element-ui": "2.15.3",
42 + "sortablejs": "^1.15.0",
42 "vue": "2.6.14", 43 "vue": "2.6.14",
43 "vue-router": "3.5.2", 44 "vue-router": "3.5.2",
45 + "vuedraggable": "^2.24.3",
44 "vuex": "3.6.2" 46 "vuex": "3.6.2"
45 }, 47 },
46 "devDependencies": { 48 "devDependencies": {
......
...@@ -22,6 +22,7 @@ export function importFlightDestination(file, date) { ...@@ -22,6 +22,7 @@ export function importFlightDestination(file, date) {
22 return request({ 22 return request({
23 method: 'post', 23 method: 'post',
24 url: settings.baseURL + '/flightDestination/importFlightDestination', 24 url: settings.baseURL + '/flightDestination/importFlightDestination',
25 + // headers: { 'Authorization': 'Bearer ' + getToken() },
25 data: formData 26 data: formData
26 }) 27 })
27 } 28 }
...@@ -38,6 +39,7 @@ export function importUrsaDestination(file, date) { ...@@ -38,6 +39,7 @@ export function importUrsaDestination(file, date) {
38 return request({ 39 return request({
39 method: 'post', 40 method: 'post',
40 url: settings.baseURL + '/ursaDestination/importUrsaDestination', 41 url: settings.baseURL + '/ursaDestination/importUrsaDestination',
42 + // headers: { 'Authorization': 'Bearer ' + getToken() },
41 data: formData 43 data: formData
42 }) 44 })
43 } 45 }
...@@ -81,7 +83,7 @@ export function searchUrsaDestination(data) { ...@@ -81,7 +83,7 @@ export function searchUrsaDestination(data) {
81 * @param waybillNo 运单号 83 * @param waybillNo 运单号
82 * @param ursa ursa 84 * @param ursa ursa
83 * @param typeName 申报类别 85 * @param typeName 申报类别
84 - * @param siteName 站点 86 + * @param siteName 始发站
85 * @param regionArray 区域 list 87 * @param regionArray 区域 list
86 * @param areaArray 地区 list 88 * @param areaArray 地区 list
87 * @param serviceTypeArray 服务代码 list 89 * @param serviceTypeArray 服务代码 list
......
...@@ -143,9 +143,15 @@ export function delFlight(data) { ...@@ -143,9 +143,15 @@ export function delFlight(data) {
143 143
144 //查询航线 144 //查询航线
145 /** 145 /**
146 +<<<<<<< HEAD
146 * @param fltNo 航班号 147 * @param fltNo 航班号
147 * @param page 页数 148 * @param page 页数
148 * @param size 页长 149 * @param size 页长
150 +=======
151 + * @param fltNo 航班号
152 + * @param page 页数
153 + * @param size 页长
154 +>>>>>>> test
149 */ 155 */
150 export function queryRoute(data) { 156 export function queryRoute(data) {
151 return request({ 157 return request({
...@@ -204,3 +210,15 @@ export function checkFlightRoute(data) { ...@@ -204,3 +210,15 @@ export function checkFlightRoute(data) {
204 data: data 210 data: data
205 }) 211 })
206 } 212 }
213 +
214 +//更新航线
215 +/**
216 + * @param id *
217 + */
218 +export function updateRoute(id) {
219 + return request({
220 + url: `/dictionary/updateRoute/${id}`,
221 + method: "post",
222 + data: {},
223 + });
224 +}
......
...@@ -69,7 +69,7 @@ let tableHeaders = { ...@@ -69,7 +69,7 @@ let tableHeaders = {
69 status: 1 69 status: 1
70 }, 70 },
71 { 71 {
72 - columnChineseName: "站点", 72 + columnChineseName: "始发站",
73 columnName: "siteName", 73 columnName: "siteName",
74 columnWidth: "80", 74 columnWidth: "80",
75 ext1: "sorTable", 75 ext1: "sorTable",
...@@ -671,7 +671,7 @@ let tableHeaders = { ...@@ -671,7 +671,7 @@ let tableHeaders = {
671 status: 1 671 status: 1
672 }, 672 },
673 { 673 {
674 - columnChineseName: "站点", 674 + columnChineseName: "始发站",
675 columnName: "siteName", 675 columnName: "siteName",
676 columnWidth: "80", 676 columnWidth: "80",
677 ext1: "sorTable", 677 ext1: "sorTable",
...@@ -1764,7 +1764,7 @@ let tableHeaders = { ...@@ -1764,7 +1764,7 @@ let tableHeaders = {
1764 status: 1 1764 status: 1
1765 }, 1765 },
1766 { 1766 {
1767 - columnChineseName: "站点", 1767 + columnChineseName: "始发站",
1768 columnName: "siteName", 1768 columnName: "siteName",
1769 columnWidth: "", 1769 columnWidth: "",
1770 ext1: "", 1770 ext1: "",
...@@ -1806,7 +1806,7 @@ let tableHeaders = { ...@@ -1806,7 +1806,7 @@ let tableHeaders = {
1806 status: 1 1806 status: 1
1807 }, 1807 },
1808 { 1808 {
1809 - columnChineseName: "申报类", 1809 + columnChineseName: "申报类",
1810 columnName: "typeName", 1810 columnName: "typeName",
1811 columnWidth: "", 1811 columnWidth: "",
1812 ext1: "", 1812 ext1: "",
...@@ -1955,7 +1955,7 @@ let tableHeaders = { ...@@ -1955,7 +1955,7 @@ let tableHeaders = {
1955 status: 1 1955 status: 1
1956 }, 1956 },
1957 { 1957 {
1958 - columnChineseName: "站点", 1958 + columnChineseName: "始发站",
1959 columnName: "siteName", 1959 columnName: "siteName",
1960 columnWidth: "", 1960 columnWidth: "",
1961 ext1: "", 1961 ext1: "",
......
1 <template> 1 <template>
2 <div class="top-right-btn"> 2 <div class="top-right-btn">
3 <el-row> 3 <el-row>
4 - <el-tooltip class="item" effect="dark" :content="showSearch ? '隐藏搜索' : '显示搜索'" placement="top"> 4 + <el-tooltip
5 - <el-button :size="size" circle icon="el-icon-search" @click="toggleSearch()" /> 5 + class="item"
6 + effect="dark"
7 + :content="showSearch ? '隐藏搜索' : '显示搜索'"
8 + placement="top"
9 + >
10 + <el-button
11 + :size="size"
12 + circle
13 + icon="el-icon-search"
14 + @click="toggleSearch()"
15 + />
6 </el-tooltip> 16 </el-tooltip>
7 <el-tooltip class="item" effect="dark" content="刷新" placement="top"> 17 <el-tooltip class="item" effect="dark" content="刷新" placement="top">
8 - <el-button :size="size" circle icon="el-icon-refresh" @click="refresh()" /> 18 + <el-button
19 + :size="size"
20 + circle
21 + icon="el-icon-refresh"
22 + @click="refresh()"
23 + />
9 </el-tooltip> 24 </el-tooltip>
10 - <el-tooltip class="item" effect="dark" content="显隐列" placement="top" v-if="columns"> 25 + <el-tooltip
11 - <el-button :size="size" circle icon="el-icon-menu" @click="showColumn()" /> 26 + class="item"
27 + effect="dark"
28 + content="显隐列"
29 + placement="top"
30 + v-if="columns"
31 + >
32 + <el-button
33 + :size="size"
34 + circle
35 + icon="el-icon-menu"
36 + @click="showColumn()"
37 + />
12 </el-tooltip> 38 </el-tooltip>
13 </el-row> 39 </el-row>
14 <el-dialog :title="title" :visible.sync="open" append-to-body :close-on-press-escape="false"> 40 <el-dialog :title="title" :visible.sync="open" append-to-body :close-on-press-escape="false">
......
This diff is collapsed. Click to expand it.
1 +<template>
2 + <el-input
3 + v-bind="$attrs"
4 + clearable
5 + @input="handleInput"
6 + @focus="handleFocus"
7 + @blur="handleBlur"
8 + @change="handleChange"
9 + class="yl-input"
10 + ></el-input>
11 +</template>
12 +
13 +<script>
14 +export default {
15 + props: {
16 + rules: {
17 + type: Array,
18 + default: () => [],
19 + },
20 + },
21 + data() {
22 + return {};
23 + },
24 + computed: {},
25 + created() {},
26 + mounted() {},
27 + methods: {
28 + handleInput(event) {
29 + // v-bind="$attrs" v-on="$listeners"
30 + this.$emit("input", event);
31 + },
32 + handleFocus(event) {
33 + this.$emit("focus", event);
34 + },
35 + handleBlur(event) {
36 + this.$emit("blur", event);
37 + },
38 + handleChange(event) {
39 + this.$emit("change", event);
40 + },
41 + },
42 +};
43 +</script>
44 +<style lang='scss'>
45 +
46 +</style>
1 +<script>
2 +/**
3 + * 动态渲染 el-table-column
4 + */
5 +export default {
6 + name: 'column',
7 + props: {
8 + attrs: {
9 + type: Object,
10 + default: () => ({}),
11 + required: true
12 + }
13 + },
14 + render: function(h) {
15 + let attrs = this.attrs;
16 + let scopedSlots = {};
17 + if (attrs.render) {
18 + scopedSlots.default = scope => attrs.render(h, scope);
19 + }
20 + return h('el-table-column', {
21 + attrs,
22 + scopedSlots
23 + });
24 + }
25 +};
26 +</script>
1 + <template>
2 + <div class="table-container">
3 + <el-row v-if="attrs.btnCofig.isBtn" style="margin-bottom: 15px">
4 + <el-col>
5 + <el-button
6 + v-for="item in attrs.btnCofig.btnGroup"
7 + :key="item.icon"
8 + :type="item.type"
9 + :icon="item.icon"
10 + :round="item.round"
11 + :size="item.size"
12 + :loading="item.loading"
13 + @click="handleClick(item)"
14 + >{{ item.btnName }}</el-button
15 + >
16 + </el-col>
17 + </el-row>
18 + <el-table
19 + :max-height="attrs.maxHeight"
20 + :empty-text="emptyText"
21 + v-bind="attrs"
22 + v-loading="loadingTable"
23 + :data="tableData"
24 + @selection-change="selectionChange"
25 + ref="tableRef"
26 + row-key="id"
27 + :header-cell-class-name="headerCellClassName"
28 + >
29 + <template v-if="columns.length">
30 + <template v-for="(item, index) in columns">
31 + <column v-if="!item.hidden" :key="index" :attrs="item"></column>
32 + </template>
33 + </template>
34 + <slot name="column" v-else></slot>
35 + </el-table>
36 + <!-- 分页 -->
37 + <div
38 + v-if="pageConfig.isPagination"
39 + class="pagination-container"
40 + :style="{ textAlign: pageConfig.position || 'right' }"
41 + >
42 + <el-pagination
43 + background
44 + :hide-on-single-page="false"
45 + :current-page="pageConfig.pageData.page"
46 + :page-sizes="[10, 15, 20, 25, 30, 35, 40]"
47 + :page-size="pageConfig.pageData.size"
48 + layout="total,prev, pager, next, jumper, ->, sizes"
49 + :total="pageConfig.total"
50 + @size-change="handleSizeChange"
51 + @current-change="handleCurrentChange"
52 + >
53 + </el-pagination>
54 + </div>
55 + </div>
56 +</template>
57 +
58 +<script>
59 +import Sortable from "sortablejs";
60 +import { objectMerge, debounce } from "@/utils";
61 +import column from "./column";
62 +export default {
63 + props: {
64 + attrs: {
65 + type: Object,
66 + default: {
67 + border: true,
68 + isDragSort: false,
69 + btnCofig: {
70 + isBtn: true,
71 + btnGroup: [
72 + {
73 + type: "primary", // text、primary、danger
74 + icon: "el-icon-search", // el-icon-edit 、el-icon-delete、el-icon-plus、el-icon-download、el-icon-upload el-icon--right
75 + btnName: "搜索",
76 + size: "mini", // medium / small / mini
77 + round: false,
78 + loading: false,
79 + event: "searchBtn",
80 + },
81 + ],
82 + },
83 + },
84 + },
85 + emptyText: {
86 + type: String,
87 + default: "暂无数据",
88 + },
89 + loadingTable: {
90 + type: Boolean,
91 + default: false,
92 + },
93 + columns: {
94 + type: Array,
95 + default: () => [],
96 + },
97 + tableData: {
98 + type: Array,
99 + default: () => [],
100 + },
101 + pageConfig: {
102 + type: Object,
103 + default: {
104 + isPagination: true,
105 + },
106 + required: true,
107 + },
108 + },
109 + components: {
110 + column,
111 + },
112 + data() {
113 + return {
114 + dropCol: objectMerge({}, this.columns),
115 + trHeight: 4,
116 + };
117 + },
118 + computed: {
119 + _attrs() {
120 + //默认table 参数
121 + const defaultParams = {};
122 + return Object.assign(defaultParams, this.attrs);
123 + },
124 + isHasAttr() {},
125 + },
126 + created() {
127 + if (this.attrs.isDragSort) {
128 + // 有没有复选框、有没有render
129 + // this.columns
130 + }
131 + },
132 + mounted() {
133 + //阻止火狐拖拽新建新页面
134 + document.body.addEventListener(
135 + "drop",
136 + (event) => {
137 + event.preventDefault();
138 + event.stopPropagation();
139 + },
140 + false
141 + );
142 + if (this.tableData.length) {
143 + this.getTrCurrentHeight();
144 + window.addEventListener("resize", this.getTrCurrentHeight);
145 + // 拖拽行更新排序
146 + // this.rowDrop();
147 + // 拖拽列更新排序
148 + this.columnDrop();
149 + }
150 + },
151 + destroyed() {
152 + if (this.tableData.length) {
153 + window.removeEventListener("resize", this.getTrCurrentHeight);
154 + }
155 + },
156 +
157 + methods: {
158 + getTrCurrentHeight: debounce(function () {
159 + this.$nextTick(() => {
160 + const trEl =
161 + this.$refs.tableRef.$refs.bodyWrapper.children[0].children[1]
162 + .children[0].clientHeight;
163 + this.trHeight = trEl;
164 + });
165 + }, 800),
166 +
167 + // 给表头列添加className
168 + headerCellClassName({ row, column, rowIndex, columnIndex }) {
169 + if (columnIndex !== 0) {
170 + return "el-table_1_column";
171 + }
172 + },
173 + useTableFunc(FuncName, ...params) {
174 + if (!this.$refs["el-table"]) {
175 + return console.warn("访问不到el-table");
176 + }
177 + if (!FuncName) {
178 + return console.error("请传入tabel方法名字");
179 + }
180 + this.$refs["el-table"][FuncName](params[0]);
181 + },
182 + // table复选框事件
183 + selectionChange(e) {
184 + console.log(e);
185 + this.$emit("selectionEvent", e);
186 + },
187 + // 条数变化
188 + handleSizeChange(e) {
189 + this.$emit("sizeChange", e);
190 + },
191 + // 页码变化
192 + handleCurrentChange(e) {
193 + this.$emit("currentChange", e);
194 + },
195 + // btn点击事件注册
196 + handleClick(item) {
197 + this.$emit(item.event, item);
198 + },
199 + // 拖拽行更新排序
200 + rowDrop() {
201 + const wrapperTr = document.querySelector(".el-table__header-wrapper tr");
202 + // console.log("wrapperTr:", wrapperTr);
203 + this.sortable = Sortable.create(wrapperTr, {
204 + sort: this.attrs.isDragSort,
205 + animation: 100,
206 + delay: 0,
207 + handle: ".move", // 只有带move类名的元素才能拖动,多选框禁止拖动
208 + onEnd: (evt) => {
209 + // 因为手动加了一个多选框, 不在表头循环数组内, 所以这里减1
210 + let oldIndx = evt.oldIndex - 1;
211 + let newIndx = evt.newIndex - 1;
212 + const oldItem = this.dropCol[oldIndx];
213 + // 真正改变列数据--变化列头,就能实现列拖动 列数据按列头索引取值 {{ scope.row[dropCol[index].prop] }}
214 + this.dropCol.splice(oldIndx, 1); // 删除旧一行 删除为1
215 + this.dropCol.splice(newIndx, 0, oldItem); // 插入新一行 插入为0
216 + },
217 + });
218 + },
219 + // 拖拽列更新排序
220 + columnDrop() {
221 + const tbody = document.querySelector(".el-table__body-wrapper tbody");
222 + const _this = this;
223 + Sortable.create(tbody, {
224 + sort: this.attrs.isDragSort,
225 + animation: 100,
226 + delay: 0,
227 + onEnd({ newIndex, oldIndex }) {
228 + // console.log("onEnd:", newIndex, oldIndex);
229 + const currRow = _this.tableData.splice(oldIndex, 1)[0];
230 + _this.tableData.splice(newIndex, 0, currRow);
231 + },
232 + });
233 + },
234 + },
235 + watch: {
236 + data() {
237 + this.$nextTick(() => {
238 + this.useTableFunc("doLayout");
239 + });
240 + },
241 + },
242 +};
243 +</script>
244 +<style lang="scss">
245 +
246 +</style>
1 +import Vue from 'vue'
2 +import VueI18n from 'vue-i18n'
3 +
4 +import ElementLocale from 'element-ui/lib/locale'
5 +import enLocale from 'element-ui/lib/locale/lang/en'
6 +import zhLocale from 'element-ui/lib/locale/lang/zh-CN'
7 +
8 +import langZh from "@/assets/languages/zh.js"
9 +import langEN from "@/assets/languages/en.js"
10 +
11 +Vue.use(VueI18n)
12 +
13 +const i18n = new VueI18n({
14 + locale: 'zh',//默认语言
15 + messages: {
16 + 'zh': {...langZh,...zhLocale},
17 + 'en': {...langEN,...enLocale}
18 + }
19 +})
20 +ElementLocale.i18n((key, value) => i18n.t(key, value))
21 +
22 +export default i18n
...@@ -16,7 +16,7 @@ export default { ...@@ -16,7 +16,7 @@ export default {
16 return this.$store.state.tagsView.cachedViews 16 return this.$store.state.tagsView.cachedViews
17 }, 17 },
18 key() { 18 key() {
19 - return this.$route.path 19 + return this.$route.fullPath
20 } 20 }
21 } 21 }
22 } 22 }
......
...@@ -4,7 +4,6 @@ ...@@ -4,7 +4,6 @@
4 @toggleClick="toggleSideBar" /> 4 @toggleClick="toggleSideBar" />
5 <breadcrumb id="breadcrumb-container" class="breadcrumb-container" v-if="!topNav" /> 5 <breadcrumb id="breadcrumb-container" class="breadcrumb-container" v-if="!topNav" />
6 <top-nav id="topmenu-container" class="topmenu-container" v-if="topNav" /> 6 <top-nav id="topmenu-container" class="topmenu-container" v-if="topNav" />
7 -
8 <div class="right-menu"> 7 <div class="right-menu">
9 <template v-if="device !== 'mobile'"> </template> 8 <template v-if="device !== 'mobile'"> </template>
10 <el-select v-model="portName" size="mini" style="width: 120px; top: -17px; right: 7px" placeholder="选择口岸"> 9 <el-select v-model="portName" size="mini" style="width: 120px; top: -17px; right: 7px" placeholder="选择口岸">
...@@ -22,25 +21,19 @@ ...@@ -22,25 +21,19 @@
22 </el-dropdown-item> 21 </el-dropdown-item>
23 </el-dropdown-menu> 22 </el-dropdown-menu>
24 </el-dropdown> 23 </el-dropdown>
25 - <!-- <el-select 24 + <el-select v-model="locale" size="mini" @change="local" style="width: 75px; top: -17px; right: 7px">
26 - v-model="locale"
27 - size="mini"
28 - @change="local"
29 - style="width: 75px; top: -17px; right: 7px"
30 - >
31 <el-option label="中文" value="zh"> </el-option> 25 <el-option label="中文" value="zh"> </el-option>
32 <el-option label="英文" value="en"> </el-option> 26 <el-option label="英文" value="en"> </el-option>
33 - </el-select> --> 27 + </el-select>
34 </div> 28 </div>
35 </div> 29 </div>
36 </template> 30 </template>
37 31
38 <script> 32 <script>
39 -import { mapGetters } from "vuex" 33 +import { mapGetters } from "vuex";
40 -import Breadcrumb from "@/components/Breadcrumb" 34 +import Breadcrumb from "@/components/Breadcrumb";
41 -import TopNav from "@/components/TopNav" 35 +import TopNav from "@/components/TopNav";
42 -import Hamburger from "@/components/Hamburger" 36 +import Hamburger from "@/components/Hamburger";
43 -import settings from "@/settings"
44 37
45 export default { 38 export default {
46 components: { 39 components: {
...@@ -88,7 +81,8 @@ export default { ...@@ -88,7 +81,8 @@ export default {
88 .then((res) => { 81 .then((res) => {
89 if (res.code === 200) { 82 if (res.code === 200) {
90 this.$store.dispatch('tagsView/delAllCachedViews') 83 this.$store.dispatch('tagsView/delAllCachedViews')
91 - // location.reload(); 84 + this.$store.dispatch('tagsView/delAllVisitedViews')
85 + // location.reload(false);
92 if (this.$route.path != '/index') { 86 if (this.$route.path != '/index') {
93 this.$router.push('/index') 87 this.$router.push('/index')
94 } 88 }
...@@ -120,17 +114,19 @@ export default { ...@@ -120,17 +114,19 @@ export default {
120 }, 114 },
121 async logout() { 115 async logout() {
122 this.$confirm("确定注销并退出系统吗?", "提示", { 116 this.$confirm("确定注销并退出系统吗?", "提示", {
117 + closeOnClickModal: false,
123 confirmButtonText: "确定", 118 confirmButtonText: "确定",
124 cancelButtonText: "取消", 119 cancelButtonText: "取消",
125 type: "warning", 120 type: "warning",
126 }).then(() => { 121 }).then(() => {
127 this.$store.dispatch("LogOut").then(() => { 122 this.$store.dispatch("LogOut").then(() => {
128 - window.location.href = settings.logoutURL;//wsso系统跳转 123 + // this.$router.push('/')
124 + window.location.href = this.settings.logoutURL;//wsso系统跳转
129 }); 125 });
130 }); 126 });
131 }, 127 },
132 local(val) { 128 local(val) {
133 - // this.$i18n.locale = val; //此处val为 zh 或者 en 129 + this.$i18n.locale = val; //此处val为 zh 或者 en
134 }, 130 },
135 }, 131 },
136 }; 132 };
...@@ -233,4 +229,15 @@ export default { ...@@ -233,4 +229,15 @@ export default {
233 } 229 }
234 } 230 }
235 } 231 }
232 +
233 +.verTip {
234 + width: auto;
235 + height: 50px;
236 + line-height: 50px;
237 + font-size: 14px;
238 + font-weight: 700;
239 + position: absolute;
240 + left: 50%;
241 + color: #1890ff;
242 +}
236 </style> 243 </style>
......
...@@ -82,13 +82,15 @@ export default { ...@@ -82,13 +82,15 @@ export default {
82 position: relative; 82 position: relative;
83 overflow: hidden; 83 overflow: hidden;
84 width: 100%; 84 width: 100%;
85 +
85 ::v-deep { 86 ::v-deep {
86 .el-scrollbar__bar { 87 .el-scrollbar__bar {
87 bottom: 0px; 88 bottom: 0px;
88 } 89 }
90 +
89 .el-scrollbar__wrap { 91 .el-scrollbar__wrap {
90 // height: 49px; 92 // height: 49px;
91 - margin-top:4px; 93 + margin-top: 4px;
92 } 94 }
93 } 95 }
94 } 96 }
......
...@@ -26,7 +26,7 @@ import Drag from "@/components/Drag" ...@@ -26,7 +26,7 @@ import Drag from "@/components/Drag"
26 import tableHeaders from '@/assets/languages/tableHeaders' 26 import tableHeaders from '@/assets/languages/tableHeaders'
27 import dictLabels from "@/assets/languages/dictLabels.js" 27 import dictLabels from "@/assets/languages/dictLabels.js"
28 import settings from './settings.js' 28 import settings from './settings.js'
29 - 29 +import * as filters from "./utils/filters.js";
30 // 全局方法挂载 30 // 全局方法挂载
31 Vue.prototype.parseTime = parseTime 31 Vue.prototype.parseTime = parseTime
32 Vue.prototype.resetForm = resetForm 32 Vue.prototype.resetForm = resetForm
...@@ -76,6 +76,10 @@ Vue.directive('focus', { ...@@ -76,6 +76,10 @@ Vue.directive('focus', {
76 } 76 }
77 }); 77 });
78 78
79 +// 全局注册过滤器
80 +Object.keys(filters).forEach((key) => {
81 + Vue.filter(key, filters[key]);
82 +});
79 83
80 /** 84 /**
81 * If you don't want to use mock-server 85 * If you don't want to use mock-server
......
1 import router from './router' 1 import router from './router'
2 import store from './store' 2 import store from './store'
3 import { Message } from 'element-ui' 3 import { Message } from 'element-ui'
4 -import { getToken, setToken, removeToken } from '@/utils/auth' 4 +import { getToken, removeToken } from '@/utils/auth'
5 -import settings from "@/settings"
6 5
7 6
8 const whiteList = ['/login', '/auth-redirect', '/bind', '/register'] 7 const whiteList = ['/login', '/auth-redirect', '/bind', '/register']
9 -
10 router.beforeEach((to, from, next) => { 8 router.beforeEach((to, from, next) => {
11 if (getToken()) { 9 if (getToken()) {
12 /* has token*/ 10 /* has token*/
...@@ -16,19 +14,16 @@ router.beforeEach((to, from, next) => { ...@@ -16,19 +14,16 @@ router.beforeEach((to, from, next) => {
16 if (store.getters.roles.length === 0) { 14 if (store.getters.roles.length === 0) {
17 // 判断当前用户是否已拉取完user_info信息 15 // 判断当前用户是否已拉取完user_info信息
18 store.dispatch('GetInfo').then(() => { 16 store.dispatch('GetInfo').then(() => {
17 + //获取用户表头
19 store.dispatch('GetTableHeaders').then(() => { 18 store.dispatch('GetTableHeaders').then(() => {
20 - store.dispatch('GenerateRoutes').then(accessRoutes => {
21 // 根据roles权限生成可访问的路由表 19 // 根据roles权限生成可访问的路由表
20 + store.dispatch('GenerateRoutes').then(accessRoutes => {
22 router.addRoutes(accessRoutes) // 动态添加可访问路由表 21 router.addRoutes(accessRoutes) // 动态添加可访问路由表
23 next({ ...to, replace: true }) // hack方法 确保addRoutes已完成 22 next({ ...to, replace: true }) // hack方法 确保addRoutes已完成
24 }) 23 })
25 }) 24 })
26 }).catch(err => { 25 }).catch(err => {
27 - Message.error(err) 26 +
28 - // store.dispatch('LogOut').then(() => {
29 - // // next({ path: '/' })
30 - // window.location.href = settings.loginURL;//wsso系统跳转
31 - // })
32 }) 27 })
33 } else { 28 } else {
34 next() 29 next()
...@@ -43,12 +38,7 @@ router.beforeEach((to, from, next) => { ...@@ -43,12 +38,7 @@ router.beforeEach((to, from, next) => {
43 setToken(token) 38 setToken(token)
44 next({ path: '/' }) 39 next({ path: '/' })
45 } else { 40 } else {
46 - if (whiteList.indexOf(to.path) !== -1) { 41 + next(`/login?redirect=${to.fullPath}`) // 否则全部重定向到登录页
47 - // 在免登录白名单,直接进入
48 - next()
49 - } else {
50 - window.location.href = settings.loginURL;//wsso系统跳转
51 - }
52 } 42 }
53 } 43 }
54 }) 44 })
......
...@@ -29,76 +29,97 @@ import ParentView from '@/components/ParentView'; ...@@ -29,76 +29,97 @@ import ParentView from '@/components/ParentView';
29 // 公共路由 29 // 公共路由
30 export const constantRoutes = [ 30 export const constantRoutes = [
31 { 31 {
32 - path: '/redirect', 32 + path: "/redirect",
33 component: Layout, 33 component: Layout,
34 hidden: true, 34 hidden: true,
35 children: [ 35 children: [
36 { 36 {
37 - path: '/redirect/:path(.*)', 37 + path: "/redirect/:path(.*)",
38 - component: (resolve) => require(['@/views/redirect'], resolve) 38 + component: (resolve) => require(["@/views/redirect"], resolve),
39 - } 39 + },
40 - ] 40 + ],
41 }, 41 },
42 - // {
43 - // path: '/login',
44 - // component: (resolve) => require(['@/views/login'], resolve),
45 - // hidden: true
46 - // },
47 { 42 {
48 - path: '/404', 43 + path: "/login",
49 - component: (resolve) => require(['@/views/error/404'], resolve), 44 + component: (resolve) => require(["@/views/login"], resolve),
50 - hidden: true 45 + hidden: true,
51 }, 46 },
52 { 47 {
53 - path: '/401', 48 + path: "/404",
54 - component: (resolve) => require(['@/views/error/401'], resolve), 49 + component: (resolve) => require(["@/views/error/404"], resolve),
55 - hidden: true 50 + hidden: true,
56 }, 51 },
57 { 52 {
58 - path: '', 53 + path: "/401",
54 + component: (resolve) => require(["@/views/error/401"], resolve),
55 + hidden: true,
56 + },
57 + {
58 + path: "",
59 component: Layout, 59 component: Layout,
60 - redirect: 'index', 60 + redirect: "index",
61 children: [ 61 children: [
62 { 62 {
63 - path: 'index', 63 + path: "index",
64 - component: (resolve) => require(['@/views/index'], resolve), 64 + component: (resolve) => require(["@/views/index"], resolve),
65 - name: 'Index', 65 + name: "Index",
66 - meta: { title: '首页', icon: 'home', noCache: true, affix: true } 66 + meta: { title: "首页", icon: "home", noCache: true, affix: true },
67 }, 67 },
68 - ] 68 + ],
69 }, 69 },
70 { 70 {
71 - path: '', 71 + path: "",
72 component: Layout, 72 component: Layout,
73 hidden: true, 73 hidden: true,
74 children: [ 74 children: [
75 { 75 {
76 - path: '/info/:handle/id=:id;routeStatus=:routeStatus;fltNo=:fltNo;route=:route;fltDate=:fltDate;status=:status', 76 + path: "/et86",
77 - component: (resolve) => require(['@/views/allocationConfig/flightAllocConfig/info'], resolve), 77 + component: (resolve) =>
78 - name: 'FlightAllocConfigInfo', 78 + require(["@/views/allocationConfig/et86"], resolve),
79 - meta: { title: '航班配舱', icon: 'user' } 79 + name: "et86",
80 + meta: { title: "ET86", icon: "user" },
81 + children: [],
82 + },
83 + {
84 + path: "/et86/:edit",
85 + component: (resolve) =>
86 + require(["@/views/allocationConfig/et86/edit"], resolve),
87 + name: "edit",
88 + meta: { title: "编辑", icon: "user" },
89 + },
90 + {
91 + path: "/info/:handle/id=:id;routeStatus=:routeStatus;fltNo=:fltNo;route=:route;fltDate=:fltDate;status=:status",
92 + component: (resolve) =>
93 + require(["@/views/allocationConfig/flightAllocConfig/info"], resolve),
94 + name: "FlightAllocConfigInfo",
95 + meta: { title: "航班配舱", icon: "user" },
80 }, 96 },
81 { 97 {
82 - path: '/weatherTable/:awbNbr', 98 + path: "/weatherTable/:awbNbr",
83 - component: (resolve) => require(['@/views/systemLog/dmLog/weatherTable'], resolve), 99 + component: (resolve) =>
84 - name: 'weatherTable', 100 + require(["@/views/systemLog/dmLog/weatherTable"], resolve),
85 - meta: { title: '流水表', icon: 'user' } 101 + name: "weatherTable",
102 + meta: { title: "流水表", icon: "user" },
86 }, 103 },
87 { 104 {
88 - path: '/upDateResult', 105 + path: "/upDateResult",
89 - component: (resolve) => require(['@/views/preMdeConfig/upDateResult'], resolve), 106 + component: (resolve) =>
90 - name: 'UpDateResult', 107 + require(["@/views/preMdeConfig/upDateResult"], resolve),
91 - meta: { title: '错误信息提示', icon: 'user' } 108 + name: "UpDateResult",
109 + meta: { title: "错误信息提示", icon: "user" },
92 }, 110 },
93 { 111 {
94 - path: '/goodsLog/type=:type', 112 + path: "/goodsLog/type=:type",
95 - component: (resolve) => require(['@/views/basicInformation/goodsStation/goodsUploadLog'], resolve), 113 + component: (resolve) =>
96 - name: 'GoodsUploadLog', 114 + require([
97 - meta: { title: '导入日志', icon: 'user' } 115 + "@/views/basicInformation/goodsStation/goodsUploadLog",
116 + ], resolve),
117 + name: "GoodsUploadLog",
118 + meta: { title: "导入日志", icon: "user" },
98 }, 119 },
99 - ] 120 + ],
100 }, 121 },
101 -] 122 +];
102 123
103 export default new Router({ 124 export default new Router({
104 mode: 'history', // 去掉url中的# 125 mode: 'history', // 去掉url中的#
......
1 -import { constantRoutes } from '@/router' 1 +import { constantRoutes } from "@/router";
2 -import { getRouters } from '@/api/menu' 2 +import { getRouters } from "@/api/menu";
3 -import Layout from '@/layout/index' 3 +import Layout from "@/layout/index";
4 -import ParentView from '@/components/ParentView'; 4 +import ParentView from "@/components/ParentView";
5 -import hasPermi from '../../directive/permission/hasPermi'; 5 +import hasPermi from "../../directive/permission/hasPermi";
6 const permission = { 6 const permission = {
7 state: { 7 state: {
8 routes: [], 8 routes: [],
...@@ -10,26 +10,35 @@ const permission = { ...@@ -10,26 +10,35 @@ const permission = {
10 defaultRoutes: [], 10 defaultRoutes: [],
11 topbarRouters: [], 11 topbarRouters: [],
12 sidebarRouters: [], 12 sidebarRouters: [],
13 - filghtAllData: {} 13 + filghtAllData: {},
14 }, 14 },
15 mutations: { 15 mutations: {
16 SET_ROUTES: (state, routes) => { 16 SET_ROUTES: (state, routes) => {
17 - state.addRoutes = routes 17 + state.addRoutes = routes;
18 - state.routes = constantRoutes.concat(routes) 18 + state.routes = constantRoutes.concat(routes);
19 }, 19 },
20 SET_DEFAULT_ROUTES: (state, routes) => { 20 SET_DEFAULT_ROUTES: (state, routes) => {
21 - state.defaultRoutes = constantRoutes.concat(routes) 21 + state.defaultRoutes = constantRoutes.concat(routes);
22 }, 22 },
23 SET_TOPBAR_ROUTES: (state, routes) => { 23 SET_TOPBAR_ROUTES: (state, routes) => {
24 // 顶部导航菜单默认添加统计报表栏指向首页 24 // 顶部导航菜单默认添加统计报表栏指向首页
25 - const index = [{ 25 + const index = [
26 - path: 'index', 26 + {
27 - meta: { title: '首页', icon: 'home' } 27 + path: "index",
28 - }] 28 + meta: { title: "首页", icon: "home" },
29 + },
30 + ];
29 state.topbarRouters = routes.concat(index); 31 state.topbarRouters = routes.concat(index);
30 }, 32 },
31 SET_SIDEBAR_ROUTERS: (state, routes) => { 33 SET_SIDEBAR_ROUTERS: (state, routes) => {
32 - state.sidebarRouters = routes 34 + state.sidebarRouters = routes;
35 + },
36 + SET_FILGHTALL: (state, data) => {
37 + let name = data.name;
38 + state.filghtAllData[name] = data.data;
39 + },
40 + REMOVE_FILGHTALL: (state, name) => {
41 + delete state.filghtAllData[name];
33 }, 42 },
34 SET_FILGHTALL: (state, data) => { 43 SET_FILGHTALL: (state, data) => {
35 let name = data.name; 44 let name = data.name;
...@@ -42,78 +51,99 @@ const permission = { ...@@ -42,78 +51,99 @@ const permission = {
42 actions: { 51 actions: {
43 // 生成路由 52 // 生成路由
44 GenerateRoutes({ commit }) { 53 GenerateRoutes({ commit }) {
45 - return new Promise(resolve => { 54 + return new Promise((resolve) => {
46 // 向后端请求路由数据 55 // 向后端请求路由数据
47 - getRouters().then(res => { 56 + getRouters().then((res) => {
57 + // const newUrl = {
58 + // id: 24,
59 + // name: "et86",
60 + // path: "/et86",
61 + // hidden: false,
62 + // component: "allocationConfig/et86",
63 + // meta: {
64 + // title: "ET86",
65 + // icon: "edit",
66 + // permissions: "allocation:rand:list",
67 + // noCache: false,
68 + // },
69 + // alwaysShow: false,
70 + // children: null,
71 + // };
72 + // res.data.map((item) => {
73 + // if (item.name == "AllocationConfig") {
74 + // item.children.push(newUrl);
75 + // }
76 + // });
48 res.data = hasPermi.routerPer(res.data); 77 res.data = hasPermi.routerPer(res.data);
49 - const sdata = JSON.parse(JSON.stringify(res.data)) 78 + const sdata = JSON.parse(JSON.stringify(res.data));
50 - const rdata = JSON.parse(JSON.stringify(res.data)) 79 + const rdata = JSON.parse(JSON.stringify(res.data));
51 - const sidebarRoutes = filterAsyncRouter(sdata) 80 + const sidebarRoutes = filterAsyncRouter(sdata);
52 - const rewriteRoutes = filterAsyncRouter(rdata, false, true) 81 + const rewriteRoutes = filterAsyncRouter(rdata, false, true);
53 - rewriteRoutes.push({ path: '*', redirect: '/404', hidden: true }) 82 + rewriteRoutes.push({ path: "*", redirect: "/404", hidden: true });
54 - commit('SET_ROUTES', rewriteRoutes) 83 + commit("SET_ROUTES", rewriteRoutes);
55 - commit('SET_SIDEBAR_ROUTERS', constantRoutes.concat(sidebarRoutes)) 84 + commit("SET_SIDEBAR_ROUTERS", constantRoutes.concat(sidebarRoutes));
56 - commit('SET_DEFAULT_ROUTES', sidebarRoutes) 85 + commit("SET_DEFAULT_ROUTES", sidebarRoutes);
57 - commit('SET_TOPBAR_ROUTES', sidebarRoutes) 86 + commit("SET_TOPBAR_ROUTES", sidebarRoutes);
58 - resolve(rewriteRoutes) 87 + resolve(rewriteRoutes);
59 - }) 88 + });
60 - }) 89 + });
61 - } 90 + },
62 - } 91 + },
63 -} 92 +};
64 93
65 // 遍历后台传来的路由字符串,转换为组件对象 94 // 遍历后台传来的路由字符串,转换为组件对象
66 function filterAsyncRouter(asyncRouterMap, lastRouter = false, type = false) { 95 function filterAsyncRouter(asyncRouterMap, lastRouter = false, type = false) {
67 - return asyncRouterMap.filter(route => { 96 + return asyncRouterMap.filter((route) => {
68 if (type && route.children) { 97 if (type && route.children) {
69 - route.children = filterChildren(route.children) 98 + route.children = filterChildren(route.children);
70 } 99 }
71 if (route.component) { 100 if (route.component) {
72 // Layout ParentView 组件特殊处理 101 // Layout ParentView 组件特殊处理
73 - if (route.component === 'Layout') { 102 + if (route.component === "Layout") {
74 - route.component = Layout 103 + route.component = Layout;
75 - } else if (route.component === 'ParentView') { 104 + } else if (route.component === "ParentView") {
76 - route.component = ParentView 105 + route.component = ParentView;
77 } else { 106 } else {
78 - route.component = loadView(route.component) 107 + route.component = loadView(route.component);
79 } 108 }
80 } 109 }
81 if (route.children != null && route.children && route.children.length) { 110 if (route.children != null && route.children && route.children.length) {
82 - route.children = filterAsyncRouter(route.children, route, type) 111 + route.children = filterAsyncRouter(route.children, route, type);
83 } else { 112 } else {
84 - delete route['children'] 113 + delete route["children"];
85 - delete route['redirect'] 114 + delete route["redirect"];
86 } 115 }
87 - return true 116 + return true;
88 - }) 117 + });
89 } 118 }
90 119
91 function filterChildren(childrenMap, lastRouter = false) { 120 function filterChildren(childrenMap, lastRouter = false) {
92 - var children = [] 121 + var children = [];
93 childrenMap.forEach((el, index) => { 122 childrenMap.forEach((el, index) => {
94 if (el.children && el.children.length) { 123 if (el.children && el.children.length) {
95 - if (el.component === 'ParentView') { 124 + if (el.component === "ParentView") {
96 - el.children.forEach(c => { 125 + el.children.forEach((c) => {
97 - c.path = el.path + '/' + c.path 126 + c.path = el.path + "/" + c.path;
98 if (c.children && c.children.length) { 127 if (c.children && c.children.length) {
99 - children = children.concat(filterChildren(c.children, c)) 128 + children = children.concat(filterChildren(c.children, c));
100 - return 129 + return;
101 } 130 }
102 - children.push(c) 131 + children.push(c);
103 - }) 132 + });
104 - return 133 + return;
105 } 134 }
106 } 135 }
107 if (lastRouter) { 136 if (lastRouter) {
108 - el.path = lastRouter.path + '/' + el.path 137 + el.path = lastRouter.path + "/" + el.path;
109 } 138 }
110 - children = children.concat(el) 139 + children = children.concat(el);
111 - }) 140 + });
112 - return children 141 + return children;
113 } 142 }
114 143
115 -export const loadView = (view) => { // 路由懒加载 144 +export const loadView = (view) => {
116 - return (resolve) => require([`@/views/${view}`], resolve) 145 + // 路由懒加载
117 -} 146 + return (resolve) => require([`@/views/${view}`], resolve);
147 +};
118 148
119 -export default permission 149 +export default permission;
......
...@@ -9,6 +9,7 @@ const user = { ...@@ -9,6 +9,7 @@ const user = {
9 state: { 9 state: {
10 token: getToken(), 10 token: getToken(),
11 name: '', 11 name: '',
12 + id: '',
12 avatar: '', 13 avatar: '',
13 activePortName: '', 14 activePortName: '',
14 portNames: [], 15 portNames: [],
...@@ -24,6 +25,9 @@ const user = { ...@@ -24,6 +25,9 @@ const user = {
24 SET_NAME: (state, name) => { 25 SET_NAME: (state, name) => {
25 state.name = name 26 state.name = name
26 }, 27 },
28 + SET_ID: (state, id) => {
29 + state.id = id
30 + },
27 SET_AVATAR: (state, avatar) => { 31 SET_AVATAR: (state, avatar) => {
28 state.avatar = avatar 32 state.avatar = avatar
29 }, 33 },
...@@ -89,9 +93,11 @@ const user = { ...@@ -89,9 +93,11 @@ const user = {
89 GetInfo({ commit, state }) { 93 GetInfo({ commit, state }) {
90 return new Promise((resolve, reject) => { 94 return new Promise((resolve, reject) => {
91 getInfo().then(res => { 95 getInfo().then(res => {
96 + if (res.code === 200) {
92 const user = res.data.user 97 const user = res.data.user
93 const avatar = user.avatar == "" ? require("@/assets/images/profile.jpg") : process.env.VUE_APP_BASE_API + user.avatar; 98 const avatar = user.avatar == "" ? require("@/assets/images/profile.jpg") : process.env.VUE_APP_BASE_API + user.avatar;
94 let ports = []; 99 let ports = [];
100 + commit('SET_ID', user.userId)
95 if (user.portName) { 101 if (user.portName) {
96 ports = user.portName.split(','); 102 ports = user.portName.split(',');
97 commit('SET_PORTNAMES', ports) 103 commit('SET_PORTNAMES', ports)
...@@ -101,9 +107,7 @@ const user = { ...@@ -101,9 +107,7 @@ const user = {
101 message: "未找到口岸信息!请确认后再登录", 107 message: "未找到口岸信息!请确认后再登录",
102 type: 'error' 108 type: 'error'
103 }) 109 })
104 - this.LogOut().then(() => { 110 + this.login()
105 - window.location.href = settings.loginURL;//wsso系统跳转
106 - })
107 } 111 }
108 if (res.data.roles && res.data.roles.length > 0) { // 验证返回的roles是否是一个非空数组 112 if (res.data.roles && res.data.roles.length > 0) { // 验证返回的roles是否是一个非空数组
109 commit('SET_ROLES', res.data.roles) 113 commit('SET_ROLES', res.data.roles)
...@@ -114,6 +118,7 @@ const user = { ...@@ -114,6 +118,7 @@ const user = {
114 commit('SET_NAME', user.userName) 118 commit('SET_NAME', user.userName)
115 commit('SET_AVATAR', avatar) 119 commit('SET_AVATAR', avatar)
116 resolve(res) 120 resolve(res)
121 + }
117 }).catch(error => { 122 }).catch(error => {
118 reject(error) 123 reject(error)
119 }) 124 })
......
1 +// 是否
2 +export function isSure(type) {
3 + if (type === 0 || type === "0" || type === false) {
4 + return "否";
5 + } else if (type === 1 || type === "1" || type === true) {
6 + return "是";
7 + }
8 +}
9 +
10 +// 布尔值转换
11 +export function returnBoolean(type) {
12 + if (type === 0 || type === "0") {
13 + return false;
14 + } else if (type === 1 || type === "1") {
15 + return true;
16 + }
17 +}
18 +
19 +export default {
20 + isSure,
21 + returnBoolean,
22 +};
23 +
...@@ -9,9 +9,9 @@ axios.defaults.headers['Content-Type'] = 'application/json;charset=utf-8' ...@@ -9,9 +9,9 @@ axios.defaults.headers['Content-Type'] = 'application/json;charset=utf-8'
9 // 创建axios实例 9 // 创建axios实例
10 const service = axios.create({ 10 const service = axios.create({
11 // axios中请求配置有baseURL选项,表示请求URL公共部分 11 // axios中请求配置有baseURL选项,表示请求URL公共部分
12 - baseURL: settings.baseURL, 12 + baseURL: settings.baseURL, //接口地址
13 // 超时 13 // 超时
14 - timeout: 90000, 14 + timeout: 30000
15 }) 15 })
16 16
17 // request拦截器 17 // request拦截器
...@@ -52,14 +52,14 @@ service.interceptors.request.use(config => { ...@@ -52,14 +52,14 @@ service.interceptors.request.use(config => {
52 // 响应拦截器 52 // 响应拦截器
53 service.interceptors.response.use(res => { 53 service.interceptors.response.use(res => {
54 if (res.headers['token']) { 54 if (res.headers['token']) {
55 - setToken(res.headers['token']) 55 + setToken(decodeURI(res.headers['token']))
56 } 56 }
57 // 未设置状态码则默认成功状态 57 // 未设置状态码则默认成功状态
58 const code = res.data.code || 200; 58 const code = res.data.code || 200;
59 // 获取错误信息 59 // 获取错误信息
60 const msg = errorCode[code] || res.data.msg || errorCode['default'] 60 const msg = errorCode[code] || res.data.msg || errorCode['default']
61 if (code === 301) { 61 if (code === 301) {
62 - MessageBox.confirm('登录状态已过期,需重新登录!msg:' + msg, '系统提示', { 62 + MessageBox.confirm('登录状态已过期,需重新登录', '系统提示', {
63 closeOnClickModal: false, 63 closeOnClickModal: false,
64 showCancelButton: false, 64 showCancelButton: false,
65 confirmButtonText: '重新登录', 65 confirmButtonText: '重新登录',
...@@ -67,10 +67,9 @@ service.interceptors.response.use(res => { ...@@ -67,10 +67,9 @@ service.interceptors.response.use(res => {
67 } 67 }
68 ).then(() => { 68 ).then(() => {
69 store.dispatch('LogOut').then(() => { 69 store.dispatch('LogOut').then(() => {
70 - // location.href = '/'; 70 + location.href = settings.routerBase + '/index';
71 - window.location.href = settings.loginURL;//wsso系统跳转 71 + })
72 }) 72 })
73 - });
74 } else if (code === 403) { 73 } else if (code === 403) {
75 //无权限页面 74 //无权限页面
76 location.href = '/401'; 75 location.href = '/401';
...@@ -81,7 +80,7 @@ service.interceptors.response.use(res => { ...@@ -81,7 +80,7 @@ service.interceptors.response.use(res => {
81 type: 'error' 80 type: 'error'
82 }) 81 })
83 return Promise.reject(new Error(msg)) 82 return Promise.reject(new Error(msg))
84 - } else if (code !== 200 && code !== 201 && code !== 202 && code !== 603) { 83 + } else if (code !== 200 && code !== 201 && code !== 202 && code != 203 && code != 603) {
85 Message({ 84 Message({
86 message: msg, 85 message: msg,
87 type: 'error' 86 type: 'error'
......
...@@ -15,7 +15,7 @@ export function downLoadZip(str, data, filename) { ...@@ -15,7 +15,7 @@ export function downLoadZip(str, data, filename) {
15 url: url, 15 url: url,
16 data: data, 16 data: data,
17 responseType: 'blob', 17 responseType: 'blob',
18 - headers: { 'Authorization': decodeURIComponent(getToken()) } 18 + headers: { 'Authorization': 'Bearer ' + getToken() }
19 }).then(res => { 19 }).then(res => {
20 resolveBlob(res, mimeMap.zip, filename) 20 resolveBlob(res, mimeMap.zip, filename)
21 }) 21 })
...@@ -49,9 +49,9 @@ export function downLoadXlsx(str, data, fileName) { ...@@ -49,9 +49,9 @@ export function downLoadXlsx(str, data, fileName) {
49 method: 'post', 49 method: 'post',
50 url: url, 50 url: url,
51 data: data, 51 data: data,
52 - timeout: 500000,
53 responseType: 'blob', 52 responseType: 'blob',
54 - headers: { 'Authorization': decodeURIComponent(getToken()) } 53 + headers: { 'Authorization': getToken() }
54 + // headers: { 'Authorization': decodeURIComponent(getToken()) }
55 //uat环境token需要做url解码处理 55 //uat环境token需要做url解码处理
56 }).then(res => { 56 }).then(res => {
57 if (res.status === 200) { 57 if (res.status === 200) {
...@@ -84,7 +84,7 @@ export function cargoXlsxPre(str, data) { ...@@ -84,7 +84,7 @@ export function cargoXlsxPre(str, data) {
84 url: url, 84 url: url,
85 data: data, 85 data: data,
86 responseType: 'blob', 86 responseType: 'blob',
87 - headers: { 'Authorization': decodeURIComponent(getToken()) } 87 + headers: { 'Authorization': getToken() }
88 }).then(res => { 88 }).then(res => {
89 if (res.status === 200) { 89 if (res.status === 200) {
90 cargoTableXlsxPre(res) 90 cargoTableXlsxPre(res)
......
...@@ -112,7 +112,7 @@ ...@@ -112,7 +112,7 @@
112 </el-form-item> 112 </el-form-item>
113 </el-col> 113 </el-col>
114 <el-col :span="6"> 114 <el-col :span="6">
115 - <el-form-item label="站点"> 115 + <el-form-item label="始发站">
116 <el-input class="formItem" type="textarea" placeholder="PVG;PEK" v-model="siteName" :rows="1" clearable> 116 <el-input class="formItem" type="textarea" placeholder="PVG;PEK" v-model="siteName" :rows="1" clearable>
117 </el-input> 117 </el-input>
118 </el-form-item> 118 </el-form-item>
...@@ -261,7 +261,7 @@ export default { ...@@ -261,7 +261,7 @@ export default {
261 size: 100, 261 size: 100,
262 allWeight: 0, 262 allWeight: 0,
263 allQty: 0, 263 allQty: 0,
264 - tableHeight: null, 264 + tableHeight: 300,
265 dialogVisible: false, 265 dialogVisible: false,
266 shiftKey: false, 266 shiftKey: false,
267 createDate: null, 267 createDate: null,
...@@ -303,7 +303,7 @@ export default { ...@@ -303,7 +303,7 @@ export default {
303 this.shiftKey = false; 303 this.shiftKey = false;
304 } 304 }
305 }); 305 });
306 - this.tableHeight = window.innerHeight - this.$refs.form.$el.offsetHeight - 60 306 + // this.tableHeight = window.innerHeight - this.$refs.form.$el.offsetHeight - 60;
307 }, 307 },
308 methods: { 308 methods: {
309 //查询条件 309 //查询条件
......
...@@ -73,7 +73,7 @@ export default { ...@@ -73,7 +73,7 @@ export default {
73 { name: "口岸代码", value: "portName", width: "" }, 73 { name: "口岸代码", value: "portName", width: "" },
74 { name: "运单号", value: "waybillNo", width: "" }, 74 { name: "运单号", value: "waybillNo", width: "" },
75 { name: "货物状态", value: "statusName", width: "" }, 75 { name: "货物状态", value: "statusName", width: "" },
76 - { name: "站点", value: "siteName", width: "" }, 76 + { name: "始发站", value: "siteName", width: "" },
77 { name: "申报类型", value: "typeName", width: "" }, 77 { name: "申报类型", value: "typeName", width: "" },
78 { name: "URSA", value: "ursa", width: "" }, 78 { name: "URSA", value: "ursa", width: "" },
79 { name: "实际重量", value: "actualWeight", width: "" }, 79 { name: "实际重量", value: "actualWeight", width: "" },
......
1 +<template>
2 + <div class=''></div>
3 + </template>
4 +
5 + <script>
6 +
7 + export default {
8 + name: '',
9 + components: {},
10 + data() {
11 +
12 + return {
13 +
14 + }
15 + },
16 +
17 + computed: {},
18 + created () {},
19 + mounted () {},
20 + methods: {}
21 + }
22 + </script>
23 + <style lang='scss' scoped>
24 +
25 + </style>
1 +<template>
2 + <div class=''></div>
3 + </template>
4 +
5 + <script>
6 +
7 + export default {
8 + name: '',
9 + components: {},
10 + data() {
11 +
12 + return {
13 +
14 + }
15 + },
16 +
17 + computed: {},
18 + created () {},
19 + mounted () {},
20 + methods: {}
21 + }
22 + </script>
23 + <style lang='scss' scoped>
24 +
25 + </style>
1 +export const formConfig = [
2 + {
3 + label: "重量(KG)",
4 + type: "Input",
5 + name: "minWeight",
6 + prop: "minWeight",
7 + placeholder: "0",
8 + rules: {
9 + required: true,
10 + message: "最大重量不得小于0KG",
11 + trigger: ["change", "blur"],
12 + },
13 + trigger: "blur", // 事件名
14 + },
15 + {
16 + label: "",
17 + type: "Input",
18 + name: "maxWeight",
19 + prop: "maxWeight",
20 + placeholder: "34",
21 + rules: {
22 + required: true,
23 + message: "最大重量不得大于34KG",
24 + trigger: ["change", "blur"],
25 + },
26 + trigger: "blur", // 事件名
27 + },
28 + {
29 + label: "件数",
30 + type: "Input",
31 + name: "minNumOfPieces",
32 + prop: "minNumOfPieces",
33 + placeholder: "0",
34 + rules: {
35 + required: true,
36 + message: "最大重量不得小于0KG",
37 + trigger: ["change", "blur"],
38 + },
39 + trigger: "blur", // 事件名
40 + },
41 + {
42 + label: "",
43 + type: "Input",
44 + name: "maxNumOfPieces",
45 + prop: "maxNumOfPieces",
46 + placeholder: "34",
47 + rules: {
48 + required: true,
49 + message: "最大重量不得大于34KG",
50 + trigger: ["change", "blur"],
51 + },
52 + trigger: "blur", // 事件名
53 + },
54 +];
This diff is collapsed. Click to expand it.
This diff is collapsed. Click to expand it.
1 +export const tableAttr = {
2 + border: true,
3 + loadingTable: false,
4 + isDragSort: true, // 拖拽tableData数据一定要加id字段
5 + maxHeight: 300,
6 + btnCofig: {
7 + isBtn: true,
8 + btnGroup: [
9 + {
10 + type: "primary",
11 + icon: "el-icon-plus",
12 + btnName: "添加",
13 + size: "mini",
14 + round: false,
15 + loading: false,
16 + event: "add",
17 + },
18 + ],
19 + },
20 +};
21 +
22 +export const columnHeader = (deleteRow) => [
23 + {
24 + label: "航班号",
25 + prop: "fltNo",
26 + align: "center",
27 + minWidth: 100,
28 + },
29 + {
30 + label: "航班日期",
31 + prop: "fltNoDate",
32 + align: "center",
33 + minWidth: 100,
34 + // sortable: true,
35 + // "sort-method": (a, b) => b.updateTime - a.updateTime,
36 + },
37 + {
38 + label: "航线优先级",
39 + prop: "fltRoute",
40 + align: "center",
41 + minWidth: 100,
42 + },
43 + {
44 + label: "爆仓是否继续配舱",
45 + prop: "isOn",
46 + align: "center",
47 + minWidth: 100,
48 + render: (h, params) => {
49 + const { row } = params;
50 + console.log(345678,row);
51 + // return h("div", `状态-${row.id}`);
52 + },
53 + },
54 + {
55 + label: "操作",
56 + align: "center",
57 + minWidth: 120,
58 + render: (h, params) => {
59 + return h("div", [
60 + h(
61 + "el-button",
62 + {
63 + style: {
64 + color: "#ff4949",
65 + },
66 + props: {
67 + type: "text",
68 + size: "mini",
69 + icon: "el-icon-delete",
70 + },
71 + on: {
72 + click() {
73 + deleteRow(params);
74 + },
75 + },
76 + },
77 + "删除"
78 + ),
79 + ]);
80 + },
81 + },
82 +];
83 +
84 +export const tableData = [
85 + {
86 + id: "1",
87 + fltNo: "A380",
88 + fltNoDate: "3",
89 + fltRoute: "",
90 + routeList: [],
91 + isOn: "1",
92 + sort: "1", // 排序字段
93 + },
94 +];
1 +export const formConfig = [
2 + {
3 + label: "创建时间(从)",
4 + type: "Date",
5 + name: "startTime",
6 + prop: "startTime",
7 + placeholder: "请选择开始时间",
8 + rules: { required: true, message: "请选择开始时间", trigger: "blur" },
9 + },
10 + {
11 + label: "创建时间(到)",
12 + type: "Date",
13 + name: "endTime",
14 + prop: "endTime",
15 + placeholder: "请选择结束时间",
16 + rules: { required: true, message: "请选择结束时间", trigger: "blur" },
17 + },
18 + {
19 + label: "规则状态",
20 + type: "Select",
21 + name: "status",
22 + prop: "status",
23 + width: "140px",
24 + placeholder: "请选择状态",
25 + options: {
26 + data: [
27 + {
28 + value: "1",
29 + label: "有效",
30 + },
31 + {
32 + value: "3",
33 + label: "无效",
34 + },
35 + ],
36 + label: "有效",
37 + value: "1",
38 + },
39 + },
40 +];
41 +
42 +export const editFormConfig = [
43 + {
44 + label: "航班号",
45 + type: "Search",
46 + name: "route",
47 + prop: "fltNo",
48 + placeholder: "请输入航班号",
49 + rules: {
50 + required: true,
51 + message: "请输入航班号",
52 + trigger: ["change", "blur"],
53 + },
54 + http: {
55 + url: "/dictionary/queryRouteByFltNo",
56 + method: "post",
57 + data: {
58 + fltNo: "",
59 + },
60 + },
61 + },
62 + {
63 + label: "",
64 + type: "inputNumber",
65 + name: "count",
66 + prop: "count",
67 + placeholder: "+",
68 + min: 0,
69 + max: 7,
70 + with: "50px",
71 + },
72 + {
73 + label: "航线优先级",
74 + type: "Input",
75 + name: "route",
76 + prop: "fltNum",
77 + placeholder: "请选择航线优先级",
78 + trigger: "focus",
79 + },
80 + {
81 + label: "爆仓是否继续配舱",
82 + type: "Checkbox",
83 + name: "checked",
84 + prop: "checked",
85 + disabled: false,
86 + },
87 +];
1 +<template>
2 + <div class="form-header container">
3 + <el-row>
4 + <el-col>
5 + <yl-form
6 + ref="ruleForm"
7 + :formConfig="formConfig"
8 + :queryForm="queryForm"
9 + @input="inputEvent"
10 + @keyup="keyUpEvent"
11 + />
12 + </el-col>
13 + </el-row>
14 + <yl-table
15 + :attrs="tableAttr"
16 + :loadingTable="tableAttr.loadingTable"
17 + :columns="columns"
18 + :tableData="tableData"
19 + :pageConfig="pageConfig"
20 + @sizeChange="handleSizeChange"
21 + @currentChange="handleCurrentChange"
22 + @search="searchBtn"
23 + @restForm="restForm"
24 + @add="addBtn"
25 + >
26 + </yl-table>
27 + </div>
28 +</template>
29 +<script>
30 +import YlForm from "@/components/YlForm";
31 +import YlTable from "@/components/YlTable";
32 +import { formConfig } from "./formConfig";
33 +import { debounce } from "@/utils";
34 +import { tableAttr, columnHeader, tableData } from "./tableConfig";
35 +import {
36 + allDictData, // 获取全部字典
37 + queryRouteByFltNo, // 航线查询
38 +} from "@/api/destinationFlight";
39 +export default {
40 + components: {
41 + YlForm,
42 + YlTable,
43 + },
44 + data() {
45 + return {
46 + formConfig: formConfig, // 表单配置项
47 + queryForm: { // 表单参数
48 + status: "有效"
49 + },
50 + pageConfig: {
51 + // 分页配置项
52 + isPagination: true,
53 + total: 13,
54 + pageData: {
55 + page: 1,
56 + size: 10,
57 + },
58 + },
59 + tableAttr: tableAttr, // table配置项
60 + columns: columnHeader(this.viewRow, this.editRow, this.deleteRow), // 表头
61 + tableData: tableData, // 表格数据
62 + selectionList: [], // table复选框筛选集合
63 + };
64 + },
65 + created() {},
66 + mounted() {},
67 + methods: {
68 + // 航线查询
69 + queryRoute(item) {
70 + queryRouteByFltNo(item).then((res) => {
71 + if (res.code == 200) {
72 + const list = res.data.list;
73 + let routeList = "";
74 + if (list.length) {
75 + list.map((item) => {
76 + routeList += item.route + ",";
77 + });
78 + this.queryForm.fltRoute = routeList.substring(
79 + 0,
80 + routeList.length - 1
81 + );
82 + } else {
83 + this.queryForm = {
84 + fltNo: item.fltNo, // 航班号
85 + };
86 + }
87 + }
88 + });
89 + },
90 + // input事件
91 + inputEvent: debounce(function () {
92 + this.queryRoute({
93 + fltNo: this.queryForm.fltNo, // 航班号
94 + });
95 + }, 800),
96 + // 回车事件
97 + keyUpEvent(item) {
98 + this.queryRoute(item);
99 + },
100 + // table复选框事件
101 + selectionTable(e) {
102 + console.log("selectionTable:", e);
103 + this.selectionList = e;
104 + },
105 + //条数变化
106 + handleSizeChange(e) {
107 + this.pageConfig.pageData.size = e;
108 + this.pageConfig.pageData.page = 1;
109 + console.log("sizeChange:", e);
110 + },
111 + //页码变化
112 + handleCurrentChange(e) {
113 + this.pageConfig.pageData.page = e;
114 + console.log("currentChange:", e);
115 + },
116 + // 搜索
117 + searchBtn(row) {
118 + this.$refs.ruleForm.handleSearch("ruleForm", (val) => {
119 + console.log(val);
120 + });
121 + console.log(this.queryForm);
122 + },
123 + // 重置表单
124 + restForm() {
125 + this.$refs.ruleForm.resetFields("ruleForm");
126 + },
127 + // 添加
128 + addBtn(item) {
129 + console.log("add:", item);
130 + this.$router.push({
131 + name: "edit",
132 + params: {
133 + edit: 12,
134 + },
135 + });
136 + },
137 + // 编辑
138 + editRow(item) {
139 + this.$router.push({
140 + name: "edit",
141 + params: {
142 + edit: 12,
143 + },
144 + });
145 + console.log("修改:", item);
146 + },
147 + // 删除
148 + deleteRow(item) {
149 + this.$confirm("是否确认删除?", "提示", {
150 + confirmButtonText: "确定",
151 + cancelButtonText: "取消",
152 + type: "warning",
153 + center: true,
154 + })
155 + .then(() => {
156 + console.log("删除:", item);
157 + this.msgSuccess("删除成功!")
158 + })
159 + .catch(() => {});
160 + },
161 + // 查看
162 + viewRow({ row }) {
163 + this.$router.push({
164 + name: "edit",
165 + params: {
166 + edit: 12,
167 + },
168 + });
169 + console.log("查看:", row);
170 + },
171 + },
172 +};
173 +</script>
174 +<style lang="scss" scoped></style>
1 +const state = {
2 + 1: "有效",
3 + 3: "无效",
4 +};
5 +export const tableAttr = {
6 + border: true,
7 + loadingTable: false,
8 + isDragSort: false, // 拖拽tableData数据一定要加id字段
9 + maxHeight: 300,
10 + btnCofig: {
11 + isBtn: true,
12 + btnGroup: [
13 + {
14 + type: "primary", // text、primary、danger
15 + icon: "el-icon-search", // el-icon-edit 、el-icon-delete、el-icon-plus、el-icon-download、el-icon-upload el-icon--right
16 + btnName: "搜索",
17 + size: "mini", // medium / small / mini
18 + round: false,
19 + loading: false,
20 + event: "search",
21 + },
22 + {
23 + type: "info",
24 + icon: "",
25 + btnName: "重置",
26 + size: "mini",
27 + round: false,
28 + loading: false,
29 + event: "restForm",
30 + },
31 + {
32 + type: "primary",
33 + icon: "el-icon-plus",
34 + btnName: "添加",
35 + size: "mini",
36 + round: false,
37 + loading: false,
38 + event: "add",
39 + },
40 + ],
41 + },
42 +};
43 +export const columnHeader = (viewRow, editRow, deleteRow) => [
44 + {
45 + type: "selection",
46 + align: "center",
47 + prop: "selection",
48 + width: "50",
49 + },
50 + {
51 + type: "index",
52 + label: "序号",
53 + prop: "id",
54 + align: "center",
55 + width: "50",
56 + },
57 + {
58 + label: "原航班号",
59 + prop: "fltNo",
60 + align: "center",
61 + minWidth: 100,
62 + },
63 + {
64 + label: "顺位航班",
65 + prop: "flightRand",
66 + align: "center",
67 + minWidth: 100,
68 + },
69 + {
70 + label: "URSA包含",
71 + prop: "includeUrsa",
72 + align: "center",
73 + minWidth: 100,
74 + },
75 + {
76 + label: "URSA不包含",
77 + prop: "notIncludeUrsa",
78 + align: "center",
79 + minWidth: 100,
80 + },
81 + {
82 + label: "状态",
83 + prop: "status",
84 + align: "center",
85 + minWidth: 100,
86 + render: (h, params) => {
87 + const { row } = params;
88 + return h("div", `${state[row.status]}`);
89 + },
90 + },
91 + {
92 + label: "创建时间",
93 + prop: "createTime",
94 + align: "center",
95 + minWidth: 100,
96 + sortable: true,
97 + "sort-method": (a, b) => b.createTime - a.createTime,
98 + },
99 + {
100 + label: "创建人",
101 + prop: "createUserName",
102 + align: "center",
103 + minWidth: 100,
104 + },
105 + {
106 + label: "修改时间",
107 + prop: "updateTime",
108 + align: "center",
109 + minWidth: 100,
110 + },
111 + {
112 + label: "修改人",
113 + prop: "updateUserName",
114 + align: "center",
115 + minWidth: 100,
116 + },
117 + {
118 + label: "操作",
119 + prop: "operate",
120 + align: "center",
121 + minWidth: 120,
122 + fixed: "right",
123 + render: (h, params) => {
124 + return h("div", [
125 + h(
126 + "el-button",
127 + {
128 + props: {
129 + type: "text",
130 + size: "mini",
131 + icon: "el-icon-view",
132 + },
133 + on: {
134 + click() {
135 + viewRow(params);
136 + },
137 + },
138 + },
139 + "查看"
140 + ),
141 + h(
142 + "el-button",
143 + {
144 + props: {
145 + type: "text",
146 + size: "mini",
147 + icon: "el-icon-edit",
148 + },
149 + on: {
150 + click() {
151 + editRow(params);
152 + },
153 + },
154 + },
155 + "修改"
156 + ),
157 + h(
158 + "el-button",
159 + {
160 + style: {
161 + color: "#ff4949",
162 + },
163 + props: {
164 + type: "text",
165 + size: "mini",
166 + icon: "el-icon-delete",
167 + },
168 + on: {
169 + click() {
170 + deleteRow(params);
171 + },
172 + },
173 + },
174 + "删除"
175 + ),
176 + ]);
177 + },
178 + },
179 +];
180 +
181 +export const tableData = [
182 + {
183 + id: "1",
184 + flightRand: "LZ003;LZ00",
185 + status: "1",
186 + fltNo: "FX0090",
187 + includeUrsa: "URSACODE191",
188 + notIncludeUrsa: "P_3",
189 + createTime: "2023-08-14",
190 + createUserName: "wjh",
191 + updateTime: "2023-08-14",
192 + updateUserName: "wjh",
193 + },
194 + {
195 + id: "2",
196 + flightRand: "LP001;LP004+1",
197 + status: "3",
198 + fltNo: "FX0090",
199 + includeUrsa: "P_;URSACODE105",
200 + notIncludeUrsa: "P_21",
201 + createTime: "2023-08-14",
202 + createUserName: "wjh",
203 + updateTime: "2023-08-14",
204 + updateUserName: "wjh",
205 + },
206 + {
207 + id: "3",
208 + flightRand: "CQ00;LZ003;CS0004",
209 + status: "1",
210 + fltNo: "CS0002",
211 + includeUrsa: "URSACODE12",
212 + notIncludeUrsa: "P_2",
213 + createTime: "2023-08-14",
214 + createUserName: "wjh",
215 + updateTime: "2023-08-14",
216 + updateUserName: "wjh",
217 + },
218 + {
219 + id: "4",
220 + flightRand: "LZ001;LZ002;LZ004",
221 + status: "1",
222 + fltNo: "FX0090",
223 + includeUrsa: "URSACODE192",
224 + notIncludeUrsa: "P_17",
225 + createTime: "2023-08-11",
226 + createUserName: "wjh",
227 + updateTime: "2023-08-11",
228 + updateUserName: "wjh",
229 + },
230 + {
231 + id: "5",
232 + flightRand: "PS001;PS003",
233 + status: "1",
234 + fltNo: "FX0091",
235 + includeUrsa: "URSACODE10",
236 + notIncludeUrsa: "P_28",
237 + createTime: "2023-08-11",
238 + createUserName: "wjh",
239 + updateTime: "2023-08-11",
240 + updateUserName: "wjh",
241 + },
242 + {
243 + id: "6",
244 + flightRand: "PS002;PS003",
245 + status: "3",
246 + fltNo: "XN007",
247 + includeUrsa: "URSACODE27",
248 + notIncludeUrsa: "P_4",
249 + createTime: "2023-08-11",
250 + createUserName: "wjh",
251 + updateTime: "2023-08-11",
252 + updateUserName: "wjh",
253 + },
254 + {
255 + id: "7",
256 + flightRand: "XN001;XN002;XN003;XN004",
257 + status: "1",
258 + fltNo: "XN001",
259 + includeUrsa: "URSACODE34",
260 + notIncludeUrsa: "P_7",
261 + createTime: "2023-08-10",
262 + createUserName: "wjh",
263 + updateTime: "2023-08-10",
264 + updateUserName: "wjh",
265 + },
266 + {
267 + id: "8",
268 + flightRand: "HA004",
269 + status: "3",
270 + fltNo: "LZ007",
271 + includeUrsa: "URSACODE71",
272 + notIncludeUrsa: "P_2",
273 + createTime: "2023-08-10",
274 + createUserName: "wjh",
275 + updateTime: "2023-08-10",
276 + updateUserName: "wjh",
277 + },
278 + {
279 + id: "9",
280 + flightRand: "AB0001;AB123",
281 + status: "1",
282 + fltNo: "AB0001",
283 + includeUrsa: "URSACODE87",
284 + notIncludeUrsa: "P_26",
285 + createTime: "2023-08-10",
286 + createUserName: "wjh",
287 + updateTime: "2023-08-10",
288 + updateUserName: "wjh",
289 + },
290 +];
...@@ -98,7 +98,7 @@ export default { ...@@ -98,7 +98,7 @@ export default {
98 colData: {}, 98 colData: {},
99 curPage: 1, 99 curPage: 1,
100 total: 0, 100 total: 0,
101 - tableHeight: null, 101 + tableHeight: 300,
102 open: false, 102 open: false,
103 loading: false, 103 loading: false,
104 }; 104 };
...@@ -109,7 +109,7 @@ export default { ...@@ -109,7 +109,7 @@ export default {
109 } 109 }
110 }, 110 },
111 mounted() { 111 mounted() {
112 - this.tableHeight = window.innerHeight - this.$refs.flightAllocForm.$el.offsetHeight - 200 112 + // this.tableHeight = window.innerHeight - this.$refs.flightAllocForm.$el.offsetHeight - 200;
113 }, 113 },
114 activated() { 114 activated() {
115 this.getList() 115 this.getList()
......
...@@ -187,7 +187,7 @@ export default { ...@@ -187,7 +187,7 @@ export default {
187 // 总条数 187 // 总条数
188 total: 0, 188 total: 0,
189 //table高度 189 //table高度
190 - tableHeight: null, 190 + tableHeight: 300,
191 // 原航班规则数据 191 // 原航班规则数据
192 sourceFlightRulesList: [], 192 sourceFlightRulesList: [],
193 //目的航班数据 193 //目的航班数据
...@@ -249,7 +249,7 @@ export default { ...@@ -249,7 +249,7 @@ export default {
249 } 249 }
250 }, 250 },
251 mounted() { 251 mounted() {
252 - this.tableHeight = window.innerHeight - this.$refs.queryForm.$el.offsetHeight - 200 252 + // this.tableHeight = window.innerHeight - this.$refs.queryForm.$el.offsetHeight - 200;
253 }, 253 },
254 activated() { 254 activated() {
255 this.findSourceFlightRules(); 255 this.findSourceFlightRules();
......
...@@ -99,7 +99,7 @@ export default { ...@@ -99,7 +99,7 @@ export default {
99 },//表单规则 99 },//表单规则
100 dialogVisible: false, 100 dialogVisible: false,
101 total: 0, 101 total: 0,
102 - tableHeight: null, 102 + tableHeight: 300,
103 loading: false, 103 loading: false,
104 tableLoading: false, 104 tableLoading: false,
105 }; 105 };
...@@ -113,7 +113,7 @@ export default { ...@@ -113,7 +113,7 @@ export default {
113 } 113 }
114 }, 114 },
115 mounted() { 115 mounted() {
116 - this.tableHeight = window.innerHeight - this.$refs.preReviewOptions.offsetHeight - 300 116 + // this.tableHeight = window.innerHeight - this.$refs.preReviewOptions.offsetHeight - 300;
117 }, 117 },
118 methods: { 118 methods: {
119 //搜索 119 //搜索
......
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
23 </el-form-item> 23 </el-form-item>
24 </el-col> 24 </el-col>
25 <el-col :span="6"> 25 <el-col :span="6">
26 - <el-form-item label="站点"> 26 + <el-form-item label="始发站">
27 <el-input type="textarea" v-model="siteName" class="formItem" placeholder="PVG;PEK" clearable :rows="1"> 27 <el-input type="textarea" v-model="siteName" class="formItem" placeholder="PVG;PEK" clearable :rows="1">
28 </el-input> 28 </el-input>
29 </el-form-item> 29 </el-form-item>
...@@ -53,7 +53,7 @@ ...@@ -53,7 +53,7 @@
53 }}</el-button> 53 }}</el-button>
54 </div> 54 </div>
55 </el-form> 55 </el-form>
56 - <el-table max-height="500" highlight-current-row border stripe v-loading="loading" :data="tableData"> 56 + <el-table max-height="300" highlight-current-row border stripe v-loading="loading" :data="tableData">
57 <el-table-column label="运单号" align="center" prop="waybillNo" /> 57 <el-table-column label="运单号" align="center" prop="waybillNo" />
58 <el-table-column label="申报类别" align="center" prop="typeName" /> 58 <el-table-column label="申报类别" align="center" prop="typeName" />
59 <el-table-column label="件数" align="center" prop="qty" width="70" /> 59 <el-table-column label="件数" align="center" prop="qty" width="70" />
...@@ -106,7 +106,7 @@ export default { ...@@ -106,7 +106,7 @@ export default {
106 fltNo: null, 106 fltNo: null,
107 //运单号 107 //运单号
108 waybillNo: "", 108 waybillNo: "",
109 - //站点 109 + //始发站
110 siteName: "", 110 siteName: "",
111 //ursa 111 //ursa
112 ursa: "", 112 ursa: "",
......
...@@ -466,7 +466,7 @@ export default { ...@@ -466,7 +466,7 @@ export default {
466 //总条数 466 //总条数
467 total: 0, 467 total: 0,
468 //表格高度 468 //表格高度
469 - tableHeight: null, 469 + tableHeight: 250,
470 //新增修改查看规则弹出层 470 //新增修改查看规则弹出层
471 open: false, 471 open: false,
472 //是否显示查看目的航班弹出层 472 //是否显示查看目的航班弹出层
...@@ -502,8 +502,7 @@ export default { ...@@ -502,8 +502,7 @@ export default {
502 this.shiftKey = false; 502 this.shiftKey = false;
503 } 503 }
504 }); 504 });
505 - this.tableHeight = 505 + // this.tableHeight = window.innerHeight - this.$refs.queryForm.$el.offsetHeight - 120;
506 - window.innerHeight - this.$refs.queryForm.$el.offsetHeight - 120;
507 }, 506 },
508 methods: { 507 methods: {
509 //输入航班号后 508 //输入航班号后
......
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
20 <el-form-item label="货站名称" prop="goodsStation"> 20 <el-form-item label="货站名称" prop="goodsStation">
21 <el-select class="selectWidth100" v-model.lazy="formData.goodsStation" filterable 21 <el-select class="selectWidth100" v-model.lazy="formData.goodsStation" filterable
22 :loading="goodsStationLoading" placeholder="不限"> 22 :loading="goodsStationLoading" placeholder="不限">
23 - <el-option v-for="(item, index) in goodsStationList" :label="item" :value="item" :key="item"> 23 + <el-option v-for="item in goodsStationList" :label="item" :value="item" :key="item">
24 </el-option> 24 </el-option>
25 </el-select> 25 </el-select>
26 </el-form-item> 26 </el-form-item>
......
...@@ -81,7 +81,7 @@ export default { ...@@ -81,7 +81,7 @@ export default {
81 checkData: [], 81 checkData: [],
82 fileList: [], 82 fileList: [],
83 errorData: [], 83 errorData: [],
84 - tableHeight: null, 84 + tableHeight: 300,
85 totalCount: 0, 85 totalCount: 0,
86 openStatus: '', 86 openStatus: '',
87 loading: false, 87 loading: false,
...@@ -92,7 +92,7 @@ export default { ...@@ -92,7 +92,7 @@ export default {
92 92
93 }, 93 },
94 mounted() { 94 mounted() {
95 - this.tableHeight = window.innerHeight - this.$refs.goodsStation.$el.offsetHeight - 200 95 + // this.tableHeight = window.innerHeight - this.$refs.goodsStation.$el.offsetHeight - 200;
96 this.selection(1) 96 this.selection(1)
97 }, 97 },
98 watch: { 98 watch: {
...@@ -244,4 +244,8 @@ export default { ...@@ -244,4 +244,8 @@ export default {
244 244
245 <style lang="scss" scoped> 245 <style lang="scss" scoped>
246 246
247 +<<<<<<< HEAD
247 </style> 248 </style>
249 +=======
250 +</style>
251 +>>>>>>> test
......
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
20 <el-form-item label="货站名称" prop="goodsStation"> 20 <el-form-item label="货站名称" prop="goodsStation">
21 <el-select class="selectWidth100" v-model.lazy="formData.goodsStation" filterable 21 <el-select class="selectWidth100" v-model.lazy="formData.goodsStation" filterable
22 :loading="goodsStationLoading" placeholder="不限"> 22 :loading="goodsStationLoading" placeholder="不限">
23 - <el-option v-for="(item, index) in goodsStationList" :label="item" :value="item" :key="item"> 23 + <el-option v-for="item in goodsStationList" :label="item" :value="item" :key="item">
24 </el-option> 24 </el-option>
25 </el-select> 25 </el-select>
26 </el-form-item> 26 </el-form-item>
......
...@@ -81,7 +81,7 @@ export default { ...@@ -81,7 +81,7 @@ export default {
81 checkData: [], 81 checkData: [],
82 fileList: [], 82 fileList: [],
83 errorData: [], 83 errorData: [],
84 - tableHeight: null, 84 + tableHeight: 300,
85 totalCount: 0, 85 totalCount: 0,
86 openStatus: '', 86 openStatus: '',
87 loading: false, 87 loading: false,
...@@ -92,7 +92,7 @@ export default { ...@@ -92,7 +92,7 @@ export default {
92 92
93 }, 93 },
94 mounted() { 94 mounted() {
95 - this.tableHeight = window.innerHeight - this.$refs.goodsStation.$el.offsetHeight - 200 95 + // this.tableHeight = window.innerHeight - this.$refs.goodsStation.$el.offsetHeight - 200;
96 this.selection(1) 96 this.selection(1)
97 }, 97 },
98 watch: { 98 watch: {
......
...@@ -64,7 +64,7 @@ export default { ...@@ -64,7 +64,7 @@ export default {
64 tableData: [], 64 tableData: [],
65 tableHeader: this.tableHeaders['goodsStationFlight'], 65 tableHeader: this.tableHeaders['goodsStationFlight'],
66 checkData: [], 66 checkData: [],
67 - tableHeight: null, 67 + tableHeight: 300,
68 totalCount: 0, 68 totalCount: 0,
69 loading: false, 69 loading: false,
70 open: false, 70 open: false,
...@@ -73,7 +73,7 @@ export default { ...@@ -73,7 +73,7 @@ export default {
73 created() { 73 created() {
74 }, 74 },
75 mounted() { 75 mounted() {
76 - this.tableHeight = window.innerHeight - this.$refs.goodsStationFlight.$el.offsetHeight - 200 76 + // this.tableHeight = window.innerHeight - this.$refs.goodsStationFlight.$el.offsetHeight - 200;
77 this.selection(1) 77 this.selection(1)
78 }, 78 },
79 watch: { 79 watch: {
......
...@@ -53,7 +53,7 @@ export default { ...@@ -53,7 +53,7 @@ export default {
53 size: 100 53 size: 100
54 }, 54 },
55 tableHeader: this.tableHeaders['cargoLog'], 55 tableHeader: this.tableHeaders['cargoLog'],
56 - tableHeight: 600, 56 + tableHeight: 300,
57 loading: false 57 loading: false
58 } 58 }
59 }, 59 },
......
...@@ -58,7 +58,7 @@ ...@@ -58,7 +58,7 @@
58 </el-form-item> 58 </el-form-item>
59 </el-col> 59 </el-col>
60 <el-col :span="6"> 60 <el-col :span="6">
61 - <el-form-item label="站点"> 61 + <el-form-item label="始发站">
62 <el-input type="textarea" v-model="siteName" class="formItem" placeholder="PVG;PEK" :rows="4" clearable> 62 <el-input type="textarea" v-model="siteName" class="formItem" placeholder="PVG;PEK" :rows="4" clearable>
63 </el-input> 63 </el-input>
64 </el-form-item> 64 </el-form-item>
...@@ -139,7 +139,7 @@ ...@@ -139,7 +139,7 @@
139 </template> 139 </template>
140 <el-select class="formItem" v-model="formData.cargoPlaneRoute" placeholder="不限" 140 <el-select class="formItem" v-model="formData.cargoPlaneRoute" placeholder="不限"
141 :disabled="routeList.length == 0" clearable @change="routeSelectChange" :key="formData.cargoPlaneRoute"> 141 :disabled="routeList.length == 0" clearable @change="routeSelectChange" :key="formData.cargoPlaneRoute">
142 - <el-option v-for="(item, index) in routeList" :label="item" :value="item" :key="item"> 142 + <el-option v-for="item in routeList" :label="item" :value="item" :key="item">
143 <Tooltips :content="item" :refName="item"></Tooltips> 143 <Tooltips :content="item" :refName="item"></Tooltips>
144 </el-option> 144 </el-option>
145 </el-select> 145 </el-select>
...@@ -149,7 +149,7 @@ ...@@ -149,7 +149,7 @@
149 <el-form-item label="预审状态"> 149 <el-form-item label="预审状态">
150 <el-select v-model="formData.preStatus" placeholder="不限" class="formItem" clearable multiple> 150 <el-select v-model="formData.preStatus" placeholder="不限" class="formItem" clearable multiple>
151 <el-option v-for="item in findConditionData.preQualificationStatus" :label="item == '' ? '非预审' : item" 151 <el-option v-for="item in findConditionData.preQualificationStatus" :label="item == '' ? '非预审' : item"
152 - :value="item"> </el-option> 152 + :value="item" :key="item"> </el-option>
153 </el-select> 153 </el-select>
154 </el-form-item> 154 </el-form-item>
155 </el-col> 155 </el-col>
...@@ -353,7 +353,7 @@ export default { ...@@ -353,7 +353,7 @@ export default {
353 limitSize: 100, //无限制-1 353 limitSize: 100, //无限制-1
354 page: 1, 354 page: 1,
355 progress: 0, 355 progress: 0,
356 - tableHeight: null, 356 + tableHeight: 250,
357 dialogVisible: false, 357 dialogVisible: false,
358 openView: false, 358 openView: false,
359 openTransfer: false, 359 openTransfer: false,
...@@ -367,7 +367,7 @@ export default { ...@@ -367,7 +367,7 @@ export default {
367 } else { 367 } else {
368 this.tableHeader = this.tableHeaders['cargo'] 368 this.tableHeader = this.tableHeaders['cargo']
369 } 369 }
370 - // this.select(0,'create') 370 + this.select(0,'create')
371 }, 371 },
372 372
373 activated() { 373 activated() {
...@@ -441,7 +441,7 @@ export default { ...@@ -441,7 +441,7 @@ export default {
441 this.shiftKey = false; 441 this.shiftKey = false;
442 } 442 }
443 }); 443 });
444 - this.tableHeight = window.innerHeight - this.$refs.cargoForm.$el.offsetHeight - 50 444 + // this.tableHeight = window.innerHeight - this.$refs.cargoForm.$el.offsetHeight - 50
445 }, 445 },
446 watch: { 446 watch: {
447 $route: { 447 $route: {
...@@ -489,7 +489,7 @@ export default { ...@@ -489,7 +489,7 @@ export default {
489 } 489 }
490 }, 490 },
491 formShow(val, oldVal) { 491 formShow(val, oldVal) {
492 - this.tableHeight = window.innerHeight - this.$refs.cargoForm.$el.offsetHeight - 120 492 + // this.tableHeight = window.innerHeight - this.$refs.cargoForm.$el.offsetHeight - 120
493 }, 493 },
494 }, 494 },
495 methods: { 495 methods: {
......
...@@ -72,7 +72,7 @@ export default { ...@@ -72,7 +72,7 @@ export default {
72 { name: "口岸代码", value: "portName", width: "" }, 72 { name: "口岸代码", value: "portName", width: "" },
73 { name: "运单号", value: "waybillNo", width: "" }, 73 { name: "运单号", value: "waybillNo", width: "" },
74 { name: "货物状态", value: "statusName", width: "" }, 74 { name: "货物状态", value: "statusName", width: "" },
75 - { name: "站点", value: "siteName", width: "" }, 75 + { name: "始发站", value: "siteName", width: "" },
76 { name: "申报类型", value: "typeName", width: "" }, 76 { name: "申报类型", value: "typeName", width: "" },
77 { name: "URSA", value: "ursa", width: "" }, 77 { name: "URSA", value: "ursa", width: "" },
78 { name: "实际重量", value: "actualWeight", width: "" }, 78 { name: "实际重量", value: "actualWeight", width: "" },
......
...@@ -34,7 +34,7 @@ ...@@ -34,7 +34,7 @@
34 </el-form-item> 34 </el-form-item>
35 <el-form-item label="航班种类"> 35 <el-form-item label="航班种类">
36 <el-select v-model="selectData.kindId" placeholder="不限" @change="getFlight" clearable> 36 <el-select v-model="selectData.kindId" placeholder="不限" @change="getFlight" clearable>
37 - <el-option v-for="item in fltKindIdList" :label="item.englishName" :value="item.id"></el-option> 37 + <el-option v-for="item in fltKindIdList" :label="item.englishName" :value="item.id" :key="item.id"></el-option>
38 </el-select> 38 </el-select>
39 </el-form-item> 39 </el-form-item>
40 <el-form-item> 40 <el-form-item>
...@@ -42,7 +42,7 @@ ...@@ -42,7 +42,7 @@
42 </el-form-item> 42 </el-form-item>
43 </el-form> 43 </el-form>
44 <el-row class="card2"> 44 <el-row class="card2">
45 - <el-col :span="1" v-for="item in fltBox"> 45 + <el-col :span="1" v-for="item in fltBox" :key="item.fltNo">
46 <div class="fltBox" @click="rowClick({ fltNo: item.fltNo, fltDate: item.fltDate, route: '' })" 46 <div class="fltBox" @click="rowClick({ fltNo: item.fltNo, fltDate: item.fltDate, route: '' })"
47 :style="{ backgroundColor: (item.percentage * 100).toFixed(2) >= 90 ? '#13ce66' : (item.percentage * 100).toFixed(2) >= 75 ? '#ffba00' : '#ff4949' }"> 47 :style="{ backgroundColor: (item.percentage * 100).toFixed(2) >= 90 ? '#13ce66' : (item.percentage * 100).toFixed(2) >= 75 ? '#ffba00' : '#ff4949' }">
48 <div class="fltName">{{ item.fltNo }}</div> 48 <div class="fltName">{{ item.fltNo }}</div>
...@@ -60,7 +60,7 @@ ...@@ -60,7 +60,7 @@
60 <template v-slot:percentage="scope"> 60 <template v-slot:percentage="scope">
61 <el-progress stroke-width="100" 61 <el-progress stroke-width="100"
62 :color="(scope.row.percentage * 100).toFixed(2) >= 90 ? '#13ce66' : (scope.row.percentage * 100).toFixed(2) >= 75 ? '#ffba00' : '#ff4949'" 62 :color="(scope.row.percentage * 100).toFixed(2) >= 90 ? '#13ce66' : (scope.row.percentage * 100).toFixed(2) >= 75 ? '#ffba00' : '#ff4949'"
63 - :stroke-width="18" 63 + :strokeWidth="18"
64 :percentage="scope.row.percentage == 0 ? 0 : Number((scope.row.percentage * 100).toFixed(2))"> 64 :percentage="scope.row.percentage == 0 ? 0 : Number((scope.row.percentage * 100).toFixed(2))">
65 </el-progress> 65 </el-progress>
66 </template> 66 </template>
...@@ -96,7 +96,7 @@ export default { ...@@ -96,7 +96,7 @@ export default {
96 totalWeight: 0,//航班总重量 96 totalWeight: 0,//航班总重量
97 allocationWeight: 0,//航班已配重量 97 allocationWeight: 0,//航班已配重量
98 type: "", 98 type: "",
99 - tableHeight: null, 99 + tableHeight: 300,
100 total: 0, 100 total: 0,
101 loading: false, 101 loading: false,
102 }; 102 };
...@@ -109,7 +109,7 @@ export default { ...@@ -109,7 +109,7 @@ export default {
109 // this.getFlight() 109 // this.getFlight()
110 // }, 110 // },
111 mounted() { 111 mounted() {
112 - this.tableHeight = window.innerHeight - this.$refs.card1.$el.offsetHeight - this.$refs.indexForm.$el.offsetHeight - 350 112 + // this.tableHeight = window.innerHeight - this.$refs.card1.$el.offsetHeight - this.$refs.indexForm.$el.offsetHeight - 350
113 this.getFlight() 113 this.getFlight()
114 }, 114 },
115 methods: { 115 methods: {
......
...@@ -71,6 +71,7 @@ export default { ...@@ -71,6 +71,7 @@ export default {
71 const username = localStorage.getItem("username"); 71 const username = localStorage.getItem("username");
72 const password = localStorage.getItem("password"); 72 const password = localStorage.getItem("password");
73 const rememberMe = localStorage.getItem("rememberMe"); 73 const rememberMe = localStorage.getItem("rememberMe");
74 + // console.log("rememberMe:", rememberMe)
74 this.loginForm = { 75 this.loginForm = {
75 username: username === undefined ? this.loginForm.username : username, 76 username: username === undefined ? this.loginForm.username : username,
76 password: password === undefined ? this.loginForm.password : password, 77 password: password === undefined ? this.loginForm.password : password,
......
...@@ -56,7 +56,6 @@ ...@@ -56,7 +56,6 @@
56 </Tables> 56 </Tables>
57 </div> 57 </div>
58 </template> 58 </template>
59 -
60 <script> 59 <script>
61 import { 60 import {
62 downLoadTemplate, 61 downLoadTemplate,
...@@ -78,7 +77,7 @@ export default { ...@@ -78,7 +77,7 @@ export default {
78 tableData: [], 77 tableData: [],
79 errorData: [], 78 errorData: [],
80 tableHeaders: this.tableHeaders['flightToArea'], 79 tableHeaders: this.tableHeaders['flightToArea'],
81 - tableHeight: null, 80 + tableHeight: 300,
82 total: 0, 81 total: 0,
83 flightType: [], 82 flightType: [],
84 form: { 83 form: {
...@@ -100,7 +99,7 @@ export default { ...@@ -100,7 +99,7 @@ export default {
100 created() { 99 created() {
101 }, 100 },
102 mounted() { 101 mounted() {
103 - this.tableHeight = window.innerHeight - this.$refs.selectForm.$el.offsetHeight - 170 102 + // this.tableHeight = window.innerHeight - this.$refs.selectForm.$el.offsetHeight - 170;
104 this.selection(1) 103 this.selection(1)
105 }, 104 },
106 activated() { 105 activated() {
......
...@@ -56,7 +56,7 @@ ...@@ -56,7 +56,7 @@
56 </el-form-item> 56 </el-form-item>
57 </el-col> 57 </el-col>
58 <el-col :span="6"> 58 <el-col :span="6">
59 - <el-form-item label="站点"> 59 + <el-form-item label="始发站">
60 <el-input type="textarea" v-model="formData.siteName" class="formItem" placeholder="PVG;PEK" 60 <el-input type="textarea" v-model="formData.siteName" class="formItem" placeholder="PVG;PEK"
61 :rows="4" clearable> 61 :rows="4" clearable>
62 </el-input> 62 </el-input>
...@@ -131,7 +131,7 @@ export default { ...@@ -131,7 +131,7 @@ export default {
131 tableHeader: this.tableHeaders['preMdeSelect'], 131 tableHeader: this.tableHeaders['preMdeSelect'],
132 accsDate: [], 132 accsDate: [],
133 valueFormat: "yyyy-MM-dd", 133 valueFormat: "yyyy-MM-dd",
134 - tableHeight: null, 134 + tableHeight: 250,
135 tableLoading: false, 135 tableLoading: false,
136 downloading: false, 136 downloading: false,
137 totalCount: 0, 137 totalCount: 0,
...@@ -141,7 +141,7 @@ export default { ...@@ -141,7 +141,7 @@ export default {
141 this.selectOptionData() 141 this.selectOptionData()
142 }, 142 },
143 mounted() { 143 mounted() {
144 - this.tableHeight = window.innerHeight - this.$refs.preMdeSelectForm.$el.offsetHeight - 150 144 + // this.tableHeight = window.innerHeight - this.$refs.preMdeSelectForm.$el.offsetHeight - 150;
145 this.select(0) 145 this.select(0)
146 }, 146 },
147 watch: { 147 watch: {
......
...@@ -58,7 +58,6 @@ ...@@ -58,7 +58,6 @@
58 </Tables> 58 </Tables>
59 </div> 59 </div>
60 </template> 60 </template>
61 -
62 <script> 61 <script>
63 import { 62 import {
64 downLoadTemplate, 63 downLoadTemplate,
...@@ -79,7 +78,7 @@ export default { ...@@ -79,7 +78,7 @@ export default {
79 tableData: [], 78 tableData: [],
80 errorData: [], 79 errorData: [],
81 tableHeaders: this.tableHeaders['ursaToArea'], 80 tableHeaders: this.tableHeaders['ursaToArea'],
82 - tableHeight: null, 81 + tableHeight: 300,
83 total: 0, 82 total: 0,
84 flightType: [], 83 flightType: [],
85 form: { 84 form: {
...@@ -101,7 +100,7 @@ export default { ...@@ -101,7 +100,7 @@ export default {
101 created() { 100 created() {
102 }, 101 },
103 mounted() { 102 mounted() {
104 - this.tableHeight = window.innerHeight - this.$refs.selectForm.$el.offsetHeight - 170 103 + // this.tableHeight = window.innerHeight - this.$refs.selectForm.$el.offsetHeight - 170;
105 this.selection(1) 104 this.selection(1)
106 }, 105 },
107 activated() { 106 activated() {
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
3 <el-card style="margin-bottom:10px"> 3 <el-card style="margin-bottom:10px">
4 <!-- cardHeader --> 4 <!-- cardHeader -->
5 <div slot="header" class="clearfix"> 5 <div slot="header" class="clearfix">
6 - <span style="font-size:16px;font-weight:700">{{ (tableName == '航线' ? '航线' : tableName == 'Site' ? '站点' : 6 + <span style="font-size:16px;font-weight:700">{{ (tableName == '航线' ? '航线' : tableName == 'Site' ? '始发站' :
7 tableName == 7 tableName ==
8 '虚拟航班' ? '虚拟航班' : tableName.replace(/( |^)[a-z]/g, L => L.toUpperCase())) + "表" 8 '虚拟航班' ? '虚拟航班' : tableName.replace(/( |^)[a-z]/g, L => L.toUpperCase())) + "表"
9 }}</span> 9 }}</span>
...@@ -199,7 +199,7 @@ export default { ...@@ -199,7 +199,7 @@ export default {
199 addDictionary: {},//选择数据 199 addDictionary: {},//选择数据
200 nowSelect: [], 200 nowSelect: [],
201 tableName: '', 201 tableName: '',
202 - tableHeight: null, 202 + tableHeight: 300,
203 total: 0, 203 total: 0,
204 status: null, 204 status: null,
205 loading: false, 205 loading: false,
...@@ -215,7 +215,17 @@ export default { ...@@ -215,7 +215,17 @@ export default {
215 // } 215 // }
216 }, 216 },
217 mounted() { 217 mounted() {
218 - this.tableHeight = window.innerHeight - this.$refs.dictForm.$el.offsetHeight - 270 218 + // this.tableHeight = window.innerHeight - this.$refs.dictForm.$el.offsetHeight - 270
219 + },
220 + filters: {
221 + // 是否为ET86航线
222 + isEtesRoute(val) {
223 + if(val == "N"){
224 + return "否"
225 + }else{
226 + return "是"
227 + }
228 + },
219 }, 229 },
220 watch: { 230 watch: {
221 tableName(val, oldVal) { 231 tableName(val, oldVal) {
......
...@@ -34,7 +34,7 @@ ...@@ -34,7 +34,7 @@
34 :limitSize="formData.size" :page="formData.page" :pageSizes="[20, 30, 40, 50]" :loading="tableLoading" 34 :limitSize="formData.size" :page="formData.page" :pageSizes="[20, 30, 40, 50]" :loading="tableLoading"
35 :height="tableHeight" @sizeChange="sizeChange" @currentChange="currentChange"> 35 :height="tableHeight" @sizeChange="sizeChange" @currentChange="currentChange">
36 <template slot="optionColumn"> 36 <template slot="optionColumn">
37 - <el-table-column header-align="center" align="center" label="操作"> 37 + <el-table-column header-align="center" align="left" label="操作" min-width="210px">
38 <template slot-scope="scope"> 38 <template slot-scope="scope">
39 <el-button type="primary" size="mini" @click="buttonClick(scope, 0)">查看</el-button> 39 <el-button type="primary" size="mini" @click="buttonClick(scope, 0)">查看</el-button>
40 <el-button type="primary" size="mini" @click="buttonClick(scope, 1)" v-hasPermi="['system:role:update']">修改 40 <el-button type="primary" size="mini" @click="buttonClick(scope, 1)" v-hasPermi="['system:role:update']">修改
...@@ -42,7 +42,7 @@ ...@@ -42,7 +42,7 @@
42 <el-button :type="scope.row.valid == 1 ? 'warning' : 'primary'" size="mini" 42 <el-button :type="scope.row.valid == 1 ? 'warning' : 'primary'" size="mini"
43 v-hasPermi="['system:role:openClose']" @click="roleStatus(scope)">{{ scope.row.valid == 1 ? "停用" : "启用" }} 43 v-hasPermi="['system:role:openClose']" @click="roleStatus(scope)">{{ scope.row.valid == 1 ? "停用" : "启用" }}
44 </el-button> 44 </el-button>
45 - <el-button type="danger" size="mini" @click="removeRole(scope)" v-hasPermi="['system:role:delete']">删除角色 45 + <el-button type="danger" size="mini" @click="removeRole(scope)" v-hasPermi="['system:role:delete']" style="margin-top: 5px;margin-left: 0;">删除角色
46 </el-button> 46 </el-button>
47 </template> 47 </template>
48 </el-table-column> 48 </el-table-column>
...@@ -85,7 +85,7 @@ export default { ...@@ -85,7 +85,7 @@ export default {
85 roleFormDisabled: false, 85 roleFormDisabled: false,
86 tableLoading: false, 86 tableLoading: false,
87 total: 0, 87 total: 0,
88 - tableHeight: null 88 + tableHeight: 300
89 }; 89 };
90 }, 90 },
91 created() { 91 created() {
...@@ -94,7 +94,7 @@ export default { ...@@ -94,7 +94,7 @@ export default {
94 } 94 }
95 }, 95 },
96 mounted() { 96 mounted() {
97 - this.tableHeight = window.innerHeight - this.$refs.selectionRoleForm.$el.offsetHeight - 250 97 + // this.tableHeight = window.innerHeight - this.$refs.selectionRoleForm.$el.offsetHeight - 250
98 }, 98 },
99 activated() { 99 activated() {
100 this.selectRoleList(); 100 this.selectRoleList();
......
...@@ -32,7 +32,7 @@ ...@@ -32,7 +32,7 @@
32 :loading="loading" :page="formData.page" :pageSizes="[20, 30, 40, 50]" :height="tableHeight" 32 :loading="loading" :page="formData.page" :pageSizes="[20, 30, 40, 50]" :height="tableHeight"
33 @sizeChange="sizeChange" @currentChange="currentChange"> 33 @sizeChange="sizeChange" @currentChange="currentChange">
34 <template slot="optionColumn"> 34 <template slot="optionColumn">
35 - <el-table-column header-align="center" align="center" width="auto" label="操作"> 35 + <el-table-column header-align="center" align="left" min-width="210px" label="操作">
36 <template slot-scope="scope"> 36 <template slot-scope="scope">
37 <el-button type="primary" size="mini" @click="buttonClick(scope, 0)">查看</el-button> 37 <el-button type="primary" size="mini" @click="buttonClick(scope, 0)">查看</el-button>
38 <el-button type="primary" size="mini" @click="buttonClick(scope, 1)" v-hasPermi="['system:user:update']">修改 38 <el-button type="primary" size="mini" @click="buttonClick(scope, 1)" v-hasPermi="['system:user:update']">修改
...@@ -112,7 +112,7 @@ export default { ...@@ -112,7 +112,7 @@ export default {
112 drawerTitle: "", 112 drawerTitle: "",
113 total: 0, 113 total: 0,
114 loading: false, 114 loading: false,
115 - tableHeight: null 115 + tableHeight: 300
116 }; 116 };
117 }, 117 },
118 created() { 118 created() {
...@@ -121,7 +121,7 @@ export default { ...@@ -121,7 +121,7 @@ export default {
121 } 121 }
122 }, 122 },
123 mounted() { 123 mounted() {
124 - this.tableHeight = window.innerHeight - this.$refs.selectionUserForm.$el.offsetHeight - 250 124 + // this.tableHeight = window.innerHeight - this.$refs.selectionUserForm.$el.offsetHeight - 250;
125 }, 125 },
126 activated() { 126 activated() {
127 this.selectUser(); 127 this.selectUser();
......
...@@ -55,7 +55,7 @@ export default { ...@@ -55,7 +55,7 @@ export default {
55 }, 55 },
56 data: [], 56 data: [],
57 tableHeader: this.tableHeaders['archiveData'], 57 tableHeader: this.tableHeaders['archiveData'],
58 - tableHeight: null, 58 + tableHeight: 300,
59 total: 0, 59 total: 0,
60 loading: false, 60 loading: false,
61 } 61 }
...@@ -64,7 +64,7 @@ export default { ...@@ -64,7 +64,7 @@ export default {
64 this.selectLog() 64 this.selectLog()
65 }, 65 },
66 mounted() { 66 mounted() {
67 - this.tableHeight = window.innerHeight - this.$refs.archiveDataForm.$el.offsetHeight - 200 67 + // this.tableHeight = window.innerHeight - this.$refs.archiveDataForm.$el.offsetHeight - 200
68 }, 68 },
69 methods: { 69 methods: {
70 selectLog(val) { 70 selectLog(val) {
......
...@@ -115,7 +115,7 @@ export default { ...@@ -115,7 +115,7 @@ export default {
115 selectDate: null, 115 selectDate: null,
116 createTimes: [], 116 createTimes: [],
117 total: 0, 117 total: 0,
118 - tableHeight: null, 118 + tableHeight: 300,
119 loading: false, 119 loading: false,
120 valueFormat: "yyyy-MM-dd", 120 valueFormat: "yyyy-MM-dd",
121 }; 121 };
...@@ -130,8 +130,7 @@ export default { ...@@ -130,8 +130,7 @@ export default {
130 this.data = []; 130 this.data = [];
131 }, 131 },
132 mounted() { 132 mounted() {
133 - this.tableHeight = 133 + // this.tableHeight = window.innerHeight - this.$refs.dmLogForm.$el.offsetHeight - 130;
134 - window.innerHeight - this.$refs.dmLogForm.$el.offsetHeight - 130;
135 }, 134 },
136 methods: { 135 methods: {
137 //数据查询 136 //数据查询
......
...@@ -96,7 +96,7 @@ export default { ...@@ -96,7 +96,7 @@ export default {
96 children: 'children', 96 children: 'children',
97 label: 'label' 97 label: 'label'
98 }, 98 },
99 - tableHeight: null, 99 + tableHeight: 300,
100 total: 0, 100 total: 0,
101 loading: false 101 loading: false
102 } 102 }
...@@ -109,7 +109,7 @@ export default { ...@@ -109,7 +109,7 @@ export default {
109 this.selectLog(); 109 this.selectLog();
110 }, 110 },
111 mounted() { 111 mounted() {
112 - this.tableHeight = window.innerHeight - this.$refs.operationLogForm.$el.offsetHeight - 240 112 + // this.tableHeight = window.innerHeight - this.$refs.operationLogForm.$el.offsetHeight - 240
113 }, 113 },
114 methods: { 114 methods: {
115 getModule() { 115 getModule() {
......
1 +//version:0.5.3
1 'use strict' 2 'use strict'
2 const path = require('path') 3 const path = require('path')
3 const defaultSettings = require('./src/settings.js') 4 const defaultSettings = require('./src/settings.js')
...@@ -34,7 +35,7 @@ module.exports = { ...@@ -34,7 +35,7 @@ module.exports = {
34 proxy: { 35 proxy: {
35 // detail: https://cli.vuejs.org/config/#devserver-proxy 36 // detail: https://cli.vuejs.org/config/#devserver-proxy
36 [process.env.VUE_APP_BASE_API]: { 37 [process.env.VUE_APP_BASE_API]: {
37 - target: defaultSettings.baseURL, 38 + target: defaultSettings.baseURL, //阿里云服务器
38 changeOrigin: true, 39 changeOrigin: true,
39 pathRewrite: { 40 pathRewrite: {
40 ['^' + process.env.VUE_APP_BASE_API]: '' 41 ['^' + process.env.VUE_APP_BASE_API]: ''
......