修改三维订阅接口

This commit is contained in:
sunzhenyu 2019-11-15 17:34:07 +08:00
parent f7b909f85d
commit 03c97eefef
3 changed files with 6 additions and 6 deletions

View File

@ -3,7 +3,7 @@ import StompClient from '@/utils/sock';
import { getTrainingCbtcDemon, runDiagramStart, runDiagramOver, setTrainingCbtcInitTime } from '@/api/simulation';
import { creatSubscribe, clearSubscribe, displayTopic, screenTopic } from '@/utils/stomp';
import { handleToken } from '@/utils/auth';
import { getToken } from '@/utils/auth';
import router from '@/router';
// 定于仿真socket接口
@ -41,7 +41,7 @@ export function Jl3dDriving(updatemmi,sound,translation,routegroup) {
var datatype = '00';
this.teststomp = new StompClient();
this.topic = '/user/queue/simulation/jl3d/'+routegroup;
let header = {'X-Token': handleToken() };
let header = {'X-Token': getToken() };
this.updatamap = function(newsectionlist,newlinklist,newsignallist,newstationstandlist,newtrainlisttest,newrealsectionlist,newrails, materiallist, nowaction, scene) {
// console.log(mapdata);

View File

@ -74,7 +74,7 @@ export function UpdateTrain(camera,traindata,control){
}
if(trainmodel.status == "02" && mmovecurve.points.length>1){
if(trainmodel.status == "02" && movecurve.points.length>1){
let point = movecurve.getPointAt(trainmodel.progress);
trainmodel.position.x = point.x;
trainmodel.position.y = 0;

View File

@ -3,7 +3,7 @@ import StompClient from '@/utils/sock';
import { getTrainingCbtcDemon, runDiagramStart, runDiagramOver, setTrainingCbtcInitTime } from '@/api/simulation';
import { creatSubscribe, clearSubscribe, displayTopic, screenTopic } from '@/utils/stomp';
import { handleToken } from '@/utils/auth';
import { getToken } from '@/utils/auth';
import router from '@/router';
// 定于仿真socket接口
@ -41,7 +41,7 @@ export function Jlmap3dSubscribe(jlmap3d,routegroup) {
var datatype = '00';
this.teststomp = new StompClient();
this.topic = '/user/queue/simulation/jl3d/'+routegroup;
const header = {'X-Token': handleToken() };
const header = {'X-Token': getToken() };
this.updatamap = function(mapdata, materiallist, nowaction, scene) {
// console.log(mapdata);
@ -444,7 +444,7 @@ export function Jlmap3dSubscribe(jlmap3d,routegroup) {
// 0x32CD32 绿
if (data.body[i]._type == 'Signal' && signallist) {
if (signallist) {
console.log(data.body[i]);
// console.log(data.body[i]);
signalupdate(data.body[i]);
}
}