Merge remote-tracking branch 'origin/test'
This commit is contained in:
commit
8988e979e1
@ -91,7 +91,8 @@ export default {
|
|||||||
},
|
},
|
||||||
subscribeMessage(res) {
|
subscribeMessage(res) {
|
||||||
if (this.$refs.deomonTopic && !window.location.href.includes('trainroom')) {
|
if (this.$refs.deomonTopic && !window.location.href.includes('trainroom')) {
|
||||||
if (getSessionStorage('project') != 'refereeJsxt' && getSessionStorage('project') != 'jsxt' && !(getSessionStorage('project').includes('design'))) {
|
// getSessionStorage('project') != 'refereeJsxt' && getSessionStorage('project') != 'jsxt' &&
|
||||||
|
if (!(getSessionStorage('project').includes('design'))) {
|
||||||
this.$refs.deomonTopic.doShow(res);
|
this.$refs.deomonTopic.doShow(res);
|
||||||
}
|
}
|
||||||
this.$store.dispatch('socket/setSimulationInvite');
|
this.$store.dispatch('socket/setSimulationInvite');
|
||||||
|
@ -1,118 +1,5 @@
|
|||||||
import request from '@/utils/request';
|
import request from '@/utils/request';
|
||||||
|
|
||||||
/** 裁判退出仿真*/
|
|
||||||
export function refereeExitSimulation(group) {
|
|
||||||
return request({
|
|
||||||
url: `/api/v1/competition/room/${group}/refree`,
|
|
||||||
method: 'delete'
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 参赛者创建演练房间 */
|
|
||||||
export function participantCreatTrainingRoom(id, data) {
|
|
||||||
return request({
|
|
||||||
url: `/api/v1/competition/${id}/room`,
|
|
||||||
method: 'post',
|
|
||||||
data: data
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 查询用户是否已经报名该竞赛 */
|
|
||||||
export function getIsSignUp(raceId, params = {}) {
|
|
||||||
return request({
|
|
||||||
url: `/api/race/${raceId}/isSignUp`,
|
|
||||||
method: 'get',
|
|
||||||
params
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 提交试卷 */
|
|
||||||
export function postCompetitionTheory(data) {
|
|
||||||
return request({
|
|
||||||
url: `/api/v1/competitionTheory/submit`,
|
|
||||||
method: 'post',
|
|
||||||
data
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 查询竞赛报名人员详情 */
|
|
||||||
export function getRaceUserById(raceId) {
|
|
||||||
return request({
|
|
||||||
url: `/api/race/${raceId}/raceUser`,
|
|
||||||
method: 'get'
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 查询加载的实操题 */
|
|
||||||
export function getPracticalQuestion(competitionId) {
|
|
||||||
return request({
|
|
||||||
url: `/api/v1/competitionPractical/competition/${competitionId}`,
|
|
||||||
method: 'get'
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 查询加载的理论题 */
|
|
||||||
export function getTheoryQuestion(competitionId) {
|
|
||||||
return request({
|
|
||||||
url: `/api/v1/competitionTheory/competition/${competitionId}`,
|
|
||||||
method: 'get'
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 查询理论题作答详情 */
|
|
||||||
export function getCompetitionDetail(competitionId) {
|
|
||||||
return request({
|
|
||||||
url: `/api/v1/competitionTheory/detail/competition/${competitionId}`,
|
|
||||||
method: 'get'
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 根据id查询竞赛信息 */
|
|
||||||
export function getRaceById(id) {
|
|
||||||
return request({
|
|
||||||
url: `/api/race/${id}`,
|
|
||||||
method: 'get'
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 退出当前赛场 */
|
|
||||||
export function quitCurrentRace(id, params) {
|
|
||||||
return request({
|
|
||||||
url: `/api/v1/competition/${id}/room`,
|
|
||||||
method: 'delete',
|
|
||||||
params
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 查看加载的竞赛试题 */
|
|
||||||
export function getTestPaperDatail(competitionId) {
|
|
||||||
return request({
|
|
||||||
url: `/api/v1/competition/${competitionId}/testPaper`,
|
|
||||||
method: 'get'
|
|
||||||
});
|
|
||||||
}
|
|
||||||
/** 提交实操结果 */
|
|
||||||
export function submitPracticalCompetition(group, competitionId) {
|
|
||||||
return request({
|
|
||||||
url: `/api/v1/competitionPractical/${group}/${competitionId}/finish`,
|
|
||||||
method: 'put'
|
|
||||||
});
|
|
||||||
}
|
|
||||||
/** 开始实操竞赛 */
|
|
||||||
export function startPracticalCompetition(group, competitionId) {
|
|
||||||
return request({
|
|
||||||
url: `/api/v1/competitionPractical/${group}/${competitionId}/start`,
|
|
||||||
method: 'put'
|
|
||||||
});
|
|
||||||
}
|
|
||||||
/** 查询实操考试结果 */
|
|
||||||
export function getPracticalCompetitionResult(competitionId) {
|
|
||||||
return request({
|
|
||||||
url: `/api/v1/competitionPractical/${competitionId}/result`,
|
|
||||||
method: 'get'
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
// 以下drts项目使用
|
// 以下drts项目使用
|
||||||
|
|
||||||
/** 项目获取试题列表 */
|
/** 项目获取试题列表 */
|
||||||
|
@ -1,37 +1,5 @@
|
|||||||
import request from '@/utils/request';
|
import request from '@/utils/request';
|
||||||
|
|
||||||
/** 发送步骤数据*/
|
|
||||||
export function sendTrainingNextStep(data, group) {
|
|
||||||
return request({
|
|
||||||
url: `/api/training/${data.trainingId}/nextStep`,
|
|
||||||
method: 'post',
|
|
||||||
data: data.operate,
|
|
||||||
params: {
|
|
||||||
group
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
/** 查询实训列表 0*/
|
|
||||||
export function pageQueryTraining(params) {
|
|
||||||
return request({
|
|
||||||
url: `/api/training/pagedQuery`,
|
|
||||||
method: 'get',
|
|
||||||
params: params
|
|
||||||
});
|
|
||||||
}
|
|
||||||
export function sendCommand(group, command) {
|
|
||||||
return request({
|
|
||||||
url: `/api/training/deviceChange?group=${group}`,
|
|
||||||
method: 'put',
|
|
||||||
data: {
|
|
||||||
param: command.val,
|
|
||||||
type: command.type,
|
|
||||||
code: command.code,
|
|
||||||
operation: command.operation
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
// 发送新的指令
|
// 发送新的指令
|
||||||
export function sendCommandNew(group, commandDefinitionId, command) {
|
export function sendCommandNew(group, commandDefinitionId, command) {
|
||||||
return request({
|
return request({
|
||||||
|
@ -137,13 +137,6 @@ export function getUserinfoPassword(id, data) {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
// 获取当前用户数量
|
|
||||||
export function getOnlineNmuber() {
|
|
||||||
return request({
|
|
||||||
url: `/api/cache/onlineUser`,
|
|
||||||
method: 'get'
|
|
||||||
});
|
|
||||||
}
|
|
||||||
// 生成线下环境用户
|
// 生成线下环境用户
|
||||||
export function generateOfflineUser(data) {
|
export function generateOfflineUser(data) {
|
||||||
return request({
|
return request({
|
||||||
|
@ -362,7 +362,7 @@ export function postDailyRunPlanLoadGenerate(id) {
|
|||||||
// 加载通用排班计划
|
// 加载通用排班计划
|
||||||
export function postSchedulingCommonGenerate(mapId) {
|
export function postSchedulingCommonGenerate(mapId) {
|
||||||
return request({
|
return request({
|
||||||
url: `/api/scheduling/common/generate?mapId=${mapId}`,
|
url: `/api/v1/scheduling/generate/common?mapId=${mapId}`,
|
||||||
method: 'post'
|
method: 'post'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -1,12 +1,5 @@
|
|||||||
import request from '@/utils/request';
|
import request from '@/utils/request';
|
||||||
|
|
||||||
export function generateSchedulingAgain(group) {
|
|
||||||
return request({
|
|
||||||
url: `/api/scheduling/${group}/rebuild`,
|
|
||||||
method: 'delete'
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 查询某天的派班计划 */
|
/** 查询某天的派班计划 */
|
||||||
export function querySechedulingNew (group, params) {
|
export function querySechedulingNew (group, params) {
|
||||||
return request({
|
return request({
|
||||||
|
@ -31,14 +31,6 @@ export function deleteFailureRule(id) {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
/** 退出仿真系统*/
|
|
||||||
export function runDiagramQuit(group) {
|
|
||||||
return request({
|
|
||||||
url: `/api/simulation/${group}/quit`,
|
|
||||||
method: 'put'
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 实训系统(新版地图) */
|
/** 实训系统(新版地图) */
|
||||||
export function trainingNotifyNew({ trainingId }) {
|
export function trainingNotifyNew({ trainingId }) {
|
||||||
return request({
|
return request({
|
||||||
@ -57,7 +49,7 @@ export function examNotifyNew({ examId }) {
|
|||||||
/** 获取用户实训列表*/
|
/** 获取用户实训列表*/
|
||||||
export function getSimulationList(data) {
|
export function getSimulationList(data) {
|
||||||
return request({
|
return request({
|
||||||
url: `/api/simulation/stats`,
|
url: `/api/stats/simulation`,
|
||||||
method: 'get',
|
method: 'get',
|
||||||
params: data
|
params: data
|
||||||
});
|
});
|
||||||
@ -66,7 +58,7 @@ export function getSimulationList(data) {
|
|||||||
/** 添加用户仿真数据*/
|
/** 添加用户仿真数据*/
|
||||||
export function postSimulationStats(data) {
|
export function postSimulationStats(data) {
|
||||||
return request({
|
return request({
|
||||||
url: `/api/simulation/stats`,
|
url: `/api/stats/simulation`,
|
||||||
method: 'post',
|
method: 'post',
|
||||||
data: data
|
data: data
|
||||||
});
|
});
|
||||||
@ -75,7 +67,7 @@ export function postSimulationStats(data) {
|
|||||||
/** 更新用户仿真数据*/
|
/** 更新用户仿真数据*/
|
||||||
export function putSimulationStats(data) {
|
export function putSimulationStats(data) {
|
||||||
return request({
|
return request({
|
||||||
url: `/api/simulation/${data.id}/stats`,
|
url: `/api/stats/${data.id}`,
|
||||||
method: 'put',
|
method: 'put',
|
||||||
data: data
|
data: data
|
||||||
});
|
});
|
||||||
@ -84,7 +76,7 @@ export function putSimulationStats(data) {
|
|||||||
/** 删除用户仿真数据*/
|
/** 删除用户仿真数据*/
|
||||||
export function deleteSimulationStats(statsId) {
|
export function deleteSimulationStats(statsId) {
|
||||||
return request({
|
return request({
|
||||||
url: `/api/simulation/${statsId}`,
|
url: `/api/stats/${statsId}`,
|
||||||
method: 'delete'
|
method: 'delete'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -236,14 +228,6 @@ export function handlerIbpEvent(group, button, stationCode) {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
/** 预览脚本仿真*/
|
|
||||||
export function scriptDraftRecordNotify(scriptId) {
|
|
||||||
return request({
|
|
||||||
url: `/api/simulation/scriptDraft/${scriptId}`,
|
|
||||||
method: 'get'
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 预览脚本仿真(新版)*/
|
/** 预览脚本仿真(新版)*/
|
||||||
export function scriptDraftRecordNotifyNew(scriptId) {
|
export function scriptDraftRecordNotifyNew(scriptId) {
|
||||||
return request({
|
return request({
|
||||||
|
@ -188,6 +188,20 @@ export default {
|
|||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.content = this.value;
|
this.content = this.value;
|
||||||
|
const that = this;
|
||||||
|
document.addEventListener('click', (e) => {
|
||||||
|
const emojiElem = document.getElementById('emoji-palette');
|
||||||
|
const emojiButtonList = document.getElementsByClassName('ql-emoji');
|
||||||
|
let flag = true;
|
||||||
|
for (let i = 0; i < emojiButtonList.length; i++) {
|
||||||
|
if (emojiButtonList[i].contains(e.target)) {
|
||||||
|
flag = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (emojiElem && !emojiElem.contains(e.target) && flag) {
|
||||||
|
that.closeEmoji();
|
||||||
|
}
|
||||||
|
});
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
onChange(e) {
|
onChange(e) {
|
||||||
@ -209,6 +223,11 @@ export default {
|
|||||||
},
|
},
|
||||||
setContents(val) {
|
setContents(val) {
|
||||||
this.$refs.editor.quill.setContents(val);
|
this.$refs.editor.quill.setContents(val);
|
||||||
|
},
|
||||||
|
closeEmoji() {
|
||||||
|
const ele_emoji_plate = document.getElementById('emoji-palette');
|
||||||
|
document.getElementById('emoji-close-div').style.display = 'none';
|
||||||
|
if (ele_emoji_plate) { ele_emoji_plate.remove(); }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
@ -226,6 +245,20 @@ export default {
|
|||||||
left: -30px;
|
left: -30px;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
/deep/ #emoji-palette{
|
||||||
|
top: -215 !important;
|
||||||
|
left: 0 !important;
|
||||||
|
max-width: 550px;
|
||||||
|
width: 550px;
|
||||||
|
#tab-toolbar{ text-align: left}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/deep/ #emoji-palette{
|
||||||
|
top: -215px !important;
|
||||||
|
left: 850px !important;
|
||||||
|
max-width: 550px;
|
||||||
|
width: 550px;
|
||||||
|
#tab-toolbar{ text-align: left}
|
||||||
|
#tab-panel{ height:175px}
|
||||||
}
|
}
|
||||||
|
|
||||||
</style>
|
</style>
|
||||||
|
@ -1,262 +0,0 @@
|
|||||||
//import request from '@/utils/request';
|
|
||||||
import { JL3D_LOCAL_STATIC } from '@/api/jlmap3d/assets3d.js';
|
|
||||||
|
|
||||||
export function getmodels(data) {
|
|
||||||
let postmap = {
|
|
||||||
id:data.mapdata.id,
|
|
||||||
mapId:data.mapdata.mapId,
|
|
||||||
assets:"null",
|
|
||||||
sections:"null",
|
|
||||||
signals:"null",
|
|
||||||
trains:"null",
|
|
||||||
stands:"null",
|
|
||||||
switchs:"null"
|
|
||||||
};
|
|
||||||
console.log(data.mapdata);
|
|
||||||
if(data.mapdata.sectionlist.sections== undefined){
|
|
||||||
return postmap;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
if(data == undefined){
|
|
||||||
|
|
||||||
return postmap;
|
|
||||||
}else{
|
|
||||||
|
|
||||||
let models = {
|
|
||||||
stationtexture:"0",
|
|
||||||
istexture:false,
|
|
||||||
assets:[],
|
|
||||||
};
|
|
||||||
//资源
|
|
||||||
let assets = [];
|
|
||||||
// for(let i=0;i<data.assetloader.modellist.length;i++){
|
|
||||||
// let asset = {
|
|
||||||
// id:data.assetloader.modellist[i].id,
|
|
||||||
// name:data.assetloader.modellist[i].name,
|
|
||||||
// deviceType:data.assetloader.modellist[i].deviceType,
|
|
||||||
// type:data.assetloader.modellist[i].type,
|
|
||||||
// assetUrl:data.assetloader.modellist[i].assetUrl
|
|
||||||
// }
|
|
||||||
// assets.push(asset);
|
|
||||||
// }
|
|
||||||
//信号机资源
|
|
||||||
let assetsignal = {
|
|
||||||
assetname:"信号机模型",
|
|
||||||
id:"1",
|
|
||||||
packageName:"高位三灯信号机",
|
|
||||||
deviceType:"SimulationSignal",
|
|
||||||
type:"signal",
|
|
||||||
url:JL3D_LOCAL_STATIC+"/MODEL/signal/d3d.FBX"
|
|
||||||
}
|
|
||||||
assets.push(assetsignal);
|
|
||||||
|
|
||||||
//列车资源
|
|
||||||
let assettrain = {
|
|
||||||
assetname:"列车模型",
|
|
||||||
id:"2",
|
|
||||||
packageName:"6节列车",
|
|
||||||
deviceType:"SimulationTrain",
|
|
||||||
type:"train",
|
|
||||||
url:JL3D_LOCAL_STATIC+"/MODEL/train/train.FBX"
|
|
||||||
}
|
|
||||||
assets.push(assettrain);
|
|
||||||
|
|
||||||
let assetneicestation = {
|
|
||||||
assetname:"内侧车站",
|
|
||||||
id:"3",
|
|
||||||
packageName:"沙盘驾驶内侧站台",
|
|
||||||
deviceType:"SimulationStation",
|
|
||||||
type:"stationInside",
|
|
||||||
url:JL3D_LOCAL_STATIC+"/MODEL/station/fuzhou.FBX"
|
|
||||||
}//JL3D_LOCAL_STATIC+"/MODEL/station/fuzhou/fuzhou.FBX"
|
|
||||||
assets.push(assetneicestation);
|
|
||||||
|
|
||||||
let assetswitch = {
|
|
||||||
assetname:"道岔模型",
|
|
||||||
id:"4",
|
|
||||||
packageName:"轨道通用道岔",
|
|
||||||
deviceType:"SimulationSwitch",
|
|
||||||
type:"switch",
|
|
||||||
url:JL3D_LOCAL_STATIC+"/MODEL/auto/autoswitch.FBX"
|
|
||||||
}
|
|
||||||
assets.push(assetswitch);
|
|
||||||
|
|
||||||
let assetwaicestation = {
|
|
||||||
assetname:"外侧车站",
|
|
||||||
id:"5",
|
|
||||||
packageName:"沙盘驾驶外侧站台",
|
|
||||||
deviceType:"SimulationStation",
|
|
||||||
type:"stationOutside",
|
|
||||||
url:JL3D_LOCAL_STATIC+"/MODEL/station/waicestation.FBX"
|
|
||||||
}
|
|
||||||
assets.push(assetwaicestation);
|
|
||||||
|
|
||||||
let assetstation3 = {
|
|
||||||
assetname:"特殊站台",
|
|
||||||
id:"6",
|
|
||||||
packageName:"沙盘驾驶特殊站台",
|
|
||||||
deviceType:"SimulationStation",
|
|
||||||
type:"stationThree",
|
|
||||||
url:JL3D_LOCAL_STATIC+"/MODEL/station/station3.FBX"
|
|
||||||
}
|
|
||||||
assets.push(assetstation3);
|
|
||||||
|
|
||||||
let backgroundmodel = {
|
|
||||||
assetname:"隧道背景",
|
|
||||||
id:"7",
|
|
||||||
packageName:"隧道背景",
|
|
||||||
deviceType:"SimulationBg",
|
|
||||||
type:"suidao",
|
|
||||||
url:JL3D_LOCAL_STATIC+"/MODEL/suidao/xiansuidao.FBX"
|
|
||||||
}
|
|
||||||
assets.push(backgroundmodel);
|
|
||||||
|
|
||||||
models.assets = assets;
|
|
||||||
models.stationtexture = "xian3";
|
|
||||||
models.istexture = true;
|
|
||||||
console.log(models);
|
|
||||||
postmap.assets = JSON.stringify(models);
|
|
||||||
//link轨道
|
|
||||||
// let links = [];
|
|
||||||
// for(let i=0;i<data.mapdata.linklist.linksgroup.children.length;i++){
|
|
||||||
// let link = {
|
|
||||||
// uuid:data.mapdata.linklist.linksgroup.children[i].uuid,
|
|
||||||
// code:data.mapdata.linklist.linksgroup.children[i].code,
|
|
||||||
// name:data.mapdata.linklist.linksgroup.children[i].name,
|
|
||||||
// lengthfact:data.mapdata.linklist.linksgroup.children[i].lengthfact,
|
|
||||||
// position:data.mapdata.linklist.linksgroup.children[i].position,
|
|
||||||
// rotation:data.mapdata.linklist.linksgroup.children[i].rotation,
|
|
||||||
// scale:data.mapdata.linklist.linksgroup.children[i].scale,
|
|
||||||
// rightlist:data.mapdata.linklist.linksgroup.children[i].rightlist,
|
|
||||||
// leftlist:data.mapdata.linklist.linksgroup.children[i].leftlist,
|
|
||||||
// lp:data.mapdata.linklist.linksgroup.children[i].lp,
|
|
||||||
// rp:data.mapdata.linklist.linksgroup.children[i].rp,
|
|
||||||
// rail:data.mapdata.linklist.linksgroup.children[i].rail,
|
|
||||||
// }
|
|
||||||
// links.push(link);
|
|
||||||
// }
|
|
||||||
// postmap.sections.link = JSON.stringify(links);
|
|
||||||
|
|
||||||
//section隧道
|
|
||||||
let sections = [];
|
|
||||||
// console.log(data.mapdata.sectionlist.sections.datalist);
|
|
||||||
for(let i in data.mapdata.sectionlist.sections.datalist){
|
|
||||||
let section = {
|
|
||||||
// uuid:data.mapdata.sectionlist.sections.modellist[i].uuid,
|
|
||||||
code:data.mapdata.sectionlist.sections.datalist[i].code,
|
|
||||||
name:data.mapdata.sectionlist.sections.datalist[i].name,
|
|
||||||
lengthFact:data.mapdata.sectionlist.sections.datalist[i].mesh.lengthFact,
|
|
||||||
standTrack:data.mapdata.sectionlist.sections.datalist[i].standTrack,
|
|
||||||
rp:data.mapdata.sectionlist.sections.datalist[i].rp,
|
|
||||||
lp:data.mapdata.sectionlist.sections.datalist[i].lp,
|
|
||||||
railpoint:data.mapdata.sectionlist.sections.datalist[i].mesh.railpoint,
|
|
||||||
rail:data.mapdata.sectionlist.sections.datalist[i].rail,
|
|
||||||
position:data.mapdata.sectionlist.sections.datalist[i].mesh.position,
|
|
||||||
rotation:data.mapdata.sectionlist.sections.datalist[i].mesh.rotation,
|
|
||||||
scale:data.mapdata.sectionlist.sections.datalist[i].mesh.scale,
|
|
||||||
}
|
|
||||||
let nowmesh = data.mapdata.sectionlist.sectiongroup.getObjectByProperty("code",section.code);
|
|
||||||
section.railpoint = nowmesh.railpoint
|
|
||||||
// console.log(nowmesh.railpoint);
|
|
||||||
// if(data.mapdata.sectionlist.sections.datalist[i].rsection){
|
|
||||||
// section.rsection = data.mapdata.sectionlist.sections.datalist[i].rsection;
|
|
||||||
// }
|
|
||||||
// if(data.mapdata.sectionlist.sections.datalist[i].lsection){
|
|
||||||
// section.lsection = data.mapdata.sectionlist.sections.datalist[i].lsection;
|
|
||||||
// }
|
|
||||||
// if(data.mapdata.sectionlist.sections.datalist[i].csection){
|
|
||||||
// section.csection = data.mapdata.sectionlist.sections.datalist[i].csection;
|
|
||||||
// }
|
|
||||||
|
|
||||||
// testmesh1.position.z = link.position.z;
|
|
||||||
|
|
||||||
sections.push(section);
|
|
||||||
}
|
|
||||||
let arrray = {
|
|
||||||
section:sections,
|
|
||||||
};
|
|
||||||
postmap.sections = JSON.stringify(arrray);
|
|
||||||
//道岔
|
|
||||||
let switchs = [];
|
|
||||||
|
|
||||||
for(let i=0;i<data.mapdata.switchlist.switchs.datalist.length;i++){
|
|
||||||
let switcha = {
|
|
||||||
// uuid:data.mapdata.switchlist.switchs.modellist[i].uuid,
|
|
||||||
code:data.mapdata.switchlist.switchs.datalist[i].code,
|
|
||||||
name:data.mapdata.switchlist.switchs.datalist[i].name,
|
|
||||||
pa:data.mapdata.switchlist.switchs.datalist[i].pa,
|
|
||||||
pb:data.mapdata.switchlist.switchs.datalist[i].pb,
|
|
||||||
pc:data.mapdata.switchlist.switchs.datalist[i].pc,
|
|
||||||
position:data.mapdata.switchlist.switchs.modellist[i].position,
|
|
||||||
rotation:data.mapdata.switchlist.switchs.modellist[i].rotation,
|
|
||||||
scale:data.mapdata.switchlist.switchs.modellist[i].scale
|
|
||||||
}
|
|
||||||
switchs.push(switcha);
|
|
||||||
}
|
|
||||||
postmap.switchs = JSON.stringify(switchs);
|
|
||||||
//信号
|
|
||||||
let signals = [];
|
|
||||||
for(let i=0;i<data.mapdata.signallist.list.length;i++){
|
|
||||||
|
|
||||||
|
|
||||||
let signal = {
|
|
||||||
// uuid:data.mapdata.signallist.list[i].mesh.uuid,
|
|
||||||
name:data.mapdata.signallist.list[i].mesh.name,
|
|
||||||
modelid:data.mapdata.signallist.list[i].mesh.modelid,
|
|
||||||
code:data.mapdata.signallist.list[i].mesh.code,
|
|
||||||
right:data.mapdata.signallist.list[i].mesh.right,
|
|
||||||
position:data.mapdata.signallist.list[i].mesh.position,
|
|
||||||
rotation:data.mapdata.signallist.list[i].mesh.rotation,
|
|
||||||
scale:data.mapdata.signallist.list[i].mesh.scale
|
|
||||||
}
|
|
||||||
|
|
||||||
signals.push(signal);
|
|
||||||
}
|
|
||||||
postmap.signals = JSON.stringify(signals);
|
|
||||||
//车站
|
|
||||||
let stands = [];
|
|
||||||
|
|
||||||
for(let i=0;i<data.mapdata.stationstandlist.list.length;i++){
|
|
||||||
let station = {
|
|
||||||
// uuid:data.mapdata.stationstandlist.list[i].uuid,
|
|
||||||
code:data.mapdata.stationstandlist.list[i].code,
|
|
||||||
name:data.mapdata.stationstandlist.list[i].name,
|
|
||||||
modelid:data.mapdata.stationstandlist.list[i].modelid,
|
|
||||||
position:data.mapdata.stationstandlist.list[i].mesh.position,
|
|
||||||
rotation:data.mapdata.stationstandlist.list[i].mesh.rotation,
|
|
||||||
scale:data.mapdata.stationstandlist.list[i].mesh.scale,
|
|
||||||
inside:data.mapdata.stationstandlist.list[i].inside,
|
|
||||||
direction1:{
|
|
||||||
name:data.mapdata.stationstandlist.list[i].direction1.name,
|
|
||||||
code:data.mapdata.stationstandlist.list[i].direction1.code
|
|
||||||
},
|
|
||||||
direction2:{
|
|
||||||
name:data.mapdata.stationstandlist.list[i].direction2.name,
|
|
||||||
code:data.mapdata.stationstandlist.list[i].direction2.code
|
|
||||||
}
|
|
||||||
}
|
|
||||||
stands.push(station);
|
|
||||||
}
|
|
||||||
postmap.stands = JSON.stringify(stands);
|
|
||||||
//列车
|
|
||||||
let trains = [];
|
|
||||||
for(let i=0;i<data.assetloader.modellist.length;i++){
|
|
||||||
if(data.assetloader.modellist[i].deviceType == "train"){
|
|
||||||
let train = {
|
|
||||||
id:data.assetloader.modellist[i].id,
|
|
||||||
name:data.assetloader.modellist[i].name,
|
|
||||||
deviceType:data.assetloader.modellist[i].deviceType,
|
|
||||||
type:data.assetloader.modellist[i].type,
|
|
||||||
assetUrl:data.assetloader.modellist[i].assetUrl
|
|
||||||
}
|
|
||||||
|
|
||||||
trains.push(train);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
postmap.trains = JSON.stringify(trains);
|
|
||||||
|
|
||||||
return postmap;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
@ -3,13 +3,13 @@ import { JL3D_LOCAL_STATIC } from '@/api/jlmap3d/assets3d.js';
|
|||||||
//信号机贴图
|
//信号机贴图
|
||||||
export function Signallightload(lights) {
|
export function Signallightload(lights) {
|
||||||
|
|
||||||
settexture(lights, "red", JL3D_LOCAL_STATIC+'/MODEL/device/signal/1.jpg');
|
settexture(lights, "red", JL3D_LOCAL_STATIC+'/device/signal/1.jpg');
|
||||||
|
|
||||||
settexture(lights, "yellow", JL3D_LOCAL_STATIC+'/MODEL/device/signal/2.jpg');
|
settexture(lights, "yellow", JL3D_LOCAL_STATIC+'/device/signal/2.jpg');
|
||||||
|
|
||||||
settexture(lights, "green", JL3D_LOCAL_STATIC+'/MODEL/device/signal/3.jpg');
|
settexture(lights, "green", JL3D_LOCAL_STATIC+'/device/signal/3.jpg');
|
||||||
|
|
||||||
settexture(lights, "black", JL3D_LOCAL_STATIC+'/MODEL/device/signal/4.jpg');
|
settexture(lights, "black", JL3D_LOCAL_STATIC+'/device/signal/4.jpg');
|
||||||
}
|
}
|
||||||
|
|
||||||
//加载贴图
|
//加载贴图
|
||||||
|
@ -7,7 +7,7 @@ var Staticmodel = {
|
|||||||
deviceType: "Switch",
|
deviceType: "Switch",
|
||||||
type: "fuzhou",
|
type: "fuzhou",
|
||||||
picUrl: "",
|
picUrl: "",
|
||||||
assetUrl: JL3D_LOCAL_STATIC+"/MODEL/device/switch/ZD6D.FBX"
|
assetUrl: JL3D_LOCAL_STATIC+"/device/switch/ZD6D.FBX"
|
||||||
},//"https://joylink.club/oss/wx/switch/switch.FBX"
|
},//"https://joylink.club/oss/wx/switch/switch.FBX"
|
||||||
|
|
||||||
Signal: {
|
Signal: {
|
||||||
@ -16,7 +16,7 @@ var Staticmodel = {
|
|||||||
deviceType: "Signal",
|
deviceType: "Signal",
|
||||||
type: "low",
|
type: "low",
|
||||||
picUrl: "",
|
picUrl: "",
|
||||||
assetUrl: JL3D_LOCAL_STATIC+"/MODEL/device/signal/signal.FBX"
|
assetUrl: JL3D_LOCAL_STATIC+"/device/signal/signal.FBX"
|
||||||
},
|
},
|
||||||
stationstand: {
|
stationstand: {
|
||||||
id: "3",
|
id: "3",
|
||||||
@ -24,7 +24,7 @@ var Staticmodel = {
|
|||||||
deviceType: "stationstand",
|
deviceType: "stationstand",
|
||||||
type: "low",
|
type: "low",
|
||||||
picUrl: "",
|
picUrl: "",
|
||||||
assetUrl: JL3D_LOCAL_STATIC+"/MODEL/device/stationstand/stationstand.FBX"
|
assetUrl: JL3D_LOCAL_STATIC+"/device/stationstand/stationstand.FBX"
|
||||||
//https://joylink.club/oss/wx/stationstand/stationstand.FBX
|
//https://joylink.club/oss/wx/stationstand/stationstand.FBX
|
||||||
|
|
||||||
|
|
||||||
@ -35,7 +35,7 @@ var Staticmodel = {
|
|||||||
deviceType: "section",
|
deviceType: "section",
|
||||||
type: "low",
|
type: "low",
|
||||||
picUrl: "",
|
picUrl: "",
|
||||||
assetUrl: JL3D_LOCAL_STATIC+"/MODEL/device/section/section.FBX"
|
assetUrl: JL3D_LOCAL_STATIC+"/device/section/section.FBX"
|
||||||
//https://joylink.club/oss/wx/stationstand/stationstand.FBX
|
//https://joylink.club/oss/wx/stationstand/stationstand.FBX
|
||||||
|
|
||||||
|
|
||||||
@ -46,7 +46,7 @@ var Staticmodel = {
|
|||||||
deviceType: "room",
|
deviceType: "room",
|
||||||
type: "low",
|
type: "low",
|
||||||
picUrl: "",
|
picUrl: "",
|
||||||
assetUrl: JL3D_LOCAL_STATIC+"/MODEL/device/room/room.FBX"
|
assetUrl: JL3D_LOCAL_STATIC+"/device/room/room.FBX"
|
||||||
//https://joylink.club/oss/wx/stationstand/stationstand.FBX
|
//https://joylink.club/oss/wx/stationstand/stationstand.FBX
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { Staticmodel } from '@/jlmap3d/jl3ddevice/config.js';
|
|
||||||
import { JL3D_LOCAL_STATIC } from '@/api/jlmap3d/assets3d.js';
|
import { JL3D_LOCAL_STATIC } from '@/api/jlmap3d/assets3d.js';
|
||||||
|
|
||||||
//loader
|
//loader
|
||||||
@ -729,7 +729,7 @@ export function Jl3ddeviceNew(dom,group,token,skinCode) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
this.updatewindowstatus = function(nowwindowstatus){
|
this.updatewindowstatus = function(nowwindowstatus){
|
||||||
scope.windowstatus == nowwindowstatus;
|
scope.windowstatus == nowwindowstatus;
|
||||||
}
|
}
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { Staticmodel } from '@/jlmap3d/jl3ddevice/config.js';
|
|
||||||
import { JL3D_LOCAL_STATIC } from '@/api/jlmap3d/assets3d.js';
|
import { JL3D_LOCAL_STATIC } from '@/api/jlmap3d/assets3d.js';
|
||||||
//loader
|
//loader
|
||||||
import { FBXLoader } from '@/jlmap3d/main/loaders/FBXLoader';
|
import { FBXLoader } from '@/jlmap3d/main/loaders/FBXLoader';
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { Staticmodel } from '@/jlmap3d/jl3ddevice/config.js';
|
// import { Staticmodel } from '@/jlmap3d/jl3ddevice/config.js';
|
||||||
import { JL3D_LOCAL_STATIC } from '@/api/jlmap3d/assets3d.js';
|
import { JL3D_LOCAL_STATIC } from '@/api/jlmap3d/assets3d.js';
|
||||||
//loader
|
//loader
|
||||||
import { FBXLoader } from '@/jlmap3d/main/loaders/FBXLoader';
|
import { FBXLoader } from '@/jlmap3d/main/loaders/FBXLoader';
|
||||||
|
@ -1,48 +1,41 @@
|
|||||||
import { JL3D_LOCAL_STATIC } from '@/api/jlmap3d/assets3d.js';
|
import { JL3D_LOCAL_STATIC,BASE_ASSET_API } from '@/api/jlmap3d/assets3d.js';
|
||||||
|
|
||||||
export function ModelManagerVR(){
|
export function ModelManagerVR(){
|
||||||
let scope = this;
|
let scope = this;
|
||||||
//
|
|
||||||
// this.testmodel = {
|
|
||||||
// code:"test",
|
|
||||||
// locateType:"01",
|
|
||||||
// mesh:null,
|
|
||||||
// url:JL3D_LOCAL_STATIC+"/vrtest/vrtest.FBX"
|
|
||||||
// };
|
|
||||||
|
|
||||||
this.stationIn = {
|
this.stationIn = {
|
||||||
code:"stationIn",
|
code:"stationIn",
|
||||||
locateType:"1",
|
locateType:"1",
|
||||||
mesh:null,
|
mesh:null,
|
||||||
url:JL3D_LOCAL_STATIC+"/vrtest/stationIn.FBX"
|
url:BASE_ASSET_API+"/MODEL/2020-11-23/71-16438.FBX"
|
||||||
};
|
};
|
||||||
|
|
||||||
this.stationOut = {
|
this.stationOut = {
|
||||||
code:"stationOut",
|
code:"stationOut",
|
||||||
locateType:"2",
|
locateType:"2",
|
||||||
mesh:null,
|
mesh:null,
|
||||||
url:JL3D_LOCAL_STATIC+"/vrtest/stationIn.FBX"
|
url:BASE_ASSET_API+"/MODEL/2020-11-23/71-16438.FBX"
|
||||||
};
|
};
|
||||||
|
|
||||||
this.otherDevice = {
|
this.otherDevice = {
|
||||||
code:"otherDevice",
|
code:"otherDevice",
|
||||||
locateType:"3",
|
locateType:"3",
|
||||||
mesh:null,
|
mesh:null,
|
||||||
url:JL3D_LOCAL_STATIC+"/vrtest/otherDevice.FBX"
|
url:BASE_ASSET_API+"/MODEL/2020-11-23/1-56188.FBX"
|
||||||
};
|
};
|
||||||
|
|
||||||
this.train = {
|
this.train = {
|
||||||
code:"train",
|
code:"train",
|
||||||
locateType:"4",
|
locateType:"4",
|
||||||
mesh:null,
|
mesh:null,
|
||||||
url:JL3D_LOCAL_STATIC+"/vrtest/vrTrain.FBX"
|
url:BASE_ASSET_API+"/MODEL/2020-11-23/72-72266.FBX"
|
||||||
};
|
};
|
||||||
|
|
||||||
this.human = {
|
this.human = {
|
||||||
code:"human",
|
code:"human",
|
||||||
locateType:"5",
|
locateType:"5",
|
||||||
mesh:null,
|
mesh:null,
|
||||||
url:JL3D_LOCAL_STATIC+"/vrtest/vrHuman.FBX"
|
url:BASE_ASSET_API+"/MODEL/2020-11-23/73-61142.FBX"
|
||||||
};
|
};
|
||||||
|
|
||||||
this.loadpromise = function (mixers){
|
this.loadpromise = function (mixers){
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { Staticmodel } from '@/jlmap3d/jl3ddevice/config.js';
|
// import { Staticmodel } from '@/jlmap3d/jl3ddevice/config.js';
|
||||||
import { JL3D_LOCAL_STATIC } from '@/api/jlmap3d/assets3d.js';
|
import { JL3D_LOCAL_STATIC } from '@/api/jlmap3d/assets3d.js';
|
||||||
|
|
||||||
//loader
|
//loader
|
||||||
@ -9,8 +9,6 @@ import { ModelManagerVR } from '@/jlmap3d/jl3dmaintainer/jl3dFaultDeviceVr/utils
|
|||||||
import { TrainControl } from '@/jlmap3d/jl3dmaintainer/jl3dFaultDeviceVr/utils/trainControl.js';
|
import { TrainControl } from '@/jlmap3d/jl3dmaintainer/jl3dFaultDeviceVr/utils/trainControl.js';
|
||||||
import { MoveanimateVr } from '@/jlmap3d/jl3dmaintainer/jl3dFaultDeviceVr/utils/moveanimatevr.js';
|
import { MoveanimateVr } from '@/jlmap3d/jl3dmaintainer/jl3dFaultDeviceVr/utils/moveanimatevr.js';
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
import { Textconfig } from '@/jlmap3d/jl3ddevice/component/textconfig.js';
|
import { Textconfig } from '@/jlmap3d/jl3ddevice/component/textconfig.js';
|
||||||
|
|
||||||
import {Materialload} from '@/jlmap3d/main/loaders/Materialload.js';
|
import {Materialload} from '@/jlmap3d/main/loaders/Materialload.js';
|
||||||
|
@ -1,39 +1,39 @@
|
|||||||
import { JL3D_LOCAL_STATIC } from '@/api/jlmap3d/assets3d.js';
|
import { JL3D_LOCAL_STATIC,BASE_ASSET_API } from '@/api/jlmap3d/assets3d.js';
|
||||||
var TrainRescueStatic = {
|
var TrainRescueStatic = {
|
||||||
animatemodel: {
|
animatemodel: {
|
||||||
id: "1",
|
id: "1",
|
||||||
name: "动画模型",
|
name: "动画模型",
|
||||||
deviceType: "animatemodel",
|
deviceType: "animatemodel",
|
||||||
type: "animatemodel",
|
type: "animatemodel",
|
||||||
url: JL3D_LOCAL_STATIC+"/vrtest/trainrescue/DH923.FBX"
|
url: BASE_ASSET_API+"/MODEL/2020-11-23/74-28231.FBX"
|
||||||
},//"https://joylink.club/oss/wx/switch/switch.FBX"
|
},//"https://joylink.club/oss/wx/switch/switch.FBX"
|
||||||
floorplane: {
|
floorplane: {
|
||||||
id: "2",
|
id: "2",
|
||||||
name: "行走范围",
|
name: "行走范围",
|
||||||
deviceType: "runplane",
|
deviceType: "runplane",
|
||||||
type: "runplane",
|
type: "runplane",
|
||||||
url: JL3D_LOCAL_STATIC+"/vrtest/trainrescue/diban.FBX"
|
url: BASE_ASSET_API+"/MODEL/2020-11-23/75-84310.FBX"
|
||||||
},
|
},
|
||||||
controlmodel: {
|
controlmodel: {
|
||||||
id: "3",
|
id: "3",
|
||||||
name: "控制台",
|
name: "控制台",
|
||||||
deviceType: "controlmodel",
|
deviceType: "controlmodel",
|
||||||
type: "controlmodel",
|
type: "controlmodel",
|
||||||
url: JL3D_LOCAL_STATIC+"/vrtest/trainrescue/kongzhigan.FBX"
|
url: BASE_ASSET_API+"/MODEL/2020-11-23/77-45640.FBX"
|
||||||
},
|
},
|
||||||
other: {
|
other: {
|
||||||
id: "4",
|
id: "4",
|
||||||
name: "其他",
|
name: "其他",
|
||||||
deviceType: "other",
|
deviceType: "other",
|
||||||
type: "other",
|
type: "other",
|
||||||
url: JL3D_LOCAL_STATIC+"/vrtest/trainrescue/TK.FBX"
|
url: BASE_ASSET_API+"/MODEL/2020-11-23/78-39158.FBX"
|
||||||
},
|
},
|
||||||
handR: {
|
handR: {
|
||||||
id: "5",
|
id: "5",
|
||||||
name: "handr",
|
name: "handr",
|
||||||
deviceType: "handr",
|
deviceType: "handr",
|
||||||
type: "handr",
|
type: "handr",
|
||||||
url: JL3D_LOCAL_STATIC+"/vrtest/trainrescue/handr.FBX"
|
url: BASE_ASSET_API+"/MODEL/2020-11-23/76-34528.FBX"
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -1,71 +0,0 @@
|
|||||||
import { JL3D_LOCAL_STATIC } from '@/api/jlmap3d/assets3d.js';
|
|
||||||
var Staticmodel = {
|
|
||||||
man1: {
|
|
||||||
id: "1",
|
|
||||||
name: "人物1",
|
|
||||||
deviceType: "man",
|
|
||||||
type: "man",
|
|
||||||
picUrl: "",
|
|
||||||
assetUrl: JL3D_LOCAL_STATIC+"/MODEL/passflow/man1.FBX"
|
|
||||||
},//"https://joylink.club/oss/wx/switch/switch.FBX"
|
|
||||||
man2: {
|
|
||||||
id: "2",
|
|
||||||
name: "人物2",
|
|
||||||
deviceType: "man",
|
|
||||||
type: "man",
|
|
||||||
picUrl: "",
|
|
||||||
assetUrl: JL3D_LOCAL_STATIC+"/MODEL/passflow/man2.FBX"
|
|
||||||
},
|
|
||||||
station: {
|
|
||||||
id: "3",
|
|
||||||
name: "车站",
|
|
||||||
deviceType: "station",
|
|
||||||
type: "hrb",
|
|
||||||
picUrl: "",
|
|
||||||
assetUrl: JL3D_LOCAL_STATIC+"/MODEL/passflow/station.FBX"
|
|
||||||
},
|
|
||||||
zhajiin: {
|
|
||||||
id: "4",
|
|
||||||
name: "闸机",
|
|
||||||
deviceType: "zhajiin",
|
|
||||||
type: "hrb",
|
|
||||||
picUrl: "",
|
|
||||||
assetUrl: JL3D_LOCAL_STATIC+"/MODEL/passflow/zhajiin.FBX"
|
|
||||||
},
|
|
||||||
zhajiout: {
|
|
||||||
id: "5",
|
|
||||||
name: "闸机",
|
|
||||||
deviceType: "zhajiout",
|
|
||||||
type: "hrb",
|
|
||||||
picUrl: "",
|
|
||||||
assetUrl: JL3D_LOCAL_STATIC+"/MODEL/passflow/zhajiout.FBX"
|
|
||||||
},
|
|
||||||
monitor: {
|
|
||||||
id: "6",
|
|
||||||
name: "摄像机",
|
|
||||||
deviceType: "monitor",
|
|
||||||
type: "hrb",
|
|
||||||
picUrl: "",
|
|
||||||
assetUrl: JL3D_LOCAL_STATIC+"/MODEL/passflow/monitor.FBX"
|
|
||||||
},
|
|
||||||
train: {
|
|
||||||
id: "7",
|
|
||||||
name: "列车",
|
|
||||||
deviceType: "train",
|
|
||||||
type: "hrb",
|
|
||||||
picUrl: "",
|
|
||||||
assetUrl: JL3D_LOCAL_STATIC+"/MODEL/train/train.FBX"
|
|
||||||
},
|
|
||||||
section: {
|
|
||||||
id: "8",
|
|
||||||
name: "区段",
|
|
||||||
deviceType: "section",
|
|
||||||
type: "hrb",
|
|
||||||
picUrl: "",
|
|
||||||
assetUrl: JL3D_LOCAL_STATIC+"/MODEL/passflow/section.FBX"
|
|
||||||
},
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
export { Staticmodel }
|
|
@ -1,4 +1,3 @@
|
|||||||
import { Staticmodel } from '@/jlmap3d/jl3dpassflow/config.js';
|
|
||||||
//静态资源文件路劲
|
//静态资源文件路劲
|
||||||
import { JL3D_LOCAL_STATIC } from '@/api/jlmap3d/assets3d.js';
|
import { JL3D_LOCAL_STATIC } from '@/api/jlmap3d/assets3d.js';
|
||||||
//loader
|
//loader
|
||||||
|
@ -1,53 +1,53 @@
|
|||||||
import { JL3D_LOCAL_STATIC } from '@/api/jlmap3d/assets3d.js';
|
import { JL3D_LOCAL_STATIC,BASE_ASSET_API } from '@/api/jlmap3d/assets3d.js';
|
||||||
var Staticmodel = [
|
var Staticmodel = [
|
||||||
{
|
{
|
||||||
id: "1",
|
id: "1",
|
||||||
name: "人物1",
|
name: "人物1",
|
||||||
deviceType: "man1",
|
deviceType: "man1",
|
||||||
type: "man1",
|
type: "man1",
|
||||||
url: "/cbtc/static/MODEL/passflow/man1.FBX"
|
url: BASE_ASSET_API + "/MODEL/2020-07-16/1-9933.FBX"
|
||||||
},{
|
},{
|
||||||
id: "2",
|
id: "2",
|
||||||
name: "人物2",
|
name: "人物2",
|
||||||
deviceType: "man2",
|
deviceType: "man2",
|
||||||
type: "man2",
|
type: "man2",
|
||||||
url: "/cbtc/static/MODEL/passflow/man2.FBX"
|
url: BASE_ASSET_API + "/MODEL/2020-07-16/2-87850.FBX"
|
||||||
},{
|
},{
|
||||||
id: "3",
|
id: "3",
|
||||||
name: "车站",
|
name: "车站",
|
||||||
deviceType: "cctvStation",
|
deviceType: "cctvStation",
|
||||||
type: "cctvStation",
|
type: "cctvStation",
|
||||||
url: "/cbtc/static/trafficplan/station.FBX"
|
url: BASE_ASSET_API + "/MODEL/2020-11-23/79-95086.FBX"
|
||||||
},{
|
},{
|
||||||
id: "4",
|
id: "4",
|
||||||
name: "闸机",
|
name: "闸机",
|
||||||
deviceType: "cctvGateIn",
|
deviceType: "cctvGateIn",
|
||||||
type: "cctvGateIn",
|
type: "cctvGateIn",
|
||||||
url: "/cbtc/static/MODEL/passflow/zhajiin.FBX"
|
url: BASE_ASSET_API + "/MODEL/2020-07-20/42-7172.FBX"
|
||||||
},{
|
},{
|
||||||
id: "5",
|
id: "5",
|
||||||
name: "闸机",
|
name: "闸机",
|
||||||
deviceType: "cctvGateOut",
|
deviceType: "cctvGateOut",
|
||||||
type: "cctvGateOut",
|
type: "cctvGateOut",
|
||||||
url: "/cbtc/static/MODEL/passflow/zhajiout.FBX"
|
url: BASE_ASSET_API + "/MODEL/2020-07-20/43-8227.FBX"
|
||||||
},{
|
},{
|
||||||
id: "6",
|
id: "6",
|
||||||
name: "摄像机",
|
name: "摄像机",
|
||||||
deviceType: "cctvMonitor",
|
deviceType: "cctvMonitor",
|
||||||
type: "cctvMonitor",
|
type: "cctvMonitor",
|
||||||
url: "/cbtc/static/MODEL/passflow/monitor.FBX"
|
url: BASE_ASSET_API + "/MODEL/2020-07-20/44-24100.FBX"
|
||||||
},{
|
},{
|
||||||
id: "7",
|
id: "7",
|
||||||
name: "列车",
|
name: "列车",
|
||||||
deviceType: "cctvTrain",
|
deviceType: "cctvTrain",
|
||||||
type: "cctvTrain",
|
type: "cctvTrain",
|
||||||
url: "/cbtc/static/trafficplan/normaltrain.FBX"
|
url: BASE_ASSET_API + "/MODEL/2020-11-23/80-14604.FBX"
|
||||||
},{
|
},{
|
||||||
id: "8",
|
id: "8",
|
||||||
name: "区段",
|
name: "区段",
|
||||||
deviceType: "cctvSection",
|
deviceType: "cctvSection",
|
||||||
type: "cctvSection",
|
type: "cctvSection",
|
||||||
url: "/cbtc/static/MODEL/passflow/section.FBX"
|
url: BASE_ASSET_API + "/MODEL/2020-07-20/45-36330.FBX"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,25 +1,25 @@
|
|||||||
import { JL3D_LOCAL_STATIC } from '@/api/jlmap3d/assets3d.js';
|
import { JL3D_LOCAL_STATIC,BASE_ASSET_API } from '@/api/jlmap3d/assets3d.js';
|
||||||
var Staticmodel = [
|
var Staticmodel = [
|
||||||
{
|
{
|
||||||
id: "1",
|
id: "1",
|
||||||
name: "人物1",
|
name: "人物1",
|
||||||
deviceType: "man1",
|
deviceType: "man1",
|
||||||
type: "man1",
|
type: "man1",
|
||||||
url: "/cbtc/static/trafficplan/man1.FBX"
|
url: BASE_ASSET_API + "/MODEL/2020-07-16/1-9933.FBX"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
id: "2",
|
id: "2",
|
||||||
name: "人物2",
|
name: "人物2",
|
||||||
deviceType: "man2",
|
deviceType: "man2",
|
||||||
type: "man2",
|
type: "man2",
|
||||||
url: "/cbtc/static/trafficplan/man2.FBX"
|
url: BASE_ASSET_API + "/MODEL/2020-07-16/2-87850.FBX"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
id: "7",
|
id: "7",
|
||||||
name: "列车",
|
name: "列车",
|
||||||
deviceType: "train",
|
deviceType: "train",
|
||||||
type: "cctvTrain",
|
type: "cctvTrain",
|
||||||
url: "/cbtc/static/trafficplan/train.FBX"
|
url: BASE_ASSET_API + "/MODEL/2020-11-16/48-14909.FBX"
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
|
|
||||||
|
@ -2,9 +2,8 @@ import { AssetModel } from '@/jlmap3d/main/loaders/model/Assetmodel';
|
|||||||
import { Assetmaterial } from '@/jlmap3d/main/loaders/model/Assetmaterial';
|
import { Assetmaterial } from '@/jlmap3d/main/loaders/model/Assetmaterial';
|
||||||
import { getBaseUrl } from '@/utils/baseUrl';
|
import { getBaseUrl } from '@/utils/baseUrl';
|
||||||
import { Loading } from 'element-ui';
|
import { Loading } from 'element-ui';
|
||||||
import { BASE_ASSET_API } from '@/api/jlmap3d/assets3d.js';
|
|
||||||
const BASE_API = getBaseUrl();
|
const BASE_API = getBaseUrl();
|
||||||
import { JL3D_LOCAL_STATIC } from '@/api/jlmap3d/assets3d.js';
|
import { JL3D_LOCAL_STATIC,BASE_ASSET_API } from '@/api/jlmap3d/assets3d.js';
|
||||||
|
|
||||||
let defaultsignal = {
|
let defaultsignal = {
|
||||||
id:"3",
|
id:"3",
|
||||||
@ -12,7 +11,7 @@ let defaultsignal = {
|
|||||||
deviceType:"signal",
|
deviceType:"signal",
|
||||||
type:"low",
|
type:"low",
|
||||||
picUrl:"",
|
picUrl:"",
|
||||||
url:JL3D_LOCAL_STATIC+"/MODEL/signal/d3d.FBX"
|
url:BASE_ASSET_API+"/MODEL/signal/d3d.FBX"
|
||||||
}
|
}
|
||||||
|
|
||||||
let defaulttrain = {
|
let defaulttrain = {
|
||||||
@ -21,7 +20,7 @@ let defaulttrain = {
|
|||||||
deviceType:"train",
|
deviceType:"train",
|
||||||
type:"num4",
|
type:"num4",
|
||||||
picUrl:"",
|
picUrl:"",
|
||||||
url:JL3D_LOCAL_STATIC+"/MODEL/train/train.FBX"
|
url:BASE_ASSET_API+"/MODEL/train/train.FBX"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -31,34 +30,24 @@ let defaultstation = {
|
|||||||
deviceType:"stand",
|
deviceType:"stand",
|
||||||
type:"num4",
|
type:"num4",
|
||||||
picUrl:"",
|
picUrl:"",
|
||||||
url:JL3D_LOCAL_STATIC+"/MODEL/station/fuzhou.FBX"
|
url:BASE_ASSET_API+"/MODEL/station/fuzhou.FBX"
|
||||||
}//JL3D_LOCAL_STATIC+"/MODEL/station/fuzhou/fuzhou.FBX"
|
}
|
||||||
let waicestation = {
|
let waicestation = {
|
||||||
id:"10",
|
id:"10",
|
||||||
name:"外侧车站",
|
name:"外侧车站",
|
||||||
deviceType:"standwaice",
|
deviceType:"standwaice",
|
||||||
type:"num4",
|
type:"num4",
|
||||||
picUrl:"",
|
picUrl:"",
|
||||||
url:JL3D_LOCAL_STATIC+"/MODEL/station/waicestation.FBX"
|
url:BASE_ASSET_API+"/MODEL/station/waicestation.FBX"
|
||||||
}
|
}
|
||||||
let station3 = {
|
|
||||||
id:"10000",
|
|
||||||
name:"特殊站台",
|
|
||||||
deviceType:"station3",
|
|
||||||
type:"num4",
|
|
||||||
picUrl:"",
|
|
||||||
url:JL3D_LOCAL_STATIC+"/MODEL/station/station3.FBX"
|
|
||||||
}
|
|
||||||
//JL3D_LOCAL_STATIC+"/MODEL/station/fuzhou/fuzhou.FBX"
|
|
||||||
//https://test.joylink.club/oss/station/fuzhou/fuzhou.FBX
|
|
||||||
//https://joylink.club/oss/station/fuzhou/fuzhou.FBX
|
|
||||||
let defaultswitch = {
|
let defaultswitch = {
|
||||||
id:"11",
|
id:"11",
|
||||||
name:"道岔",
|
name:"道岔",
|
||||||
deviceType:"switch",
|
deviceType:"switch",
|
||||||
type:"fuzhou",
|
type:"fuzhou",
|
||||||
picUrl:"",
|
picUrl:"",
|
||||||
url:JL3D_LOCAL_STATIC+"/MODEL/daocha/daocha.FBX"
|
url:BASE_ASSET_API+"/MODEL/daocha/daocha.FBX"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -68,37 +57,19 @@ let defaultsuidao = {
|
|||||||
deviceType:"suidao",
|
deviceType:"suidao",
|
||||||
type:"suidao",
|
type:"suidao",
|
||||||
picUrl:"",
|
picUrl:"",
|
||||||
url:JL3D_LOCAL_STATIC+"/MODEL/suidao/suidao.FBX"
|
url:BASE_ASSET_API+"/MODEL/suidao/suidao.FBX"
|
||||||
}
|
}
|
||||||
|
|
||||||
let hebsuidao = {
|
|
||||||
id:"1010",
|
|
||||||
name:"hebsuidao",
|
|
||||||
deviceType:"hebsuidao",
|
|
||||||
type:"hebsuidao",
|
|
||||||
picUrl:"",
|
|
||||||
url:JL3D_LOCAL_STATIC+"/MODEL/suidao/hebsuidao.FBX"
|
|
||||||
}
|
|
||||||
let nbsuidao = {
|
|
||||||
id:"1010",
|
|
||||||
name:"nbsuidao",
|
|
||||||
deviceType:"nbsuidao",
|
|
||||||
type:"nbsuidao",
|
|
||||||
picUrl:"",
|
|
||||||
url:JL3D_LOCAL_STATIC+"/MODEL/suidao/nbsuidao.FBX"
|
|
||||||
}
|
|
||||||
let defaultbackground = {
|
let defaultbackground = {
|
||||||
id:"16",
|
id:"16",
|
||||||
name:"background",
|
name:"background",
|
||||||
deviceType:"background",
|
deviceType:"background",
|
||||||
type:"background",
|
type:"background",
|
||||||
picUrl:"",
|
picUrl:"",
|
||||||
url:JL3D_LOCAL_STATIC+"/MODEL/suidao/background.FBX"
|
url:BASE_ASSET_API+"/MODEL/suidao/background.FBX"
|
||||||
}
|
}
|
||||||
//JL3D_LOCAL_STATIC+"/MODEL/suidao/suidao.FBX"
|
|
||||||
//https://test.joylink.club/oss/suidao/suidao.FBX
|
|
||||||
//https://joylink.club/oss/suidao/suidao.FBX
|
|
||||||
|
|
||||||
|
|
||||||
let defaultautorail = {
|
let defaultautorail = {
|
||||||
id:"100",
|
id:"100",
|
||||||
@ -106,7 +77,7 @@ let defaultautorail = {
|
|||||||
deviceType:"autorail",
|
deviceType:"autorail",
|
||||||
type:"autorail",
|
type:"autorail",
|
||||||
picUrl:"",
|
picUrl:"",
|
||||||
url:JL3D_LOCAL_STATIC+"/MODEL/auto/rail.FBX"
|
url:BASE_ASSET_API+"/MODEL/auto/rail.FBX"
|
||||||
}
|
}
|
||||||
|
|
||||||
let autoswitch = {
|
let autoswitch = {
|
||||||
@ -115,7 +86,7 @@ let autoswitch = {
|
|||||||
deviceType:"autoswitch",
|
deviceType:"autoswitch",
|
||||||
type:"fuzhou",
|
type:"fuzhou",
|
||||||
picUrl:"",
|
picUrl:"",
|
||||||
url:JL3D_LOCAL_STATIC+"/MODEL/auto/autoswitch.FBX"
|
url:BASE_ASSET_API+"/MODEL/auto/autoswitch.FBX"
|
||||||
}
|
}
|
||||||
|
|
||||||
let autoswitch1 = {
|
let autoswitch1 = {
|
||||||
@ -124,7 +95,7 @@ let autoswitch1 = {
|
|||||||
deviceType:"autoswitch1",
|
deviceType:"autoswitch1",
|
||||||
type:"fuzhou",
|
type:"fuzhou",
|
||||||
picUrl:"",
|
picUrl:"",
|
||||||
url:JL3D_LOCAL_STATIC+"/MODEL/auto/switch1.FBX"
|
url:BASE_ASSET_API+"/MODEL/auto/switch1.FBX"
|
||||||
}
|
}
|
||||||
|
|
||||||
let autoswitch2 = {
|
let autoswitch2 = {
|
||||||
@ -133,7 +104,7 @@ let autoswitch2 = {
|
|||||||
deviceType:"autoswitch2",
|
deviceType:"autoswitch2",
|
||||||
type:"fuzhou",
|
type:"fuzhou",
|
||||||
picUrl:"",
|
picUrl:"",
|
||||||
url:JL3D_LOCAL_STATIC+"/MODEL/auto/switch2.FBX"
|
url:BASE_ASSET_API+"/MODEL/auto/switch2.FBX"
|
||||||
}
|
}
|
||||||
|
|
||||||
export function AssetLoader(){
|
export function AssetLoader(){
|
||||||
|
@ -68,7 +68,7 @@ export function DriverLoadNew(data,scope,netdata,mapdata,sectionlist,signallist,
|
|||||||
let signaldata = JSON.parse(netdata.signals);
|
let signaldata = JSON.parse(netdata.signals);
|
||||||
let standsdata = JSON.parse(netdata.stands);
|
let standsdata = JSON.parse(netdata.stands);
|
||||||
let psddata = data.psdList;
|
let psddata = data.psdList;
|
||||||
assetloader.setModelListOver(JSON.parse(netdata.assets).sceneAssetList,-13);
|
assetloader.setModelListOver(JSON.parse(netdata.assets).sceneAssetList,0);
|
||||||
|
|
||||||
assetloader.assetPromiseOver(sceneload)
|
assetloader.assetPromiseOver(sceneload)
|
||||||
.then(function(data){
|
.then(function(data){
|
||||||
|
@ -646,7 +646,7 @@ class SkinCode extends defaultStyle {
|
|||||||
trainHeadArrowOffsetX: 2 // 列车车头三角偏移
|
trainHeadArrowOffsetX: 2 // 列车车头三角偏移
|
||||||
},
|
},
|
||||||
common: {
|
common: {
|
||||||
trainHeight: 17, // 列车高度
|
trainHeight: 10, // 列车高度
|
||||||
trainHeadDistance: 2, // 列车和车头之间的间距
|
trainHeadDistance: 2, // 列车和车头之间的间距
|
||||||
trainWidth: 76, // 列车长度
|
trainWidth: 76, // 列车长度
|
||||||
trainTextFontSize: 10, // 列车字号
|
trainTextFontSize: 10, // 列车字号
|
||||||
|
@ -125,7 +125,7 @@ deviceState[deviceType.StationStand] = {
|
|||||||
assignSkip: 0, // 是否指定跳停
|
assignSkip: 0, // 是否指定跳停
|
||||||
runLevelTime: 0, // 区间运行时间 自动为 0
|
runLevelTime: 0, // 区间运行时间 自动为 0
|
||||||
parkingTime: 0, // 站台停车时间 自动为0
|
parkingTime: 0, // 站台停车时间 自动为0
|
||||||
|
num:0, // 站台上等车人数
|
||||||
// /** 折返策略*/
|
// /** 折返策略*/
|
||||||
// reentryStrategy: {
|
// reentryStrategy: {
|
||||||
// Default: '01', /** 默认(缺省值)*/
|
// Default: '01', /** 默认(缺省值)*/
|
||||||
@ -246,7 +246,9 @@ deviceState[deviceType.Train] = {
|
|||||||
/** 列车精确位置 (成都一号线使用)*/
|
/** 列车精确位置 (成都一号线使用)*/
|
||||||
offsetp:0,
|
offsetp:0,
|
||||||
/** 列车所在物理区段 */
|
/** 列车所在物理区段 */
|
||||||
physicalCode:''
|
physicalCode:'',
|
||||||
|
/** 列车上的人数 */
|
||||||
|
num:0
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -24,7 +24,8 @@ class Status {
|
|||||||
assignSkip: device.assignSkip, // 是否指定跳停
|
assignSkip: device.assignSkip, // 是否指定跳停
|
||||||
runLevelTime: device.runLevelTime, // 区间运行时间 自动为 0
|
runLevelTime: device.runLevelTime, // 区间运行时间 自动为 0
|
||||||
parkingTime: device.parkingTime, // 站台停车时间 自动为0
|
parkingTime: device.parkingTime, // 站台停车时间 自动为0
|
||||||
fault: device.fault /** 非故障*/
|
fault: device.fault, /** 非故障*/
|
||||||
|
num:device.num
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
handleSection(device) {
|
handleSection(device) {
|
||||||
@ -94,7 +95,8 @@ class Status {
|
|||||||
jump: device.jump, /** 是否跳停 */
|
jump: device.jump, /** 是否跳停 */
|
||||||
hold: device.hold, /** 是否扣车 */
|
hold: device.hold, /** 是否扣车 */
|
||||||
offsetp:device.offsetp, /** 列车精确位置 (成都一号线使用)*/
|
offsetp:device.offsetp, /** 列车精确位置 (成都一号线使用)*/
|
||||||
physicalCode:device.physicalCode /** 列车所在物理区段 */
|
physicalCode:device.physicalCode, /** 列车所在物理区段 */
|
||||||
|
num:device.num /** 列车上的人数*/
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
handleStation(device) {
|
handleStation(device) {
|
||||||
|
@ -41,14 +41,34 @@ class ESolidStand extends Group {
|
|||||||
|
|
||||||
setState(model) {
|
setState(model) {
|
||||||
const style = this.model.style;
|
const style = this.model.style;
|
||||||
// 列车跳停
|
const path = window.location.href;
|
||||||
model.assignSkip && this.setColor(style.StationStand.solidStand.designatedJumpStopColor);
|
if (!path.includes('/practiceDisplay')) {
|
||||||
// 全部跳停
|
// 列车跳停
|
||||||
model.allSkip && this.setColor(style.StationStand.solidStand.jumpStopColor);
|
model.assignSkip && this.setColor(style.StationStand.solidStand.designatedJumpStopColor);
|
||||||
// 停车
|
// 全部跳停
|
||||||
model.trainParking && this.setColor(style.StationStand.solidStand.stopColor);
|
model.allSkip && this.setColor(style.StationStand.solidStand.jumpStopColor);
|
||||||
// 紧急停车
|
// 停车
|
||||||
model.emergencyClosed && this.setColor(this.style.StationStand.solidStand.spareColor);
|
model.trainParking && this.setColor(style.StationStand.solidStand.stopColor);
|
||||||
|
// 紧急停车
|
||||||
|
model.emergencyClosed && this.setColor(this.style.StationStand.solidStand.spareColor);
|
||||||
|
} else {
|
||||||
|
this.handlePassagerColor(model.num);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
handlePassagerColor(num) {
|
||||||
|
if (num && num > 0) {
|
||||||
|
const passagerNum = parseInt(num);
|
||||||
|
if (passagerNum < 40) {
|
||||||
|
this.setColor('#29a909');
|
||||||
|
} else if (passagerNum < 80 && passagerNum >= 40) {
|
||||||
|
this.setColor('#ffa500');
|
||||||
|
} else {
|
||||||
|
this.setColor('#F00');
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
this.setColor('#29a909');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -47,12 +47,12 @@ class EMouse extends Group {
|
|||||||
direction = this.device.model.right != 1;
|
direction = this.device.model.right != 1;
|
||||||
}
|
}
|
||||||
if (LangStorage.getLang() == 'en') {
|
if (LangStorage.getLang() == 'en') {
|
||||||
text = ` The planned train: ${trainType} \n Table No.: ${this.device.model.serviceNumber} \n Train Trip No.: ${this.device.model.tripNumber}\n Destination: ${this.device.model.destinationCode ? this.device.model.destinationCode : ''}\n Train No.: ${this.device.model.groupNumber}\n Early or late: ${destinationText}\n Direction: ${direction ? 'up' : 'down'}\n Crew No.: \n Start Station: \n Terminal Station: \n Occupied Track: ${this.device.model.sectionModel ? (this.device.model.sectionModel.parentName ? this.device.model.sectionModel.parentName : this.device.model.sectionModel.name) : ''}\n Current Station: \n Train-ground communication: normal \n Operation Speed level: 4 \n Detained: ${this.device.model.hold ? 'Detained' : 'Normal'}\n \n 跳停状态: ${this.device.model.jump ? 'Skip to continue moving' : 'Normal'}Stationary: ${!this.device.model.stop ? 'No' : 'Yes'}\n Blocked: No \n Speed: ${this.device.model.speed || 0} km/h \n Authorized Distance: ${this.device.model.maLen || 0} m`;
|
text = ` The planned train: ${trainType} \n Table No.: ${this.device.model.serviceNumber} \n Train Trip No.: ${this.device.model.tripNumber}\n Destination: ${this.device.model.destinationCode ? this.device.model.destinationCode : ''}\n Train No.: ${this.device.model.groupNumber}\n Early or late: ${destinationText}\n Direction: ${direction ? 'up' : 'down'}\n Crew No.: \n Start Station: \n Terminal Station: \n Occupied Track: ${this.device.model.sectionModel ? (this.device.model.sectionModel.parentName ? this.device.model.sectionModel.parentName : this.device.model.sectionModel.name) : ''}\n Current Station: \n Train-ground communication: normal \n Operation Speed level: 4 \n Detained: ${this.device.model.hold ? 'Detained' : 'Normal'}\n \n 跳停状态: ${this.device.model.jump ? 'Skip to continue moving' : 'Normal'}Stationary: ${!this.device.model.stop ? 'No' : 'Yes'}\n Blocked: No \n Speed: ${this.device.model.speed || 0} km/h \n Authorized Distance: ${this.device.model.maLen || 0} m\nNumber of people: ${this.device.model.num ? this.device.model.num : 0}`;
|
||||||
} else {
|
} else {
|
||||||
if (Vue.prototype.$jlmap.lineCode == '11' || Vue.prototype.$jlmap.lineCode == '10') {
|
if (Vue.prototype.$jlmap.lineCode == '11' || Vue.prototype.$jlmap.lineCode == '10') {
|
||||||
text = `列车类型: ${trainType}\n来\0\0\0\0源:人工标记\n车\0组\0号: ${this.device.model.groupNumber}\n表\0\0\0\0号: ${this.device.model.serviceNumber}\n车\0次\0号: ${this.device.model.tripNumber}\n目的地号: ${this.device.model.destinationCode ? this.device.model.destinationCode : ''}\n早\0晚\0点: ${destinationText}\n运行方向: ${direction ? '上行' : '下行'}\nATP报告方向: ${direction ? '上行' : '下行'}\n起点站名: \n终点站名: \n占用轨道: ${this.device.model.sectionModel ? (this.device.model.sectionModel.parentName ? this.device.model.sectionModel.parentName : this.device.model.sectionModel.name) : ''}\n所在车站: \n车次通信: 通信车\n运行时间: \n停站时间: \n扣车状态: ${ this.device.model.hold ? '扣车' : '正常'}\n车载扣车: 不执行\n跳停状态: ${this.device.model.jump ? '跳停' : '正常'}\n停稳状态: ${!this.device.model.stop ? '未停稳' : '停稳'}\n阻塞状态: 无\n列车状态: ${this.device.model.runLevel || 'CTC'}车\n最高信号系统控制: CTC\n驾驶模式: ${this.device.model.driveMode}模式\n最高ATP模式: AM\nATP1状态: 激活\nATP2状态: 备用\n速度: ${this.device.model.speed || 0} km/h\n车门状态: ${this.device.model.speed ? '关闭' : direction ? '左开右关' : '左关右开'}\n制动状态: 无紧急制动\n停车保证: 可保证停车\n站台无法进入: 否\n前方站台停车点: 中间\n折法策略: \n折返状态: \n屏蔽门开门许可: 是\n运营里程: 无效\n总重量: 196T\n车长: 11860cm\n列车编组: 1`;
|
text = `列车类型: ${trainType}\n来\0\0\0\0源:人工标记\n车\0组\0号: ${this.device.model.groupNumber}\n表\0\0\0\0号: ${this.device.model.serviceNumber}\n车\0次\0号: ${this.device.model.tripNumber}\n目的地号: ${this.device.model.destinationCode ? this.device.model.destinationCode : ''}\n早\0晚\0点: ${destinationText}\n运行方向: ${direction ? '上行' : '下行'}\nATP报告方向: ${direction ? '上行' : '下行'}\n起点站名: \n终点站名: \n占用轨道: ${this.device.model.sectionModel ? (this.device.model.sectionModel.parentName ? this.device.model.sectionModel.parentName : this.device.model.sectionModel.name) : ''}\n所在车站: \n车次通信: 通信车\n运行时间: \n停站时间: \n扣车状态: ${ this.device.model.hold ? '扣车' : '正常'}\n车载扣车: 不执行\n跳停状态: ${this.device.model.jump ? '跳停' : '正常'}\n停稳状态: ${!this.device.model.stop ? '未停稳' : '停稳'}\n阻塞状态: 无\n列车状态: ${this.device.model.runLevel || 'CTC'}车\n最高信号系统控制: CTC\n驾驶模式: ${this.device.model.driveMode}模式\n最高ATP模式: AM\nATP1状态: 激活\nATP2状态: 备用\n速度: ${this.device.model.speed || 0} km/h\n车门状态: ${this.device.model.speed ? '关闭' : direction ? '左开右关' : '左关右开'}\n制动状态: 无紧急制动\n停车保证: 可保证停车\n站台无法进入: 否\n前方站台停车点: 中间\n折法策略: \n折返状态: \n屏蔽门开门许可: 是\n运营里程: 无效\n总重量: 196T\n车长: 11860cm\n列车编组: 1`;
|
||||||
} else {
|
} else {
|
||||||
text = `列车类型: ${trainType} \n表\0\0\0\0号: ${this.device.model.serviceNumber}\n车\0次\0号: ${this.device.model.tripNumber}\n目的地号: ${this.device.model.destinationCode ? this.device.model.destinationCode : ''}\n车\0组\0号: ${this.device.model.groupNumber}\n早\0晚\0点: ${destinationText}\n运行方向: ${direction ? '上行' : '下行'}\n乘务组号: \n起点站名: \n终点站名: \n占用轨道: ${this.device.model.sectionModel ? (this.device.model.sectionModel.parentName ? this.device.model.sectionModel.parentName : this.device.model.sectionModel.name) : ''}\n所在车站: \n车地通信: 正常\n运行等级: 4\n扣车状态: ${this.device.model.hold ? '扣车' : '正常'}\n跳停状态: ${this.device.model.jump ? '跳停' : '正常'} \n停稳状态: ${!this.device.model.stop ? '未停稳' : '停稳'}\n阻塞状态: 无\n列车速度: ${this.device.model.speed || 0} km/h\n列车移动授权距离: ${this.device.model.maLen || 0} m`;
|
text = `列车类型: ${trainType} \n表\0\0\0\0号: ${this.device.model.serviceNumber}\n车\0次\0号: ${this.device.model.tripNumber}\n目的地号: ${this.device.model.destinationCode ? this.device.model.destinationCode : ''}\n车\0组\0号: ${this.device.model.groupNumber}\n早\0晚\0点: ${destinationText}\n运行方向: ${direction ? '上行' : '下行'}\n乘务组号: \n起点站名: \n终点站名: \n占用轨道: ${this.device.model.sectionModel ? (this.device.model.sectionModel.parentName ? this.device.model.sectionModel.parentName : this.device.model.sectionModel.name) : ''}\n所在车站: \n车地通信: 正常\n运行等级: 4\n扣车状态: ${this.device.model.hold ? '扣车' : '正常'}\n跳停状态: ${this.device.model.jump ? '跳停' : '正常'} \n停稳状态: ${!this.device.model.stop ? '未停稳' : '停稳'}\n阻塞状态: 无\n列车速度: ${this.device.model.speed || 0} km/h\n列车移动授权距离: ${this.device.model.maLen || 0} m${this.device.model.num ? '\n车内人数: ' + this.device.model.num : ''}`;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
const trainTip = this.device.style.Train.common.trainTip;
|
const trainTip = this.device.style.Train.common.trainTip;
|
||||||
|
@ -289,7 +289,8 @@ export default class TrainBody extends Group {
|
|||||||
this.deviceModel.down = false;
|
this.deviceModel.down = false;
|
||||||
}
|
}
|
||||||
setTrainColor(color) {
|
setTrainColor(color) {
|
||||||
this.trainBodyBox && this.trainBodyBox.setStyle('fill', color);
|
this.trainBodyBox && this.trainBodyBox.setColor('fill', color);
|
||||||
|
// Style('fill', color);
|
||||||
}
|
}
|
||||||
setHShow(isShow) {
|
setHShow(isShow) {
|
||||||
if (this.textH) {
|
if (this.textH) {
|
||||||
|
@ -84,6 +84,7 @@ export default class Train extends Group {
|
|||||||
hold:model.hold,
|
hold:model.hold,
|
||||||
jump:model.jump,
|
jump:model.jump,
|
||||||
stop:model.stop,
|
stop:model.stop,
|
||||||
|
num:model.num,
|
||||||
dt: model.dt,
|
dt: model.dt,
|
||||||
driveMode: model.driveMode,
|
driveMode: model.driveMode,
|
||||||
model: model
|
model: model
|
||||||
@ -335,24 +336,36 @@ export default class Train extends Group {
|
|||||||
const flag = model.trainWindowModel ? model.trainWindowModel.reversal : false;
|
const flag = model.trainWindowModel ? model.trainWindowModel.reversal : false;
|
||||||
if (model) {
|
if (model) {
|
||||||
this.recover();
|
this.recover();
|
||||||
if (this.style.Train.common.trainHeadColorChangeMode) {
|
// if (this.style.Train.common.trainHeadColorChangeMode) {
|
||||||
this.setDriveMode(model.driveMode + model.runLevel);
|
// this.setDriveMode(model.driveMode + model.runLevel);
|
||||||
} else {
|
// } else {
|
||||||
this.setDriveMode(model.driveMode);
|
// this.setDriveMode(model.driveMode);
|
||||||
}
|
// }
|
||||||
this.setRunStatus(model.stop, flag);
|
this.setRunStatus(model.stop, flag);
|
||||||
this.setCommunicationStatus(model.runLevel);
|
const path = window.location.href;
|
||||||
|
if (!path.includes('/practiceDisplay')) {
|
||||||
|
if (this.style.Train.common.trainHeadColorChangeMode) {
|
||||||
|
this.setDriveMode(model.driveMode + model.runLevel);
|
||||||
|
} else {
|
||||||
|
this.setDriveMode(model.driveMode);
|
||||||
|
}
|
||||||
|
this.setCommunicationStatus(model.runLevel);
|
||||||
|
this.setSoonerOrLater(model.dt);
|
||||||
|
}
|
||||||
this.setDoorStatus(model.doorCloseLock);
|
this.setDoorStatus(model.doorCloseLock);
|
||||||
this.setAlarmStatus(model.alarmStatus);
|
this.setAlarmStatus(model.alarmStatus);
|
||||||
this.setHoldStatus(model.hold);
|
this.setHoldStatus(model.hold);
|
||||||
this.setJumpStatus(model.jump);
|
this.setJumpStatus(model.jump);
|
||||||
this.setSoonerOrLater(model.dt);
|
// this.setSoonerOrLater(model.dt);
|
||||||
this.setTrainTypeColor(model.type);
|
this.setTrainTypeColor(model.type);
|
||||||
this.setPlanRoutingTypeColor(model.planRoutingType);
|
this.setPlanRoutingTypeColor(model.planRoutingType);
|
||||||
const style = this.style;
|
const style = this.style;
|
||||||
if (style.Section.trainPosition.display) {
|
if (style.Section.trainPosition.display) {
|
||||||
this.updateSection(object);
|
this.updateSection(object);
|
||||||
}
|
}
|
||||||
|
if (path.includes('/practiceDisplay')) {
|
||||||
|
this.handlePassagerColor(model.num);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
setTrainTypeColor(type) {
|
setTrainTypeColor(type) {
|
||||||
@ -365,6 +378,31 @@ export default class Train extends Group {
|
|||||||
this.trainB && this.trainB.removeTrainDetail();
|
this.trainB && this.trainB.removeTrainDetail();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
handlePassagerColor(num) {
|
||||||
|
if (num) {
|
||||||
|
// && num > 0
|
||||||
|
const passagerNum = parseInt(num);
|
||||||
|
if (passagerNum < 100) {
|
||||||
|
this.trainB && this.trainB.setTrainColor('#29a909');
|
||||||
|
this.trainL && this.trainL.setColor('#29a909');
|
||||||
|
this.trainR && this.trainR.setColor('#29a909');
|
||||||
|
} else if (passagerNum < 200 && passagerNum >= 100) {
|
||||||
|
this.trainB && this.trainB.setTrainColor('#ffa500');
|
||||||
|
this.trainL && this.trainL.setColor('#ffa500');
|
||||||
|
this.trainR && this.trainR.setColor('#ffa500');
|
||||||
|
} else {
|
||||||
|
this.trainB && this.trainB.setTrainColor('#F00');
|
||||||
|
this.trainL && this.trainL.setColor('#F00');
|
||||||
|
this.trainR && this.trainR.setColor('#F00');
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
this.trainB && this.trainB.setTrainColor('#29a909');
|
||||||
|
this.trainL && this.trainL.setColor('#29a909');
|
||||||
|
this.trainR && this.trainR.setColor('#29a909');
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
getBoundingRect() {
|
getBoundingRect() {
|
||||||
const list = [this.trainB, this.trainL, this.trainR];
|
const list = [this.trainB, this.trainL, this.trainR];
|
||||||
let rect = null;
|
let rect = null;
|
||||||
|
@ -407,8 +407,9 @@ export default {
|
|||||||
[`集中站 ${this.model.stationName} 区段 ${this.model.sectionName}报告恢复计轴有效`]);
|
[`集中站 ${this.model.stationName} 区段 ${this.model.sectionName}报告恢复计轴有效`]);
|
||||||
}
|
}
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
|
console.error(error);
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.$refs.noticeInfo.doShow(operate, error.message);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
if (this.model.stationName != this.model.confirmStationName) {
|
if (this.model.stationName != this.model.confirmStationName) {
|
||||||
|
@ -121,7 +121,8 @@ export default {
|
|||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate, [error.message]);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
|
@ -149,7 +149,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
|
@ -178,7 +178,7 @@ export default {
|
|||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.$refs.noticeInfo && this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo && this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -196,7 +196,8 @@ export default {
|
|||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow({}, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
|
@ -100,7 +100,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
|
@ -119,7 +119,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
|
@ -148,7 +148,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
|
@ -146,7 +146,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
|
@ -148,7 +148,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
|
@ -127,7 +127,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
|
@ -148,7 +148,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
|
@ -148,7 +148,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
|
@ -130,7 +130,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
|
@ -132,7 +132,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
|
@ -1,6 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="menus" :style="{width: width + 'px'}">
|
<div class="menus" :style="{width: width + 'px'}">
|
||||||
<menu-cancel ref="menuCancel" />
|
|
||||||
<menu-bar v-show="isShowBar" ref="menuBar" :selected="selected" />
|
<menu-bar v-show="isShowBar" ref="menuBar" :selected="selected" />
|
||||||
<menu-button ref="menuButton" />
|
<menu-button ref="menuButton" />
|
||||||
<menu-station-stand ref="menuStationStand" :selected="selected" />
|
<menu-station-stand ref="menuStationStand" :selected="selected" />
|
||||||
@ -18,7 +17,6 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { mapGetters } from 'vuex';
|
import { mapGetters } from 'vuex';
|
||||||
import MenuCancel from './menuCancel';
|
|
||||||
import MenuSignal from './menuSignal';
|
import MenuSignal from './menuSignal';
|
||||||
import MenuButton from './menuButton';
|
import MenuButton from './menuButton';
|
||||||
import MenuStationStand from './menuStationStand';
|
import MenuStationStand from './menuStationStand';
|
||||||
@ -37,7 +35,6 @@ export default {
|
|||||||
components: {
|
components: {
|
||||||
MenuBar,
|
MenuBar,
|
||||||
MenuButton,
|
MenuButton,
|
||||||
MenuCancel,
|
|
||||||
MenuSignal,
|
MenuSignal,
|
||||||
MenuSwitch,
|
MenuSwitch,
|
||||||
MenuSection,
|
MenuSection,
|
||||||
|
@ -356,7 +356,7 @@ export default {
|
|||||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
selectedChange() {
|
selectedChange() {
|
||||||
@ -384,7 +384,7 @@ export default {
|
|||||||
this.$refs.password.doShow(operate);
|
this.$refs.password.doShow(operate);
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -407,7 +407,7 @@ export default {
|
|||||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@ -429,7 +429,7 @@ export default {
|
|||||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
@ -1,122 +0,0 @@
|
|||||||
<template>
|
|
||||||
<div>
|
|
||||||
<pop-menu ref="popMenu" :menu="menu" />
|
|
||||||
</div>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
import PopMenu from '@/components/PopMenu';
|
|
||||||
import { mapGetters } from 'vuex';
|
|
||||||
import { DeviceMenu } from '@/scripts/ConstDic';
|
|
||||||
import { exitFullscreen } from '@/utils/screen';
|
|
||||||
import { runDiagramQuit } from '@/api/simulation';
|
|
||||||
import { EventBus } from '@/scripts/event-bus';
|
|
||||||
|
|
||||||
export default {
|
|
||||||
name: 'CancelMenu',
|
|
||||||
components: {
|
|
||||||
PopMenu
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
menu: [],
|
|
||||||
menuNormal: [],
|
|
||||||
menuScreen: [
|
|
||||||
{
|
|
||||||
label: '放大地图',
|
|
||||||
handler: this.magnifyMap,
|
|
||||||
disabled: false
|
|
||||||
},
|
|
||||||
{
|
|
||||||
label: '缩小地图',
|
|
||||||
handler: this.shrinkMap,
|
|
||||||
disabled: false
|
|
||||||
},
|
|
||||||
{
|
|
||||||
label: '返回',
|
|
||||||
handler: this.back,
|
|
||||||
disabled: false
|
|
||||||
}
|
|
||||||
]
|
|
||||||
};
|
|
||||||
},
|
|
||||||
computed: {
|
|
||||||
...mapGetters('map', [
|
|
||||||
'stationList'
|
|
||||||
]),
|
|
||||||
isScreen() { // 大屏隐藏所有菜单
|
|
||||||
return this.$route.params.mode === 'dp' ||
|
|
||||||
this.$store.state.training.roles == 'BigScreen';
|
|
||||||
},
|
|
||||||
group() {
|
|
||||||
return this.$route.query.group;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
watch: {
|
|
||||||
'$store.state.menuOperation.buttonOperation': function (val, old) {
|
|
||||||
if (!this.isScreen && this.menu && this.menu.length > 1) {
|
|
||||||
this.menu[0].disabled = true;
|
|
||||||
this.menu[1].disabled = !((this.menu[1] && val));
|
|
||||||
}
|
|
||||||
},
|
|
||||||
'$store.state.menuOperation.menuCount': function (val) {
|
|
||||||
if (this.$store.getters['menuOperation/checkDialogIsOpen'](DeviceMenu.Cancel)) {
|
|
||||||
this.doShow(this.$store.state.menuOperation.menuPosition);
|
|
||||||
} else {
|
|
||||||
this.doClose();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
clickEvent() {
|
|
||||||
const self = this;
|
|
||||||
window.onclick = function (e) {
|
|
||||||
self.doClose();
|
|
||||||
};
|
|
||||||
},
|
|
||||||
initMenu() {
|
|
||||||
this.menuNormal = [];
|
|
||||||
if (this.isScreen) {
|
|
||||||
this.menu = [...this.menuScreen];
|
|
||||||
}
|
|
||||||
// else {
|
|
||||||
// this.menu = [...this.menuNormal];
|
|
||||||
// }
|
|
||||||
},
|
|
||||||
doShow(point) {
|
|
||||||
this.clickEvent();
|
|
||||||
this.initMenu();
|
|
||||||
if (this.$refs && this.$refs.popMenu && this.menu && this.menu.length) {
|
|
||||||
this.$refs.popMenu.resetShowPosition(point);
|
|
||||||
}
|
|
||||||
},
|
|
||||||
doClose() {
|
|
||||||
if (this.$refs && this.$refs.popMenu) {
|
|
||||||
this.$refs.popMenu.close();
|
|
||||||
}
|
|
||||||
},
|
|
||||||
// 设置地图定位
|
|
||||||
mapLocation(item) {
|
|
||||||
if (item) {
|
|
||||||
this.$store.dispatch('training/updateOffsetStationCode', { offsetStationCode: item.code });
|
|
||||||
this.doClose();
|
|
||||||
}
|
|
||||||
},
|
|
||||||
// 放大地图
|
|
||||||
magnifyMap() {
|
|
||||||
this.$store.dispatch('menuOperation/handleMagnifyCount');
|
|
||||||
},
|
|
||||||
// 缩小地图
|
|
||||||
shrinkMap() {
|
|
||||||
this.$store.dispatch('menuOperation/handleShrinkCount');
|
|
||||||
},
|
|
||||||
// 返回
|
|
||||||
async back() {
|
|
||||||
await runDiagramQuit(this.group);
|
|
||||||
EventBus.$emit('trainingSubscribeStop');
|
|
||||||
history.go(-1);
|
|
||||||
exitFullscreen();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
};
|
|
||||||
</script>
|
|
@ -124,7 +124,8 @@ export default {
|
|||||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
}
|
}
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(operate, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -151,7 +151,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
|
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
@ -175,7 +175,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -151,7 +151,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
|
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
@ -175,7 +175,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -135,13 +135,11 @@ export default {
|
|||||||
this.loading = false;
|
this.loading = false;
|
||||||
if (valid) {
|
if (valid) {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
} else {
|
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
|
@ -118,8 +118,6 @@ export default {
|
|||||||
this.loading = false;
|
this.loading = false;
|
||||||
if (valid) {
|
if (valid) {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
} else {
|
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
|
@ -135,13 +135,10 @@ export default {
|
|||||||
this.loading = false;
|
this.loading = false;
|
||||||
if (valid) {
|
if (valid) {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
} else {
|
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
|
@ -180,7 +180,7 @@ export default {
|
|||||||
if (selectType.fault) {
|
if (selectType.fault) {
|
||||||
this.faultUnlock(selectType);
|
this.faultUnlock(selectType);
|
||||||
} else {
|
} else {
|
||||||
this.$refs.noticeInfo.doShow({}, `该区段[${selectType.name}(${selectType.code})]没有故障`);
|
this.$refs.noticeInfo.doShow(`该区段[${selectType.name}(${selectType.code})]没有故障`);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -207,7 +207,7 @@ export default {
|
|||||||
if (route) {
|
if (route) {
|
||||||
this.setRoute(route);
|
this.setRoute(route);
|
||||||
} else {
|
} else {
|
||||||
this.$refs.noticeInfo.doShow({}, `没有以[${this.oldSelected.name}(${this.oldSelected.code})]为始端信号机,以[${selectType.name}(${selectType.code})] 为终端信号机的进路`);
|
this.$refs.noticeInfo.doShow(`没有以[${this.oldSelected.name}(${this.oldSelected.code})]为始端信号机,以[${selectType.name}(${selectType.code})] 为终端信号机的进路`);
|
||||||
}
|
}
|
||||||
this.clickNum = 0;
|
this.clickNum = 0;
|
||||||
} else {
|
} else {
|
||||||
@ -244,7 +244,7 @@ export default {
|
|||||||
case OperationEvent.Signal.reopenSignal.button.operation: {
|
case OperationEvent.Signal.reopenSignal.button.operation: {
|
||||||
// 信号重开
|
// 信号重开
|
||||||
if (selectType.greenOpen) {
|
if (selectType.greenOpen) {
|
||||||
this.$refs.noticeInfo.doShow({}, `信号机[${selectType.name}(${selectType.code})]已开启,无需重开信号机`);
|
this.$refs.noticeInfo.doShow(`信号机[${selectType.name}(${selectType.code})]已开启,无需重开信号机`);
|
||||||
} else {
|
} else {
|
||||||
// 开放进路信号机因故关闭
|
// 开放进路信号机因故关闭
|
||||||
this.reopenSignalByRoute(selectType);
|
this.reopenSignalByRoute(selectType);
|
||||||
@ -266,7 +266,7 @@ export default {
|
|||||||
}
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
this.$refs.noticeInfo.doShow({}, `信号机[${selectType.name}(${selectType.code})]没有已锁闭进路,不能设置联锁自动进路`);
|
this.$refs.noticeInfo.doShow(`信号机[${selectType.name}(${selectType.code})]没有已锁闭进路,不能设置联锁自动进路`);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@ -313,7 +313,8 @@ export default {
|
|||||||
setRoute(route) {
|
setRoute(route) {
|
||||||
commitOperate(menuOperate.Signal.arrangementRoute, {routeCode:route.code}, 3).then(({valid, operate})=>{
|
commitOperate(menuOperate.Signal.arrangementRoute, {routeCode:route.code}, 3).then(({valid, operate})=>{
|
||||||
}).catch(error=>{
|
}).catch(error=>{
|
||||||
this.$refs.noticeInfo.doShow({}, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 取消进路
|
// 取消进路
|
||||||
@ -328,7 +329,8 @@ export default {
|
|||||||
cancelTrainRouteByLow(selectType) {
|
cancelTrainRouteByLow(selectType) {
|
||||||
commitOperate(menuOperate.Signal.cancelTrainRoute, {signalCode:selectType.code}, 3).then(({valid, operate})=>{
|
commitOperate(menuOperate.Signal.cancelTrainRoute, {signalCode:selectType.code}, 3).then(({valid, operate})=>{
|
||||||
}).catch(error=>{
|
}).catch(error=>{
|
||||||
this.$refs.noticeInfo.doShow({}, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 现地总人解
|
// 现地总人解
|
||||||
@ -344,7 +346,8 @@ export default {
|
|||||||
reopenSignalByRoute(selectType) {
|
reopenSignalByRoute(selectType) {
|
||||||
commitOperate(menuOperate.Signal.reopenSignal, {signalCode:selectType.code}, 3).then(({valid, operate})=>{
|
commitOperate(menuOperate.Signal.reopenSignal, {signalCode:selectType.code}, 3).then(({valid, operate})=>{
|
||||||
}).catch(error=>{
|
}).catch(error=>{
|
||||||
this.$refs.noticeInfo.doShow({}, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 信号重开
|
// 信号重开
|
||||||
@ -367,7 +370,8 @@ export default {
|
|||||||
signalCloseByLow(selectType) {
|
signalCloseByLow(selectType) {
|
||||||
commitOperate(menuOperate.Signal.signalClose, {signalCode:selectType.code}, 3).then(({valid, operate})=>{
|
commitOperate(menuOperate.Signal.signalClose, {signalCode:selectType.code}, 3).then(({valid, operate})=>{
|
||||||
}).catch(error=>{
|
}).catch(error=>{
|
||||||
this.$refs.noticeInfo.doShow({}, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 进路交人工控
|
// 进路交人工控
|
||||||
@ -390,14 +394,16 @@ export default {
|
|||||||
singalPassModel(selectType) {
|
singalPassModel(selectType) {
|
||||||
commitOperate(menuOperate.Signal.setAutoInterlock, {signalCode:selectType.code}, 3).then(({valid, operate})=>{
|
commitOperate(menuOperate.Signal.setAutoInterlock, {signalCode:selectType.code}, 3).then(({valid, operate})=>{
|
||||||
}).catch(error=>{
|
}).catch(error=>{
|
||||||
this.$refs.noticeInfo.doShow({}, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 取消通过模式
|
// 取消通过模式
|
||||||
singalCancelPassModel(selectType) {
|
singalCancelPassModel(selectType) {
|
||||||
commitOperate(menuOperate.Signal.cancelAutoInterlock, {signalCode:selectType.code}, 3).then(({valid, operate})=>{
|
commitOperate(menuOperate.Signal.cancelAutoInterlock, {signalCode:selectType.code}, 3).then(({valid, operate})=>{
|
||||||
}).catch(error=>{
|
}).catch(error=>{
|
||||||
this.$refs.noticeInfo.doShow({}, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 查询进路状态
|
// 查询进路状态
|
||||||
|
@ -198,7 +198,7 @@ export default {
|
|||||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 全站取消联锁自动触发
|
// 全站取消联锁自动触发
|
||||||
@ -214,7 +214,7 @@ export default {
|
|||||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 上电解锁
|
// 上电解锁
|
||||||
|
@ -223,14 +223,16 @@ export default {
|
|||||||
setDetainTrainByLow(selectType) {
|
setDetainTrainByLow(selectType) {
|
||||||
commitOperate(menuOperate.StationStand.setDetainTrain, {standCode:selectType.code}, 3).then(({valid, operate})=>{
|
commitOperate(menuOperate.StationStand.setDetainTrain, {standCode:selectType.code}, 3).then(({valid, operate})=>{
|
||||||
}).catch(error=>{
|
}).catch(error=>{
|
||||||
this.$refs.noticeInfo.doShow({}, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
/** 取消扣车 */
|
/** 取消扣车 */
|
||||||
cancleDetainTrainByLow(selectType) {
|
cancleDetainTrainByLow(selectType) {
|
||||||
commitOperate(menuOperate.StationStand.cancelDetainTrain, {standCode:selectType.code}, 3).then(({valid, operate})=>{
|
commitOperate(menuOperate.StationStand.cancelDetainTrain, {standCode:selectType.code}, 3).then(({valid, operate})=>{
|
||||||
}).catch(error=>{
|
}).catch(error=>{
|
||||||
this.$refs.noticeInfo.doShow({}, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 设置扣车
|
// 设置扣车
|
||||||
|
@ -226,7 +226,8 @@ export default {
|
|||||||
lock(selectType) {
|
lock(selectType) {
|
||||||
commitOperate(menuOperate.Switch.lock, {switchCode:selectType.code}, 3).then(({valid, operate})=>{
|
commitOperate(menuOperate.Switch.lock, {switchCode:selectType.code}, 3).then(({valid, operate})=>{
|
||||||
}).catch(error=>{
|
}).catch(error=>{
|
||||||
this.$refs.noticeInfo.doShow({}, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 道岔解锁
|
// 道岔解锁
|
||||||
@ -236,7 +237,8 @@ export default {
|
|||||||
this.$refs.switchControl.doShow(operate, selectType);
|
this.$refs.switchControl.doShow(operate, selectType);
|
||||||
}
|
}
|
||||||
}).catch(error=>{
|
}).catch(error=>{
|
||||||
this.$refs.noticeInfo.doShow({}, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 现地道岔强扳
|
// 现地道岔强扳
|
||||||
@ -247,21 +249,24 @@ export default {
|
|||||||
}
|
}
|
||||||
|
|
||||||
}).catch(error=>{
|
}).catch(error=>{
|
||||||
this.$refs.noticeInfo.doShow({}, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 单操到定位
|
// 单操到定位
|
||||||
locate(selectType) {
|
locate(selectType) {
|
||||||
commitOperate(menuOperate.Switch.locate, {switchCode:selectType.code}, 3).then(({valid, operate})=>{
|
commitOperate(menuOperate.Switch.locate, {switchCode:selectType.code}, 3).then(({valid, operate})=>{
|
||||||
}).catch(error=>{
|
}).catch(error=>{
|
||||||
this.$refs.noticeInfo.doShow({}, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 单操到反位
|
// 单操到反位
|
||||||
reverse(selectType) {
|
reverse(selectType) {
|
||||||
commitOperate(menuOperate.Switch.reverse, {switchCode:selectType.code}, 3).then(({valid, operate})=>{
|
commitOperate(menuOperate.Switch.reverse, {switchCode:selectType.code}, 3).then(({valid, operate})=>{
|
||||||
}).catch(error=>{
|
}).catch(error=>{
|
||||||
this.$refs.noticeInfo.doShow({}, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 区段切除
|
// 区段切除
|
||||||
|
@ -330,10 +330,6 @@ export default {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
nextStation() {
|
nextStation() {
|
||||||
// commitOperate(menuOperate.Train.nextStation, { groupNumber: this.selected.code }, 3).then(({valid, operate})=>{
|
|
||||||
// }).catch((error) => {
|
|
||||||
// this.$refs.noticeInfo.doShow(error.message);
|
|
||||||
// });
|
|
||||||
const group = this.$route.query.group;
|
const group = this.$route.query.group;
|
||||||
const param = {
|
const param = {
|
||||||
commandType: 'Drive_Ahead',
|
commandType: 'Drive_Ahead',
|
||||||
@ -342,14 +338,11 @@ export default {
|
|||||||
};
|
};
|
||||||
commitTrainSend(group, param).then(({valid, operate})=>{
|
commitTrainSend(group, param).then(({valid, operate})=>{
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
routeBlockRun() {
|
routeBlockRun() {
|
||||||
// commitOperate(menuOperate.Train.routeBlockRun, { groupNumber: this.selected.code }, 3).then(({valid, operate})=>{
|
|
||||||
// }).catch((error) => {
|
|
||||||
// this.$refs.noticeInfo.doShow(error.message);
|
|
||||||
// });
|
|
||||||
const group = this.$route.query.group;
|
const group = this.$route.query.group;
|
||||||
const param = {
|
const param = {
|
||||||
commandType: 'Route_Block_Drive',
|
commandType: 'Route_Block_Drive',
|
||||||
@ -358,7 +351,8 @@ export default {
|
|||||||
};
|
};
|
||||||
commitTrainSend(group, param).then(({valid, operate})=>{
|
commitTrainSend(group, param).then(({valid, operate})=>{
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
handleOverFuideSignal() {
|
handleOverFuideSignal() {
|
||||||
@ -370,7 +364,8 @@ export default {
|
|||||||
};
|
};
|
||||||
commitTrainSend(group, param).then(({valid, operate})=>{
|
commitTrainSend(group, param).then(({valid, operate})=>{
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
handleOverEedLight() {
|
handleOverEedLight() {
|
||||||
@ -382,7 +377,8 @@ export default {
|
|||||||
};
|
};
|
||||||
commitTrainSend(group, param).then(({valid, operate})=>{
|
commitTrainSend(group, param).then(({valid, operate})=>{
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 限速行驶
|
// 限速行驶
|
||||||
@ -397,10 +393,10 @@ export default {
|
|||||||
if (valid) {
|
if (valid) {
|
||||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
} else {
|
} else {
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
undeveloped() {
|
undeveloped() {
|
||||||
|
@ -226,12 +226,12 @@ export default {
|
|||||||
// if (valid) {
|
// if (valid) {
|
||||||
// this.doClose();
|
// this.doClose();
|
||||||
// } else {
|
// } else {
|
||||||
// // this.$refs.noticeInfo.doShow(operate);
|
// // this.$refs.noticeInfo.doShow();
|
||||||
// }
|
// }
|
||||||
// }).catch(error => {
|
// }).catch(error => {
|
||||||
// this.loading = false;
|
// this.loading = false;
|
||||||
// this.doClose();
|
// this.doClose();
|
||||||
// // this.$refs.noticeInfo.doShow(operate);
|
// // this.$refs.noticeInfo.doShow();
|
||||||
// });
|
// });
|
||||||
// } else {
|
// } else {
|
||||||
// return false;
|
// return false;
|
||||||
|
@ -152,12 +152,12 @@ export default {
|
|||||||
// if (valid) {
|
// if (valid) {
|
||||||
// this.doClose();
|
// this.doClose();
|
||||||
// } else {
|
// } else {
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
// this.$refs.noticeInfo.doShow();
|
||||||
// }
|
// }
|
||||||
// }).catch(() => {
|
// }).catch(() => {
|
||||||
// this.loading = false;
|
// this.loading = false;
|
||||||
// this.doClose();
|
// this.doClose();
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
// this.$refs.noticeInfo.doShow();
|
||||||
// });
|
// });
|
||||||
// } else {
|
// } else {
|
||||||
// return false;
|
// return false;
|
||||||
|
@ -226,12 +226,12 @@ export default {
|
|||||||
// if (valid) {
|
// if (valid) {
|
||||||
// this.doClose();
|
// this.doClose();
|
||||||
// } else {
|
// } else {
|
||||||
// // this.$refs.noticeInfo.doShow(operate);
|
// // this.$refs.noticeInfo.doShow();
|
||||||
// }
|
// }
|
||||||
// }).catch(error => {
|
// }).catch(error => {
|
||||||
// this.loading = false;
|
// this.loading = false;
|
||||||
// this.doClose();
|
// this.doClose();
|
||||||
// // this.$refs.noticeInfo.doShow(operate);
|
// // this.$refs.noticeInfo.doShow();
|
||||||
// });
|
// });
|
||||||
// } else {
|
// } else {
|
||||||
// return false;
|
// return false;
|
||||||
|
@ -1,6 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="chengdou-01__menus" :style="{width: width + 'px'}">
|
<div class="chengdou-01__menus" :style="{width: width + 'px'}">
|
||||||
<menu-cancel ref="menuCancel" />
|
|
||||||
<menu-bar v-show="isShowBar" ref="menuBar" :selected="selected" />
|
<menu-bar v-show="isShowBar" ref="menuBar" :selected="selected" />
|
||||||
<menu-request ref="menuRequest" />
|
<menu-request ref="menuRequest" />
|
||||||
<menu-station-stand ref="menuStationStand" :selected="selected" />
|
<menu-station-stand ref="menuStationStand" :selected="selected" />
|
||||||
@ -19,7 +18,6 @@
|
|||||||
<script>
|
<script>
|
||||||
import { mapGetters } from 'vuex';
|
import { mapGetters } from 'vuex';
|
||||||
import MenuRequest from './menuRequest';
|
import MenuRequest from './menuRequest';
|
||||||
import MenuCancel from './menuCancel';
|
|
||||||
import MenuSignal from './menuSignal';
|
import MenuSignal from './menuSignal';
|
||||||
import MenuStationStand from './menuStationStand';
|
import MenuStationStand from './menuStationStand';
|
||||||
import MenuSwitch from './menuSwitch';
|
import MenuSwitch from './menuSwitch';
|
||||||
|
@ -1,94 +0,0 @@
|
|||||||
<template>
|
|
||||||
<div>
|
|
||||||
<pop-menu ref="popMenu" :menu="menu" />
|
|
||||||
</div>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
import PopMenu from '@/components/PopMenu';
|
|
||||||
import { mapGetters } from 'vuex';
|
|
||||||
import { DeviceMenu } from '@/scripts/ConstDic';
|
|
||||||
import { exitFullscreen } from '@/utils/screen';
|
|
||||||
import { runDiagramQuit } from '@/api/simulation';
|
|
||||||
import { EventBus } from '@/scripts/event-bus';
|
|
||||||
|
|
||||||
export default {
|
|
||||||
name: 'CancelMenu',
|
|
||||||
components: {
|
|
||||||
PopMenu
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
menu: [],
|
|
||||||
menuScreen: [
|
|
||||||
{
|
|
||||||
label: '放大地图',
|
|
||||||
handler: this.magnifyMap,
|
|
||||||
disabled: false
|
|
||||||
},
|
|
||||||
{
|
|
||||||
label: '缩小地图',
|
|
||||||
handler: this.shrinkMap,
|
|
||||||
disabled: false
|
|
||||||
},
|
|
||||||
{
|
|
||||||
label: '返回',
|
|
||||||
handler: this.back,
|
|
||||||
disabled: false
|
|
||||||
}
|
|
||||||
]
|
|
||||||
};
|
|
||||||
},
|
|
||||||
computed: {
|
|
||||||
...mapGetters('map', [
|
|
||||||
'stationList'
|
|
||||||
]),
|
|
||||||
group() {
|
|
||||||
return this.$route.query.group;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
watch: {
|
|
||||||
'$store.state.menuOperation.menuCount': function (val) {
|
|
||||||
if (this.$store.getters['menuOperation/checkDialogIsOpen'](DeviceMenu.Cancel)) {
|
|
||||||
this.doShow(this.$store.state.menuOperation.menuPosition);
|
|
||||||
} else {
|
|
||||||
this.doClose();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
clickEvent() {
|
|
||||||
const self = this;
|
|
||||||
window.onclick = function (e) {
|
|
||||||
self.doClose();
|
|
||||||
};
|
|
||||||
},
|
|
||||||
doShow(point) {
|
|
||||||
this.clickEvent();
|
|
||||||
if (this.$refs && this.$refs.popMenu && this.menu && this.menu.length) {
|
|
||||||
this.$refs.popMenu.resetShowPosition(point);
|
|
||||||
}
|
|
||||||
},
|
|
||||||
doClose() {
|
|
||||||
if (this.$refs && this.$refs.popMenu) {
|
|
||||||
this.$refs.popMenu.close();
|
|
||||||
}
|
|
||||||
},
|
|
||||||
// 放大地图
|
|
||||||
magnifyMap() {
|
|
||||||
this.$store.dispatch('menuOperation/handleMagnifyCount');
|
|
||||||
},
|
|
||||||
// 缩小地图
|
|
||||||
shrinkMap() {
|
|
||||||
this.$store.dispatch('menuOperation/handleShrinkCount');
|
|
||||||
},
|
|
||||||
// 返回
|
|
||||||
async back() {
|
|
||||||
await runDiagramQuit(this.group);
|
|
||||||
EventBus.$emit('trainingSubscribeStop');
|
|
||||||
history.go(-1);
|
|
||||||
exitFullscreen();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
};
|
|
||||||
</script>
|
|
@ -129,7 +129,7 @@ export default {
|
|||||||
}
|
}
|
||||||
}, 1000).catch(() => {
|
}, 1000).catch(() => {
|
||||||
this.loading = true;
|
this.loading = true;
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -123,7 +123,6 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
// this.doClose();
|
// this.doClose();
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -186,10 +186,10 @@ export default {
|
|||||||
if (valid) {
|
if (valid) {
|
||||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
} else {
|
} else {
|
||||||
this.$refs.noticeInfo.doShow(step);
|
this.$refs.noticeInfo.doShow();
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.$refs.noticeInfo.doShow(step);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 设置故障
|
// 设置故障
|
||||||
|
@ -258,7 +258,7 @@ export default {
|
|||||||
this.$refs.routeControl.doShow(step, this.selected);
|
this.$refs.routeControl.doShow(step, this.selected);
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.$refs.noticeInfo.doShow(step);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 设置故障
|
// 设置故障
|
||||||
@ -311,7 +311,7 @@ export default {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.$refs.noticeInfo.doShow(step);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
checkRoutes(routes) {
|
checkRoutes(routes) {
|
||||||
@ -377,7 +377,7 @@ export default {
|
|||||||
this.$store.dispatch('menuOperation/pushRequestList', { device: this.selected, operation: { code: OperationEvent.Signal.lock.menu.operation, name: '终端信号机封锁', cmdType:CMD.Signal.CMD_SIGNAL_BLOCK}});
|
this.$store.dispatch('menuOperation/pushRequestList', { device: this.selected, operation: { code: OperationEvent.Signal.lock.menu.operation, name: '终端信号机封锁', cmdType:CMD.Signal.CMD_SIGNAL_BLOCK}});
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.$refs.noticeInfo.doShow(step);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 信号解封
|
// 信号解封
|
||||||
|
@ -142,12 +142,12 @@ export default {
|
|||||||
// if (valid) {
|
// if (valid) {
|
||||||
// this.doClose();
|
// this.doClose();
|
||||||
// } else {
|
// } else {
|
||||||
// // this.$refs.noticeInfo.doShow(operate);
|
// // this.$refs.noticeInfo.doShow();
|
||||||
// }
|
// }
|
||||||
// }).catch(error => {
|
// }).catch(error => {
|
||||||
// this.loading = false;
|
// this.loading = false;
|
||||||
// this.doClose();
|
// this.doClose();
|
||||||
// // this.$refs.noticeInfo.doShow(operate);
|
// // this.$refs.noticeInfo.doShow();
|
||||||
// });
|
// });
|
||||||
// } else {
|
// } else {
|
||||||
// return false;
|
// return false;
|
||||||
|
@ -217,7 +217,7 @@ export default {
|
|||||||
|
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.$refs.noticeInfo.doShow(step);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
triggerFaultManagement() {
|
triggerFaultManagement() {
|
||||||
|
@ -240,10 +240,6 @@ export default {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
nextStation() {
|
nextStation() {
|
||||||
// commitOperate(menuOperate.Train.nextStation, { groupNumber: this.selected.code }, 3).then(({valid, operate})=>{
|
|
||||||
// }).catch((error) => {
|
|
||||||
// this.$refs.noticeInfo.doShow(error.message);
|
|
||||||
// });
|
|
||||||
const group = this.$route.query.group;
|
const group = this.$route.query.group;
|
||||||
const param = {
|
const param = {
|
||||||
commandType: 'Drive_Ahead',
|
commandType: 'Drive_Ahead',
|
||||||
@ -252,14 +248,11 @@ export default {
|
|||||||
};
|
};
|
||||||
commitTrainSend(group, param).then(({valid, operate})=>{
|
commitTrainSend(group, param).then(({valid, operate})=>{
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
routeBlockRun() {
|
routeBlockRun() {
|
||||||
// commitOperate(menuOperate.Train.routeBlockRun, { groupNumber: this.selected.code }, 3).then(({valid, operate})=>{
|
|
||||||
// }).catch((error) => {
|
|
||||||
// this.$refs.noticeInfo.doShow(error.message);
|
|
||||||
// });
|
|
||||||
const group = this.$route.query.group;
|
const group = this.$route.query.group;
|
||||||
const param = {
|
const param = {
|
||||||
commandType: 'Route_Block_Drive',
|
commandType: 'Route_Block_Drive',
|
||||||
@ -268,7 +261,8 @@ export default {
|
|||||||
};
|
};
|
||||||
commitTrainSend(group, param).then(({valid, operate})=>{
|
commitTrainSend(group, param).then(({valid, operate})=>{
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
handleOverFuideSignal() {
|
handleOverFuideSignal() {
|
||||||
@ -280,7 +274,8 @@ export default {
|
|||||||
};
|
};
|
||||||
commitTrainSend(group, param).then(({valid, operate})=>{
|
commitTrainSend(group, param).then(({valid, operate})=>{
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
handleOverEedLight() {
|
handleOverEedLight() {
|
||||||
@ -292,7 +287,8 @@ export default {
|
|||||||
};
|
};
|
||||||
commitTrainSend(group, param).then(({valid, operate})=>{
|
commitTrainSend(group, param).then(({valid, operate})=>{
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 限速行驶
|
// 限速行驶
|
||||||
@ -308,10 +304,10 @@ export default {
|
|||||||
if (valid) {
|
if (valid) {
|
||||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
} else {
|
} else {
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 设计划车
|
// 设计划车
|
||||||
@ -327,7 +323,7 @@ export default {
|
|||||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
this.$refs.trainControl.doShow(operate, this.selected);
|
this.$refs.trainControl.doShow(operate, this.selected);
|
||||||
} else {
|
} else {
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
@ -344,7 +340,7 @@ export default {
|
|||||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
this.$refs.trainControl.doShow(operate, this.selected);
|
this.$refs.trainControl.doShow(operate, this.selected);
|
||||||
} else {
|
} else {
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
@ -361,7 +357,7 @@ export default {
|
|||||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
this.$refs.trainControl.doShow(operate, this.selected);
|
this.$refs.trainControl.doShow(operate, this.selected);
|
||||||
} else {
|
} else {
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
@ -378,7 +374,7 @@ export default {
|
|||||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
this.$refs.trainDetailInfo.doShow(operate, this.selected);
|
this.$refs.trainDetailInfo.doShow(operate, this.selected);
|
||||||
} else {
|
} else {
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
@ -117,7 +117,8 @@ export default {
|
|||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate, [error.message]);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
|
@ -149,7 +149,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
|
@ -183,7 +183,7 @@ export default {
|
|||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.$refs.noticeInfo && this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo && this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -180,7 +180,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
|
@ -232,12 +232,12 @@ export default {
|
|||||||
this.doClose();
|
this.doClose();
|
||||||
} else {
|
} else {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -238,7 +238,8 @@ export default {
|
|||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 进路交自动控
|
// 进路交自动控
|
||||||
@ -250,7 +251,8 @@ export default {
|
|||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
|
@ -271,7 +271,8 @@ export default {
|
|||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -285,7 +286,8 @@ export default {
|
|||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
|
@ -567,7 +567,8 @@ export default {
|
|||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
|
@ -257,7 +257,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
@ -281,7 +281,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
@ -305,7 +305,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
|
@ -117,7 +117,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
|
@ -148,7 +148,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
// this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
|
@ -131,7 +131,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
|
@ -143,7 +143,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
// this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
|
@ -171,7 +171,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
// this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
|
@ -160,7 +160,7 @@ export default {
|
|||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
// this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
|
@ -179,7 +179,8 @@ export default {
|
|||||||
}).catch(error => {
|
}).catch(error => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
console.error(error);
|
||||||
|
// this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
|
@ -1,6 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="menus" :style="{width: width + 'px'}">
|
<div class="menus" :style="{width: width + 'px'}">
|
||||||
<menu-cancel ref="menuCancel" />
|
|
||||||
<menu-bar v-show="isShowBar" ref="menuBar" :selected="selected" />
|
<menu-bar v-show="isShowBar" ref="menuBar" :selected="selected" />
|
||||||
<menu-button ref="menuButton" />
|
<menu-button ref="menuButton" />
|
||||||
<menu-station-stand ref="menuStationStand" :selected="selected" />
|
<menu-station-stand ref="menuStationStand" :selected="selected" />
|
||||||
@ -17,7 +16,6 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { mapGetters } from 'vuex';
|
import { mapGetters } from 'vuex';
|
||||||
import MenuCancel from './menuCancel';
|
|
||||||
import MenuSignal from './menuSignal';
|
import MenuSignal from './menuSignal';
|
||||||
import MenuButton from './menuButton';
|
import MenuButton from './menuButton';
|
||||||
import MenuStationStand from './menuStationStand';
|
import MenuStationStand from './menuStationStand';
|
||||||
|
@ -238,7 +238,8 @@ export default {
|
|||||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
}
|
}
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(operate, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
resetPosition() {
|
resetPosition() {
|
||||||
@ -356,11 +357,12 @@ export default {
|
|||||||
});
|
});
|
||||||
if (!flag) {
|
if (!flag) {
|
||||||
this.deviceList = [];
|
this.deviceList = [];
|
||||||
this.$refs.noticeInfo.doShow(operate, '未找到选择进路!');
|
this.$refs.noticeInfo.doShow('未找到选择进路!');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
handelFunctionButton(model, subType) {
|
handelFunctionButton(model, subType) {
|
||||||
|
debugger;
|
||||||
const operate = {
|
const operate = {
|
||||||
over: true,
|
over: true,
|
||||||
operation: this.$store.state.menuOperation.buttonOperation,
|
operation: this.$store.state.menuOperation.buttonOperation,
|
||||||
@ -391,14 +393,15 @@ export default {
|
|||||||
operate.param = {stationCodes: [model.code]};
|
operate.param = {stationCodes: [model.code]};
|
||||||
break;
|
break;
|
||||||
case 'emergency':
|
case 'emergency':
|
||||||
operate.cmdType = CMD.ControlConvertMenu.CMD_CM_FORCE_STATION_CONTROL;
|
operate.cmdType = CMD.ControlConvertMenu.CMD_CM_EMERGENCY_STATION_CONTROL;
|
||||||
operate.param = {stationCodes: [model.code]};
|
operate.param = {stationCodes: [model.code]};
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
this.$store.dispatch('training/nextNew', operate).then(({ valid, response }) => {}).catch((error) => {
|
this.$store.dispatch('training/nextNew', operate).then(({ valid, response }) => {}).catch((error) => {
|
||||||
this.deviceList = [];
|
this.deviceList = [];
|
||||||
this.$refs.noticeInfo.doShow(operate, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
handelTotalCancel(model, subType) {
|
handelTotalCancel(model, subType) {
|
||||||
@ -435,7 +438,8 @@ export default {
|
|||||||
}
|
}
|
||||||
this.$store.dispatch('training/nextNew', operate).then(({ valid, response }) => {}).catch((error) => {
|
this.$store.dispatch('training/nextNew', operate).then(({ valid, response }) => {}).catch((error) => {
|
||||||
this.deviceList = [];
|
this.deviceList = [];
|
||||||
this.$refs.noticeInfo.doShow(operate, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
handleGuideRoute(deviceList) {
|
handleGuideRoute(deviceList) {
|
||||||
@ -458,7 +462,8 @@ export default {
|
|||||||
this.$refs.password.doShow(operate);
|
this.$refs.password.doShow(operate);
|
||||||
}
|
}
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(operate, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
const operate = {
|
const operate = {
|
||||||
@ -476,7 +481,8 @@ export default {
|
|||||||
this.$refs.password.doShow(operate);
|
this.$refs.password.doShow(operate);
|
||||||
}
|
}
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(operate, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
} else if (deviceList.length === 2) {
|
} else if (deviceList.length === 2) {
|
||||||
@ -494,13 +500,14 @@ export default {
|
|||||||
this.deviceList = [];
|
this.deviceList = [];
|
||||||
flag = true;
|
flag = true;
|
||||||
this.$store.dispatch('training/nextNew', operate).then(({ valid, response }) => {}).catch((error) => {
|
this.$store.dispatch('training/nextNew', operate).then(({ valid, response }) => {}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(operate, error.message);
|
this.$refs.noticeInfo.doShow();
|
||||||
|
console.error(error);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
if (!flag) {
|
if (!flag) {
|
||||||
this.deviceList = [];
|
this.deviceList = [];
|
||||||
this.$refs.noticeInfo.doShow(operate, '未找到选择进路!');
|
this.$refs.noticeInfo.doShow('未找到选择进路!');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -519,7 +526,8 @@ export default {
|
|||||||
operate.param = {signalCode: model.code};
|
operate.param = {signalCode: model.code};
|
||||||
this.deviceList = [];
|
this.deviceList = [];
|
||||||
this.$store.dispatch('training/nextNew', operate).then(({valid, response}) => {}).catch((error) => {
|
this.$store.dispatch('training/nextNew', operate).then(({valid, response}) => {}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(operate, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -540,7 +548,8 @@ export default {
|
|||||||
operate.param = {signalCode: model.code, routeCodeList: routeCodeList};
|
operate.param = {signalCode: model.code, routeCodeList: routeCodeList};
|
||||||
this.deviceList = [];
|
this.deviceList = [];
|
||||||
this.$store.dispatch('training/nextNew', operate).then(({valid, response}) => {}).catch((error) => {
|
this.$store.dispatch('training/nextNew', operate).then(({valid, response}) => {}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(operate, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
handelSwitchOperate(model) {
|
handelSwitchOperate(model) {
|
||||||
@ -552,7 +561,8 @@ export default {
|
|||||||
param: { switchCode: model.code}
|
param: { switchCode: model.code}
|
||||||
};
|
};
|
||||||
this.$store.dispatch('training/nextNew', operate).then(({valid, response}) => {}).catch((error) => {
|
this.$store.dispatch('training/nextNew', operate).then(({valid, response}) => {}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(operate, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
handelBlockOrUnblock(model) {
|
handelBlockOrUnblock(model) {
|
||||||
@ -578,7 +588,8 @@ export default {
|
|||||||
operate.param = {signalCode: model.code};
|
operate.param = {signalCode: model.code};
|
||||||
}
|
}
|
||||||
this.$store.dispatch('training/nextNew', operate).then(({valid, response}) => {}).catch((error) => {
|
this.$store.dispatch('training/nextNew', operate).then(({valid, response}) => {}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(operate, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
handelGuideLock(model) {
|
handelGuideLock(model) {
|
||||||
@ -595,7 +606,8 @@ export default {
|
|||||||
operate.cmdType = CMD.Station.CMD_STATION_SET_MASTER_GUIDE_LOCK;
|
operate.cmdType = CMD.Station.CMD_STATION_SET_MASTER_GUIDE_LOCK;
|
||||||
}
|
}
|
||||||
this.$store.dispatch('training/nextNew', operate).then(({valid, response}) => {}).catch((error) => {
|
this.$store.dispatch('training/nextNew', operate).then(({valid, response}) => {}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(operate, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
handelFaultSection(model) {
|
handelFaultSection(model) {
|
||||||
@ -607,7 +619,8 @@ export default {
|
|||||||
param: {sectionCode: model.code}
|
param: {sectionCode: model.code}
|
||||||
};
|
};
|
||||||
this.$store.dispatch('training/nextNew', operate).then(({valid, response}) => {}).catch((error) => {
|
this.$store.dispatch('training/nextNew', operate).then(({valid, response}) => {}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(operate, error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
selectedChange() {
|
selectedChange() {
|
||||||
|
@ -1,94 +0,0 @@
|
|||||||
<template>
|
|
||||||
<div>
|
|
||||||
<pop-menu ref="popMenu" :menu="menu" />
|
|
||||||
</div>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
import PopMenu from '@/components/PopMenu';
|
|
||||||
import { mapGetters } from 'vuex';
|
|
||||||
import { DeviceMenu } from '@/scripts/ConstDic';
|
|
||||||
import { exitFullscreen } from '@/utils/screen';
|
|
||||||
import { runDiagramQuit } from '@/api/simulation';
|
|
||||||
import { EventBus } from '@/scripts/event-bus';
|
|
||||||
|
|
||||||
export default {
|
|
||||||
name: 'CancelMenu',
|
|
||||||
components: {
|
|
||||||
PopMenu
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
menu: [],
|
|
||||||
menuScreen: [
|
|
||||||
{
|
|
||||||
label: '放大地图',
|
|
||||||
handler: this.magnifyMap,
|
|
||||||
disabled: false
|
|
||||||
},
|
|
||||||
{
|
|
||||||
label: '缩小地图',
|
|
||||||
handler: this.shrinkMap,
|
|
||||||
disabled: false
|
|
||||||
},
|
|
||||||
{
|
|
||||||
label: '返回',
|
|
||||||
handler: this.back,
|
|
||||||
disabled: false
|
|
||||||
}
|
|
||||||
]
|
|
||||||
};
|
|
||||||
},
|
|
||||||
computed: {
|
|
||||||
...mapGetters('map', [
|
|
||||||
'stationList'
|
|
||||||
]),
|
|
||||||
group() {
|
|
||||||
return this.$route.query.group;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
watch: {
|
|
||||||
'$store.state.menuOperation.menuCount': function (val) {
|
|
||||||
if (this.$store.getters['menuOperation/checkDialogIsOpen'](DeviceMenu.Cancel)) {
|
|
||||||
this.doShow(this.$store.state.menuOperation.menuPosition);
|
|
||||||
} else {
|
|
||||||
this.doClose();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
clickEvent() {
|
|
||||||
const self = this;
|
|
||||||
window.onclick = function (e) {
|
|
||||||
self.doClose();
|
|
||||||
};
|
|
||||||
},
|
|
||||||
doShow(point) {
|
|
||||||
this.clickEvent();
|
|
||||||
if (this.$refs && this.$refs.popMenu && this.menu && this.menu.length) {
|
|
||||||
this.$refs.popMenu.resetShowPosition(point);
|
|
||||||
}
|
|
||||||
},
|
|
||||||
doClose() {
|
|
||||||
if (this.$refs && this.$refs.popMenu) {
|
|
||||||
this.$refs.popMenu.close();
|
|
||||||
}
|
|
||||||
},
|
|
||||||
// 放大地图
|
|
||||||
magnifyMap() {
|
|
||||||
this.$store.dispatch('menuOperation/handleMagnifyCount');
|
|
||||||
},
|
|
||||||
// 缩小地图
|
|
||||||
shrinkMap() {
|
|
||||||
this.$store.dispatch('menuOperation/handleShrinkCount');
|
|
||||||
},
|
|
||||||
// 返回
|
|
||||||
async back() {
|
|
||||||
await runDiagramQuit(this.group);
|
|
||||||
EventBus.$emit('trainingSubscribeStop');
|
|
||||||
history.go(-1);
|
|
||||||
exitFullscreen();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
};
|
|
||||||
</script>
|
|
@ -129,7 +129,7 @@ export default {
|
|||||||
}
|
}
|
||||||
}, 1000).catch(() => {
|
}, 1000).catch(() => {
|
||||||
this.loading = true;
|
this.loading = true;
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,127 +1,135 @@
|
|||||||
<template>
|
<template>
|
||||||
<el-dialog class="chengdou-03__systerm stand-stop-time" :title="title" :visible.sync="show" width="320px"
|
<el-dialog
|
||||||
:before-close="doClose" :zIndex="2000" :modal="false" :close-on-click-modal="false" v-dialogDrag>
|
v-dialogDrag
|
||||||
<el-row justify="center" class="button-group">
|
class="chengdou-03__systerm stand-stop-time"
|
||||||
<el-col :span="10" :offset="2">
|
:title="title"
|
||||||
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">确定</el-button>
|
:visible.sync="show"
|
||||||
</el-col>
|
width="320px"
|
||||||
<el-col :span="8" :offset="4">
|
:before-close="doClose"
|
||||||
<el-button :id="domIdCancel" @click="cancel">取 消</el-button>
|
:z-index="2000"
|
||||||
</el-col>
|
:modal="false"
|
||||||
</el-row>
|
:close-on-click-modal="false"
|
||||||
</el-dialog>
|
>
|
||||||
|
<el-row justify="center" class="button-group">
|
||||||
|
<el-col :span="10" :offset="2">
|
||||||
|
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">确定</el-button>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8" :offset="4">
|
||||||
|
<el-button :id="domIdCancel" @click="cancel">取 消</el-button>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
</el-dialog>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { mapGetters } from 'vuex';
|
import { mapGetters } from 'vuex';
|
||||||
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'TrainAdd',
|
name: 'TrainAdd',
|
||||||
components: {
|
components: {
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
trainNoList: [],
|
trainNoList: [],
|
||||||
addModel: {
|
addModel: {
|
||||||
|
|
||||||
},
|
|
||||||
|
|
||||||
rules: {
|
|
||||||
// groupNumber: [
|
|
||||||
// { required: true, message: '请输入车次号', trigger: 'blur' }
|
|
||||||
// ],
|
|
||||||
// stationStandCode: [
|
|
||||||
// { required: true, message: '请选择终端', trigger: 'change' }
|
|
||||||
// ],
|
|
||||||
},
|
|
||||||
operation: null,
|
|
||||||
dialogShow: false,
|
|
||||||
loading: false,
|
|
||||||
}
|
|
||||||
},
|
|
||||||
computed: {
|
|
||||||
...mapGetters('map', [
|
|
||||||
'stationStandList'
|
|
||||||
]),
|
|
||||||
show() {
|
|
||||||
return this.dialogShow && !this.$store.state.menuOperation.break;
|
|
||||||
},
|
},
|
||||||
domIdCancel() {
|
|
||||||
return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : '';
|
|
||||||
},
|
|
||||||
domIdConfirm() {
|
|
||||||
return this.dialogShow ? OperationEvent.Command.planTrain.addPlanTrain.domId : '';
|
|
||||||
},
|
|
||||||
title() {
|
|
||||||
return '设置限速'
|
|
||||||
}
|
|
||||||
},
|
|
||||||
mounted() {
|
|
||||||
this.$nextTick(() => {
|
|
||||||
this.$store.dispatch('training/tipReload');
|
|
||||||
})
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
doShow(operate) {
|
|
||||||
this.operate = operate || {};
|
|
||||||
this.operation = operate.operation;
|
|
||||||
|
|
||||||
if (!this.dialogShow) {
|
rules: {
|
||||||
this.loading = false;
|
// groupNumber: [
|
||||||
}
|
// { required: true, message: '请输入车次号', trigger: 'blur' }
|
||||||
|
// ],
|
||||||
this.dialogShow = true;
|
// stationStandCode: [
|
||||||
this.$nextTick(function () {
|
// { required: true, message: '请选择终端', trigger: 'change' }
|
||||||
this.$store.dispatch('training/emitTipFresh');
|
// ],
|
||||||
});
|
|
||||||
},
|
},
|
||||||
doClose() {
|
operation: null,
|
||||||
|
dialogShow: false,
|
||||||
|
loading: false
|
||||||
|
};
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
|
...mapGetters('map', [
|
||||||
|
'stationStandList'
|
||||||
|
]),
|
||||||
|
show() {
|
||||||
|
return this.dialogShow && !this.$store.state.menuOperation.break;
|
||||||
|
},
|
||||||
|
domIdCancel() {
|
||||||
|
return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : '';
|
||||||
|
},
|
||||||
|
domIdConfirm() {
|
||||||
|
return this.dialogShow ? OperationEvent.Command.planTrain.addPlanTrain.domId : '';
|
||||||
|
},
|
||||||
|
title() {
|
||||||
|
return '设置限速';
|
||||||
|
}
|
||||||
|
},
|
||||||
|
mounted() {
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.$store.dispatch('training/tipReload');
|
||||||
|
});
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
doShow(operate) {
|
||||||
|
this.operate = operate || {};
|
||||||
|
this.operation = operate.operation;
|
||||||
|
|
||||||
|
if (!this.dialogShow) {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.dialogShow = false;
|
|
||||||
this.$store.dispatch('training/emitTipFresh');
|
|
||||||
},
|
|
||||||
commit() {
|
|
||||||
this.$refs['form'].validate((valid) => {
|
|
||||||
if (valid) {
|
|
||||||
let operate = {
|
|
||||||
send: true,
|
|
||||||
|
|
||||||
operation: OperationEvent.Command.planTrain.addPlanTrain.operation,
|
|
||||||
}
|
|
||||||
|
|
||||||
this.loading = true;
|
|
||||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
|
||||||
this.loading = false;
|
|
||||||
if (valid) {
|
|
||||||
this.doClose();
|
|
||||||
} else {
|
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
|
||||||
}
|
|
||||||
}).catch(error => {
|
|
||||||
this.loading = false;
|
|
||||||
this.doClose();
|
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
|
||||||
})
|
|
||||||
} else {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
cancel() {
|
|
||||||
let operate = {
|
|
||||||
|
|
||||||
operation: OperationEvent.Command.cancel.menu.operation,
|
|
||||||
}
|
|
||||||
|
|
||||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
|
||||||
if (valid) {
|
|
||||||
this.doClose();
|
|
||||||
}
|
|
||||||
}).catch(error => { this.doClose(); });
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
this.dialogShow = true;
|
||||||
|
this.$nextTick(function () {
|
||||||
|
this.$store.dispatch('training/emitTipFresh');
|
||||||
|
});
|
||||||
|
},
|
||||||
|
doClose() {
|
||||||
|
this.loading = false;
|
||||||
|
this.dialogShow = false;
|
||||||
|
this.$store.dispatch('training/emitTipFresh');
|
||||||
|
},
|
||||||
|
commit() {
|
||||||
|
this.$refs['form'].validate((valid) => {
|
||||||
|
if (valid) {
|
||||||
|
const operate = {
|
||||||
|
send: true,
|
||||||
|
|
||||||
|
operation: OperationEvent.Command.planTrain.addPlanTrain.operation
|
||||||
|
};
|
||||||
|
|
||||||
|
this.loading = true;
|
||||||
|
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||||
|
this.loading = false;
|
||||||
|
if (valid) {
|
||||||
|
this.doClose();
|
||||||
|
}
|
||||||
|
}).catch(error => {
|
||||||
|
this.loading = false;
|
||||||
|
this.doClose();
|
||||||
|
console.error(error);
|
||||||
|
// this.$refs.noticeInfo.doShow();
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
cancel() {
|
||||||
|
const operate = {
|
||||||
|
|
||||||
|
operation: OperationEvent.Command.cancel.menu.operation
|
||||||
|
};
|
||||||
|
|
||||||
|
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||||
|
if (valid) {
|
||||||
|
this.doClose();
|
||||||
|
}
|
||||||
|
}).catch(error => { this.doClose(); });
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
};
|
||||||
</script>
|
</script>
|
||||||
<style scoped>
|
<style scoped>
|
||||||
.chengdou-03__systerm .el-dialog .base-label {
|
.chengdou-03__systerm .el-dialog .base-label {
|
||||||
|
@ -163,7 +163,7 @@ export default {
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
this.$refs.noticeInfo.doShow(operate, ['密码输入错误!']);
|
this.$refs.noticeInfo.doShow('密码输入错误!');
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
click(key) {
|
click(key) {
|
||||||
|
@ -232,13 +232,12 @@ export default {
|
|||||||
this.loading = false;
|
this.loading = false;
|
||||||
if (valid) {
|
if (valid) {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
} else {
|
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
|
||||||
}
|
}
|
||||||
}).catch(error => {
|
}).catch(error => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.doClose();
|
this.doClose();
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
console.error(error);
|
||||||
|
// this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
|
@ -1,154 +1,165 @@
|
|||||||
<template>
|
<template>
|
||||||
<el-dialog class="chengdou-03__systerm stand-stop-time" :title="title" :visible.sync="show" width="320px"
|
<el-dialog
|
||||||
:before-close="doClose" :zIndex="2000" :modal="false" :close-on-click-modal="false" v-dialogDrag>
|
v-dialogDrag
|
||||||
<el-form size="small" label-width="100px" :model="addModel" :rules="rules" ref="form">
|
class="chengdou-03__systerm stand-stop-time"
|
||||||
<div style="padding: 10px 15px; border: 1px double lightgray; margin: 20px 0px; height: 120px;">
|
:title="title"
|
||||||
<span class="base-label">添加位置</span>
|
:visible.sync="show"
|
||||||
<div style="position: relative; top:-10px;">
|
width="320px"
|
||||||
<el-form-item prop="stationStandCode">
|
:before-close="doClose"
|
||||||
<span slot="label">终   端:</span>
|
:z-index="2000"
|
||||||
<el-select v-model="addModel.stationStandCode" filterable placeholder="请选择">
|
:modal="false"
|
||||||
<el-option v-for="item in stationStandList" :key="item.code" :label="item.name"
|
:close-on-click-modal="false"
|
||||||
:value="item.code">
|
>
|
||||||
</el-option>
|
<el-form ref="form" size="small" label-width="100px" :model="addModel" :rules="rules">
|
||||||
</el-select>
|
<div style="padding: 10px 15px; border: 1px double lightgray; margin: 20px 0px; height: 120px;">
|
||||||
</el-form-item>
|
<span class="base-label">添加位置</span>
|
||||||
<el-form-item label="前车车次号:" prop="trainNumberLimber">
|
<div style="position: relative; top:-10px;">
|
||||||
<el-input v-model="addModel.trainNumberLimber"></el-input>
|
<el-form-item prop="stationStandCode">
|
||||||
</el-form-item>
|
<span slot="label">终   端:</span>
|
||||||
</div>
|
<el-select v-model="addModel.stationStandCode" filterable placeholder="请选择">
|
||||||
</div>
|
<el-option
|
||||||
<el-form-item label="添加车次号:" label-width="115px" prop="groupNumber">
|
v-for="item in stationStandList"
|
||||||
<el-input v-model="addModel.groupNumber"></el-input>
|
:key="item.code"
|
||||||
</el-form-item>
|
:label="item.name"
|
||||||
</el-form>
|
:value="item.code"
|
||||||
<el-row justify="center" class="button-group">
|
/>
|
||||||
<el-col :span="10" :offset="2">
|
</el-select>
|
||||||
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">确定</el-button>
|
</el-form-item>
|
||||||
</el-col>
|
<el-form-item label="前车车次号:" prop="trainNumberLimber">
|
||||||
<el-col :span="8" :offset="4">
|
<el-input v-model="addModel.trainNumberLimber" />
|
||||||
<el-button :id="domIdCancel" @click="cancel">取 消</el-button>
|
</el-form-item>
|
||||||
</el-col>
|
</div>
|
||||||
</el-row>
|
</div>
|
||||||
</el-dialog>
|
<el-form-item label="添加车次号:" label-width="115px" prop="groupNumber">
|
||||||
|
<el-input v-model="addModel.groupNumber" />
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
<el-row justify="center" class="button-group">
|
||||||
|
<el-col :span="10" :offset="2">
|
||||||
|
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">确定</el-button>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8" :offset="4">
|
||||||
|
<el-button :id="domIdCancel" @click="cancel">取 消</el-button>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
</el-dialog>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { mapGetters } from 'vuex';
|
import { mapGetters } from 'vuex';
|
||||||
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'TrainAdd',
|
name: 'TrainAdd',
|
||||||
components: {
|
components: {
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
trainNoList: [],
|
trainNoList: [],
|
||||||
addModel: {
|
addModel: {
|
||||||
groupNumber: '',
|
groupNumber: '',
|
||||||
stationStandCode: '',
|
stationStandCode: '',
|
||||||
trainNumberLimber: '',
|
trainNumberLimber: ''
|
||||||
},
|
},
|
||||||
|
|
||||||
rules: {
|
rules: {
|
||||||
groupNumber: [
|
groupNumber: [
|
||||||
{ required: true, message: '请输入车次号', trigger: 'blur' }
|
{ required: true, message: '请输入车次号', trigger: 'blur' }
|
||||||
],
|
],
|
||||||
// trainNumberLimber: [
|
// trainNumberLimber: [
|
||||||
// { required: true, message: '请输入前车车次号', trigger: 'blur' }
|
// { required: true, message: '请输入前车车次号', trigger: 'blur' }
|
||||||
// ],
|
// ],
|
||||||
stationStandCode: [
|
stationStandCode: [
|
||||||
{ required: true, message: '请选择终端', trigger: 'change' }
|
{ required: true, message: '请选择终端', trigger: 'change' }
|
||||||
],
|
]
|
||||||
},
|
|
||||||
operation: null,
|
|
||||||
dialogShow: false,
|
|
||||||
loading: false,
|
|
||||||
}
|
|
||||||
},
|
|
||||||
computed: {
|
|
||||||
...mapGetters('map', [
|
|
||||||
'stationStandList'
|
|
||||||
]),
|
|
||||||
show() {
|
|
||||||
return this.dialogShow && !this.$store.state.menuOperation.break;
|
|
||||||
},
|
},
|
||||||
domIdCancel() {
|
operation: null,
|
||||||
return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : '';
|
dialogShow: false,
|
||||||
},
|
loading: false
|
||||||
domIdConfirm() {
|
};
|
||||||
return this.dialogShow ? OperationEvent.Command.planTrain.addPlanTrain.domId : '';
|
},
|
||||||
},
|
computed: {
|
||||||
title() {
|
...mapGetters('map', [
|
||||||
return '添加计划车'
|
'stationStandList'
|
||||||
}
|
]),
|
||||||
|
show() {
|
||||||
|
return this.dialogShow && !this.$store.state.menuOperation.break;
|
||||||
},
|
},
|
||||||
mounted() {
|
domIdCancel() {
|
||||||
this.$nextTick(() => {
|
return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : '';
|
||||||
this.$store.dispatch('training/tipReload');
|
|
||||||
})
|
|
||||||
},
|
},
|
||||||
methods: {
|
domIdConfirm() {
|
||||||
doShow(operate) {
|
return this.dialogShow ? OperationEvent.Command.planTrain.addPlanTrain.domId : '';
|
||||||
this.operate = operate || {};
|
},
|
||||||
this.operation = operate.operation;
|
title() {
|
||||||
|
return '添加计划车';
|
||||||
|
}
|
||||||
|
},
|
||||||
|
mounted() {
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.$store.dispatch('training/tipReload');
|
||||||
|
});
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
doShow(operate) {
|
||||||
|
this.operate = operate || {};
|
||||||
|
this.operation = operate.operation;
|
||||||
|
|
||||||
//非断电激活时设置初始值
|
// 非断电激活时设置初始值
|
||||||
if (!this.dialogShow) {
|
if (!this.dialogShow) {
|
||||||
this.loading = false;
|
|
||||||
}
|
|
||||||
|
|
||||||
this.dialogShow = true;
|
|
||||||
this.$nextTick(function () {
|
|
||||||
this.$store.dispatch('training/emitTipFresh');
|
|
||||||
});
|
|
||||||
},
|
|
||||||
doClose() {
|
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.dialogShow = false;
|
|
||||||
this.$store.dispatch('training/emitTipFresh');
|
|
||||||
},
|
|
||||||
commit() {
|
|
||||||
this.$refs['form'].validate((valid) => {
|
|
||||||
if (valid) {
|
|
||||||
let operate = {
|
|
||||||
send: true,
|
|
||||||
|
|
||||||
operation: OperationEvent.Command.planTrain.addPlanTrain.operation,
|
|
||||||
}
|
|
||||||
|
|
||||||
this.loading = true;
|
|
||||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
|
||||||
this.loading = false;
|
|
||||||
if (valid) {
|
|
||||||
this.doClose();
|
|
||||||
} else {
|
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
|
||||||
}
|
|
||||||
}).catch(error => {
|
|
||||||
this.loading = false;
|
|
||||||
this.doClose();
|
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
|
||||||
})
|
|
||||||
} else {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
cancel() {
|
|
||||||
let operate = {
|
|
||||||
|
|
||||||
operation: OperationEvent.Command.cancel.menu.operation,
|
|
||||||
}
|
|
||||||
|
|
||||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
|
||||||
if (valid) {
|
|
||||||
this.doClose();
|
|
||||||
}
|
|
||||||
}).catch(error => { this.doClose(); });
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
this.dialogShow = true;
|
||||||
|
this.$nextTick(function () {
|
||||||
|
this.$store.dispatch('training/emitTipFresh');
|
||||||
|
});
|
||||||
|
},
|
||||||
|
doClose() {
|
||||||
|
this.loading = false;
|
||||||
|
this.dialogShow = false;
|
||||||
|
this.$store.dispatch('training/emitTipFresh');
|
||||||
|
},
|
||||||
|
commit() {
|
||||||
|
this.$refs['form'].validate((valid) => {
|
||||||
|
if (valid) {
|
||||||
|
const operate = {
|
||||||
|
send: true,
|
||||||
|
|
||||||
|
operation: OperationEvent.Command.planTrain.addPlanTrain.operation
|
||||||
|
};
|
||||||
|
|
||||||
|
this.loading = true;
|
||||||
|
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||||
|
this.loading = false;
|
||||||
|
if (valid) {
|
||||||
|
this.doClose();
|
||||||
|
}
|
||||||
|
}).catch(error => {
|
||||||
|
this.loading = false;
|
||||||
|
this.doClose();
|
||||||
|
console.error(error);
|
||||||
|
// this.$refs.noticeInfo.doShow();
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
cancel() {
|
||||||
|
const operate = {
|
||||||
|
|
||||||
|
operation: OperationEvent.Command.cancel.menu.operation
|
||||||
|
};
|
||||||
|
|
||||||
|
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||||
|
if (valid) {
|
||||||
|
this.doClose();
|
||||||
|
}
|
||||||
|
}).catch(error => { this.doClose(); });
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
};
|
||||||
</script>
|
</script>
|
||||||
<style scoped>
|
<style scoped>
|
||||||
.chengdou-03__systerm .el-dialog .base-label {
|
.chengdou-03__systerm .el-dialog .base-label {
|
||||||
|
@ -1,141 +1,148 @@
|
|||||||
<template>
|
<template>
|
||||||
<el-dialog class="chengdou-03__systerm stand-stop-time" :title="title" :visible.sync="show" width="320px"
|
<el-dialog
|
||||||
:before-close="doClose" :zIndex="2000" :modal="false" :close-on-click-modal="false" v-dialogDrag>
|
v-dialogDrag
|
||||||
<el-form size="small" label-width="100px" :model="addModel" :rules="rules" ref="form">
|
class="chengdou-03__systerm stand-stop-time"
|
||||||
<el-form-item prop="stationStandCode">
|
:title="title"
|
||||||
<span slot="label">终  端:</span>
|
:visible.sync="show"
|
||||||
<el-select v-model="addModel.stationStandCode" filterable placeholder="请选择">
|
width="320px"
|
||||||
<el-option v-for="item in stationStandList" :key="item.code" :label="item.name" :value="item.code">
|
:before-close="doClose"
|
||||||
</el-option>
|
:z-index="2000"
|
||||||
</el-select>
|
:modal="false"
|
||||||
</el-form-item>
|
:close-on-click-modal="false"
|
||||||
<el-form-item label="车 次 号:" prop="groupNumber">
|
>
|
||||||
<el-input v-model="addModel.groupNumber"></el-input>
|
<el-form ref="form" size="small" label-width="100px" :model="addModel" :rules="rules">
|
||||||
</el-form-item>
|
<el-form-item prop="stationStandCode">
|
||||||
</el-form>
|
<span slot="label">终  端:</span>
|
||||||
<el-row justify="center" class="button-group">
|
<el-select v-model="addModel.stationStandCode" filterable placeholder="请选择">
|
||||||
<el-col :span="10" :offset="2">
|
<el-option v-for="item in stationStandList" :key="item.code" :label="item.name" :value="item.code" />
|
||||||
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">确定</el-button>
|
</el-select>
|
||||||
</el-col>
|
</el-form-item>
|
||||||
<el-col :span="8" :offset="4">
|
<el-form-item label="车 次 号:" prop="groupNumber">
|
||||||
<el-button :id="domIdCancel" @click="cancel">取 消</el-button>
|
<el-input v-model="addModel.groupNumber" />
|
||||||
</el-col>
|
</el-form-item>
|
||||||
</el-row>
|
</el-form>
|
||||||
</el-dialog>
|
<el-row justify="center" class="button-group">
|
||||||
|
<el-col :span="10" :offset="2">
|
||||||
|
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">确定</el-button>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8" :offset="4">
|
||||||
|
<el-button :id="domIdCancel" @click="cancel">取 消</el-button>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
</el-dialog>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { mapGetters } from 'vuex';
|
import { mapGetters } from 'vuex';
|
||||||
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'TrainAdd',
|
name: 'TrainAdd',
|
||||||
components: {
|
components: {
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
trainNoList: [],
|
trainNoList: [],
|
||||||
addModel: {
|
addModel: {
|
||||||
groupNumber: '',
|
groupNumber: '',
|
||||||
stationStandCode: '',
|
stationStandCode: ''
|
||||||
},
|
},
|
||||||
|
|
||||||
rules: {
|
rules: {
|
||||||
groupNumber: [
|
groupNumber: [
|
||||||
{ required: true, message: '请输入车次号', trigger: 'blur' }
|
{ required: true, message: '请输入车次号', trigger: 'blur' }
|
||||||
],
|
],
|
||||||
stationStandCode: [
|
stationStandCode: [
|
||||||
{ required: true, message: '请选择终端', trigger: 'change' }
|
{ required: true, message: '请选择终端', trigger: 'change' }
|
||||||
],
|
]
|
||||||
},
|
|
||||||
operation: null,
|
|
||||||
dialogShow: false,
|
|
||||||
loading: false,
|
|
||||||
}
|
|
||||||
},
|
|
||||||
computed: {
|
|
||||||
...mapGetters('map', [
|
|
||||||
'stationStandList'
|
|
||||||
]),
|
|
||||||
show() {
|
|
||||||
return this.dialogShow && !this.$store.state.menuOperation.break;
|
|
||||||
},
|
},
|
||||||
domIdCancel() {
|
operation: null,
|
||||||
return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : '';
|
dialogShow: false,
|
||||||
},
|
loading: false
|
||||||
domIdConfirm() {
|
};
|
||||||
return this.dialogShow ? OperationEvent.Command.planTrain.delPlanTrain.domId : '';
|
},
|
||||||
},
|
computed: {
|
||||||
title() {
|
...mapGetters('map', [
|
||||||
return '删除计划车'
|
'stationStandList'
|
||||||
}
|
]),
|
||||||
|
show() {
|
||||||
|
return this.dialogShow && !this.$store.state.menuOperation.break;
|
||||||
},
|
},
|
||||||
mounted() {
|
domIdCancel() {
|
||||||
this.$nextTick(() => {
|
return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : '';
|
||||||
this.$store.dispatch('training/tipReload');
|
|
||||||
})
|
|
||||||
},
|
},
|
||||||
methods: {
|
domIdConfirm() {
|
||||||
doShow(operate) {
|
return this.dialogShow ? OperationEvent.Command.planTrain.delPlanTrain.domId : '';
|
||||||
this.operate = operate || {};
|
},
|
||||||
this.operation = operate.operation;
|
title() {
|
||||||
|
return '删除计划车';
|
||||||
|
}
|
||||||
|
},
|
||||||
|
mounted() {
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.$store.dispatch('training/tipReload');
|
||||||
|
});
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
doShow(operate) {
|
||||||
|
this.operate = operate || {};
|
||||||
|
this.operation = operate.operation;
|
||||||
|
|
||||||
//非断电激活时设置初始值
|
// 非断电激活时设置初始值
|
||||||
if (!this.dialogShow) {
|
if (!this.dialogShow) {
|
||||||
this.loading = false;
|
|
||||||
}
|
|
||||||
|
|
||||||
this.dialogShow = true;
|
|
||||||
this.$nextTick(function () {
|
|
||||||
this.$store.dispatch('training/emitTipFresh');
|
|
||||||
});
|
|
||||||
},
|
|
||||||
doClose() {
|
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.dialogShow = false;
|
|
||||||
this.$store.dispatch('training/emitTipFresh');
|
|
||||||
},
|
|
||||||
commit() {
|
|
||||||
this.$refs['form'].validate((valid) => {
|
|
||||||
if (valid) {
|
|
||||||
let operate = {
|
|
||||||
send: true,
|
|
||||||
|
|
||||||
operation: OperationEvent.Command.planTrain.delPlanTrain.operation,
|
|
||||||
}
|
|
||||||
|
|
||||||
this.loading = true;
|
|
||||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
|
||||||
this.loading = false;
|
|
||||||
if (valid) {
|
|
||||||
this.doClose();
|
|
||||||
} else {
|
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
|
||||||
}
|
|
||||||
}).catch(error => {
|
|
||||||
this.loading = false;
|
|
||||||
this.doClose();
|
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
|
||||||
})
|
|
||||||
} else {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
cancel() {
|
|
||||||
let operate = {
|
|
||||||
|
|
||||||
operation: OperationEvent.Command.cancel.menu.operation,
|
|
||||||
}
|
|
||||||
|
|
||||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
|
||||||
if (valid) {
|
|
||||||
this.doClose();
|
|
||||||
}
|
|
||||||
}).catch(error => { this.doClose(); });
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
this.dialogShow = true;
|
||||||
|
this.$nextTick(function () {
|
||||||
|
this.$store.dispatch('training/emitTipFresh');
|
||||||
|
});
|
||||||
|
},
|
||||||
|
doClose() {
|
||||||
|
this.loading = false;
|
||||||
|
this.dialogShow = false;
|
||||||
|
this.$store.dispatch('training/emitTipFresh');
|
||||||
|
},
|
||||||
|
commit() {
|
||||||
|
this.$refs['form'].validate((valid) => {
|
||||||
|
if (valid) {
|
||||||
|
const operate = {
|
||||||
|
send: true,
|
||||||
|
|
||||||
|
operation: OperationEvent.Command.planTrain.delPlanTrain.operation
|
||||||
|
};
|
||||||
|
|
||||||
|
this.loading = true;
|
||||||
|
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||||
|
this.loading = false;
|
||||||
|
if (valid) {
|
||||||
|
this.doClose();
|
||||||
|
}
|
||||||
|
}).catch(error => {
|
||||||
|
this.loading = false;
|
||||||
|
this.doClose();
|
||||||
|
console.error(error);
|
||||||
|
// this.$refs.noticeInfo.doShow();
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
cancel() {
|
||||||
|
const operate = {
|
||||||
|
|
||||||
|
operation: OperationEvent.Command.cancel.menu.operation
|
||||||
|
};
|
||||||
|
|
||||||
|
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||||
|
if (valid) {
|
||||||
|
this.doClose();
|
||||||
|
}
|
||||||
|
}).catch(error => { this.doClose(); });
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
};
|
||||||
</script>
|
</script>
|
||||||
<style scoped>
|
<style scoped>
|
||||||
.chengdou-03__systerm .el-dialog .base-label {
|
.chengdou-03__systerm .el-dialog .base-label {
|
||||||
|
@ -1,152 +1,163 @@
|
|||||||
<template>
|
<template>
|
||||||
<el-dialog class="chengdou-03__systerm stand-stop-time" :title="title" :visible.sync="show" width="320px"
|
<el-dialog
|
||||||
:before-close="doClose" :zIndex="2000" :modal="false" :close-on-click-modal="false" v-dialogDrag>
|
v-dialogDrag
|
||||||
<el-form size="small" label-width="100px" :model="addModel" :rules="rules" ref="form">
|
class="chengdou-03__systerm stand-stop-time"
|
||||||
<el-form-item label="车 次 号:" label-width="115px" prop="groupNumber">
|
:title="title"
|
||||||
<el-input v-model="addModel.groupNumber"></el-input>
|
:visible.sync="show"
|
||||||
</el-form-item>
|
width="320px"
|
||||||
<div style="padding: 10px 15px; border: 1px double lightgray; margin: 20px 0px; height: 120px;">
|
:before-close="doClose"
|
||||||
<span class="base-label">目的</span>
|
:z-index="2000"
|
||||||
<div style="position: relative; top:-10px;">
|
:modal="false"
|
||||||
<el-form-item prop="stationStandCode">
|
:close-on-click-modal="false"
|
||||||
<span slot="label">终  端:</span>
|
>
|
||||||
<el-select v-model="addModel.stationStandCode" filterable placeholder="请选择">
|
<el-form ref="form" size="small" label-width="100px" :model="addModel" :rules="rules">
|
||||||
<el-option v-for="item in stationStandList" :key="item.code" :label="item.name"
|
<el-form-item label="车 次 号:" label-width="115px" prop="groupNumber">
|
||||||
:value="item.code">
|
<el-input v-model="addModel.groupNumber" />
|
||||||
</el-option>
|
</el-form-item>
|
||||||
</el-select>
|
<div style="padding: 10px 15px; border: 1px double lightgray; margin: 20px 0px; height: 120px;">
|
||||||
</el-form-item>
|
<span class="base-label">目的</span>
|
||||||
<el-form-item label="车 次 号:" prop="trainNumberLimber">
|
<div style="position: relative; top:-10px;">
|
||||||
<el-input v-model="addModel.trainNumberLimber"></el-input>
|
<el-form-item prop="stationStandCode">
|
||||||
</el-form-item>
|
<span slot="label">终  端:</span>
|
||||||
</div>
|
<el-select v-model="addModel.stationStandCode" filterable placeholder="请选择">
|
||||||
</div>
|
<el-option
|
||||||
</el-form>
|
v-for="item in stationStandList"
|
||||||
<el-row justify="center" class="button-group">
|
:key="item.code"
|
||||||
<el-col :span="10" :offset="2">
|
:label="item.name"
|
||||||
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">确定</el-button>
|
:value="item.code"
|
||||||
</el-col>
|
/>
|
||||||
<el-col :span="8" :offset="4">
|
</el-select>
|
||||||
<el-button :id="domIdCancel" @click="cancel">取 消</el-button>
|
</el-form-item>
|
||||||
</el-col>
|
<el-form-item label="车 次 号:" prop="trainNumberLimber">
|
||||||
</el-row>
|
<el-input v-model="addModel.trainNumberLimber" />
|
||||||
</el-dialog>
|
</el-form-item>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</el-form>
|
||||||
|
<el-row justify="center" class="button-group">
|
||||||
|
<el-col :span="10" :offset="2">
|
||||||
|
<el-button :id="domIdConfirm" type="primary" :loading="loading" @click="commit">确定</el-button>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8" :offset="4">
|
||||||
|
<el-button :id="domIdCancel" @click="cancel">取 消</el-button>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
</el-dialog>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { mapGetters } from 'vuex';
|
import { mapGetters } from 'vuex';
|
||||||
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'TrainTranstalet',
|
name: 'TrainTranstalet',
|
||||||
components: {
|
components: {
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
trainNoList: [],
|
trainNoList: [],
|
||||||
addModel: {
|
addModel: {
|
||||||
groupNumber: '',
|
groupNumber: '',
|
||||||
stationStandCode: '',
|
stationStandCode: '',
|
||||||
trainNumberLimber: '',
|
trainNumberLimber: ''
|
||||||
},
|
},
|
||||||
|
|
||||||
rules: {
|
rules: {
|
||||||
groupNumber: [
|
groupNumber: [
|
||||||
{ required: true, message: '请输入车次号', trigger: 'blur' }
|
{ required: true, message: '请输入车次号', trigger: 'blur' }
|
||||||
],
|
],
|
||||||
trainNumberLimber: [
|
trainNumberLimber: [
|
||||||
{ required: true, message: '请输入前车车次号', trigger: 'blur' }
|
{ required: true, message: '请输入前车车次号', trigger: 'blur' }
|
||||||
],
|
],
|
||||||
stationStandCode: [
|
stationStandCode: [
|
||||||
{ required: true, message: '请选择终端', trigger: 'change' }
|
{ required: true, message: '请选择终端', trigger: 'change' }
|
||||||
],
|
]
|
||||||
},
|
|
||||||
operation: null,
|
|
||||||
dialogShow: false,
|
|
||||||
loading: false,
|
|
||||||
}
|
|
||||||
},
|
|
||||||
computed: {
|
|
||||||
...mapGetters('map', [
|
|
||||||
'stationStandList'
|
|
||||||
]),
|
|
||||||
show() {
|
|
||||||
return this.dialogShow && !this.$store.state.menuOperation.break;
|
|
||||||
},
|
},
|
||||||
domIdCancel() {
|
operation: null,
|
||||||
return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : '';
|
dialogShow: false,
|
||||||
},
|
loading: false
|
||||||
domIdConfirm() {
|
};
|
||||||
return this.dialogShow ? OperationEvent.Command.planTrain.translatPlanTrain.domId : '';
|
},
|
||||||
},
|
computed: {
|
||||||
title() {
|
...mapGetters('map', [
|
||||||
return '平移计划车'
|
'stationStandList'
|
||||||
}
|
]),
|
||||||
|
show() {
|
||||||
|
return this.dialogShow && !this.$store.state.menuOperation.break;
|
||||||
},
|
},
|
||||||
mounted() {
|
domIdCancel() {
|
||||||
this.$nextTick(() => {
|
return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : '';
|
||||||
this.$store.dispatch('training/tipReload');
|
|
||||||
})
|
|
||||||
},
|
},
|
||||||
methods: {
|
domIdConfirm() {
|
||||||
doShow(operate) {
|
return this.dialogShow ? OperationEvent.Command.planTrain.translatPlanTrain.domId : '';
|
||||||
this.operate = operate || {};
|
},
|
||||||
this.operation = operate.operation;
|
title() {
|
||||||
|
return '平移计划车';
|
||||||
|
}
|
||||||
|
},
|
||||||
|
mounted() {
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.$store.dispatch('training/tipReload');
|
||||||
|
});
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
doShow(operate) {
|
||||||
|
this.operate = operate || {};
|
||||||
|
this.operation = operate.operation;
|
||||||
|
|
||||||
//非断电激活时设置初始值
|
// 非断电激活时设置初始值
|
||||||
if (!this.dialogShow) {
|
if (!this.dialogShow) {
|
||||||
this.loading = false;
|
|
||||||
}
|
|
||||||
|
|
||||||
this.dialogShow = true;
|
|
||||||
this.$nextTick(function () {
|
|
||||||
this.$store.dispatch('training/emitTipFresh');
|
|
||||||
});
|
|
||||||
},
|
|
||||||
doClose() {
|
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.dialogShow = false;
|
|
||||||
this.$store.dispatch('training/emitTipFresh');
|
|
||||||
},
|
|
||||||
commit() {
|
|
||||||
this.$refs['form'].validate((valid) => {
|
|
||||||
if (valid) {
|
|
||||||
let operate = {
|
|
||||||
send: true,
|
|
||||||
|
|
||||||
operation: OperationEvent.Command.planTrain.translatPlanTrain.operation,
|
|
||||||
}
|
|
||||||
|
|
||||||
this.loading = true;
|
|
||||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
|
||||||
this.loading = false;
|
|
||||||
if (valid) {
|
|
||||||
this.doClose();
|
|
||||||
} else {
|
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
|
||||||
}
|
|
||||||
}).catch(error => {
|
|
||||||
this.loading = false;
|
|
||||||
this.doClose();
|
|
||||||
// this.$refs.noticeInfo.doShow(operate);
|
|
||||||
})
|
|
||||||
} else {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
cancel() {
|
|
||||||
let operate = {
|
|
||||||
|
|
||||||
operation: OperationEvent.Command.cancel.menu.operation,
|
|
||||||
}
|
|
||||||
|
|
||||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
|
||||||
if (valid) {
|
|
||||||
this.doClose();
|
|
||||||
}
|
|
||||||
}).catch(error => { this.doClose(); });
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
this.dialogShow = true;
|
||||||
|
this.$nextTick(function () {
|
||||||
|
this.$store.dispatch('training/emitTipFresh');
|
||||||
|
});
|
||||||
|
},
|
||||||
|
doClose() {
|
||||||
|
this.loading = false;
|
||||||
|
this.dialogShow = false;
|
||||||
|
this.$store.dispatch('training/emitTipFresh');
|
||||||
|
},
|
||||||
|
commit() {
|
||||||
|
this.$refs['form'].validate((valid) => {
|
||||||
|
if (valid) {
|
||||||
|
const operate = {
|
||||||
|
send: true,
|
||||||
|
|
||||||
|
operation: OperationEvent.Command.planTrain.translatPlanTrain.operation
|
||||||
|
};
|
||||||
|
|
||||||
|
this.loading = true;
|
||||||
|
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||||
|
this.loading = false;
|
||||||
|
if (valid) {
|
||||||
|
this.doClose();
|
||||||
|
}
|
||||||
|
}).catch(error => {
|
||||||
|
this.loading = false;
|
||||||
|
this.doClose();
|
||||||
|
console.error(error);
|
||||||
|
// this.$refs.noticeInfo.doShow();
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
cancel() {
|
||||||
|
const operate = {
|
||||||
|
|
||||||
|
operation: OperationEvent.Command.cancel.menu.operation
|
||||||
|
};
|
||||||
|
|
||||||
|
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||||
|
if (valid) {
|
||||||
|
this.doClose();
|
||||||
|
}
|
||||||
|
}).catch(error => { this.doClose(); });
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
};
|
||||||
</script>
|
</script>
|
||||||
|
@ -173,10 +173,10 @@ export default {
|
|||||||
if (valid) {
|
if (valid) {
|
||||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
} else {
|
} else {
|
||||||
this.$refs.noticeInfo.doShow(step);
|
this.$refs.noticeInfo.doShow();
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.$refs.noticeInfo.doShow(step);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 故障解锁
|
// 故障解锁
|
||||||
|
@ -219,10 +219,6 @@ export default {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
nextStation() {
|
nextStation() {
|
||||||
// commitOperate(menuOperate.Train.nextStation, { groupNumber: this.selected.code }, 3).then(({valid, operate})=>{
|
|
||||||
// }).catch((error) => {
|
|
||||||
// this.$refs.noticeInfo.doShow(error.message);
|
|
||||||
// });
|
|
||||||
const group = this.$route.query.group;
|
const group = this.$route.query.group;
|
||||||
const param = {
|
const param = {
|
||||||
commandType: 'Drive_Ahead',
|
commandType: 'Drive_Ahead',
|
||||||
@ -231,14 +227,11 @@ export default {
|
|||||||
};
|
};
|
||||||
commitTrainSend(group, param).then(({valid, operate})=>{
|
commitTrainSend(group, param).then(({valid, operate})=>{
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
routeBlockRun() {
|
routeBlockRun() {
|
||||||
// commitOperate(menuOperate.Train.routeBlockRun, { groupNumber: this.selected.code }, 3).then(({valid, operate})=>{
|
|
||||||
// }).catch((error) => {
|
|
||||||
// this.$refs.noticeInfo.doShow(error.message);
|
|
||||||
// });
|
|
||||||
const group = this.$route.query.group;
|
const group = this.$route.query.group;
|
||||||
const param = {
|
const param = {
|
||||||
commandType: 'Route_Block_Drive',
|
commandType: 'Route_Block_Drive',
|
||||||
@ -247,7 +240,8 @@ export default {
|
|||||||
};
|
};
|
||||||
commitTrainSend(group, param).then(({valid, operate})=>{
|
commitTrainSend(group, param).then(({valid, operate})=>{
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
handleOverFuideSignal() {
|
handleOverFuideSignal() {
|
||||||
@ -259,7 +253,8 @@ export default {
|
|||||||
};
|
};
|
||||||
commitTrainSend(group, param).then(({valid, operate})=>{
|
commitTrainSend(group, param).then(({valid, operate})=>{
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
handleOverEedLight() {
|
handleOverEedLight() {
|
||||||
@ -271,7 +266,8 @@ export default {
|
|||||||
};
|
};
|
||||||
commitTrainSend(group, param).then(({valid, operate})=>{
|
commitTrainSend(group, param).then(({valid, operate})=>{
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
this.$refs.noticeInfo.doShow(error.message);
|
console.error(error);
|
||||||
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 限速行驶
|
// 限速行驶
|
||||||
@ -287,10 +283,10 @@ export default {
|
|||||||
if (valid) {
|
if (valid) {
|
||||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
} else {
|
} else {
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 设计划车
|
// 设计划车
|
||||||
@ -306,7 +302,7 @@ export default {
|
|||||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
this.$refs.trainControl.doShow(operate, this.selected);
|
this.$refs.trainControl.doShow(operate, this.selected);
|
||||||
} else {
|
} else {
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
@ -323,7 +319,7 @@ export default {
|
|||||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
this.$refs.trainControl.doShow(operate, this.selected);
|
this.$refs.trainControl.doShow(operate, this.selected);
|
||||||
} else {
|
} else {
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
@ -340,7 +336,7 @@ export default {
|
|||||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
this.$refs.trainControl.doShow(operate, this.selected);
|
this.$refs.trainControl.doShow(operate, this.selected);
|
||||||
} else {
|
} else {
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
@ -357,7 +353,7 @@ export default {
|
|||||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||||
this.$refs.trainDetailInfo.doShow(operate, this.selected);
|
this.$refs.trainDetailInfo.doShow(operate, this.selected);
|
||||||
} else {
|
} else {
|
||||||
this.$refs.noticeInfo.doShow(operate);
|
this.$refs.noticeInfo.doShow();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user