From f98242374b81d2cd04f50d2c41f0c7aa0bd8e4e4 Mon Sep 17 00:00:00 2001
From: fan <18706759286@163.com>
Date: Fri, 11 Sep 2020 09:26:51 +0800
Subject: [PATCH 1/6] =?UTF-8?q?=E4=BC=9A=E8=AF=9D=E8=B0=83=E6=95=B4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/store/modules/socket.js | 4 +
src/store/modules/training.js | 13 +-
src/utils/baseUrl.js | 4 +-
src/views/login/index.vue | 11 +-
src/views/newMap/chatView/chatBox.vue | 2 +-
.../newMap/displayNew/demon/addQuest.vue | 3 +
src/views/newMap/displayNew/demonChat.vue | 331 +++++++++---------
.../displayNew/dispatherContest/index.vue | 1 +
.../displayNew/dispatherContest/sceneList.vue | 5 +
src/views/newMap/displayNew/menuDemon.vue | 8 +-
.../scriptDisplay/component/scriptTip.vue | 13 +-
.../scriptDisplay/scriptPreview/index.vue | 58 +--
.../scriptPreview/scriptButtonGroup.vue | 3 +
.../scriptPreview/scriptPreviewChat.vue | 164 +--------
.../scriptDisplay/scriptRecord/index.vue | 22 +-
.../scriptDisplay/scriptRecord/scriptChat.vue | 192 ----------
.../jointTrainingNew/chatView/chatBox.vue | 227 ++++--------
.../jointTrainingNew/chatView/chatContent.vue | 16 +-
.../jointTrainingNew/chatView/chatTooltip.vue | 104 ------
src/views/newMap/jointTrainingNew/index.vue | 36 +-
.../memberManage/membersManage.vue | 16 +-
src/views/newMap/mapsystemNew/index.vue | 29 ++
22 files changed, 356 insertions(+), 906 deletions(-)
delete mode 100644 src/views/newMap/displayNew/scriptDisplay/scriptRecord/scriptChat.vue
delete mode 100644 src/views/newMap/jointTrainingNew/chatView/chatTooltip.vue
diff --git a/src/store/modules/socket.js b/src/store/modules/socket.js
index 2c2f92110..d71a35030 100644
--- a/src/store/modules/socket.js
+++ b/src/store/modules/socket.js
@@ -177,6 +177,9 @@ function handleSimulationInfo(state, data) {
case 'CREATE':
state.createConversition = data;
break;
+ case 'EXIT':
+ state.exitConversition = data;
+ break;
}
}
@@ -234,6 +237,7 @@ const socket = {
acceptConversionInvite:{}, // 仿真会话成员接收邀请
createConversition:{}, // 仿真创建会话
overConversition: {}, // 仿真会话结束
+ exitConversition: {}, // 仿真成员退出会话
conversationInfo: {}, // 仿真会话消息
message: {}, // 仿真聊天
diff --git a/src/store/modules/training.js b/src/store/modules/training.js
index 554df291d..228bebb69 100644
--- a/src/store/modules/training.js
+++ b/src/store/modules/training.js
@@ -40,7 +40,8 @@ const training = {
memberList: [], // 综合仿真成员列表
memberData: {}, // 综合仿真成员列表
simulationUserList: [], // 综合仿真用户列表
- orignalUserRoleId:'' // 设置旧的角色的id
+ orignalUserRoleId:'', // 设置旧的角色的id
+ scriptQuitCount: 0 // 主动退出剧本
},
getters: {
@@ -103,6 +104,9 @@ const training = {
},
commonMenuStep: (state) => {
return state.commonMenuStep;
+ },
+ scriptQuitCount: (state) => {
+ return state.scriptQuitCount;
}
},
@@ -290,6 +294,9 @@ const training = {
},
setOrignalUserRoleId:(state, orignalUserRoleId) => {
state.orignalUserRoleId = orignalUserRoleId;
+ },
+ setScriptQuit: (state) => {
+ state.scriptQuitCount++;
}
},
@@ -712,6 +719,10 @@ const training = {
setRoleDeviceCode:({ commit }, roleDeviceCode) => {
commit('setRoleDeviceCode', roleDeviceCode);
},
+ /** 剧本仿真 主动退出*/
+ setScriptQuit:({ commit }) => {
+ commit('setScriptQuit');
+ },
/** 剧本仿真 设置旧的角色的id */
setOrignalUserRoleId:({ commit }, data) => {
commit('setOrignalUserRoleId', data);
diff --git a/src/utils/baseUrl.js b/src/utils/baseUrl.js
index 778caeb7b..55d352581 100644
--- a/src/utils/baseUrl.js
+++ b/src/utils/baseUrl.js
@@ -2,10 +2,10 @@ export function getBaseUrl() {
let BASE_API;
if (process.env.NODE_ENV === 'development') {
// BASE_API = 'https://joylink.club/jlcloud';
- BASE_API = 'https://test.joylink.club/jlcloud';
+ // BASE_API = 'https://test.joylink.club/jlcloud';
// BASE_API = 'http://192.168.3.5:9000'; // 袁琪
// BASE_API = 'http://192.168.3.6:9000'; // 旭强
- // BASE_API = 'http://192.168.3.41:9000'; // 张赛
+ BASE_API = 'http://192.168.3.41:9000'; // 张赛
// BASE_API = 'http://192.168.3.82:9000'; // 杜康
// BASE_API = 'http://b29z135112.zicp.vip';
// BASE_API = 'http://2925963m2a.zicp.vip'; // 杜康
diff --git a/src/views/login/index.vue b/src/views/login/index.vue
index 5302153ab..d7e5b83ff 100644
--- a/src/views/login/index.vue
+++ b/src/views/login/index.vue
@@ -130,7 +130,8 @@
-
“新誉杯”竞赛规程
+
“新誉杯”决赛事项通知
+
“新誉杯”竞赛规程
@@ -583,8 +584,12 @@ export default {
this.days.push(Math.floor((day % 100) / 10));
this.days.push(day % 10);
},
- goCompetitionRules() {
- window.open('https://mp.weixin.qq.com/s?__biz=MzI3NzMwODY3OQ==&mid=2247506304&idx=1&sn=77708ca228404cee2b28e131cdfb9735&chksm=eb6aade8dc1d24fe6eb9f1334aadda239f47dafc79de7d522e0f3f00e2d3ba1dd213dda6764c&xtrack=1&scene=90&subscene=93&sessionid=1598522875&clicktime=1598523062&enterid=1598523062&ascene=56&devicetype=android-29&version=3.0.27.2701&nettype=WIFI&abtest_cookie=AAACAA%3D%3D&lang=zh_CN&exportkey=AQZ2cTPSob%2B5kBDiWnKw0Js%3D&pass_ticket=12Xyhe%2BbZsC9Vuzfs0iYUUn0i%2Br5JlZiOGCxWoExuthBhnIrpkmUyjVRi6bjyA1I&wx_header=1&platform=win', '_blank');
+ goCompetitionRules(val) {
+ if (val === '1') {
+ window.open('https://mp.weixin.qq.com/s?__biz=MzI3NzMwODY3OQ==&mid=2247506304&idx=1&sn=77708ca228404cee2b28e131cdfb9735&chksm=eb6aade8dc1d24fe6eb9f1334aadda239f47dafc79de7d522e0f3f00e2d3ba1dd213dda6764c&xtrack=1&scene=90&subscene=93&sessionid=1598522875&clicktime=1598523062&enterid=1598523062&ascene=56&devicetype=android-29&version=3.0.27.2701&nettype=WIFI&abtest_cookie=AAACAA%3D%3D&lang=zh_CN&exportkey=AQZ2cTPSob%2B5kBDiWnKw0Js%3D&pass_ticket=12Xyhe%2BbZsC9Vuzfs0iYUUn0i%2Br5JlZiOGCxWoExuthBhnIrpkmUyjVRi6bjyA1I&wx_header=1&platform=win', '_blank');
+ } else if (val === '2') {
+ window.open('https://mp.weixin.qq.com/s?__biz=MzI3NzMwODY3OQ==&mid=2247506789&idx=1&sn=5b5c1e6e0ca7dc54a935f57cee4eb1a2&chksm=eb6aaf0ddc1d261ba2ba7b9bed810b12b3317d45b1a484095d13b3d7e075b091d92fc7b9afb8&mpshare=1&scene=1&srcid=0910Yd3PVFs0WjWZyumLN9Jo&sharer_sharetime=1599740490862&sharer_shareid=98d62529ea7e8d0f6fb2281f854f3ea1&version=3.0.30.2006&platform=win&rd2werd=1#wechat_redirect', '_blank');
+ }
}
}
};
diff --git a/src/views/newMap/chatView/chatBox.vue b/src/views/newMap/chatView/chatBox.vue
index d0f1a3948..21f125cfb 100644
--- a/src/views/newMap/chatView/chatBox.vue
+++ b/src/views/newMap/chatView/chatBox.vue
@@ -297,7 +297,7 @@ export default {
quitConversition() {
this.loading = true;
overSimulationConversition(this.group, this.conversitionId).then(resp => {
- this.$emit('resetCoversition');
+ // this.$emit('resetCoversition');
this.loading = false;
}).catch(() => {
this.$message.error('退出会话失败!');
diff --git a/src/views/newMap/displayNew/demon/addQuest.vue b/src/views/newMap/displayNew/demon/addQuest.vue
index a3c01b0d9..a8c2e4a6e 100644
--- a/src/views/newMap/displayNew/demon/addQuest.vue
+++ b/src/views/newMap/displayNew/demon/addQuest.vue
@@ -204,6 +204,9 @@ export default {
// }
// });
this.form.type = '';
+ res.data.memberList.sort((a, b) => {
+ return parseInt(a.id) - parseInt(b.id);
+ });
this.$store.dispatch('training/setMemberList', {memberList:res.data.memberList, userId:this.$store.state.user.id});
const activeMemberList = [];
res.data.actionList.forEach((activeMember)=>{
diff --git a/src/views/newMap/displayNew/demonChat.vue b/src/views/newMap/displayNew/demonChat.vue
index 982f1bfe8..a2af54b0f 100644
--- a/src/views/newMap/displayNew/demonChat.vue
+++ b/src/views/newMap/displayNew/demonChat.vue
@@ -3,25 +3,15 @@
-
+
diff --git a/src/views/newMap/displayNew/scriptDisplay/scriptPreview/scriptButtonGroup.vue b/src/views/newMap/displayNew/scriptDisplay/scriptPreview/scriptButtonGroup.vue
index bd6cb10a0..15f0ad982 100644
--- a/src/views/newMap/displayNew/scriptDisplay/scriptPreview/scriptButtonGroup.vue
+++ b/src/views/newMap/displayNew/scriptDisplay/scriptPreview/scriptButtonGroup.vue
@@ -182,6 +182,9 @@ export default {
const resp = await getDraftScriptByGroupNew(group);
if (resp.code == 200) {
if (resp.data.memberList && resp.data.memberList.length > 0) {
+ resp.data.memberList.sort((a, b) => {
+ return parseInt(a.id) - parseInt(b.id);
+ });
this.$store.dispatch('training/setMemberList', {memberList:resp.data.memberList, userId:this.$store.state.user.id});
if (this.$store.state.training.started) {
this.activeTrainList = this.$store.state.map.activeTrainList;
diff --git a/src/views/newMap/displayNew/scriptDisplay/scriptPreview/scriptPreviewChat.vue b/src/views/newMap/displayNew/scriptDisplay/scriptPreview/scriptPreviewChat.vue
index df200906c..8d2c1f964 100644
--- a/src/views/newMap/displayNew/scriptDisplay/scriptPreview/scriptPreviewChat.vue
+++ b/src/views/newMap/displayNew/scriptDisplay/scriptPreview/scriptPreviewChat.vue
@@ -3,21 +3,13 @@
-
+
diff --git a/src/views/newMap/jointTrainingNew/chatView/chatBox.vue b/src/views/newMap/jointTrainingNew/chatView/chatBox.vue
index f112dd848..9ab92b291 100644
--- a/src/views/newMap/jointTrainingNew/chatView/chatBox.vue
+++ b/src/views/newMap/jointTrainingNew/chatView/chatBox.vue
@@ -48,7 +48,6 @@
@@ -80,6 +79,7 @@
:conversition-id="conversitionId"
:conversition-member-list="conversitionMemberList"
:message-list="messageList"
+ :my-member-id="myMemberId"
:simulation-users="simulationUsers"
:common-conversation="commonConversation"
:user-role="userRole"
@@ -96,21 +96,17 @@
-
-
diff --git a/src/views/newMap/jointTrainingNew/index.vue b/src/views/newMap/jointTrainingNew/index.vue
index 6884aaa69..de11cba7b 100644
--- a/src/views/newMap/jointTrainingNew/index.vue
+++ b/src/views/newMap/jointTrainingNew/index.vue
@@ -72,7 +72,7 @@ import MenuTrainList from './menuTrainList';
import { mapGetters } from 'vuex';
import { OperateMode, TrainingMode } from '@/scripts/ConstDic';
import { loadNewMapDataByGroup } from '@/utils/loaddata';
-import { clearSimulation, getSimulationInfoNew, getSimulationUserInfo, getSimulationMemberList, getAllSimulationUser } from '@/api/simulation';
+import { clearSimulation, getSimulationInfoNew, getSimulationUserInfo } from '@/api/simulation';
import {getRaceUserById, getTestPaperDatail} from '@/api/competition';
import { getSessionStorage } from '@/utils/auth';
import Jl3dDrive from '@/views/jlmap3d/drive/jl3ddrive';
@@ -182,7 +182,7 @@ export default {
'$store.state.map.mapViewLoadedCount': function () { // 地图视图加载完成标识
this.mapViewLoadedOver = true;
this.showSelectStation && this.setShowStation(this.showStation);
- this.initMemberUserInfo();
+ // this.initMemberUserInfo();
if (this.$route.query.type === 'VR_PSD') {
this.deviceShow = true;
}
@@ -192,9 +192,9 @@ export default {
this.hidepanel();
}
},
- '$store.state.socket.memberChangeCount': function () { // 仿真成员变更
- this.initMemberUserInfo();
- },
+ // '$store.state.socket.memberChangeCount': function () { // 仿真成员变更
+ // this.initMemberUserInfo();
+ // },
'$store.state.socket.permissionOver': function () {
this.$alert(this.$t('tip.userRightsHaveBeenReclaimed'), this.$t('tip.hint'), {
confirmButtonText: this.$t('global.confirm'),
@@ -291,19 +291,19 @@ export default {
this.endViewLoading();
}
},
- initMemberUserInfo() {
- // 获取仿真成员列表
- getSimulationMemberList(this.$route.query.group).then(resp => {
- this.$store.dispatch('training/setMemberList', { memberList: resp.data, userId: this.$store.state.user.id });
- }).catch(() => {
- this.$messageBox('获取仿真成员列表失败!');
- });
- getAllSimulationUser(this.$route.query.group).then(resp => {
- this.$store.dispatch('training/setSimulationUserList', resp.data);
- }).catch(() => {
- this.$messageBox('获取所有仿真用户失败!');
- });
- },
+ // initMemberUserInfo() {
+ // // 获取仿真成员列表
+ // getSimulationMemberList(this.$route.query.group).then(resp => {
+ // this.$store.dispatch('training/setMemberList', { memberList: resp.data, userId: this.$store.state.user.id });
+ // }).catch(() => {
+ // this.$messageBox('获取仿真成员列表失败!');
+ // });
+ // getAllSimulationUser(this.$route.query.group).then(resp => {
+ // this.$store.dispatch('training/setSimulationUserList', resp.data);
+ // }).catch(() => {
+ // this.$messageBox('获取所有仿真用户失败!');
+ // });
+ // },
devicemodel() {
if (this.deviceShow == false) {
this.deviceShow = true;
diff --git a/src/views/newMap/jointTrainingNew/memberManage/membersManage.vue b/src/views/newMap/jointTrainingNew/memberManage/membersManage.vue
index c487ce492..f9ce524c5 100644
--- a/src/views/newMap/jointTrainingNew/memberManage/membersManage.vue
+++ b/src/views/newMap/jointTrainingNew/memberManage/membersManage.vue
@@ -137,11 +137,11 @@ export default {
queryMember(val) {
this.$refs.tree.filter(val);
},
- '$store.state.socket.simulationRoleList':function(val) {
- if (val && val.length) {
- this.handlerMemberOnOff(val);
- }
- },
+ // '$store.state.socket.simulationRoleList':function(val) {
+ // if (val && val.length) {
+ // this.handlerMemberOnOff(val);
+ // }
+ // },
'$store.state.training.simulationUserList': function(val) {
this.simulationUserList = val;
},
@@ -277,9 +277,9 @@ export default {
}
return (data.label.indexOf(value) !== -1 || flag) && driverNoShow;
},
- handlerMemberOnOff(data) {
- this.$store.dispatch('training/updateMemberAndUser', { simulationUserList: data, userId: this.userId });
- }
+ // handlerMemberOnOff(data) {
+ // this.$store.dispatch('training/updateMemberAndUser', { simulationUserList: data, userId: this.userId });
+ // }
}
};
diff --git a/src/views/newMap/mapsystemNew/index.vue b/src/views/newMap/mapsystemNew/index.vue
index a4fdfc00e..dafcf2a3a 100644
--- a/src/views/newMap/mapsystemNew/index.vue
+++ b/src/views/newMap/mapsystemNew/index.vue
@@ -9,6 +9,7 @@ import MapCommon from './common/index';
import { getToken } from '@/utils/auth';
import { creatSubscribe, clearSubscribe, displayTopic} from '@/utils/stomp';
import { checkLoginLine } from '@/api/login';
+import { getSimulationMemberList, getAllSimulationUser } from '@/api/simulation';
import { mapGetters } from 'vuex';
export default {
@@ -46,12 +47,24 @@ export default {
'$store.state.map.mapViewLoadedCount': function (val) { // 地图视图加载完成标识 开始加载默认状态
this.mapBoxP = document.getElementById(this.canvasId).children[0];
this.mapBoxP.style.cursor = '';
+ this.initMemberUserInfo();
this.subscribe();
},
+ '$store.state.socket.memberChangeCount': function () { // 仿真成员变更
+ this.initMemberUserInfo();
+ },
+ '$store.state.training.setScriptQuit': function () {
+ this.initMemberUserInfo();
+ },
'$store.state.socket.simulationError': function (val) {
if (val) {
this.simulationError(val);
}
+ },
+ '$store.state.socket.simulationRoleList':function(val) {
+ if (val && val.length) {
+ this.handlerMemberOnOff(val);
+ }
}
},
mounted() {
@@ -149,6 +162,22 @@ export default {
}
}
}, 1000);
+ },
+ initMemberUserInfo() {
+ // 获取仿真成员列表
+ getSimulationMemberList(this.$route.query.group).then(resp => {
+ this.$store.dispatch('training/setMemberList', { memberList: resp.data, userId: this.$store.state.user.id });
+ }).catch(() => {
+ this.$messageBox('获取仿真成员列表失败!');
+ });
+ getAllSimulationUser(this.$route.query.group).then(resp => {
+ this.$store.dispatch('training/setSimulationUserList', resp.data);
+ }).catch(() => {
+ this.$messageBox('获取所有仿真用户失败!');
+ });
+ },
+ handlerMemberOnOff(data) {
+ this.$store.dispatch('training/updateMemberAndUser', { simulationUserList: data, userId: this.userId });
}
}
};
From 60bfa0504bfd0a9da9d5baaeaf2eb2ba8e282bbe Mon Sep 17 00:00:00 2001
From: fan <18706759286@163.com>
Date: Fri, 11 Sep 2020 10:08:25 +0800
Subject: [PATCH 2/6] =?UTF-8?q?=E5=89=A7=E6=9C=AC=E5=8A=A0=E8=BD=BD?=
=?UTF-8?q?=E9=87=8D=E6=96=B0=E8=8E=B7=E5=8F=96=E8=BF=90=E8=A1=8C=E6=95=B0?=
=?UTF-8?q?=E6=8D=AE&=E4=BC=9A=E8=AF=9D=E8=B0=83=E6=95=B4&drts=E6=B7=BB?=
=?UTF-8?q?=E5=8A=A0=E8=BF=9E=E6=8E=A5?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/views/login/index.vue | 3 +++
src/views/newMap/displayNew/menuDemon.vue | 1 +
src/views/newMap/jointTrainingNew/chatView/chatBox.vue | 5 ++++-
3 files changed, 8 insertions(+), 1 deletion(-)
diff --git a/src/views/login/index.vue b/src/views/login/index.vue
index d7e5b83ff..fd1587d18 100644
--- a/src/views/login/index.vue
+++ b/src/views/login/index.vue
@@ -130,6 +130,7 @@
+
“新誉杯”官方网站
“新誉杯”决赛事项通知
“新誉杯”竞赛规程
@@ -589,6 +590,8 @@ export default {
window.open('https://mp.weixin.qq.com/s?__biz=MzI3NzMwODY3OQ==&mid=2247506304&idx=1&sn=77708ca228404cee2b28e131cdfb9735&chksm=eb6aade8dc1d24fe6eb9f1334aadda239f47dafc79de7d522e0f3f00e2d3ba1dd213dda6764c&xtrack=1&scene=90&subscene=93&sessionid=1598522875&clicktime=1598523062&enterid=1598523062&ascene=56&devicetype=android-29&version=3.0.27.2701&nettype=WIFI&abtest_cookie=AAACAA%3D%3D&lang=zh_CN&exportkey=AQZ2cTPSob%2B5kBDiWnKw0Js%3D&pass_ticket=12Xyhe%2BbZsC9Vuzfs0iYUUn0i%2Br5JlZiOGCxWoExuthBhnIrpkmUyjVRi6bjyA1I&wx_header=1&platform=win', '_blank');
} else if (val === '2') {
window.open('https://mp.weixin.qq.com/s?__biz=MzI3NzMwODY3OQ==&mid=2247506789&idx=1&sn=5b5c1e6e0ca7dc54a935f57cee4eb1a2&chksm=eb6aaf0ddc1d261ba2ba7b9bed810b12b3317d45b1a484095d13b3d7e075b091d92fc7b9afb8&mpshare=1&scene=1&srcid=0910Yd3PVFs0WjWZyumLN9Jo&sharer_sharetime=1599740490862&sharer_shareid=98d62529ea7e8d0f6fb2281f854f3ea1&version=3.0.30.2006&platform=win&rd2werd=1#wechat_redirect', '_blank');
+ } else if (val === '3') {
+ window.open('http://metroskills.camet.org.cn', '_blank');
}
}
}
diff --git a/src/views/newMap/displayNew/menuDemon.vue b/src/views/newMap/displayNew/menuDemon.vue
index 9afd7a552..fec9ee256 100644
--- a/src/views/newMap/displayNew/menuDemon.vue
+++ b/src/views/newMap/displayNew/menuDemon.vue
@@ -332,6 +332,7 @@ export default {
this.$store.dispatch('training/setRoles', 'AUDIENCE');
this.$store.dispatch('training/setPrdType', '');
}
+ this.$refs.menuSchema.loadRunData();
this.userRole = userRole;
this.$store.dispatch('scriptRecord/updateBgSet', true);
// this.$refs.chatbox.setMembers(id);
diff --git a/src/views/newMap/jointTrainingNew/chatView/chatBox.vue b/src/views/newMap/jointTrainingNew/chatView/chatBox.vue
index 9ab92b291..02592f3cd 100644
--- a/src/views/newMap/jointTrainingNew/chatView/chatBox.vue
+++ b/src/views/newMap/jointTrainingNew/chatView/chatBox.vue
@@ -179,7 +179,7 @@ export default {
return this.$store.state.user.id;
},
conversitionId() {
- return (this.conversitionStateMap[this.myMemberId] || {}).conversitionId;
+ return (this.conversitionStateMap[this.myMemberId] || {conversitionId:''}).conversitionId;
},
privateMemberList() {
return (this.conversitionStateMap[this.myMemberId] || {privateMemberList: []}).privateMemberList;
@@ -203,6 +203,9 @@ export default {
userRole(val) {
if (val === 'AUDIENCE') {
this.goCommonConversation();
+ this.myMemberId = '';
+ } else {
+ this.myMemberId = this.simulationUsers[this.userId].memberId;
}
},
'$store.state.map.mapViewLoadedCount':function(val) {
From 50c9a4eabbef0c94122fad56046caaf756ef4025 Mon Sep 17 00:00:00 2001
From: zyy <1787816799@qq.com>
Date: Fri, 11 Sep 2020 10:18:07 +0800
Subject: [PATCH 3/6] =?UTF-8?q?=E8=B0=83=E6=95=B4=E9=81=93=E5=B2=94?=
=?UTF-8?q?=E7=94=9F=E6=88=90=20=E9=81=93=E5=B2=94=E5=8C=BA=E6=AE=B5?=
=?UTF-8?q?=E9=97=AE=E9=A2=98?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/jmapNew/map.js | 1 +
src/jmapNew/shape/Switch/index.js | 4 ++--
src/views/newMap/newMapdraft/mapoperate/switch/create.vue | 7 ++++++-
3 files changed, 9 insertions(+), 3 deletions(-)
diff --git a/src/jmapNew/map.js b/src/jmapNew/map.js
index b36b890c3..2b06adb33 100644
--- a/src/jmapNew/map.js
+++ b/src/jmapNew/map.js
@@ -270,6 +270,7 @@ class Jlmap {
// }
if (this.mapDevice[code]) {
this.$painter.delete(this.mapDevice[code]);
+ delete this.mapDevice[code];
}
if (!elem._dispose) {
this.mapDevice[code] = deepAssign(this.mapDevice[code] || {}, oDevice);
diff --git a/src/jmapNew/shape/Switch/index.js b/src/jmapNew/shape/Switch/index.js
index 19b81bab3..d17230f3a 100644
--- a/src/jmapNew/shape/Switch/index.js
+++ b/src/jmapNew/shape/Switch/index.js
@@ -516,8 +516,8 @@ export default class Switch extends Group {
model.singleLock && this.setMonolock(); // 道岔单锁
model.blockade && this.block(); // 道岔封锁
model.singleLock && model.blockade && this.blockMonolock(); // 单锁&锁闭状态
-
- if (!this.style.Switch.core.graphShow) {
+ const path = window.location.href;
+ if (!this.style.Switch.core.graphShow && !path.includes('/map/draw')) {
this.setSectionState(this.sheltertriangle, this.model); // 处理岔芯颜色
}
// this.interlockingReserved(); // 联锁预留道岔
diff --git a/src/views/newMap/newMapdraft/mapoperate/switch/create.vue b/src/views/newMap/newMapdraft/mapoperate/switch/create.vue
index 6bbe5fa8b..3c080e2f8 100644
--- a/src/views/newMap/newMapdraft/mapoperate/switch/create.vue
+++ b/src/views/newMap/newMapdraft/mapoperate/switch/create.vue
@@ -153,7 +153,8 @@ export default {
}
return rtn;
},
- changeSectionAttr() { // 修改区段属性
+ // 修改区段属性
+ changeSectionAttr() {
const changeSectionList = []; // 改变的区段列表
this.sectionList.forEach(section => {
const oneSection = section.points[section.points.length - 1];
@@ -169,12 +170,14 @@ export default {
if (!this.checkAddListA(oneSection, section.code)) { // 右侧关系清空
const sectionModel = deepAssign({}, section);
sectionModel.rightSectionCode = '';
+ sectionModel.parentCode = '';
sectionModel.sepTypeRight = '00'; // 分隔符
sectionModel.type = '03';
const list = this.findSectionA(sectionModel.points[sectionModel.points.length - 1].x, sectionModel.points[sectionModel.points.length - 1].y);
list.forEach(elem => {
const sectionModel = deepAssign({}, elem);
sectionModel.leftSectionCode = '';
+ sectionModel.parentCode = '';
sectionModel.sepTypeLeft = '00';
sectionModel.type = '03';
changeSectionList.push(sectionModel);
@@ -188,12 +191,14 @@ export default {
if (!this.checkAddListB(oneSectionStar, section.code)) { // 左侧关系清空
const sectionModel = deepAssign({}, section);
sectionModel.leftSectionCode = '';
+ sectionModel.parentCode = '';
sectionModel.sepTypeLeft = '00';
sectionModel.type = '03';
const list = this.findSectionB(sectionModel.points[0].x, sectionModel.points[0].y);
list.forEach(elem => {
const sectionModel = deepAssign({}, elem);
sectionModel.rightSectionCode = '';
+ sectionModel.parentCode = '';
sectionModel.sepTypeRight = '00'; // 分隔符
sectionModel.type = '03';
changeSectionList.push(sectionModel);
From e5687c13ddbd451bb17426a4477422f2849a5557 Mon Sep 17 00:00:00 2001
From: zyy <1787816799@qq.com>
Date: Fri, 11 Sep 2020 10:28:55 +0800
Subject: [PATCH 4/6] =?UTF-8?q?=E8=B0=83=E6=95=B4=E9=81=93=E5=B2=94?=
=?UTF-8?q?=E7=94=9F=E6=88=90=E9=80=BB=E8=BE=91?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/utils/baseUrl.js | 4 +-
.../newMapdraft/mapoperate/switch/create.vue | 78 +++++++++----------
2 files changed, 39 insertions(+), 43 deletions(-)
diff --git a/src/utils/baseUrl.js b/src/utils/baseUrl.js
index 55d352581..778caeb7b 100644
--- a/src/utils/baseUrl.js
+++ b/src/utils/baseUrl.js
@@ -2,10 +2,10 @@ export function getBaseUrl() {
let BASE_API;
if (process.env.NODE_ENV === 'development') {
// BASE_API = 'https://joylink.club/jlcloud';
- // BASE_API = 'https://test.joylink.club/jlcloud';
+ BASE_API = 'https://test.joylink.club/jlcloud';
// BASE_API = 'http://192.168.3.5:9000'; // 袁琪
// BASE_API = 'http://192.168.3.6:9000'; // 旭强
- BASE_API = 'http://192.168.3.41:9000'; // 张赛
+ // BASE_API = 'http://192.168.3.41:9000'; // 张赛
// BASE_API = 'http://192.168.3.82:9000'; // 杜康
// BASE_API = 'http://b29z135112.zicp.vip';
// BASE_API = 'http://2925963m2a.zicp.vip'; // 杜康
diff --git a/src/views/newMap/newMapdraft/mapoperate/switch/create.vue b/src/views/newMap/newMapdraft/mapoperate/switch/create.vue
index 3c080e2f8..4a94461d0 100644
--- a/src/views/newMap/newMapdraft/mapoperate/switch/create.vue
+++ b/src/views/newMap/newMapdraft/mapoperate/switch/create.vue
@@ -170,14 +170,12 @@ export default {
if (!this.checkAddListA(oneSection, section.code)) { // 右侧关系清空
const sectionModel = deepAssign({}, section);
sectionModel.rightSectionCode = '';
- sectionModel.parentCode = '';
sectionModel.sepTypeRight = '00'; // 分隔符
sectionModel.type = '03';
const list = this.findSectionA(sectionModel.points[sectionModel.points.length - 1].x, sectionModel.points[sectionModel.points.length - 1].y);
list.forEach(elem => {
const sectionModel = deepAssign({}, elem);
sectionModel.leftSectionCode = '';
- sectionModel.parentCode = '';
sectionModel.sepTypeLeft = '00';
sectionModel.type = '03';
changeSectionList.push(sectionModel);
@@ -191,14 +189,12 @@ export default {
if (!this.checkAddListB(oneSectionStar, section.code)) { // 左侧关系清空
const sectionModel = deepAssign({}, section);
sectionModel.leftSectionCode = '';
- sectionModel.parentCode = '';
sectionModel.sepTypeLeft = '00';
sectionModel.type = '03';
const list = this.findSectionB(sectionModel.points[0].x, sectionModel.points[0].y);
list.forEach(elem => {
const sectionModel = deepAssign({}, elem);
sectionModel.rightSectionCode = '';
- sectionModel.parentCode = '';
sectionModel.sepTypeRight = '00'; // 分隔符
sectionModel.type = '03';
changeSectionList.push(sectionModel);
@@ -249,45 +245,45 @@ export default {
const sectionb = this.findSectionData(sectionLists, elem.sectionBCode);
const sectiona = this.findSectionData(sectionLists, elem.sectionACode);
const sectionc = this.findSectionData(sectionLists, elem.sectionCCode);
- const parentSectionModel = this.$store.getters['map/getDeviceByCode'](sectiona.parentCode);
- if (!parentSectionModel) { // 找不到父元素删除
- if (switchSectionList.indexOf(elem.code) == -1) {
- let uid;
- if (!elem['uid']) {
- uid = getUID('T', [...this.sectionList, ...addSectionList]);
- elem['uid'] = uid;
- }
- addSectionList.push({ code: elem.uid });
- sectiona.parentCode = elem['uid'];
- sectionb.parentCode = elem['uid'];
- sectionc.parentCode = elem['uid'];
- elem['relevanceSectionList'] = [elem.sectionACode, elem.sectionBCode, elem.sectionCCode];
- sectionList.push(elem);
- switchList.forEach(ele => {
- const sectiona1 = this.findSectionData(sectionLists, ele.sectionACode);
- const sectionc1 = this.findSectionData(sectionLists, ele.sectionCCode);
- const sectionb1 = this.findSectionData(sectionLists, ele.sectionBCode);
- if (sectionb1.points[sectionb1.points.length - 1].x == sectionb.points[0].x && sectionb1.points[sectionb1.points.length - 1].y == sectionb.points[0].y) {
- ele['uid'] = uid;
- elem['relevanceSectionList'] = [elem.sectionACode, elem.sectionBCode, elem.sectionCCode, ele.sectionACode, ele.sectionBCode, ele.sectionCCode];
- sectiona1.parentCode = uid;
- sectionb1.parentCode = uid;
- sectionc1.parentCode = uid;
- switchSectionList.push(ele.code);
- sectionList.forEach((item, index) => {
- if (item.code == ele.code) {
- sectionList.splice(index, 1);
- }
- });
- }
- });
+ // const parentSectionModel = this.$store.getters['map/getDeviceByCode'](sectiona.parentCode);
+ // if (!parentSectionModel) { // 找不到父元素删除
+ if (switchSectionList.indexOf(elem.code) == -1) {
+ let uid;
+ if (!elem['uid']) {
+ uid = getUID('T', [...this.sectionList, ...addSectionList]);
+ elem['uid'] = uid;
}
- } else {
- parentSectionModel.relevanceSectionList.push(elem.sectionACode);
- parentSectionModel.relevanceSectionList.push(elem.sectionBCode);
- parentSectionModel.relevanceSectionList.push(elem.sectionCCode);
- models.push(parentSectionModel);
+ addSectionList.push({ code: elem.uid });
+ sectiona.parentCode = elem['uid'];
+ sectionb.parentCode = elem['uid'];
+ sectionc.parentCode = elem['uid'];
+ elem['relevanceSectionList'] = [elem.sectionACode, elem.sectionBCode, elem.sectionCCode];
+ sectionList.push(elem);
+ switchList.forEach(ele => {
+ const sectiona1 = this.findSectionData(sectionLists, ele.sectionACode);
+ const sectionc1 = this.findSectionData(sectionLists, ele.sectionCCode);
+ const sectionb1 = this.findSectionData(sectionLists, ele.sectionBCode);
+ if (sectionb1.points[sectionb1.points.length - 1].x == sectionb.points[0].x && sectionb1.points[sectionb1.points.length - 1].y == sectionb.points[0].y) {
+ ele['uid'] = uid;
+ elem['relevanceSectionList'] = [elem.sectionACode, elem.sectionBCode, elem.sectionCCode, ele.sectionACode, ele.sectionBCode, ele.sectionCCode];
+ sectiona1.parentCode = uid;
+ sectionb1.parentCode = uid;
+ sectionc1.parentCode = uid;
+ switchSectionList.push(ele.code);
+ sectionList.forEach((item, index) => {
+ if (item.code == ele.code) {
+ sectionList.splice(index, 1);
+ }
+ });
+ }
+ });
}
+ // } else {
+ // parentSectionModel.relevanceSectionList.push(elem.sectionACode);
+ // parentSectionModel.relevanceSectionList.push(elem.sectionBCode);
+ // parentSectionModel.relevanceSectionList.push(elem.sectionCCode);
+ // models.push(parentSectionModel);
+ // }
sectiona.relSwitchCode = elem.code;
sectionb.relSwitchCode = elem.code;
sectionc.relSwitchCode = elem.code;
From 3ca753a31be8115a086093fce334147c79a67530 Mon Sep 17 00:00:00 2001
From: fan <18706759286@163.com>
Date: Fri, 11 Sep 2020 13:23:24 +0800
Subject: [PATCH 5/6] =?UTF-8?q?=E8=B0=83=E6=95=B4=E4=BC=9A=E8=AF=9D?=
=?UTF-8?q?=E5=92=8Cdrts=E5=80=92=E8=AE=A1=E6=97=B6=E6=97=B6=E9=97=B4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/views/login/index.vue | 2 +-
.../newMap/displayNew/scriptDisplay/scriptRecord/index.vue | 3 +--
src/views/newMap/displayNew/utils.js | 2 +-
src/views/newMap/jointTrainingNew/chatView/chatBox.vue | 5 ++++-
4 files changed, 7 insertions(+), 5 deletions(-)
diff --git a/src/views/login/index.vue b/src/views/login/index.vue
index fd1587d18..53d0178d3 100644
--- a/src/views/login/index.vue
+++ b/src/views/login/index.vue
@@ -213,7 +213,7 @@ export default {
versionBaseNoShow: VersionBaseNoShow,
mainBodyNoShow: MainBodyNoShow,
noQrcodeList: NoQrcodeList,
- expirationDate: 1607562000000,
+ expirationDate: 1605488400000,
countdown: null,
days: [0, 0, 0],
gameOver: false,
diff --git a/src/views/newMap/displayNew/scriptDisplay/scriptRecord/index.vue b/src/views/newMap/displayNew/scriptDisplay/scriptRecord/index.vue
index 0877b530f..58ac69080 100644
--- a/src/views/newMap/displayNew/scriptDisplay/scriptRecord/index.vue
+++ b/src/views/newMap/displayNew/scriptDisplay/scriptRecord/index.vue
@@ -151,7 +151,7 @@ export default {
}
});
}
- this.memberData = [...this.treeData[0].children, ...this.treeData[1].children, ...this.treeData[2].children, ...this.treeData[3].children, ...this.treeData[4].children];
+ // this.memberData = [...this.treeData[0].children, ...this.treeData[1].children, ...this.treeData[2].children, ...this.treeData[3].children, ...this.treeData[4].children];
this.treeData[2].children = driverList;
} else {
this.activeTrainList = activeTrainList;
@@ -195,7 +195,6 @@ export default {
children: result.deviceListData[4]
}];
this.memberData = result.lastMemberList;
-
// 设置当前角色
const member = resp.data.find(mem=>{
return mem.userId != '' && mem.userId != undefined;
diff --git a/src/views/newMap/displayNew/utils.js b/src/views/newMap/displayNew/utils.js
index 83c76350c..38b5f9439 100644
--- a/src/views/newMap/displayNew/utils.js
+++ b/src/views/newMap/displayNew/utils.js
@@ -45,9 +45,9 @@ export function covertMemberData (activeTrainList, resp) {
if (activeTrainList.length > 0) {
if (activeTrainList.includes(member.deviceCode)) {
deviceListData[deviceTypeIndex].push(member);
- lastMemberList.push(member);
}
}
+ lastMemberList.push(member);
driverList.push(member);
} else {
deviceListData[deviceTypeIndex].push(member);
diff --git a/src/views/newMap/jointTrainingNew/chatView/chatBox.vue b/src/views/newMap/jointTrainingNew/chatView/chatBox.vue
index 02592f3cd..749bac1ca 100644
--- a/src/views/newMap/jointTrainingNew/chatView/chatBox.vue
+++ b/src/views/newMap/jointTrainingNew/chatView/chatBox.vue
@@ -205,7 +205,7 @@ export default {
this.goCommonConversation();
this.myMemberId = '';
} else {
- this.myMemberId = this.simulationUsers[this.userId].memberId;
+ this.myMemberId = (this.simulationUsers[this.userId] || {}).memberId;
}
},
'$store.state.map.mapViewLoadedCount':function(val) {
@@ -503,6 +503,9 @@ export default {
if (memberList && memberList.length) {
memberList.forEach(memberId => {
const member = this.memberData[memberId];
+ if (member && member.type === 'DRIVER' && !this.activeTrains.includes(member.deviceCode)) {
+ return;
+ }
if (member && member.userId) {
this.memberIdList.push(member.id);
this.userString += ((this.userString ? ',' : '') + member.label + '(' + this.simulationUsers[member.userId].nickName + ')');
From 5d7b1db6be167252f58676b55243f309ba615e60 Mon Sep 17 00:00:00 2001
From: fan <18706759286@163.com>
Date: Fri, 11 Sep 2020 13:35:08 +0800
Subject: [PATCH 6/6] =?UTF-8?q?=E8=B0=83=E6=95=B4=E6=B7=BB=E5=8A=A0?=
=?UTF-8?q?=E4=BB=BF=E7=9C=9F=E6=88=90=E5=91=98=E7=AE=A1=E7=90=86?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/views/newMap/jointTrainingNew/chatView/chatBox.vue | 4 ++--
.../newMap/jointTrainingNew/memberManage/addMember.vue | 6 +++++-
.../newMap/jointTrainingNew/memberManage/membersManage.vue | 6 +++---
3 files changed, 10 insertions(+), 6 deletions(-)
diff --git a/src/views/newMap/jointTrainingNew/chatView/chatBox.vue b/src/views/newMap/jointTrainingNew/chatView/chatBox.vue
index 749bac1ca..e122c6f1f 100644
--- a/src/views/newMap/jointTrainingNew/chatView/chatBox.vue
+++ b/src/views/newMap/jointTrainingNew/chatView/chatBox.vue
@@ -288,7 +288,7 @@ export default {
const device = this.$store.getters['map/getDeviceByCode'](item.deviceCode);
switch (item.type) {
case 'DISPATCHER':
- this.memberData[item.id].label = '行调' + (dispatcherList.length + 1);
+ this.memberData[item.id].label = '行调' + (item.name || '');
dispatcherList.push(this.memberData[item.id]);
break;
case 'ELECTRIC_DISPATCHER':
@@ -307,7 +307,7 @@ export default {
driverList.push(this.memberData[item.id]);
break;
case 'MAINTAINER':
- this.memberData[item.id].label = '通号' + (maintainerList.length + 1);
+ this.memberData[item.id].label = '通号' + (item.name || '');
maintainerList.push(this.memberData[item.id]);
break;
}
diff --git a/src/views/newMap/jointTrainingNew/memberManage/addMember.vue b/src/views/newMap/jointTrainingNew/memberManage/addMember.vue
index 2314196e3..f35f2449a 100644
--- a/src/views/newMap/jointTrainingNew/memberManage/addMember.vue
+++ b/src/views/newMap/jointTrainingNew/memberManage/addMember.vue
@@ -19,6 +19,9 @@
/>
+
+
+