Merge remote-tracking branch 'origin/test'
This commit is contained in:
commit
c33c50005c
@ -4,3 +4,6 @@ English | [简体中文](./README-zh.md)
|
|||||||
|
|
||||||
|
|
||||||
Copyright (c) 2018-present Joylink
|
Copyright (c) 2018-present Joylink
|
||||||
|
### 项目环境
|
||||||
|
- "node": "<=14.21.3";
|
||||||
|
- "webpack": ">=4 < 4.29";
|
Binary file not shown.
Before Width: | Height: | Size: 4.8 KiB After Width: | Height: | Size: 6.3 KiB |
@ -396,7 +396,7 @@ export function JobPaneData() {
|
|||||||
],
|
],
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name:"电力调度",
|
name:"工电调度",
|
||||||
value:"dldd",
|
value:"dldd",
|
||||||
text:"负责供电系统的正常运行。",
|
text:"负责供电系统的正常运行。",
|
||||||
picurl:"",
|
picurl:"",
|
||||||
|
@ -425,6 +425,10 @@ export default class Train extends Group {
|
|||||||
// 西安二号线 列车停车状态 闪烁红色
|
// 西安二号线 列车停车状态 闪烁红色
|
||||||
this.updateTrainBodyFault(model.orderStop);
|
this.updateTrainBodyFault(model.orderStop);
|
||||||
}
|
}
|
||||||
|
if (!model.groundCommunicable) {
|
||||||
|
this.trainL && this.trainL.setColor('#f00');
|
||||||
|
this.trainR && this.trainR.setColor('#f00');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
setTrainTypeColor(type) {
|
setTrainTypeColor(type) {
|
||||||
|
@ -48,7 +48,8 @@ export default class EMouse extends Group {
|
|||||||
e.target._subType == 'Text') {
|
e.target._subType == 'Text') {
|
||||||
this.text.hide();
|
this.text.hide();
|
||||||
} else {
|
} else {
|
||||||
this.device.control.setControlColor(this.device.style.ZcControl.lamp.controlColor);
|
// this.device.control.setControlColor(this.device.style.ZcControl.lamp.controlColor);
|
||||||
|
this.device.setState(this.device.model)
|
||||||
this.device.control.setTextColor('#FFFFFF');
|
this.device.control.setTextColor('#FFFFFF');
|
||||||
this.device.control.setTextBorder(false);
|
this.device.control.setTextBorder(false);
|
||||||
this.device.control.setArcBorder(false);
|
this.device.control.setArcBorder(false);
|
||||||
|
@ -73,7 +73,6 @@ export default class ZcControl extends Group {
|
|||||||
// 设置状态
|
// 设置状态
|
||||||
setState(model) {
|
setState(model) {
|
||||||
this.recover();
|
this.recover();
|
||||||
|
|
||||||
// 只响应前端自定义类型的状态变化
|
// 只响应前端自定义类型的状态变化
|
||||||
if (model._free) {
|
if (model._free) {
|
||||||
this.setAshShow();
|
this.setAshShow();
|
||||||
|
@ -13,6 +13,7 @@ import SetTrainOperation from '@/jmapNew/theme/components/menus/dialog/setTrainO
|
|||||||
import NoticeInfo from '@/jmapNew/theme/components/menus/childDialog/noticeInfo';
|
import NoticeInfo from '@/jmapNew/theme/components/menus/childDialog/noticeInfo';
|
||||||
import SetFault from '@/jmapNew/theme/components/menus/dialog/setFault';
|
import SetFault from '@/jmapNew/theme/components/menus/dialog/setFault';
|
||||||
import { DeviceMenu } from '@/scripts/ConstDic';
|
import { DeviceMenu } from '@/scripts/ConstDic';
|
||||||
|
import CMD from '@/scripts/cmdPlugin/CommandEnum';
|
||||||
export default {
|
export default {
|
||||||
name: 'MenuTrain',
|
name: 'MenuTrain',
|
||||||
components: {
|
components: {
|
||||||
@ -87,6 +88,31 @@ export default {
|
|||||||
{
|
{
|
||||||
label: '回库',
|
label: '回库',
|
||||||
handler: this.setInbound
|
handler: this.setInbound
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '受电弓操作',
|
||||||
|
children: [
|
||||||
|
{
|
||||||
|
label: '受电弓1升',
|
||||||
|
handler: this.pantogrphOneUp,
|
||||||
|
cmdType: CMD.Driver.CMD_SPECIAL_PANTOGRAPH_UP_DOWN
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '受电弓1降',
|
||||||
|
handler: this.pantogrphOneDown,
|
||||||
|
cmdType: CMD.Driver.CMD_SPECIAL_PANTOGRAPH_UP_DOWN
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '受电弓2升',
|
||||||
|
handler: this.pantogrphTwoUp,
|
||||||
|
cmdType: CMD.Driver.CMD_SPECIAL_PANTOGRAPH_UP_DOWN
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '受电弓2降',
|
||||||
|
handler: this.pantogrphTwoDown,
|
||||||
|
cmdType: CMD.Driver.CMD_SPECIAL_PANTOGRAPH_UP_DOWN
|
||||||
|
}
|
||||||
|
]
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
@ -211,6 +237,34 @@ export default {
|
|||||||
this.$refs.popMenu.close();
|
this.$refs.popMenu.close();
|
||||||
// this.$store.dispatch('map/setTrainWindowShow', false);
|
// this.$store.dispatch('map/setTrainWindowShow', false);
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
pantogrphOneUp() {
|
||||||
|
commitOperate(menuOperate.Driver.specialPantographUpDown, { index: 1, up: true, groupNumber: this.selected.code }, 3).then(({valid, operate}) => {
|
||||||
|
}).catch((error)=> {
|
||||||
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
|
});
|
||||||
|
},
|
||||||
|
pantogrphOneDown() {
|
||||||
|
commitOperate(menuOperate.Driver.specialPantographUpDown, { index: 1, up: false, groupNumber: this.selected.code }, 3).then(({valid, operate}) => {
|
||||||
|
}).catch((error)=> {
|
||||||
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
|
});
|
||||||
|
},
|
||||||
|
pantogrphTwoUp() {
|
||||||
|
commitOperate(menuOperate.Driver.specialPantographUpDown, { index: 2, up: true, groupNumber: this.selected.code }, 3).then(({valid, operate}) => {
|
||||||
|
}).catch((error)=> {
|
||||||
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
|
});
|
||||||
|
},
|
||||||
|
pantogrphTwoDown() {
|
||||||
|
commitOperate(menuOperate.Driver.specialPantographUpDown, { index: 2, up: false, groupNumber: this.selected.code }, 3).then(({valid, operate}) => {
|
||||||
|
}).catch((error)=> {
|
||||||
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -1,19 +1,34 @@
|
|||||||
import store from '@/store/index';
|
import store from "@/store/index";
|
||||||
/**
|
/**
|
||||||
* 判断菜单行值控制全
|
* 判断菜单行值控制全
|
||||||
* @param {String} stationCode 所属车站code
|
* @param {String} stationCode 所属车站code
|
||||||
* @param {String} centralStationCode 所属集中站code
|
* @param {String} centralStationCode 所属集中站code
|
||||||
* @param {String} work 当前客户端
|
* @param {String} work 当前客户端
|
||||||
* */
|
* */
|
||||||
export function judgeStationControl(stationCode, centralStationCode, work) {
|
export function judgeStationControl(
|
||||||
const centralStation = store.getters['map/getDeviceByCode'](centralStationCode);
|
stationCode,
|
||||||
|
centralStationCode,
|
||||||
|
work,
|
||||||
|
isAvailableInOtherControlMode
|
||||||
|
) {
|
||||||
|
const centralStation = store.getters["map/getDeviceByCode"](
|
||||||
|
centralStationCode
|
||||||
|
);
|
||||||
|
const isCenterMode = centralStation.controlMode === "Center";
|
||||||
|
const isLocalMode =
|
||||||
|
centralStation.controlMode === "Local" ||
|
||||||
|
centralStation.controlMode === "Emergency";
|
||||||
// 角色车站是 设备所属车站或所属集中站
|
// 角色车站是 设备所属车站或所属集中站
|
||||||
if (work === 'localWork') {
|
if (work === "localWork") {
|
||||||
const flag1 = store.state.training.roleDeviceCode === stationCode || store.state.training.roleDeviceCode === centralStationCode;
|
const isBelongingStation =
|
||||||
const flag2 = centralStation.controlMode === 'Local' || centralStation.controlMode === 'Emergency';
|
store.state.training.roleDeviceCode === stationCode ||
|
||||||
return flag1 && flag2;
|
store.state.training.roleDeviceCode === centralStationCode;
|
||||||
} else if ( work === 'dispatchWork' ) {
|
return (
|
||||||
return centralStation.controlMode === 'Center';
|
((isCenterMode && isAvailableInOtherControlMode) || isLocalMode) &&
|
||||||
|
isBelongingStation
|
||||||
|
);
|
||||||
|
} else if (work === "dispatchWork") {
|
||||||
|
return isCenterMode || (isLocalMode && isAvailableInOtherControlMode);
|
||||||
} else {
|
} else {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@ -631,6 +631,10 @@ export const menuOperate = {
|
|||||||
takeOver: {
|
takeOver: {
|
||||||
operation: OperationEvent.Driver.takeOver.menu.operation,
|
operation: OperationEvent.Driver.takeOver.menu.operation,
|
||||||
cmdType: CMD.Driver.CMD_DRIVER_TAKEOVER
|
cmdType: CMD.Driver.CMD_DRIVER_TAKEOVER
|
||||||
|
},
|
||||||
|
specialPantographUpDown: {
|
||||||
|
operation: OperationEvent.Driver.pantograph.menu.operation,
|
||||||
|
cmdType: CMD.Driver.CMD_SPECIAL_PANTOGRAPH_UP_DOWN
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
CTC: {
|
CTC: {
|
||||||
|
@ -132,7 +132,9 @@ export default {
|
|||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
|
if (!this.$store.state.trainingNew.trainingSwitch) {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
|
}
|
||||||
this.$refs.noticeInfo.doShow();
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -220,7 +220,9 @@ export default {
|
|||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
|
if (!this.$store.state.trainingNew.trainingSwitch) {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
|
}
|
||||||
this.$refs.noticeInfo.doShow();
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -117,7 +117,9 @@ export default {
|
|||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
|
if (!this.$store.state.trainingNew.trainingSwitch) {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
|
}
|
||||||
this.$refs.noticeInfo.doShow();
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
@ -137,7 +137,9 @@ export default {
|
|||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
|
if (!this.$store.state.trainingNew.trainingSwitch) {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
|
}
|
||||||
this.$refs.noticeInfo.doShow();
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
@ -212,7 +212,9 @@ export default {
|
|||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
|
if (!this.$store.state.trainingNew.trainingSwitch) {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
|
}
|
||||||
this.$refs.noticeInfo.doShow();
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
@ -156,7 +156,9 @@ export default {
|
|||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
|
if (!this.$store.state.trainingNew.trainingSwitch) {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
|
}
|
||||||
this.$refs.noticeInfo.doShow();
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
|
@ -285,7 +285,9 @@ export default {
|
|||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
|
if (!this.$store.state.trainingNew.trainingSwitch) {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
|
}
|
||||||
this.$refs.noticeInfo.doShow();
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -142,7 +142,9 @@ export default {
|
|||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
|
if (!this.$store.state.trainingNew.trainingSwitch) {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
|
}
|
||||||
this.$refs.noticeInfo.doShow();
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
@ -140,7 +140,9 @@ export default {
|
|||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
|
if (!this.$store.state.trainingNew.trainingSwitch) {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
|
}
|
||||||
this.$refs.noticeInfo.doShow();
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
|
@ -142,7 +142,9 @@ export default {
|
|||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
|
if (!this.$store.state.trainingNew.trainingSwitch) {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
|
}
|
||||||
this.$refs.noticeInfo.doShow();
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
@ -149,7 +149,9 @@ export default {
|
|||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
|
if (!this.$store.state.trainingNew.trainingSwitch) {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
|
}
|
||||||
this.$refs.noticeInfo.doShow();
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
@ -169,7 +169,9 @@ export default {
|
|||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
|
if (!this.$store.state.trainingNew.trainingSwitch) {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
|
}
|
||||||
this.$refs.noticeInfo.doShow();
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
@ -106,7 +106,9 @@ export default {
|
|||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
|
if (!this.$store.state.trainingNew.trainingSwitch) {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
|
}
|
||||||
this.$refs.noticeInfo.doShow();
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
@ -137,7 +137,9 @@ export default {
|
|||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
|
if (!this.$store.state.trainingNew.trainingSwitch) {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
|
}
|
||||||
this.$refs.noticeInfo.doShow();
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
@ -152,7 +152,9 @@ export default {
|
|||||||
this.doClose();
|
this.doClose();
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
|
if (!this.$store.state.trainingNew.trainingSwitch) {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
|
}
|
||||||
this.$refs.noticeInfo.doShow();
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
@ -147,7 +147,7 @@ export default {
|
|||||||
updateTableValue(controlTransfer) {
|
updateTableValue(controlTransfer) {
|
||||||
this.concertrateStationList.forEach((row, index) => {
|
this.concertrateStationList.forEach((row, index) => {
|
||||||
if (row.code == controlTransfer.code) {
|
if (row.code == controlTransfer.code) {
|
||||||
if (controlTransfer.applicantId) {
|
if (controlTransfer.applicantId && this.$store.state.training.roles !== 'DISPATCHER') {
|
||||||
this.disabledCommit = true;
|
this.disabledCommit = true;
|
||||||
} else {
|
} else {
|
||||||
this.disabledCommit = false;
|
this.disabledCommit = false;
|
||||||
|
@ -64,14 +64,16 @@ export default {
|
|||||||
handler: this.arrangementRoute,
|
handler: this.arrangementRoute,
|
||||||
cmdType: CMD.Signal.CMD_SIGNAL_SET_ROUTE,
|
cmdType: CMD.Signal.CMD_SIGNAL_SET_ROUTE,
|
||||||
isDisabled: (signal, work) => false,
|
isDisabled: (signal, work) => false,
|
||||||
isShow: (signal, work) => true
|
isShow: (signal, work) => true,
|
||||||
|
isAvailableInOtherControlMode: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: '取消进路',
|
label: '取消进路',
|
||||||
handler: this.cancelTrainRoute,
|
handler: this.cancelTrainRoute,
|
||||||
cmdType: CMD.Signal.CMD_SIGNAL_CANCEL_ROUTE,
|
cmdType: CMD.Signal.CMD_SIGNAL_CANCEL_ROUTE,
|
||||||
isDisabled: (signal, work) => false,
|
isDisabled: (signal, work) => false,
|
||||||
isShow: (signal, work) => true
|
isShow: (signal, work) => true,
|
||||||
|
isAvailableInOtherControlMode: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: '信号重开',
|
label: '信号重开',
|
||||||
@ -127,14 +129,16 @@ export default {
|
|||||||
handler: this.humanControl,
|
handler: this.humanControl,
|
||||||
cmdType: CMD.Signal.CMD_SIGNAL_CLOSE_AUTO_SETTING,
|
cmdType: CMD.Signal.CMD_SIGNAL_CLOSE_AUTO_SETTING,
|
||||||
isDisabled: (signal, work) => false,
|
isDisabled: (signal, work) => false,
|
||||||
isShow: (signal, work) => true
|
isShow: (signal, work) => true,
|
||||||
|
isAvailableInOtherControlMode: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: '进路自排开',
|
label: '进路自排开',
|
||||||
handler: this.atsAutoControl,
|
handler: this.atsAutoControl,
|
||||||
cmdType: CMD.Signal.CMD_SIGNAL_OPEN_AUTO_SETTING,
|
cmdType: CMD.Signal.CMD_SIGNAL_OPEN_AUTO_SETTING,
|
||||||
isDisabled: (signal, work) => false,
|
isDisabled: (signal, work) => false,
|
||||||
isShow: (signal, work) => true
|
isShow: (signal, work) => true,
|
||||||
|
isAvailableInOtherControlMode: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: '设置通过模式',
|
label: '设置通过模式',
|
||||||
@ -206,7 +210,7 @@ export default {
|
|||||||
initMenu() {
|
initMenu() {
|
||||||
this.menu = [];
|
this.menu = [];
|
||||||
this.menuNormal.forEach(menuItem => {
|
this.menuNormal.forEach(menuItem => {
|
||||||
menuItem.disabled = !judgeStationControl(this.selected.belongStationCode, this.selected.stationCode, this.work) || menuItem.isDisabled(this.selected, this.work);
|
menuItem.disabled = !judgeStationControl(this.selected.belongStationCode, this.selected.stationCode, this.work, menuItem.isAvailableInOtherControlMode) || menuItem.isDisabled(this.selected, this.work);
|
||||||
menuItem.show = menuItem.isShow(this.selected, this.work);
|
menuItem.show = menuItem.isShow(this.selected, this.work);
|
||||||
this.menu.push(menuItem);
|
this.menu.push(menuItem);
|
||||||
});
|
});
|
||||||
|
@ -70,7 +70,7 @@ export default {
|
|||||||
label: '取消扣车',
|
label: '取消扣车',
|
||||||
handler: this.cancelDetainTrain,
|
handler: this.cancelDetainTrain,
|
||||||
cmdType:CMD.Stand.CMD_STAND_CANCEL_HOLD_TRAIN,
|
cmdType:CMD.Stand.CMD_STAND_CANCEL_HOLD_TRAIN,
|
||||||
isDisabled: (stand, work) => stand.stationHoldTrain === 1,
|
isDisabled: (stand, work) => stand.stationHoldTrain !== 1,
|
||||||
isShow: (stand, work) => work === 'localWork'
|
isShow: (stand, work) => work === 'localWork'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -84,7 +84,7 @@ export default {
|
|||||||
label: '取消扣车',
|
label: '取消扣车',
|
||||||
handler: this.cancelDetainTrain,
|
handler: this.cancelDetainTrain,
|
||||||
cmdType:CMD.Stand.CMD_STAND_CANCEL_HOLD_TRAIN,
|
cmdType:CMD.Stand.CMD_STAND_CANCEL_HOLD_TRAIN,
|
||||||
isDisabled: (stand, work) => stand.centerHoldTrain === 1,
|
isDisabled: (stand, work) => stand.centerHoldTrain !== 1,
|
||||||
isShow: (stand, work) => work === 'dispatchWork'
|
isShow: (stand, work) => work === 'dispatchWork'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -226,6 +226,31 @@ export default {
|
|||||||
handler: this.handlerApplyRmMode
|
handler: this.handlerApplyRmMode
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '受电弓操作',
|
||||||
|
children: [
|
||||||
|
{
|
||||||
|
label: '受电弓1升',
|
||||||
|
handler: this.pantogrphOneUp,
|
||||||
|
cmdType: CMD.Driver.CMD_SPECIAL_PANTOGRAPH_UP_DOWN
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '受电弓1降',
|
||||||
|
handler: this.pantogrphOneDown,
|
||||||
|
cmdType: CMD.Driver.CMD_SPECIAL_PANTOGRAPH_UP_DOWN
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '受电弓2升',
|
||||||
|
handler: this.pantogrphTwoUp,
|
||||||
|
cmdType: CMD.Driver.CMD_SPECIAL_PANTOGRAPH_UP_DOWN
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '受电弓2降',
|
||||||
|
handler: this.pantogrphTwoDown,
|
||||||
|
cmdType: CMD.Driver.CMD_SPECIAL_PANTOGRAPH_UP_DOWN
|
||||||
|
}
|
||||||
|
]
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
menuSpeed: [
|
menuSpeed: [
|
||||||
@ -586,6 +611,34 @@ export default {
|
|||||||
this.$refs.trainSetWorkATP.doShow(operate, this.selected);
|
this.$refs.trainSetWorkATP.doShow(operate, this.selected);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
},
|
||||||
|
pantogrphOneUp() {
|
||||||
|
commitOperate(menuOperate.Driver.specialPantographUpDown, { index: 1, up: true, groupNumber: this.selected.code }, 3).then(({valid, operate}) => {
|
||||||
|
}).catch((error)=> {
|
||||||
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
|
});
|
||||||
|
},
|
||||||
|
pantogrphOneDown() {
|
||||||
|
commitOperate(menuOperate.Driver.specialPantographUpDown, { index: 1, up: false, groupNumber: this.selected.code }, 3).then(({valid, operate}) => {
|
||||||
|
}).catch((error)=> {
|
||||||
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
|
});
|
||||||
|
},
|
||||||
|
pantogrphTwoUp() {
|
||||||
|
commitOperate(menuOperate.Driver.specialPantographUpDown, { index: 2, up: true, groupNumber: this.selected.code }, 3).then(({valid, operate}) => {
|
||||||
|
}).catch((error)=> {
|
||||||
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
|
});
|
||||||
|
},
|
||||||
|
pantogrphTwoDown() {
|
||||||
|
commitOperate(menuOperate.Driver.specialPantographUpDown, { index: 2, up: false, groupNumber: this.selected.code }, 3).then(({valid, operate}) => {
|
||||||
|
}).catch((error)=> {
|
||||||
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -61,7 +61,7 @@ export default {
|
|||||||
{ label: '司机', value: 'DRIVER', enLabel: 'Driver ' },
|
{ label: '司机', value: 'DRIVER', enLabel: 'Driver ' },
|
||||||
{ label: '通号', value: 'MAINTAINER', enLabel: 'Repairman ' },
|
{ label: '通号', value: 'MAINTAINER', enLabel: 'Repairman ' },
|
||||||
{ label: '车辆段/停车场调度', value: 'DEPOT_DISPATCHER', enLabel: 'Depot dispatcher ' },
|
{ label: '车辆段/停车场调度', value: 'DEPOT_DISPATCHER', enLabel: 'Depot dispatcher ' },
|
||||||
{ label: '电力调度', value: 'ELECTRIC_DISPATCHER', enLabel: 'Electric dispatcher' },
|
{ label: '工电调度', value: 'ELECTRIC_DISPATCHER', enLabel: 'Electric dispatcher' },
|
||||||
{ label: '电力工务', value: 'STATION_ELECTRIC_WORKER', enLabel: 'Station electric worker' },
|
{ label: '电力工务', value: 'STATION_ELECTRIC_WORKER', enLabel: 'Station electric worker' },
|
||||||
{ label: '行调', value: 'DISPATCHER', enLabel: 'Dispatcher ' },
|
{ label: '行调', value: 'DISPATCHER', enLabel: 'Dispatcher ' },
|
||||||
{ label: '上级部门', value: 'PARENT_DEPARTMENT', enLabel: 'Parent department' },
|
{ label: '上级部门', value: 'PARENT_DEPARTMENT', enLabel: 'Parent department' },
|
||||||
|
@ -104,7 +104,8 @@ export default {
|
|||||||
CMD_INBOUND: {value: 'Inbound', label: '回库'},
|
CMD_INBOUND: {value: 'Inbound', label: '回库'},
|
||||||
CMD_CHANGE_PRESELECTION_MODE: {value: 'Change_Preselection_Mode', label: '修改预选模式'},
|
CMD_CHANGE_PRESELECTION_MODE: {value: 'Change_Preselection_Mode', label: '修改预选模式'},
|
||||||
CMD_APPLY_NRM: {value: 'Apply_NRM', label: '转NRM模式'},
|
CMD_APPLY_NRM: {value: 'Apply_NRM', label: '转NRM模式'},
|
||||||
CMD_DRIVER_TAKEOVER: {value: 'Driver_TakeOver', label: '接管开关'}
|
CMD_DRIVER_TAKEOVER: {value: 'Driver_TakeOver', label: '接管开关'},
|
||||||
|
CMD_SPECIAL_PANTOGRAPH_UP_DOWN: { value: 'Special_Pantograph_Up_Down', label: '受电弓升降' }
|
||||||
// CMD_DEPART_TRAIN: {value: 'Depart_Train', label: '发车'},
|
// CMD_DEPART_TRAIN: {value: 'Depart_Train', label: '发车'},
|
||||||
// CMD_PARKING_TRAIN : {value: 'Parking_Train', label: '停车'}
|
// CMD_PARKING_TRAIN : {value: 'Parking_Train', label: '停车'}
|
||||||
},
|
},
|
||||||
|
@ -5149,6 +5149,12 @@ export const OperationEvent = {
|
|||||||
operation: '130e',
|
operation: '130e',
|
||||||
domId: '_Tips-Driver-takeOver'
|
domId: '_Tips-Driver-takeOver'
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
pantograph: {
|
||||||
|
menu: {
|
||||||
|
operation: '130f',
|
||||||
|
domId: '_Tips-Driver-pantograph'
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
// 语音会话
|
// 语音会话
|
||||||
|
@ -37,7 +37,7 @@ export function covertMemberData (activeTrainList, resp) {
|
|||||||
member.label = member.type + name + userName;
|
member.label = member.type + name + userName;
|
||||||
member.normalName = member.type + name;
|
member.normalName = member.type + name;
|
||||||
}
|
}
|
||||||
const deviceType = ['行调', '通号', '行值', '司机', '车辆段/停车场调度', '上级部门', '电力调度', '车辆段/停车场信号楼', '车站助理', '车站站长',
|
const deviceType = ['行调', '通号', '行值', '司机', '车辆段/停车场调度', '上级部门', '工电调度', '车辆段/停车场信号楼', '车站助理', '车站站长',
|
||||||
'车站信号员', '车站客运员', '车站扳道员', '车站引导员', '车站工务工', '设备管理员', '车务段段长', '电力工务', '值班站长', '站务员'];
|
'车站信号员', '车站客运员', '车站扳道员', '车站引导员', '车站工务工', '设备管理员', '车务段段长', '电力工务', '值班站长', '站务员'];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -123,7 +123,7 @@ export default {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
id: "23",
|
id: "23",
|
||||||
name: "电力调度职责介绍",
|
name: "工电调度职责介绍",
|
||||||
pic: '/other/23.png',
|
pic: '/other/23.png',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -410,8 +410,8 @@ export default {
|
|||||||
dispatcherList[item.id] = this.memberData[item.id];
|
dispatcherList[item.id] = this.memberData[item.id];
|
||||||
break;
|
break;
|
||||||
case 'ELECTRIC_DISPATCHER':
|
case 'ELECTRIC_DISPATCHER':
|
||||||
this.memberData[item.id].label = '电力调度' + (item.name || '');
|
this.memberData[item.id].label = '工电调度' + (item.name || '');
|
||||||
this.memberData[item.id].labelName = '电力调度' + (item.name || '');
|
this.memberData[item.id].labelName = '工电调度' + (item.name || '');
|
||||||
electricDispatcherList[item.id] = this.memberData[item.id];
|
electricDispatcherList[item.id] = this.memberData[item.id];
|
||||||
break;
|
break;
|
||||||
case 'DEPOT_DISPATCHER':
|
case 'DEPOT_DISPATCHER':
|
||||||
@ -539,7 +539,7 @@ export default {
|
|||||||
children: parentDepartmentList
|
children: parentDepartmentList
|
||||||
}, {
|
}, {
|
||||||
|
|
||||||
label: '电力调度',
|
label: '工电调度',
|
||||||
id: 'electricDispatcher',
|
id: 'electricDispatcher',
|
||||||
type: 'role',
|
type: 'role',
|
||||||
children: electricDispatcherList
|
children: electricDispatcherList
|
||||||
|
@ -320,8 +320,8 @@ export default {
|
|||||||
dispatcherList[item.id] = this.memberData[item.id];
|
dispatcherList[item.id] = this.memberData[item.id];
|
||||||
break;
|
break;
|
||||||
case 'ELECTRIC_DISPATCHER':
|
case 'ELECTRIC_DISPATCHER':
|
||||||
this.memberData[item.id].label = '电力调度' + (item.name || '');
|
this.memberData[item.id].label = '工电调度' + (item.name || '');
|
||||||
this.memberData[item.id].labelName = '电力调度' + (item.name || '');
|
this.memberData[item.id].labelName = '工电调度' + (item.name || '');
|
||||||
electricDispatcherList[item.id] = this.memberData[item.id];
|
electricDispatcherList[item.id] = this.memberData[item.id];
|
||||||
break;
|
break;
|
||||||
case 'DEPOT_DISPATCHER':
|
case 'DEPOT_DISPATCHER':
|
||||||
@ -447,7 +447,7 @@ export default {
|
|||||||
children: parentDepartmentList
|
children: parentDepartmentList
|
||||||
}, {
|
}, {
|
||||||
|
|
||||||
label: '电力调度',
|
label: '工电调度',
|
||||||
id: 'electricDispatcher',
|
id: 'electricDispatcher',
|
||||||
type: 'role',
|
type: 'role',
|
||||||
children: electricDispatcherList
|
children: electricDispatcherList
|
||||||
|
@ -123,6 +123,7 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
id() {
|
id() {
|
||||||
|
this.stopNoReadPlay();
|
||||||
this.cancelRecording();
|
this.cancelRecording();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -140,6 +141,46 @@ export default {
|
|||||||
this.contentDom = '';
|
this.contentDom = '';
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
stopNoReadPlay() {
|
||||||
|
this.play = false;
|
||||||
|
this.currentAudioList = [];
|
||||||
|
this.messageList.forEach(item => {
|
||||||
|
this.$set(item, 'activeAuto', false);
|
||||||
|
});
|
||||||
|
const audioDom = document.querySelector('#audioPlay');
|
||||||
|
audioDom && audioDom.pause();
|
||||||
|
},
|
||||||
|
playNoReadMessage() {
|
||||||
|
if (!this.id && !this.privateChatId) return;
|
||||||
|
const list = this.getNoReadVoiceList();
|
||||||
|
if (this.play) {
|
||||||
|
const filterList = list.filter(item => {
|
||||||
|
return !this.currentAudioList.find(ii => {
|
||||||
|
return ii.id == item.id;
|
||||||
|
});
|
||||||
|
});
|
||||||
|
this.currentAudioList.push(...filterList);
|
||||||
|
} else {
|
||||||
|
if (list.length) {
|
||||||
|
this.currentAudioList = list;
|
||||||
|
this.playAllAudio();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
getNoReadVoiceList() {
|
||||||
|
const filter = this.messageList.filter(item => {
|
||||||
|
return item.type == 'Voice' && !item.allRead && !item.readerSet.includes(this.myMemberId) && this.myMemberId != item.memberId;
|
||||||
|
});
|
||||||
|
return filter;
|
||||||
|
},
|
||||||
|
setActiveAutoStatus(ms, s = false) {
|
||||||
|
const findIndex = this.messageList.findIndex(item => {
|
||||||
|
return item.id == ms.id;
|
||||||
|
});
|
||||||
|
if (findIndex > -1) {
|
||||||
|
this.$set(this.messageList[findIndex], 'activeAuto', s);
|
||||||
|
}
|
||||||
|
},
|
||||||
setIsBottomFn() {
|
setIsBottomFn() {
|
||||||
const scrollTop = this.contentDom.scrollHeight - this.contentDom.clientHeight;
|
const scrollTop = this.contentDom.scrollHeight - this.contentDom.clientHeight;
|
||||||
if (scrollTop == 0 || this.contentDom.scrollTop >= scrollTop) {
|
if (scrollTop == 0 || this.contentDom.scrollTop >= scrollTop) {
|
||||||
@ -157,16 +198,18 @@ export default {
|
|||||||
},
|
},
|
||||||
playAllAudio() {
|
playAllAudio() {
|
||||||
this.$nextTick(function() {
|
this.$nextTick(function() {
|
||||||
this.currentMessage = this.currentAudioList.shift();
|
if (!this.currentAudioList || !this.currentAudioList[0] || this.currentAudioList[0].type === 'Text') {
|
||||||
if (this.currentMessage.type === 'Text') {
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
this.currentMessage = this.currentAudioList.shift();
|
||||||
document.querySelector('#audioPlay').src = this.currentMessage.audioPath;
|
document.querySelector('#audioPlay').src = this.currentMessage.audioPath;
|
||||||
document.querySelector('#audioPlay').play();
|
document.querySelector('#audioPlay').play();
|
||||||
this.$set(this.currentMessage, 'activeAuto', true);
|
this.$set(this.currentMessage, 'activeAuto', true);
|
||||||
|
this.setActiveAutoStatus(this.currentMessage, true);
|
||||||
this.play = true;
|
this.play = true;
|
||||||
document.querySelector('#audioPlay').onended = () => {
|
document.querySelector('#audioPlay').onended = () => {
|
||||||
this.$set(this.currentMessage, 'activeAuto', false);
|
this.$set(this.currentMessage, 'activeAuto', false);
|
||||||
|
this.setActiveAutoStatus(this.currentMessage);
|
||||||
if (!this.currentAudioList || !this.currentAudioList.length) {
|
if (!this.currentAudioList || !this.currentAudioList.length) {
|
||||||
this.play = false;
|
this.play = false;
|
||||||
} else {
|
} else {
|
||||||
@ -176,8 +219,7 @@ export default {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
playAudio(audioPath, data) {
|
playAudio(audioPath, data) {
|
||||||
this.$set(this.currentMessage, 'activeAuto', false);
|
this.stopNoReadPlay();
|
||||||
this.currentAudioList = [];
|
|
||||||
this.currentMessage = data;
|
this.currentMessage = data;
|
||||||
this.play = true;
|
this.play = true;
|
||||||
document.querySelector('#audioPlay').src = audioPath;
|
document.querySelector('#audioPlay').src = audioPath;
|
||||||
@ -362,6 +404,10 @@ export default {
|
|||||||
}
|
}
|
||||||
}).catch(() => { console.error('操作失败!'); });
|
}).catch(() => { console.error('操作失败!'); });
|
||||||
} else {
|
} else {
|
||||||
|
if (this.seconds < 1) {
|
||||||
|
this.$message.info('为保证语言质量,录制时长不能小于1秒!');
|
||||||
|
return;
|
||||||
|
}
|
||||||
this.stopRecording(); // 发送语音
|
this.stopRecording(); // 发送语音
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -56,7 +56,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="right">
|
<div class="right">
|
||||||
<chat-content v-if="id || privateChatId" :id="id" :group-name="activeGroupName" :private-chat-id="privateChatId" :message-list="activeMessageList" />
|
<chat-content v-if="id || privateChatId" :id="id" ref="chatContentRef" :group-name="activeGroupName" :private-chat-id="privateChatId" :message-list="activeMessageList" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div v-show="tabActive==1" class="contentBox">
|
<div v-show="tabActive==1" class="contentBox">
|
||||||
@ -183,7 +183,10 @@ export default {
|
|||||||
return item.id == val.id;
|
return item.id == val.id;
|
||||||
});
|
});
|
||||||
if (find) {
|
if (find) {
|
||||||
|
const fMess = find.messageList.find(ii => ii.id == val.message.id);
|
||||||
|
if (!fMess) {
|
||||||
find.messageList.push(val.message);
|
find.messageList.push(val.message);
|
||||||
|
}
|
||||||
if (!this.id && this.privateChatId && this.privateChatId == this.getPrivateChatId(find)) {
|
if (!this.id && this.privateChatId && this.privateChatId == this.getPrivateChatId(find)) {
|
||||||
this.id = val.id;
|
this.id = val.id;
|
||||||
}
|
}
|
||||||
@ -556,6 +559,10 @@ export default {
|
|||||||
return objectIsEqual(m1.sort(), m2.sort());
|
return objectIsEqual(m1.sort(), m2.sort());
|
||||||
},
|
},
|
||||||
groupClick(item) {
|
groupClick(item) {
|
||||||
|
if (this.$refs.chatContentRef && this.$refs.chatContentRef.recordSending) {
|
||||||
|
this.$message.info('请结束正在录制的语音!');
|
||||||
|
return;
|
||||||
|
}
|
||||||
this.id = item.id || 0;
|
this.id = item.id || 0;
|
||||||
if (item.type == 'GROUP_CHAT') {
|
if (item.type == 'GROUP_CHAT') {
|
||||||
this.privateChatId = '';
|
this.privateChatId = '';
|
||||||
@ -580,15 +587,22 @@ export default {
|
|||||||
setReadGroup() {
|
setReadGroup() {
|
||||||
if (!this.id || !this.dialogVisible) { return; }
|
if (!this.id || !this.dialogVisible) { return; }
|
||||||
const id = this.id;
|
const id = this.id;
|
||||||
setGroupReadMessage(this.groupId, {id}).then(res => {
|
this.$nextTick(() => {
|
||||||
res.data.forEach(item => {
|
this.$refs.chatContentRef && this.$refs.chatContentRef.playNoReadMessage();
|
||||||
const obj = {
|
setGroupReadMessage(this.groupId, {id}).then(() => {
|
||||||
id: id,
|
const findG = this.groupList.find(item => {
|
||||||
message: {
|
return item.id == this.id;
|
||||||
...item
|
});
|
||||||
|
if (findG) {
|
||||||
|
findG.messageList.forEach(ii => {
|
||||||
|
if (!ii.readerSet.includes(this.myMemberId)) {
|
||||||
|
ii.readerSet.push(this.myMemberId);
|
||||||
|
if (objectIsEqual(findG.memberList.sort(), ii.readerSet.sort())) {
|
||||||
|
ii.allRead = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
};
|
|
||||||
this.getMessageStatus(obj);
|
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
@ -6,6 +6,9 @@
|
|||||||
</el-badge>
|
</el-badge>
|
||||||
</div>
|
</div>
|
||||||
<chatDialog ref="chatDialog" @setTotalUnread="setTotalUnread" />
|
<chatDialog ref="chatDialog" @setTotalUnread="setTotalUnread" />
|
||||||
|
<audio id="chatBuzzer" style="display:none">
|
||||||
|
<source :src="buzzerAudio" type="audio/mpeg">
|
||||||
|
</audio>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@ -13,6 +16,7 @@
|
|||||||
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
||||||
// import {UserOperationType} from '@/scripts/ConstDic';
|
// import {UserOperationType} from '@/scripts/ConstDic';
|
||||||
import chatDialog from './chatDialog';
|
import chatDialog from './chatDialog';
|
||||||
|
import teleRing from '@/assets/teleRing.mp3';
|
||||||
export default {
|
export default {
|
||||||
name: 'ChatBox',
|
name: 'ChatBox',
|
||||||
components: {
|
components: {
|
||||||
@ -20,7 +24,8 @@ export default {
|
|||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
totalUnreadNum: 0
|
totalUnreadNum: 0,
|
||||||
|
buzzerAudio: teleRing
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
computed:{
|
computed:{
|
||||||
@ -36,11 +41,27 @@ export default {
|
|||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.$store.dispatch('training/emitTipFresh');
|
this.$store.dispatch('training/emitTipFresh');
|
||||||
});
|
});
|
||||||
|
},
|
||||||
|
totalUnreadNum(val) {
|
||||||
|
if (val && !this.$refs.chatDialog.dialogVisible) {
|
||||||
|
this.playBuzzer();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
playBuzzer() {
|
||||||
|
const audioDom = document.querySelector('#chatBuzzer');
|
||||||
|
if (audioDom) {
|
||||||
|
audioDom.currentTime = 0;
|
||||||
|
audioDom.play();
|
||||||
|
}
|
||||||
|
},
|
||||||
|
pauseBuzzer() {
|
||||||
|
const audioDom = document.querySelector('#chatBuzzer');
|
||||||
|
audioDom && audioDom.pause();
|
||||||
|
},
|
||||||
setTotalUnread(val) {
|
setTotalUnread(val) {
|
||||||
this.totalUnreadNum = val;
|
this.totalUnreadNum = val;
|
||||||
},
|
},
|
||||||
@ -52,6 +73,7 @@ export default {
|
|||||||
// };
|
// };
|
||||||
this.$store.dispatch('training/setChatBoxMin', false);
|
this.$store.dispatch('training/setChatBoxMin', false);
|
||||||
this.$refs.chatDialog.dialogVisible = true;
|
this.$refs.chatDialog.dialogVisible = true;
|
||||||
|
this.pauseBuzzer();
|
||||||
// if (this.$store.state.trainingNew.trainingSwitch) {
|
// if (this.$store.state.trainingNew.trainingSwitch) {
|
||||||
// this.$nextTick(() => {
|
// this.$nextTick(() => {
|
||||||
// this.$store.dispatch('trainingNew/next', operate);
|
// this.$store.dispatch('trainingNew/next', operate);
|
||||||
|
@ -43,7 +43,7 @@
|
|||||||
<el-divider direction="vertical" />
|
<el-divider direction="vertical" />
|
||||||
<el-button size="small" type="text" @click="resetTraining">重置</el-button>
|
<el-button size="small" type="text" @click="resetTraining">重置</el-button>
|
||||||
<el-divider direction="vertical" />
|
<el-divider direction="vertical" />
|
||||||
<el-button size="small" type="text" @click="showMode = 'draftTrainingList'">返回列表</el-button>
|
<el-button size="small" type="text" @click="goBackList">返回列表</el-button>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<el-divider content-position="center">实训背景</el-divider>
|
<el-divider content-position="center">实训背景</el-divider>
|
||||||
@ -130,6 +130,7 @@ import EditOperate from './editOperate';
|
|||||||
import CreateDraftTraining from './createDraftTraining';
|
import CreateDraftTraining from './createDraftTraining';
|
||||||
import GradeRules from './gradeRules';
|
import GradeRules from './gradeRules';
|
||||||
import TrackList from './trackList';
|
import TrackList from './trackList';
|
||||||
|
import { EventBus } from '@/scripts/event-bus';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'DesignIndex',
|
name: 'DesignIndex',
|
||||||
@ -217,6 +218,15 @@ export default {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
goBackList() {
|
||||||
|
const qObj = {...this.$route.query};
|
||||||
|
qObj.record = false;
|
||||||
|
this.$router.replace({ query:{...qObj}});
|
||||||
|
this.showMode = 'draftTrainingList';
|
||||||
|
this.$nextTick(() => {
|
||||||
|
EventBus.$emit('viewLoading', false);
|
||||||
|
});
|
||||||
|
},
|
||||||
computedRoleDisabled(role) {
|
computedRoleDisabled(role) {
|
||||||
if (!this.editData.client) {
|
if (!this.editData.client) {
|
||||||
return false;
|
return false;
|
||||||
|
@ -218,7 +218,7 @@ export default {
|
|||||||
type: 'role',
|
type: 'role',
|
||||||
children: result.deviceListData[5]
|
children: result.deviceListData[5]
|
||||||
}, {
|
}, {
|
||||||
label: '电力调度',
|
label: '工电调度',
|
||||||
id: 'electricDispatcher',
|
id: 'electricDispatcher',
|
||||||
type: 'role',
|
type: 'role',
|
||||||
children: result.deviceListData[6]
|
children: result.deviceListData[6]
|
||||||
@ -344,7 +344,7 @@ export default {
|
|||||||
const covertmember = this.covert(lastData, ConstConfig.ConstSelect.roleTypeNew);
|
const covertmember = this.covert(lastData, ConstConfig.ConstSelect.roleTypeNew);
|
||||||
const newMember = covertmember[0];
|
const newMember = covertmember[0];
|
||||||
this.memberList.push(newMember);
|
this.memberList.push(newMember);
|
||||||
const deviceTypeList = ['行调', '行值', '司机', '通号', '车辆段/停车场调度', '上级部门', '电力调度', '车辆段/停车场信号楼', '车站助理', '车站站长', '车站信号员', '车站客运员', '车站扳道员', '车站引导员', '车站工务工', '设备管理员', '车务段段长', '电力工务'];
|
const deviceTypeList = ['行调', '行值', '司机', '通号', '车辆段/停车场调度', '上级部门', '工电调度', '车辆段/停车场信号楼', '车站助理', '车站站长', '车站信号员', '车站客运员', '车站扳道员', '车站引导员', '车站工务工', '设备管理员', '车务段段长', '电力工务'];
|
||||||
const index = deviceTypeList.indexOf(newMember.type);
|
const index = deviceTypeList.indexOf(newMember.type);
|
||||||
if (index >= 0) {
|
if (index >= 0) {
|
||||||
const treeDataIn = this.treeData[index];
|
const treeDataIn = this.treeData[index];
|
||||||
@ -553,7 +553,7 @@ export default {
|
|||||||
prdType = '';
|
prdType = '';
|
||||||
role.type = 'PARENT_DEPARTMENT';
|
role.type = 'PARENT_DEPARTMENT';
|
||||||
this.$store.dispatch('training/setRoles', 'PARENT_DEPARTMENT');
|
this.$store.dispatch('training/setRoles', 'PARENT_DEPARTMENT');
|
||||||
} else if (role.type == '电力调度') {
|
} else if (role.type == '工电调度') {
|
||||||
prdType = '';
|
prdType = '';
|
||||||
role.type = 'ELECTRIC_DISPATCHER';
|
role.type = 'ELECTRIC_DISPATCHER';
|
||||||
this.$store.dispatch('training/setRoles', 'ELECTRIC_DISPATCHER');
|
this.$store.dispatch('training/setRoles', 'ELECTRIC_DISPATCHER');
|
||||||
@ -629,7 +629,7 @@ export default {
|
|||||||
'MAINTAINER':'通号',
|
'MAINTAINER':'通号',
|
||||||
'DEPOT_DISPATCHER':'车辆段/停车场调度',
|
'DEPOT_DISPATCHER':'车辆段/停车场调度',
|
||||||
'PARENT_DEPARTMENT':'上级部门',
|
'PARENT_DEPARTMENT':'上级部门',
|
||||||
'ELECTRIC_DISPATCHER':'电力调度',
|
'ELECTRIC_DISPATCHER':'工电调度',
|
||||||
'SIGNAL_BUILDING':'车辆段/停车场信号楼',
|
'SIGNAL_BUILDING':'车辆段/停车场信号楼',
|
||||||
'STATION_ASSISTANT':'车站助理',
|
'STATION_ASSISTANT':'车站助理',
|
||||||
'STATION_MASTER':'车站站长',
|
'STATION_MASTER':'车站站长',
|
||||||
|
Loading…
Reference in New Issue
Block a user