From 507fdd25931697e8d1d085ce59c383b06615f745 Mon Sep 17 00:00:00 2001
From: fan <18706759286@163.com>
Date: Wed, 22 Jul 2020 13:30:56 +0800
Subject: [PATCH] =?UTF-8?q?=E7=BB=BC=E5=90=88=E4=BB=BF=E7=9C=9F=E9=A1=B5?=
=?UTF-8?q?=E9=9D=A2=E8=B0=83=E6=95=B4&=E5=88=A0=E9=99=A4=E8=BF=9E?=
=?UTF-8?q?=E6=8E=A5=E7=9C=9F=E5=AE=9E=E8=AE=BE=E5=A4=87?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/router/{index_HYD.js => index_HEB.js} | 0
src/scripts/ProjectConfig.js | 1 +
src/store/{index_HYD.js => index_HEB.js} | 0
src/utils/request.js | 1 +
src/utils/sock.js | 8 +-
src/views/login/index.vue | 8 +-
src/views/newMap/jointTrainingNew/index.vue | 20 --
.../newMap/jointTrainingNew/menuDemon.vue | 28 +-
.../jointTrainingNew/menuDraft/realDevice.vue | 293 ------------------
.../newMap/jointTrainingNew/menuSchema.vue | 43 ++-
vue.config.js | 2 +-
11 files changed, 38 insertions(+), 366 deletions(-)
rename src/router/{index_HYD.js => index_HEB.js} (100%)
rename src/store/{index_HYD.js => index_HEB.js} (100%)
delete mode 100644 src/views/newMap/jointTrainingNew/menuDraft/realDevice.vue
diff --git a/src/router/index_HYD.js b/src/router/index_HEB.js
similarity index 100%
rename from src/router/index_HYD.js
rename to src/router/index_HEB.js
diff --git a/src/scripts/ProjectConfig.js b/src/scripts/ProjectConfig.js
index 4fd9fb833..196197743 100644
--- a/src/scripts/ProjectConfig.js
+++ b/src/scripts/ProjectConfig.js
@@ -226,6 +226,7 @@ export const VersionBaseNoShow = ['heb', 'designheb']; // 登录页右下角版
export const MainBodyNoShow = ['heb', 'designheb', 'jyd', 'designjyd', 'tky', 'designtky', 'bxkc', 'designbxkc']; // 登录页右下角主体不展示
export const GenerateRouteProjectList = ['jsxt', 'refereeJsxt'];// 需要在公共路由中生成登录页面的项目
export const ProjectLoginStyleList = ['jsxt', 'refereeJsxt', 'gzb', 'designgzb', 'xty', 'designxty', 'xadt', 'designxadt', 'tky', 'designtky', 'jyd', 'designjyd', 'bxkc', 'designbxkc']; // 登录页样式
+export const NoQrcodeList = ['heb', 'designheb'];
export const goOtherPlatformMenu = { // 导航栏快速切换平台
login: '/design/login',
design: '/login',
diff --git a/src/store/index_HYD.js b/src/store/index_HEB.js
similarity index 100%
rename from src/store/index_HYD.js
rename to src/store/index_HEB.js
diff --git a/src/utils/request.js b/src/utils/request.js
index 0e9119800..0b109b4b7 100644
--- a/src/utils/request.js
+++ b/src/utils/request.js
@@ -63,6 +63,7 @@ service.interceptors.response.use(
});
});
});
+ return response.data;
} else if (res.code === 500) {
const defaultError = { type: '服务异常:', message: '未知错误!'};
const errorTip = ConstConfig.ConstSelect.interfaceErrorConfig[res.code + ''];
diff --git a/src/utils/sock.js b/src/utils/sock.js
index 8f28e28c9..dd9928771 100644
--- a/src/utils/sock.js
+++ b/src/utils/sock.js
@@ -53,9 +53,11 @@ StompClient.prototype = {
// sock断开回调
that.clientIns.ws.onclose = () => {
console.info(`通信连接已断开!`);
- checkLoginLine().then(() => {
- that.count++;
- that.reconnect(that.count);
+ checkLoginLine().then((resp) => {
+ if (resp.code == 200) {
+ that.count++;
+ that.reconnect(that.count);
+ }
}).catch((err) => {
that.logOut(err);
});
diff --git a/src/views/login/index.vue b/src/views/login/index.vue
index dd85e37f8..612275fba 100644
--- a/src/views/login/index.vue
+++ b/src/views/login/index.vue
@@ -79,7 +79,7 @@
{{ $t('login.autoLogin') }}
@@ -140,7 +138,6 @@ export default {
questionList: [],
practicalExamTime: 0,
isAdmin: false,
- adminMode: true,
deviceShow: false
};
},
@@ -250,7 +247,6 @@ export default {
this.group = this.$route.query.group;
this.mapId = this.$route.query.mapId;
this.lineCode = this.$route.query.lineCode;
- // this.drawWay = this.$route.query.drawWay;
Message.closeAll();
},
async mounted() {
@@ -351,7 +347,6 @@ export default {
if (!isSuccess) {
this.$store.dispatch('map/mapClear');
}
-
this.$nextTick(() => {
EventBus.$emit('viewLoading', false);
});
@@ -375,11 +370,6 @@ export default {
this.endViewLoading();
}
},
- async initDeviceVo() {
- // getLoginInfo(getToken()).then(resp => {
- // this.$store.dispatch('SetProjecteDevice', resp.data.deviceVO);
- // });
- },
initMemberUserInfo() {
getSimulationMemberList(this.$route.query.group).then(resp => {
this.$store.dispatch('training/setMemberList', {memberList:resp.data, userId: this.$store.state.user.id});
@@ -465,7 +455,6 @@ export default {
resp['code'] = 200;
resp.data['userRole'] = 'ADMIN';
} else {
- await this.initDeviceVo();
resp = await this.getUserRole();
}
if (resp && resp.code == 200) {
@@ -509,11 +498,6 @@ export default {
this.jl3dmaintainershow = true;
break;
}
- if (this.isAdmin && this.adminMode) {
- this.$store.dispatch('training/setPrdType', swch || '02');
- this.$store.dispatch('training/setRoles', 'AUDIENCE');
- this.hideIbp();
- }
},
startCounting() {
const storeKey = this.$store.state.user.id + '' + this.$route.query.raceId + 'practical';
@@ -690,10 +674,6 @@ export default {
addSimulationMember() {
this.$refs.addMember.doShow();
},
- changeAdminMode(adminMode, swch) { // (管理/演练)模式
- this.adminMode = adminMode;
- this.setSimulationPrdType(swch);
- },
checkRoleChange(data) {
data.forEach(item => {
if (item.messageType === 'KICK_OUT' && item.userId == this.userId) {
diff --git a/src/views/newMap/jointTrainingNew/menuDemon.vue b/src/views/newMap/jointTrainingNew/menuDemon.vue
index f0c373a48..245417189 100644
--- a/src/views/newMap/jointTrainingNew/menuDemon.vue
+++ b/src/views/newMap/jointTrainingNew/menuDemon.vue
@@ -3,13 +3,12 @@
- 设备管理
- 成员管理
- 生成二维码
- {{ $t('joinTraining.connectRealDevices') }}
+ 设备管理
+ 成员管理
+ 生成二维码
{{ $t('joinTraining.driverPerspective') }}
cctv
-
+
{{ $t('joinTraining.drivingByPlan') }}
{{ $t('joinTraining.initialize') }}
@@ -24,7 +23,6 @@
-
@@ -38,8 +36,8 @@ import { ranAsPlan, exitRunPlan, clearSimulation } from '@/api/simulation';
import { exitFullscreen } from '@/utils/screen';
import { getSimulationQrcode } from '@/api/jointSimulation';
import { getSessionStorage } from '@/utils/auth';
-import RealDevice from './menuDraft/realDevice';
import { refereeExitSimulation, quitCurrentRace, startPracticalCompetition, submitPracticalCompetition } from '@/api/competition';
+import { NoQrcodeList } from '@/scripts/ProjectConfig';
import { prefixIntrger } from '@/utils/date';
import localStore from 'storejs';
@@ -49,7 +47,6 @@ export default {
ChatBox,
QrCode,
SetTime,
- RealDevice,
Equipment
},
props: {
@@ -83,12 +80,6 @@ export default {
return false;
}
},
- adminMode: {
- type: Boolean,
- default() {
- return false;
- }
- },
offsetBottom: {
type: [String, Number],
default: 15
@@ -104,7 +95,8 @@ export default {
stationList: [],
stationLists: [],
jsStart: true,
- isGoback: false
+ isGoback: false,
+ noQrcodeList: NoQrcodeList
};
},
computed: {
@@ -120,9 +112,6 @@ export default {
isDriver() {
return this.userRole == 'DRIVER';
},
- hasRealDevice() {
- return getSessionStorage('project').endsWith('gzb') && this.userRole === 'CI';
- },
project() {
return getSessionStorage('project');
}
@@ -348,9 +337,6 @@ export default {
jlmap3dcctv() {
this.$emit('hidejl3dcctv');
},
- setRelDevice() {
- this.$refs.realDevice.doShow();
- },
formatTime(initTime) {
const hh = prefixIntrger(initTime.getHours(), 2);
const mm = prefixIntrger(initTime.getMinutes(), 2);
diff --git a/src/views/newMap/jointTrainingNew/menuDraft/realDevice.vue b/src/views/newMap/jointTrainingNew/menuDraft/realDevice.vue
deleted file mode 100644
index 0a339031b..000000000
--- a/src/views/newMap/jointTrainingNew/menuDraft/realDevice.vue
+++ /dev/null
@@ -1,293 +0,0 @@
-
-
-
-
- -
- {{ handleDeviceTitle(node) }}
- {{ handleDeviceTitle(node) }}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 未查询到真实设备
-
-
-
-
-
-
-
-
diff --git a/src/views/newMap/jointTrainingNew/menuSchema.vue b/src/views/newMap/jointTrainingNew/menuSchema.vue
index 868c74f24..fe6d072ab 100644
--- a/src/views/newMap/jointTrainingNew/menuSchema.vue
+++ b/src/views/newMap/jointTrainingNew/menuSchema.vue
@@ -1,31 +1,25 @@
-
-
-
+
+ 大屏
+
{{ $t('joinTraining.runGraphPreview') }}
-
+
{{ $t('joinTraining.runGraphLoading') }}
-
+
{{ $t('joinTraining.faultSetting') }}
{{ $t('joinTraining.normalOperation') }}
{{ $t('joinTraining.faultOperation') }}
-
- 管理模式
- 演练模式
-