merge
This commit is contained in:
commit
f95b9eb1b7
@ -29,6 +29,7 @@
|
||||
"stompjs": "^2.3.3",
|
||||
"storejs": "^1.0.25",
|
||||
"vue": "2.6.10",
|
||||
"vue-i18n": "^8.12.0",
|
||||
"vue-router": "3.0.6",
|
||||
"vuedraggable": "^2.20.0",
|
||||
"vuex": "3.1.0",
|
||||
|
@ -7,5 +7,6 @@
|
||||
<script>
|
||||
export default {
|
||||
name: 'App'
|
||||
}
|
||||
};
|
||||
|
||||
</script>
|
||||
|
7
src/i18n/index.js
Normal file
7
src/i18n/index.js
Normal file
@ -0,0 +1,7 @@
|
||||
import en from './langs/en';
|
||||
import zh from './langs/zh';
|
||||
|
||||
export default {
|
||||
en,
|
||||
zh
|
||||
};
|
5
src/i18n/langs/en.js
Normal file
5
src/i18n/langs/en.js
Normal file
@ -0,0 +1,5 @@
|
||||
import enLocale from 'element-ui/lib/locale/lang/en';
|
||||
|
||||
export default {
|
||||
...enLocale
|
||||
};
|
5
src/i18n/langs/zh.js
Normal file
5
src/i18n/langs/zh.js
Normal file
@ -0,0 +1,5 @@
|
||||
import cnLocale from 'element-ui/lib/locale/lang/zh-CN';
|
||||
|
||||
export default {
|
||||
...cnLocale
|
||||
};
|
@ -16,7 +16,7 @@ export default class defaultStyle {
|
||||
this.textFontSize = 10;
|
||||
|
||||
/** 默认字体 族类*/
|
||||
this.fontFamily = 'consolas';
|
||||
this.fontFamily = '宋体';
|
||||
|
||||
/** 默认字体颜色*/
|
||||
this.textFontColor = '#C0C0C0';
|
||||
|
@ -15,7 +15,7 @@ class SkinStyle extends defaultStyle {
|
||||
text: {
|
||||
position: 0, // 区段名称位置 1 上面 -1 下面 0 对称
|
||||
distance: 18, // 文字离区段距离
|
||||
fontSize: 10, // 字体大小
|
||||
fontSize: 11, // 字体大小
|
||||
fontWeight: 'normal', // 字体粗细
|
||||
fontColor: '#FFFFFF', // 字体颜色
|
||||
textAlign: 'center', // 水平对齐方式
|
||||
@ -35,7 +35,7 @@ class SkinStyle extends defaultStyle {
|
||||
standText: {
|
||||
position: 0, // 区段名称位置 1 上面 -1 下面 0 对称
|
||||
distance: 28, // 文字离区段距离
|
||||
fontSize: 10, // 字体大小
|
||||
fontSize: 11, // 字体大小
|
||||
fontWeight: 'normal', // 字体粗细
|
||||
fontColor: '#FFFFFF', // 字体颜色
|
||||
textAlign: 'center', // 水平对齐方式
|
||||
@ -45,7 +45,7 @@ class SkinStyle extends defaultStyle {
|
||||
reentryText: {
|
||||
position: 0, // 区段名称位置 1 上面 -1 下面 0 对称
|
||||
distance: 28, // 文字离区段距离
|
||||
fontSize: 10, // 字体大小
|
||||
fontSize: 11, // 字体大小
|
||||
fontWeight: 'normal', // 字体粗细
|
||||
fontColor: '#FFFFFF', // 字体颜色
|
||||
textAlign: 'center', // 水平对齐方式
|
||||
@ -55,7 +55,7 @@ class SkinStyle extends defaultStyle {
|
||||
transferText: {
|
||||
position: 0, // 区段名称位置 1 上面 -1 下面 0 对称
|
||||
distance: 28, // 文字离区段距离
|
||||
fontSize: 10, // 字体大小
|
||||
fontSize: 11, // 字体大小
|
||||
fontWeight: 'normal', // 字体粗细
|
||||
fontColor: '#FFFFFF', // 字体颜色
|
||||
textAlign: 'center', // 水平对齐方式
|
||||
@ -66,7 +66,7 @@ class SkinStyle extends defaultStyle {
|
||||
opposite: true, // 对称相反
|
||||
position: 0, // 区段名称位置 1 上面 -1 下面 0 对称
|
||||
distance: 10, // 文字离区段距离
|
||||
fontSize: 10, // 字体大小
|
||||
fontSize: 11, // 字体大小
|
||||
fontWeight: 'bold', // 字体粗细
|
||||
fontColor: 'yellow', // 字体颜色
|
||||
textAlign: 'center', // 水平对齐方式
|
||||
@ -125,7 +125,7 @@ class SkinStyle extends defaultStyle {
|
||||
distance: 0, // 文字和灯杆的距离
|
||||
isNoRotation: true, // 是否禁止旋转
|
||||
isAlignCenter: true, // 信号字体对其方式
|
||||
fontSize: 10, // 信号机名称字体大小
|
||||
fontSize: 11, // 信号机名称字体大小
|
||||
fontWeight: 'bold', // 信号机名称字体粗细
|
||||
defaultColor: '#FFFFFF', // 信号灯字体默认色
|
||||
blockColor: '#EF0C08', // 信号灯字体锁定颜色
|
||||
@ -162,7 +162,7 @@ class SkinStyle extends defaultStyle {
|
||||
delay: {
|
||||
direction: true, // 延时解锁方向
|
||||
offset: { x: 15, y: -10}, // 延时解锁偏移量
|
||||
fontSize: 9, // 延迟解锁字体大小
|
||||
fontSize: 11, // 延迟解锁字体大小
|
||||
fontColor: '#FF0000', // 延迟解锁颜色
|
||||
fontWeight: 'bold' // 字体粗细
|
||||
},
|
||||
@ -176,7 +176,7 @@ class SkinStyle extends defaultStyle {
|
||||
|
||||
this[deviceType.StationStand] = {
|
||||
common: { // 通用属性
|
||||
textFontSize: 10 // 站台默认字体大小
|
||||
textFontSize: 11 // 站台默认字体大小
|
||||
},
|
||||
safetyDoor: { // 屏蔽门
|
||||
height: 3, // 站台屏蔽门高度
|
||||
@ -185,7 +185,7 @@ class SkinStyle extends defaultStyle {
|
||||
splitDoorColor: '#F61107' // 屏蔽门切除颜色
|
||||
},
|
||||
stand: { // 站台
|
||||
headFontSize: 10, // 站台首端字体大小
|
||||
headFontSize: 11, // 站台首端字体大小
|
||||
spareColor: '#606060', // 站台空闲颜色
|
||||
stopColor: '#FEFE00', // 站台列车停站颜色
|
||||
jumpStopColor: '#9A99FF', // 站台跳停颜色
|
||||
@ -226,7 +226,7 @@ class SkinStyle extends defaultStyle {
|
||||
this[deviceType.StationControl] = {
|
||||
text: {
|
||||
distance: 2, // 灯和文字之间的距离
|
||||
fontSize: 10, // 字体大小
|
||||
fontSize: 11, // 字体大小
|
||||
fontFormat: 'consolas', // 字体格式
|
||||
fontColor: '#ffffff', // 字体颜色
|
||||
fontWeight: 'normal', // 字体粗细
|
||||
@ -272,7 +272,7 @@ class SkinStyle extends defaultStyle {
|
||||
text: {
|
||||
position: 0, // 区段名称位置 1 上面 -1 下面 0 对称
|
||||
offset: {x: 0, y: 8}, // 道岔名称与区段距离
|
||||
fontSize: 10, // 字体大小
|
||||
fontSize: 11, // 字体大小
|
||||
fontWeight: 'normal', // 字体粗细
|
||||
borderColor: '#FE0000', // 道岔边框颜色
|
||||
lossColor: '#FFFFFF', // 道岔失去颜色
|
||||
@ -381,7 +381,7 @@ class SkinStyle extends defaultStyle {
|
||||
trainWidth: 76, // 列车长度
|
||||
trainTextFontSize: 15, // 列车字号
|
||||
fontFamily: '宋体', // 默认字体 族类
|
||||
nameFontSize: 10, // 字体大小
|
||||
nameFontSize: 11, // 字体大小
|
||||
haveTextHSDA: false, // 是否需创建textHSDA对象
|
||||
haveArrowText: true, // 是否需创建arrowText对象
|
||||
haveTrainBorder: false// 是否需创建trainBorder对象
|
||||
|
@ -560,10 +560,12 @@ export function trainMenuFiltration(menuObj) {
|
||||
/**
|
||||
* 离开菜单以及执行完菜单取消选中状态
|
||||
*/
|
||||
export function mouseCancelState(device) {
|
||||
const instance = (Vue.prototype.$jlmap.getDeviceByCode(device.code) || {}).instance;
|
||||
if (instance && instance.mouseEvent && instance.mouseEvent['mouseout']) {
|
||||
instance.mouseEvent['down'] = false;
|
||||
instance.mouseEvent['mouseout'](Vue.prototype.$jlmap.$zr.curEvent);
|
||||
export function mouseCancelState(selected) {
|
||||
const device = Vue.prototype.$jlmap.getDeviceByCode(selected.code);
|
||||
const instance = (device || {}).instance;
|
||||
debugger;
|
||||
if (instance && instance.mouseEvent && instance.mouseEvent.mouseout) {
|
||||
device['down'] = false;
|
||||
instance.mouseEvent.mouseout(Vue.prototype.$jlmap.$zr.curEvent);
|
||||
}
|
||||
}
|
||||
|
@ -1,185 +1,194 @@
|
||||
<template>
|
||||
<el-dialog class="fuzhou-01__systerm view-train-id" title="列车识别号显示设置" :visible.sync="show" width="420px"
|
||||
:before-close="doClose" :zIndex="2000" :modal="false" :close-on-click-modal="false" v-dialogDrag>
|
||||
<div style="padding: 10px 20px; border: 1px double lightgray;">
|
||||
<span class="base-label">计划车显示模式</span>
|
||||
<el-radio-group v-model="planMode">
|
||||
<el-row>
|
||||
<el-col :span="10">
|
||||
<el-radio :label="1">表号+车次号</el-radio>
|
||||
</el-col>
|
||||
<el-col :span="10" :offset="4">
|
||||
<el-radio :label="2">表号+车组号</el-radio>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="10">
|
||||
<el-radio :label="3">目的地号+车次号</el-radio>
|
||||
</el-col>
|
||||
<el-col :span="10" :offset="4">
|
||||
<el-radio :label="4">目的地号+车组号</el-radio>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="10">
|
||||
<el-radio :label="5">目的地号+表号+车次号</el-radio>
|
||||
</el-col>
|
||||
<el-col :span="10" :offset="4">
|
||||
<el-radio :label="6">目的地号+表号+车组号</el-radio>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-radio-group>
|
||||
</div>
|
||||
<div style="padding: 10px 20px; border: 1px double lightgray; margin: 20px 0px;">
|
||||
<span class="base-label">头码车显示模式</span>
|
||||
<el-radio-group v-model="headMode">
|
||||
<el-row>
|
||||
<el-col :span="10">
|
||||
<el-radio :label="3">目的地号+车次号</el-radio>
|
||||
</el-col>
|
||||
<el-col :span="6" :offset="8">
|
||||
<el-radio :label="4">目的地号+车组号</el-radio>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-radio-group>
|
||||
</div>
|
||||
<div style="padding: 10px 20px; border: 1px double lightgray;">
|
||||
<span class="base-label">字体大小</span>
|
||||
<el-row>
|
||||
<el-col :span="10">
|
||||
<el-input v-model="fontSize" size="small" min="16" max="99"></el-input>
|
||||
</el-col>
|
||||
<el-col :span="10" :offset="1">
|
||||
<span style="height:32px; line-height:32px;">(范围:16-99)</span>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</div>
|
||||
<el-row class="button-group">
|
||||
<el-col :span="6" :offset="2">
|
||||
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">确定</el-button>
|
||||
</el-col>
|
||||
<el-col :span="4" :offset="8">
|
||||
<el-button :id="domIdCancel" @click="cancel">取 消</el-button>
|
||||
</el-col>
|
||||
<el-dialog
|
||||
v-dialogDrag
|
||||
class="fuzhou-01__systerm view-train-id"
|
||||
title="列车识别号显示设置"
|
||||
:visible.sync="show"
|
||||
width="420px"
|
||||
:before-close="doClose"
|
||||
:z-index="2000"
|
||||
:modal="false"
|
||||
:close-on-click-modal="false"
|
||||
>
|
||||
<div style="padding: 10px 20px; border: 1px double lightgray;">
|
||||
<span class="base-label">计划车显示模式</span>
|
||||
<el-radio-group v-model="planMode">
|
||||
<el-row>
|
||||
<el-col :span="10">
|
||||
<el-radio :label="1">表号+车次号</el-radio>
|
||||
</el-col>
|
||||
<el-col :span="10" :offset="4">
|
||||
<el-radio :label="2">表号+车组号</el-radio>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<notice-info ref="noticeInfo"></notice-info>
|
||||
</el-dialog>
|
||||
<el-row>
|
||||
<el-col :span="10">
|
||||
<el-radio :label="3">目的地号+车次号</el-radio>
|
||||
</el-col>
|
||||
<el-col :span="10" :offset="4">
|
||||
<el-radio :label="4">目的地号+车组号</el-radio>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="10">
|
||||
<el-radio :label="5">目的地号+表号+车次号</el-radio>
|
||||
</el-col>
|
||||
<el-col :span="10" :offset="4">
|
||||
<el-radio :label="6">目的地号+表号+车组号</el-radio>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-radio-group>
|
||||
</div>
|
||||
<div style="padding: 10px 20px; border: 1px double lightgray; margin: 20px 0px;">
|
||||
<span class="base-label">头码车显示模式</span>
|
||||
<el-radio-group v-model="headMode">
|
||||
<el-row>
|
||||
<el-col :span="10">
|
||||
<el-radio :label="3">目的地号+车次号</el-radio>
|
||||
</el-col>
|
||||
<el-col :span="6" :offset="8">
|
||||
<el-radio :label="4">目的地号+车组号</el-radio>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-radio-group>
|
||||
</div>
|
||||
<div style="padding: 10px 20px; border: 1px double lightgray;">
|
||||
<span class="base-label">字体大小</span>
|
||||
<el-row>
|
||||
<el-col :span="10">
|
||||
<el-input v-model="fontSize" size="small" min="16" max="99" />
|
||||
</el-col>
|
||||
<el-col :span="10" :offset="1">
|
||||
<span style="height:32px; line-height:32px;">(范围:16-99)</span>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</div>
|
||||
<el-row class="button-group">
|
||||
<el-col :span="6" :offset="2">
|
||||
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">确定</el-button>
|
||||
</el-col>
|
||||
<el-col :span="4" :offset="8">
|
||||
<el-button :id="domIdCancel" @click="cancel">取 消</el-button>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<notice-info ref="noticeInfo" />
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { OperationEvent, checkOperationIsCurrentOperate } from '@/scripts/ConstDic';
|
||||
import deviceType from '@/jmap/constant/deviceType';
|
||||
import NoticeInfo from '../dialog/childDialog/childDialog/noticeInfo';
|
||||
import { OperationEvent } from '@/scripts/ConstDic';
|
||||
// import deviceType from '@/jmap/constant/deviceType';
|
||||
import NoticeInfo from '../dialog/childDialog/childDialog/noticeInfo';
|
||||
|
||||
export default {
|
||||
name: 'ViewTrainId',
|
||||
data() {
|
||||
return {
|
||||
dialogShow: false,
|
||||
loading: false,
|
||||
operate: null,
|
||||
operation: '',
|
||||
planMode: 5,
|
||||
headMode: 5,
|
||||
fontSize: 16,
|
||||
}
|
||||
},
|
||||
components: {
|
||||
NoticeInfo
|
||||
},
|
||||
computed: {
|
||||
show() {
|
||||
return this.dialogShow && !this.$store.state.menuOperation.break;
|
||||
},
|
||||
domIdCancel() {
|
||||
return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : '';
|
||||
},
|
||||
domIdConfirm() {
|
||||
return this.dialogShow ? OperationEvent.Command.close.confirm.domId : '';
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.$nextTick(() => {
|
||||
this.setTrainDispaly();
|
||||
this.$store.dispatch('training/tipReload');
|
||||
})
|
||||
},
|
||||
methods: {
|
||||
doShow(operate) {
|
||||
this.operate = operate || {};
|
||||
this.operation = operate.operation;
|
||||
export default {
|
||||
name: 'ViewTrainId',
|
||||
components: {
|
||||
NoticeInfo
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
dialogShow: false,
|
||||
loading: false,
|
||||
operate: null,
|
||||
operation: '',
|
||||
planMode: 5,
|
||||
headMode: 5,
|
||||
fontSize: 16
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
show() {
|
||||
return this.dialogShow && !this.$store.state.menuOperation.break;
|
||||
},
|
||||
domIdCancel() {
|
||||
return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : '';
|
||||
},
|
||||
domIdConfirm() {
|
||||
return this.dialogShow ? OperationEvent.Command.close.confirm.domId : '';
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.$nextTick(() => {
|
||||
this.setTrainDispaly();
|
||||
this.$store.dispatch('training/tipReload');
|
||||
});
|
||||
},
|
||||
methods: {
|
||||
doShow(operate) {
|
||||
this.operate = operate || {};
|
||||
this.operation = operate.operation;
|
||||
|
||||
//非断电激活时设置初始值
|
||||
if (!this.dialogShow) {
|
||||
this.loading = false;
|
||||
}
|
||||
// 非断电激活时设置初始值
|
||||
if (!this.dialogShow) {
|
||||
this.loading = false;
|
||||
}
|
||||
|
||||
this.dialogShow = true;
|
||||
this.$nextTick(function () {
|
||||
this.$store.dispatch('training/emitTipFresh');
|
||||
});
|
||||
},
|
||||
doClose() {
|
||||
this.loading = false;
|
||||
this.dialogShow = false;
|
||||
this.$store.dispatch('training/emitTipFresh');
|
||||
},
|
||||
cancel() {
|
||||
let operate = {
|
||||
type: this.operate.type,
|
||||
operation: OperationEvent.Command.cancel.menu.operation,
|
||||
}
|
||||
this.dialogShow = true;
|
||||
this.$nextTick(function () {
|
||||
this.$store.dispatch('training/emitTipFresh');
|
||||
});
|
||||
},
|
||||
doClose() {
|
||||
this.loading = false;
|
||||
this.dialogShow = false;
|
||||
this.$store.dispatch('training/emitTipFresh');
|
||||
},
|
||||
cancel() {
|
||||
const operate = {
|
||||
type: this.operate.type,
|
||||
operation: OperationEvent.Command.cancel.menu.operation
|
||||
};
|
||||
|
||||
this.$store.dispatch('training/next', operate).then(({ valid }) => {
|
||||
if (valid) {
|
||||
this.doClose();
|
||||
}
|
||||
})
|
||||
},
|
||||
commit() {
|
||||
let operate = {
|
||||
over: true,
|
||||
type: this.operate.type,
|
||||
operation: OperationEvent.Command.close.confirm.operation,
|
||||
val: [this.planMode, this.headMode, this.fontSize].join('::')
|
||||
}
|
||||
this.$store.dispatch('training/next', operate).then(({ valid }) => {
|
||||
if (valid) {
|
||||
this.doClose();
|
||||
}
|
||||
});
|
||||
},
|
||||
commit() {
|
||||
const operate = {
|
||||
over: true,
|
||||
type: this.operate.type,
|
||||
operation: OperationEvent.Command.close.confirm.operation,
|
||||
val: [this.planMode, this.headMode, this.fontSize].join('::')
|
||||
};
|
||||
|
||||
this.loading = true
|
||||
this.$store.dispatch('training/next', operate).then(({ valid }) => {
|
||||
this.loading = false
|
||||
if (valid) {
|
||||
this.setTrainDispaly();
|
||||
this.doClose();
|
||||
}
|
||||
}).catch(error => {
|
||||
this.loading = false;
|
||||
})
|
||||
},
|
||||
setTrainDispaly() {
|
||||
let updatlist = [];
|
||||
let trainList = this.$store.getters['training/viewTrainList'];
|
||||
if (trainList && trainList.length > 0) {
|
||||
let nameFormat = this.trainNameFormatBy(this.planMode);
|
||||
let nameFontSize = this.fontSize;
|
||||
trainList.forEach(elem => {
|
||||
updatlist.push(Object.assign(this.$jlmap.getDeviceByCode(elem.code), {nameFormat, nameFontSize }));
|
||||
});
|
||||
this.loading = true;
|
||||
this.$store.dispatch('training/next', operate).then(({ valid }) => {
|
||||
this.loading = false;
|
||||
if (valid) {
|
||||
this.setTrainDispaly();
|
||||
this.doClose();
|
||||
}
|
||||
}).catch(() => {
|
||||
this.loading = false;
|
||||
});
|
||||
},
|
||||
setTrainDispaly() {
|
||||
const updatlist = [];
|
||||
const trainList = this.$store.getters['training/viewTrainList'];
|
||||
if (trainList && trainList.length > 0) {
|
||||
const nameFormat = this.trainNameFormatBy(this.planMode);
|
||||
const nameFontSize = this.fontSize;
|
||||
trainList.forEach(elem => {
|
||||
updatlist.push(Object.assign(this.$jlmap.getDeviceByCode(elem.code), {nameFormat, nameFontSize }));
|
||||
});
|
||||
|
||||
this.$store.dispatch('map/updateMapDevices', updatlist);
|
||||
}
|
||||
},
|
||||
trainNameFormatBy(mode) {
|
||||
switch (mode.toString()) {
|
||||
case '1': return 'serviceNumber:tripNumber'; //表号+车次号
|
||||
case '2': return 'serviceNumber:groupNumber'; //表号+车组号
|
||||
case '3': return 'targetCode:tripNumber'; //目的地号+车次号
|
||||
case '4': return 'targetCode:groupNumber'; //目的地号+车组号
|
||||
case '5': return 'targetCode:serviceNumber:tripNumber'; //目的地号+表号+车次号
|
||||
case '6': return 'targetCode:serviceNumber:groupNumber'; //目的地号+表号+车组号
|
||||
}
|
||||
this.$store.dispatch('map/updateMapDevices', updatlist);
|
||||
}
|
||||
},
|
||||
trainNameFormatBy(mode) {
|
||||
switch (mode.toString()) {
|
||||
case '1': return 'serviceNumber:tripNumber'; // 表号+车次号
|
||||
case '2': return 'serviceNumber:groupNumber'; // 表号+车组号
|
||||
case '3': return 'targetCode:tripNumber'; // 目的地号+车次号
|
||||
case '4': return 'targetCode:groupNumber'; // 目的地号+车组号
|
||||
case '5': return 'targetCode:serviceNumber:tripNumber'; // 目的地号+表号+车次号
|
||||
case '6': return 'targetCode:serviceNumber:groupNumber'; // 目的地号+表号+车组号
|
||||
}
|
||||
|
||||
return ''; //无格式类型
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
return ''; // 无格式类型
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
@ -254,7 +254,7 @@ export const MenuDisabledState = {
|
||||
cancelDetainTrain() {
|
||||
const device = getCurrentStateObject();
|
||||
if (store.state.training.prdType == '02') {
|
||||
if (device && device.holdStatus == deviceState.StationStand.holdStatus.State03) {
|
||||
if (device && device.holdStatus != deviceState.StationStand.holdStatus.State03) {
|
||||
return true;
|
||||
}
|
||||
} else {
|
||||
|
11
src/main.js
11
src/main.js
@ -9,10 +9,12 @@ import 'element-ui/lib/theme-chalk/index.css';
|
||||
|
||||
import '@/styles/index.scss'; // global css
|
||||
|
||||
import Theme from '@/jmap/theme/factory';
|
||||
import LangStorage from '@/utils/lang';
|
||||
import App from './App';
|
||||
import VueI18n from 'vue-i18n';
|
||||
import store from './store';
|
||||
import router from './router';
|
||||
import Theme from '@/jmap/theme/factory';
|
||||
|
||||
import '@/icons'; // icon
|
||||
import '@/permission'; // permission control
|
||||
@ -20,13 +22,20 @@ import '@/scripts/GlobalPlugin';
|
||||
import '@/directives';
|
||||
|
||||
Vue.use(ElementUI);
|
||||
Vue.use(VueI18n);
|
||||
|
||||
Vue.config.productionTip = false;
|
||||
|
||||
const i18n = new VueI18n({
|
||||
locale: LangStorage.getLang('zh'),
|
||||
messages
|
||||
});
|
||||
|
||||
new Vue({
|
||||
el: '#app',
|
||||
router,
|
||||
store,
|
||||
i18n,
|
||||
render: h => h(App)
|
||||
});
|
||||
|
||||
|
@ -3,10 +3,10 @@ export function getBaseUrl() {
|
||||
let BASE_API;
|
||||
if (process.env.NODE_ENV === 'development') {
|
||||
// BASE_API = 'https://joylink.club/jlcloud';
|
||||
BASE_API = 'https://test.joylink.club/jlcloud';
|
||||
// BASE_API = 'http://192.168.3.5:9010' // 袁琪
|
||||
// BASE_API = 'http://192.168.3.6:9010'; // 旭强
|
||||
// BASE_API = 'http://192.168.3.4:9010' // 琰培
|
||||
// BASE_API = 'https://test.joylink.club/jlcloud';
|
||||
BASE_API = 'http://192.168.3.5:9000'; // 袁琪
|
||||
// BASE_API = 'http://192.168.3.6:9000'; // 旭强
|
||||
// BASE_API = 'http://192.168.3.4:9000' // 琰培
|
||||
} else {
|
||||
BASE_API = process.env.VUE_APP_BASE_API;
|
||||
}
|
||||
|
17
src/utils/lang.js
Normal file
17
src/utils/lang.js
Normal file
@ -0,0 +1,17 @@
|
||||
import Cookies from 'js-cookie';
|
||||
|
||||
const I18N_LANG = 'user_lang';
|
||||
export default {
|
||||
setLang(lang) {
|
||||
Cookies.set(I18N_LANG, lang);
|
||||
},
|
||||
getLang(defaultLang) {
|
||||
const localLang = Cookies.get(I18N_LANG);
|
||||
|
||||
if (localLang == null) {
|
||||
return defaultLang;
|
||||
} else {
|
||||
return localLang;
|
||||
}
|
||||
}
|
||||
};
|
@ -1,67 +1,75 @@
|
||||
<template>
|
||||
<el-dialog :title="title" :visible.sync="show" width="600px" :before-close="doClose" :zIndex="2000" :modal="false"
|
||||
:close-on-click-modal="false" v-dialogDrag>
|
||||
<div style="height: 80px; line-height: 80px; font-size: 16px; padding-left: 10px;">{{roomName}}邀请你加入综合演练!</div>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" @click="handleJoin">确认</el-button>
|
||||
<el-button @click="dialogShow = false">取 消</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
<el-dialog
|
||||
v-dialogDrag
|
||||
:title="title"
|
||||
:visible.sync="show"
|
||||
width="600px"
|
||||
:before-close="doClose"
|
||||
:z-index="2000"
|
||||
:modal="false"
|
||||
:close-on-click-modal="false"
|
||||
>
|
||||
<div style="height: 80px; line-height: 80px; font-size: 16px; padding-left: 10px;">{{ roomName }}邀请你加入综合演练!</div>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" @click="handleJoin">确认</el-button>
|
||||
<el-button @click="dialogShow = false">取 消</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getjointTraining, putJointTrainingSimulationEntrance } from '@/api/chat';
|
||||
import { getPublishMapInfo } from '@/api/jmap/map';
|
||||
import { launchFullscreen } from '@/utils/screen';
|
||||
import { getjointTraining, putJointTrainingSimulationEntrance } from '@/api/chat';
|
||||
import { getPublishMapInfo } from '@/api/jmap/map';
|
||||
import { launchFullscreen } from '@/utils/screen';
|
||||
|
||||
export default {
|
||||
name: 'DeomonList',
|
||||
data() {
|
||||
return {
|
||||
dialogShow: false,
|
||||
group: '',
|
||||
roomName: '',
|
||||
state: '',
|
||||
mapId: '',
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
show() {
|
||||
return this.dialogShow;
|
||||
},
|
||||
title() {
|
||||
return '综合演练快速入口';
|
||||
},
|
||||
},
|
||||
mounted() {
|
||||
},
|
||||
methods: {
|
||||
doShow(data) {
|
||||
this.roomName = data.creator.nickName;
|
||||
this.group = data.group;
|
||||
this.state = data.state
|
||||
this.mapId = data.mapId;
|
||||
this.dialogShow = true;
|
||||
},
|
||||
doClose() {
|
||||
this.dialogShow = false;
|
||||
},
|
||||
async handleJoin() {
|
||||
if (this.state == '02') {
|
||||
launchFullscreen();
|
||||
await putJointTrainingSimulationEntrance(this.group);
|
||||
let rest = await getPublishMapInfo(this.mapId);
|
||||
let query = { skinStyle: rest.data.skinStyle, mapId: this.mapId, group: this.group };
|
||||
this.$router.push({ path: `/jointTraining`, query: query });
|
||||
} else if (this.state == '01') {
|
||||
let query = { group: this.group };
|
||||
this.$router.push({ path: `/trainroom`, query: query });
|
||||
}
|
||||
this.dialogShow = false;
|
||||
getjointTraining(this.group);
|
||||
}
|
||||
}
|
||||
}
|
||||
export default {
|
||||
name: 'DeomonList',
|
||||
data() {
|
||||
return {
|
||||
dialogShow: false,
|
||||
group: '',
|
||||
roomName: '',
|
||||
state: '',
|
||||
mapId: ''
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
show() {
|
||||
return this.dialogShow;
|
||||
},
|
||||
title() {
|
||||
return '综合演练快速入口';
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
},
|
||||
methods: {
|
||||
doShow(data) {
|
||||
this.roomName = data.creator.nickName;
|
||||
this.group = data.group;
|
||||
this.state = data.state;
|
||||
this.mapId = data.mapId;
|
||||
this.dialogShow = true;
|
||||
},
|
||||
doClose() {
|
||||
this.dialogShow = false;
|
||||
},
|
||||
async handleJoin() {
|
||||
if (this.state == '02') {
|
||||
launchFullscreen();
|
||||
await putJointTrainingSimulationEntrance(this.group);
|
||||
const rest = await getPublishMapInfo(this.mapId);
|
||||
const query = { skinStyle: rest.data.skinStyle, mapId: this.mapId, group: this.group };
|
||||
this.$router.push({ path: `/jointTraining`, query: query });
|
||||
} else if (this.state == '01') {
|
||||
const query = { group: this.group };
|
||||
this.$router.push({ path: `/trainroom`, query: query });
|
||||
}
|
||||
this.dialogShow = false;
|
||||
getjointTraining(this.group);
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style rel="stylesheet/scss" lang="scss" scoped>
|
||||
@ -74,4 +82,4 @@
|
||||
background-color: #e4e3e3 !important;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
</style>
|
||||
|
@ -26,7 +26,7 @@
|
||||
@node-contextmenu="showContextMenu"
|
||||
@node-click="clickEvent"
|
||||
>
|
||||
<span slot-scope="{ node, data }" class="custom-tree-node">
|
||||
<span slot-scope="{ node }" class="custom-tree-node">
|
||||
<span
|
||||
v-if="node.data.type === 'lesson'"
|
||||
:class="node.data.valid? 'el-icon-sold-out':'el-icon-goods'"
|
||||
@ -50,7 +50,7 @@
|
||||
</el-card>
|
||||
</template>
|
||||
<script>
|
||||
import { getCourseLessonTree, getCourseLessonDetail } from '@/api/management/exam';
|
||||
import { getCourseLessonTree } from '@/api/management/exam';
|
||||
import { PermissionType } from '@/scripts/ConstDic';
|
||||
import { UrlConfig } from '@/router/index';
|
||||
import FilterCity from '@/views/components/filterCity';
|
||||
|
@ -16,7 +16,7 @@
|
||||
<el-form-item label="是否通过:" prop="detail">
|
||||
<span v-if="resultModel.result === '01'" style="color:darkgray">未计算</span>
|
||||
<span v-else-if="resultModel.result === '02'" style="color:green">通过</span>
|
||||
<span v-else="resultModel.result === '03'" style="color:red">未通过</span>
|
||||
<span v-else-if="resultModel.result === '03'" style="color:red">未通过</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="考试用时:" prop="detail">
|
||||
<span>{{ Math.ceil(resultModel.usedTime/60) + ' 分钟' }}</span>
|
||||
|
@ -1,156 +1,158 @@
|
||||
<template>
|
||||
<div class="plan-tool" style="width: 100%">
|
||||
<title-bar ref="titleBar"></title-bar>
|
||||
<menu-bar ref="menuBar" :skinStyle="skinStyle" :PlanConvert="PlanConvert" @dispatchDialog="dispatchDialog">
|
||||
</menu-bar>
|
||||
<schedule ref="schedule" :skinStyle="skinStyle" :PlanConvert="PlanConvert" :maxHeight="height"
|
||||
:maxWidth="width"></schedule>
|
||||
<status-bar ref="statusBar" :maxTop="height" @setPosition="setPosition"></status-bar>
|
||||
<div class="plan-tool" style="width: 100%">
|
||||
<title-bar ref="titleBar" />
|
||||
<menu-bar ref="menuBar" :skin-style="skinStyle" :plan-convert="PlanConvert" @dispatchDialog="dispatchDialog" />
|
||||
<schedule
|
||||
ref="schedule"
|
||||
:skin-style="skinStyle"
|
||||
:plan-convert="PlanConvert"
|
||||
:max-height="height"
|
||||
:max-width="width"
|
||||
/>
|
||||
<status-bar ref="statusBar" :max-top="height" @setPosition="setPosition" />
|
||||
|
||||
<open-run-plan ref="openRunPlan" :skin-style="skinStyle" @dispatchDialog="dispatchDialog" />
|
||||
<create-empty-plan ref="createEmptyPlan" @dispatchOperate="dispatchOperate" />
|
||||
<parameter ref="parameter" />
|
||||
<off-line ref="offLine" @handleConfirm="handleConfirm" @dispatchDialog="dispatchDialog" />
|
||||
<add-planning-train ref="addPlanningTrain" @dispatchDialog="dispatchDialog" />
|
||||
<edit-planning-train
|
||||
ref="editPlanningTrain"
|
||||
@dispatchDialog="dispatchDialog"
|
||||
@dispatchOperate="dispatchOperate"
|
||||
/>
|
||||
<edit-smooth-run-time ref="editSmoothRunTime" @dispatchDialog="dispatchDialog" />
|
||||
<add-smooth-run-time ref="addSmoothRunTime" @dispatchDialog="dispatchDialog" />
|
||||
<duplicate-train ref="duplicateTrain" @dispatchDialog="dispatchDialog" @dispatchOperate="dispatchOperate" />
|
||||
<modifying-routing ref="modifyingRouting" @dispatchDialog="dispatchDialog" />
|
||||
<modifying-begin-time ref="modifyingBeginTime" />
|
||||
|
||||
<open-run-plan ref="openRunPlan" :skinStyle="skinStyle" @dispatchDialog="dispatchDialog"> </open-run-plan>
|
||||
<create-empty-plan ref="createEmptyPlan" @dispatchOperate="dispatchOperate"></create-empty-plan>
|
||||
<parameter ref="parameter"></parameter>
|
||||
<off-line ref="offLine" @handleConfirm="handleConfirm" @dispatchDialog="dispatchDialog"></off-line>
|
||||
<add-planning-train ref="addPlanningTrain" @dispatchDialog="dispatchDialog"></add-planning-train>
|
||||
<edit-planning-train ref="editPlanningTrain" @dispatchDialog="dispatchDialog"
|
||||
@dispatchOperate="dispatchOperate"></edit-planning-train>
|
||||
<edit-smooth-run-time ref="editSmoothRunTime" @dispatchDialog="dispatchDialog"></edit-smooth-run-time>
|
||||
<add-smooth-run-time ref="addSmoothRunTime" @dispatchDialog="dispatchDialog"></add-smooth-run-time>
|
||||
<duplicate-train ref="duplicateTrain" @dispatchDialog="dispatchDialog" @dispatchOperate="dispatchOperate">
|
||||
</duplicate-train>
|
||||
<modifying-routing ref="modifyingRouting" @dispatchDialog="dispatchDialog"></modifying-routing>
|
||||
<modifying-begin-time ref="modifyingBeginTime"></modifying-begin-time>
|
||||
<systerm-out ref="systermOut" />
|
||||
<add-task ref="addTask" @dispatchOperate="dispatchOperate" />
|
||||
<delete-task ref="deleteTask" @dispatchOperate="dispatchOperate" />
|
||||
<modifying-task ref="modifyingTask" @dispatchOperate="dispatchOperate" />
|
||||
|
||||
<systerm-out ref="systermOut"></systerm-out>
|
||||
<add-task ref="addTask" @dispatchOperate="dispatchOperate"></add-task>
|
||||
<delete-task ref="deleteTask" @dispatchOperate="dispatchOperate"></delete-task>
|
||||
<modifying-task ref="modifyingTask" @dispatchOperate="dispatchOperate"></modifying-task>
|
||||
<edit-station-between-time ref="editStationBetweenTime" />
|
||||
|
||||
<edit-station-between-time ref="editStationBetweenTime"></edit-station-between-time>
|
||||
|
||||
<modifying-station-interval-time ref="modifyingStationIntervalTime"></modifying-station-interval-time>
|
||||
</div>
|
||||
<modifying-station-interval-time ref="modifyingStationIntervalTime" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import TitleBar from './titleBar';
|
||||
import MenuBar from './menuBar';
|
||||
import MenuTool from './menuTool';
|
||||
import StatusBar from './statusBar';
|
||||
import Schedule from './schedule';
|
||||
import OpenRunPlan from './menus/openRunPlan';
|
||||
import CreateEmptyPlan from './menus/createEmptyPlan';
|
||||
import Parameter from './menus/parameter/index';
|
||||
import OffLine from './menus/offLine';
|
||||
import AddPlanningTrain from './menus/addPlanningTrain';
|
||||
import EditPlanningTrain from './menus/editPlanningTrain';
|
||||
import DuplicateTrain from './menus/duplicateTrain';
|
||||
import SystermOut from './menus/systermOut';
|
||||
import AddTask from './menus/addTask';
|
||||
import DeleteTask from './menus/deleteTask'
|
||||
import ModifyingTask from './menus/modifyingTask';
|
||||
import ModifyingRouting from './menus/modifyingRouting'
|
||||
import ModifyingBeginTime from './menus/modifyingBeginTime';
|
||||
import EditStationBetweenTime from './menus/editStationBetweenTime';
|
||||
import AddSmoothRunTime from './menus/addSmoothRunTime';
|
||||
import EditSmoothRunTime from './menus/editSmoothRunTime';
|
||||
import ModifyingStationIntervalTime from './menus/modifyingStationIntervalTime';
|
||||
import WindowResizeHandler from '@/mixin/WindowResizeHandler';
|
||||
import { mapGetters } from 'vuex';
|
||||
import { deletePlanService } from '@/api/runplan';
|
||||
import TitleBar from './titleBar';
|
||||
import MenuBar from './menuBar';
|
||||
import StatusBar from './statusBar';
|
||||
import Schedule from './schedule';
|
||||
import OpenRunPlan from './menus/openRunPlan';
|
||||
import CreateEmptyPlan from './menus/createEmptyPlan';
|
||||
import Parameter from './menus/parameter/index';
|
||||
import OffLine from './menus/offLine';
|
||||
import AddPlanningTrain from './menus/addPlanningTrain';
|
||||
import EditPlanningTrain from './menus/editPlanningTrain';
|
||||
import DuplicateTrain from './menus/duplicateTrain';
|
||||
import SystermOut from './menus/systermOut';
|
||||
import AddTask from './menus/addTask';
|
||||
import DeleteTask from './menus/deleteTask';
|
||||
import ModifyingTask from './menus/modifyingTask';
|
||||
import ModifyingRouting from './menus/modifyingRouting';
|
||||
import ModifyingBeginTime from './menus/modifyingBeginTime';
|
||||
import EditStationBetweenTime from './menus/editStationBetweenTime';
|
||||
import AddSmoothRunTime from './menus/addSmoothRunTime';
|
||||
import EditSmoothRunTime from './menus/editSmoothRunTime';
|
||||
import ModifyingStationIntervalTime from './menus/modifyingStationIntervalTime';
|
||||
import WindowResizeHandler from '@/mixin/WindowResizeHandler';
|
||||
import { deletePlanService } from '@/api/runplan';
|
||||
|
||||
export default {
|
||||
name: 'Menus',
|
||||
mixins: [
|
||||
WindowResizeHandler
|
||||
],
|
||||
components: {
|
||||
TitleBar,
|
||||
MenuBar,
|
||||
MenuTool,
|
||||
StatusBar,
|
||||
Schedule,
|
||||
OpenRunPlan,
|
||||
CreateEmptyPlan,
|
||||
Parameter,
|
||||
OffLine,
|
||||
AddPlanningTrain,
|
||||
EditPlanningTrain,
|
||||
DuplicateTrain,
|
||||
SystermOut,
|
||||
AddTask,
|
||||
DeleteTask,
|
||||
ModifyingTask,
|
||||
ModifyingRouting,
|
||||
ModifyingBeginTime,
|
||||
EditStationBetweenTime,
|
||||
AddSmoothRunTime,
|
||||
EditSmoothRunTime,
|
||||
ModifyingStationIntervalTime
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
width: 0,
|
||||
height: 0,
|
||||
PlanConvert: {}
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
skinStyle() {
|
||||
return this.$route.query.skinStyle || '02';
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.PlanConvert = this.$theme.loadPlanConvert(this.skinStyle);
|
||||
|
||||
},
|
||||
methods: {
|
||||
resizeHandler() {
|
||||
this.width = this._clientWidth;
|
||||
this.height = this._clientHeight;
|
||||
},
|
||||
setPosition() {
|
||||
this.$nextTick(() => {
|
||||
this.$refs.schedule.setPosition();
|
||||
})
|
||||
},
|
||||
dispatchDialog(dialogObj) {
|
||||
this.$nextTick(() => {
|
||||
if (this.$refs[dialogObj.name]) {
|
||||
this.$refs[dialogObj.name].doShow(dialogObj.params);
|
||||
}
|
||||
})
|
||||
},
|
||||
dispatchOperate(operateObj) {
|
||||
this.$nextTick(() => {
|
||||
if (this.$refs[operateObj.dialogName]) {
|
||||
this.$refs[operateObj.dialogName][operateObj.operate](operateObj.params);
|
||||
}
|
||||
})
|
||||
},
|
||||
handleConfirm(params) {
|
||||
if (params.operate == 'AddPlanningTrain') {
|
||||
// 添加计划
|
||||
this.$refs.addPlanningTrain.handleConfirm();
|
||||
} else if (params.operate == 'DeletePlanningTrain') {
|
||||
// 删除计划
|
||||
let model = {
|
||||
planId: this.$route.query.planId,
|
||||
serviceNumber: params.serviceNumber
|
||||
}
|
||||
export default {
|
||||
name: 'Menus',
|
||||
components: {
|
||||
TitleBar,
|
||||
MenuBar,
|
||||
StatusBar,
|
||||
Schedule,
|
||||
OpenRunPlan,
|
||||
CreateEmptyPlan,
|
||||
Parameter,
|
||||
OffLine,
|
||||
AddPlanningTrain,
|
||||
EditPlanningTrain,
|
||||
DuplicateTrain,
|
||||
SystermOut,
|
||||
AddTask,
|
||||
DeleteTask,
|
||||
ModifyingTask,
|
||||
ModifyingRouting,
|
||||
ModifyingBeginTime,
|
||||
EditStationBetweenTime,
|
||||
AddSmoothRunTime,
|
||||
EditSmoothRunTime,
|
||||
ModifyingStationIntervalTime
|
||||
},
|
||||
mixins: [
|
||||
WindowResizeHandler
|
||||
],
|
||||
data() {
|
||||
return {
|
||||
width: 0,
|
||||
height: 0,
|
||||
PlanConvert: {}
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
skinStyle() {
|
||||
return this.$route.query.skinStyle || '02';
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.PlanConvert = this.$theme.loadPlanConvert(this.skinStyle);
|
||||
|
||||
deletePlanService(model).then(resp => {
|
||||
this.$message.success('删除计划成功');
|
||||
this.$store.dispatch('runPlan/setSelected', {});
|
||||
this.$refs.openRunPlan.loadRunPlanData(this.$route.query);
|
||||
}).catch(error => {
|
||||
this.$messageBox('删除计划失败');
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
resizeHandler() {
|
||||
this.width = this._clientWidth;
|
||||
this.height = this._clientHeight;
|
||||
},
|
||||
setPosition() {
|
||||
this.$nextTick(() => {
|
||||
this.$refs.schedule.setPosition();
|
||||
});
|
||||
},
|
||||
dispatchDialog(dialogObj) {
|
||||
this.$nextTick(() => {
|
||||
if (this.$refs[dialogObj.name]) {
|
||||
this.$refs[dialogObj.name].doShow(dialogObj.params);
|
||||
}
|
||||
});
|
||||
},
|
||||
dispatchOperate(operateObj) {
|
||||
this.$nextTick(() => {
|
||||
if (this.$refs[operateObj.dialogName]) {
|
||||
this.$refs[operateObj.dialogName][operateObj.operate](operateObj.params);
|
||||
}
|
||||
});
|
||||
},
|
||||
handleConfirm(params) {
|
||||
if (params.operate == 'AddPlanningTrain') {
|
||||
// 添加计划
|
||||
this.$refs.addPlanningTrain.handleConfirm();
|
||||
} else if (params.operate == 'DeletePlanningTrain') {
|
||||
// 删除计划
|
||||
const model = {
|
||||
planId: this.$route.query.planId,
|
||||
serviceNumber: params.serviceNumber
|
||||
};
|
||||
|
||||
deletePlanService(model).then(resp => {
|
||||
this.$message.success('删除计划成功');
|
||||
this.$store.dispatch('runPlan/setSelected', {});
|
||||
this.$refs.openRunPlan.loadRunPlanData(this.$route.query);
|
||||
}).catch(() => {
|
||||
this.$messageBox('删除计划失败');
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style>
|
||||
@ -185,7 +187,6 @@
|
||||
font-size: x-large;
|
||||
}
|
||||
|
||||
|
||||
.planEdit__tool {
|
||||
overflow: hidden !important;
|
||||
}
|
||||
@ -318,7 +319,6 @@
|
||||
margin-top: 10px;
|
||||
}
|
||||
|
||||
|
||||
.planEdit__tool .el-dialog .el-input {
|
||||
border: 2px inset #E9E9E9;
|
||||
}
|
||||
@ -484,4 +484,4 @@
|
||||
background: #E9E9E9 !important;
|
||||
color: #000 !important;
|
||||
}
|
||||
</style>
|
||||
</style>
|
||||
|
@ -3,23 +3,23 @@
|
||||
<div class="nav">
|
||||
<template v-for="(item,i) in menus">
|
||||
<template v-if="noShowingChildren(item.children)">
|
||||
<li class="nav-li" @click="hookClick(item)">
|
||||
<li :key="i" class="nav-li" @click="hookClick(item)">
|
||||
<span class="nav-li-text">{{ item.title }}</span>
|
||||
</li>
|
||||
</template>
|
||||
<template v-else>
|
||||
<li class="nav-li" @click.stop="popupMenuA(item, i)">
|
||||
<li :key="i" class="nav-li" @click.stop="popupMenuA(item, i)">
|
||||
<span class="nav-li-text">{{ item.title }}</span>
|
||||
<ul class="nav-ul" :class="{'active' :i==classA}">
|
||||
<template v-for="(child,j) in item.children">
|
||||
<template
|
||||
v-if="child.children&&child.children.length>0&&hasShowingChildren(child.children)"
|
||||
>
|
||||
<li v-if="child.type === 'separator'" class="menu-separator">
|
||||
<li v-if="child.type === 'separator'" :key="j" class="menu-separator">
|
||||
<span class="status"> </span>
|
||||
<span class="separator"> </span>
|
||||
</li>
|
||||
<li v-else-if="child.type === 'file'" class="menu-li">
|
||||
<li v-else-if="child.type === 'file'" :key="j" class="menu-li">
|
||||
<div class="menu-li-block" :disabled="child.disabled">
|
||||
<span class="menu-li-text">
|
||||
<span class="status"> </span>
|
||||
@ -35,7 +35,7 @@
|
||||
</span>
|
||||
</div>
|
||||
</li>
|
||||
<li v-else class="menu-li" @click.stop="popupMenuB(child, j)">
|
||||
<li v-else :key="j" class="menu-li" @click.stop="popupMenuB(child, j)">
|
||||
<div class="menu-li-block" :disabled="child.disabled">
|
||||
<span class="menu-li-text">
|
||||
<span class="status"> </span>
|
||||
@ -44,11 +44,11 @@
|
||||
</div>
|
||||
<ul class="menu-ul" :class="{'active' :j==classB}">
|
||||
<template v-for="(grandchild,k) in child.children">
|
||||
<li v-if="grandchild.type === 'separator'" class="menu-separator">
|
||||
<li v-if="grandchild.type === 'separator'" :key="k" class="menu-separator">
|
||||
<span class="status"> </span>
|
||||
<span class="separator"> </span>
|
||||
</li>
|
||||
<li v-else-if="grandchild.type === 'file'" class="menu-li">
|
||||
<li v-else-if="grandchild.type === 'file'" :key="k" class="menu-li">
|
||||
<div class="menu-li-block" :disabled="grandchild.disabled">
|
||||
<span class="menu-li-text">
|
||||
<span class="status"> </span>
|
||||
@ -68,7 +68,7 @@
|
||||
</span>
|
||||
</div>
|
||||
</li>
|
||||
<li v-else class="menu-li" @click.stop="hookClick(grandchild)">
|
||||
<li v-else :key="k" class="menu-li" @click.stop="hookClick(grandchild)">
|
||||
<div class="menu-li-block" :disabled="grandchild.disabled">
|
||||
<span class="menu-li-text">
|
||||
<span class="status"> </span>
|
||||
@ -81,11 +81,11 @@
|
||||
</li>
|
||||
</template>
|
||||
<template v-else>
|
||||
<li v-if="child.type === 'separator'" class="menu-separator">
|
||||
<li v-if="child.type === 'separator'" :key="j" class="menu-separator">
|
||||
<span class="status"> </span>
|
||||
<span class="separator"> </span>
|
||||
</li>
|
||||
<li v-else-if="child.type === 'file'" class="menu-li">
|
||||
<li v-else-if="child.type === 'file'" :key="j" class="menu-li">
|
||||
<div class="menu-li-block" :disabled="child.disabled">
|
||||
<span class="menu-li-text">
|
||||
<span class="status"> </span>
|
||||
@ -101,7 +101,7 @@
|
||||
</span>
|
||||
</div>
|
||||
</li>
|
||||
<li v-else class="menu-li" @click.stop="hookClick(child)">
|
||||
<li v-else :key="j" class="menu-li" @click.stop="hookClick(child)">
|
||||
<div class="menu-li-block" :disabled="child.disabled">
|
||||
<span class="menu-li-text">
|
||||
<span class="status"> </span>
|
||||
|
@ -1,64 +1,64 @@
|
||||
<template>
|
||||
<div class="app-wrapper">
|
||||
<el-scrollbar wrapClass="scrollbar-wrapper">
|
||||
<div class="map-list" v-show="listShow" :style="{width: widthLeft+'px'}">
|
||||
<plan-list ref="planList" :height="height"></plan-list>
|
||||
</div>
|
||||
<drap-left :widthLeft="widthLeft" @drapWidth="drapWidth"></drap-left>
|
||||
<transition>
|
||||
<router-view></router-view>
|
||||
</transition>
|
||||
</el-scrollbar>
|
||||
</div>
|
||||
<div class="app-wrapper">
|
||||
<el-scrollbar wrap-class="scrollbar-wrapper">
|
||||
<div v-show="listShow" class="map-list" :style="{width: widthLeft+'px'}">
|
||||
<plan-list ref="planList" :height="height" />
|
||||
</div>
|
||||
<drap-left :width-left="widthLeft" @drapWidth="drapWidth" />
|
||||
<transition>
|
||||
<router-view />
|
||||
</transition>
|
||||
</el-scrollbar>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { mapGetters } from 'vuex';
|
||||
import planList from './planmanage/planList';
|
||||
import WindowResizeHandler from '@/mixin/WindowResizeHandler';
|
||||
import drapLeft from '@/views/components/drapLeft/index';
|
||||
import localStore from 'storejs';
|
||||
import { mapGetters } from 'vuex';
|
||||
import planList from './planmanage/planList';
|
||||
import WindowResizeHandler from '@/mixin/WindowResizeHandler';
|
||||
import drapLeft from '@/views/components/drapLeft/index';
|
||||
import localStore from 'storejs';
|
||||
|
||||
export default {
|
||||
name: 'Exam',
|
||||
components: {
|
||||
planList,
|
||||
drapLeft
|
||||
},
|
||||
mixins: [WindowResizeHandler],
|
||||
data() {
|
||||
return {
|
||||
height: 0,
|
||||
listShow: true,
|
||||
widthLeft: 450,
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
...mapGetters([
|
||||
'lessonbar',
|
||||
])
|
||||
},
|
||||
watch: {
|
||||
'lessonbar.opened': function (val) {
|
||||
this.listShow = val;
|
||||
this.resizeHandler();
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.widthLeft = Number(localStore.get('LeftWidth'));
|
||||
},
|
||||
methods: {
|
||||
resizeHandler() {
|
||||
this.height = this._clientHeight;
|
||||
},
|
||||
refresh() {
|
||||
this.$refs && this.$refs.planList && this.$refs.planList.refresh();
|
||||
},
|
||||
drapWidth(width) {
|
||||
this.widthLeft = Number(width);
|
||||
}
|
||||
}
|
||||
}
|
||||
export default {
|
||||
name: 'Exam',
|
||||
components: {
|
||||
planList,
|
||||
drapLeft
|
||||
},
|
||||
mixins: [WindowResizeHandler],
|
||||
data() {
|
||||
return {
|
||||
height: 0,
|
||||
listShow: true,
|
||||
widthLeft: 450
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
...mapGetters([
|
||||
'lessonbar'
|
||||
])
|
||||
},
|
||||
watch: {
|
||||
'lessonbar.opened': function (val) {
|
||||
this.listShow = val;
|
||||
this.resizeHandler();
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.widthLeft = Number(localStore.get('LeftWidth'));
|
||||
},
|
||||
methods: {
|
||||
resizeHandler() {
|
||||
this.height = this._clientHeight;
|
||||
},
|
||||
refresh() {
|
||||
this.$refs && this.$refs.planList && this.$refs.planList.refresh();
|
||||
},
|
||||
drapWidth(width) {
|
||||
this.widthLeft = Number(width);
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
<style rel="stylesheet/scss" lang="scss" scoped>
|
||||
@import "src/styles/mixin.scss";
|
||||
@ -74,4 +74,4 @@
|
||||
.map-list {
|
||||
float: left;
|
||||
}
|
||||
</style>
|
||||
</style>
|
||||
|
Loading…
Reference in New Issue
Block a user