From c703e4affd9f4a72ce85bbc6c664e94e352b747a Mon Sep 17 00:00:00 2001
From: zyy <1787816799@qq.com>
Date: Thu, 21 May 2020 17:22:28 +0800
Subject: [PATCH 1/9] =?UTF-8?q?=E8=B0=83=E6=95=B4=E6=8B=86=E5=8C=85?=
=?UTF-8?q?=E6=A8=A1=E5=9D=97=E5=8C=96?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
package.json | 1 +
vue.config.js | 69 ++++++++++++++++++++-------------------------------
2 files changed, 28 insertions(+), 42 deletions(-)
diff --git a/package.json b/package.json
index 9a08831b7..7e4b6fab2 100644
--- a/package.json
+++ b/package.json
@@ -41,6 +41,7 @@
"vue-router": "^3.1.6",
"vuedraggable": "^2.23.2",
"vuex": "^3.1.0",
+ "webpack-bundle-analyzer": "^3.8.0",
"xlsx": "^0.14.2",
"zrender": "^4.0.4"
},
diff --git a/vue.config.js b/vue.config.js
index 1ad4200d7..49b05b59f 100644
--- a/vue.config.js
+++ b/vue.config.js
@@ -6,6 +6,9 @@ const defaultSettings = require('./src/settings.js');
const CopyWebpackPlugin = require('copy-webpack-plugin');
const webpack = require('webpack');
+const BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin;
+// http://127.0.0.1:8888/
+
// const CompressionPlugin = require('compression-webpack-plugin');
// const productionGzipExtensions = ['js', 'css'];
// const isProduction = process.env.NODE_ENV === 'production';
@@ -106,6 +109,7 @@ module.exports = {
ignore: ['.*']
}
]));
+ config.plugins.push(new BundleAnalyzerPlugin());
const externalsConfig = {
// 'vue': 'Vue',
// 'vuex': 'Vuex',
@@ -171,67 +175,48 @@ module.exports = {
config
.optimization.splitChunks({
chunks: 'all', // async表示抽取异步模块,all表示对所有模块生效,initial表示对同步模块生效
+ maxInitialRequests: Infinity,
+ minSize: 300000, // 依赖包超过300000bit将被单独打包 当模块 大于30kb
+ minChunks: 1, // 打包⽣生成的chunk⽂文件最少有⼏几个chunk引⽤用了了这个模块
+ automaticNameDelimiter:'-', // 打包分割符号
cacheGroups: {
- // libs: {
- // name: 'chunk-libs',
- // test: /[\\/]node_modules[\\/]/,
- // priority: -10,
- // chunks: 'initial' // only package third parties that are initially dependent
- // },
vendors: {
test: /[\\/]node_modules[\\/]/,
- name: 'vendor', // 要缓存的 分隔出来的 chunk 名称
- priority: -10 // 缓存组优先级 数字越⼤大,优先级越⾼高
+ name(module) {
+ const packageName = module.context.match(/[\\/]node_modules[\\/](.*?)([\\/]|$)/)[1];
+ return `chunk.${packageName.replace('@', '')}`;
+ },
+ priority: 10, // 缓存组优先级 数字越⼤大,优先级越⾼高
+ reuseExistingChunk: true // 如果当前代码块包含的模块已经有了,就不在产生一个新的代码块
},
- elementUI: {
- name: 'elementUI',
- test: /element-ui/,
- // minChunks: 1,
- priority: -10,
- chunks: 'all'
- },
- xlsx: {
- name: 'xlsx',
- test: /xlsx/,
- // minChunks: 1,
- priority: -10,
- chunks: 'all'
- },
- zrender: {
- name: 'zrender',
- test: /zrender/,
- // minChunks: 1,
- priority: -10,
- chunks: 'all'
- },
- jmap: {
- name: 'jmap',
+ jlmap: {
+ name: 'jlmap',
test: path.resolve(__dirname, './src/jmap'),
- priority: -10,
+ priority: 8,
minChunks: 1,
- reuseExistingChunk: true // 可设置是否重⽤用该chunk
+ reuseExistingChunk: true
},
jmapNew: {
name: 'jmapNew',
test: path.resolve(__dirname, './src/jmapNew'),
- priority: -20,
+ priority: 9,
minChunks: 1,
reuseExistingChunk: true
},
jlmap3d: {
name: 'jlmap3d',
test: path.resolve(__dirname, './src/jlmap3d'),
- priority: -10,
- minChunks: 1,
- reuseExistingChunk: true
- },
- ibp: {
- name: 'ibp',
- test: path.resolve(__dirname, './src/ibp'),
- priority: -10,
+ priority: 7,
minChunks: 1,
reuseExistingChunk: true
}
+ // ibp: {
+ // name: 'ibp',
+ // test: path.resolve(__dirname, './src/ibp'),
+ // priority: -10,
+ // minChunks: 1,
+ // reuseExistingChunk: true
+ // }
}
});
config.optimization.runtimeChunk('single');
From 35eb28c4c9e2e4b0f2339b5183e5ee849bf8f6ac Mon Sep 17 00:00:00 2001
From: zyy <1787816799@qq.com>
Date: Thu, 21 May 2020 17:28:10 +0800
Subject: [PATCH 2/9] =?UTF-8?q?=E8=BF=87=E6=BB=A4=E5=BC=80=E5=8F=91?=
=?UTF-8?q?=E7=8E=AF=E5=A2=83?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
vue.config.js | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/vue.config.js b/vue.config.js
index 49b05b59f..e83d6bda5 100644
--- a/vue.config.js
+++ b/vue.config.js
@@ -109,7 +109,9 @@ module.exports = {
ignore: ['.*']
}
]));
- config.plugins.push(new BundleAnalyzerPlugin());
+ if (process.env.NODE_ENV == 'production') {
+ config.plugins.push(new BundleAnalyzerPlugin());
+ }
const externalsConfig = {
// 'vue': 'Vue',
// 'vuex': 'Vuex',
From fbe1da2a0808129f7eb5dbf22bfd9ae6b772188b Mon Sep 17 00:00:00 2001
From: zyy <1787816799@qq.com>
Date: Thu, 21 May 2020 17:52:07 +0800
Subject: [PATCH 3/9] =?UTF-8?q?=E5=88=A0=E9=99=A4=E6=A8=A1=E5=9D=97?=
=?UTF-8?q?=E5=88=86=E6=9E=90=E4=BE=9D=E8=B5=96?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
package.json | 1 -
vue.config.js | 8 +++-----
2 files changed, 3 insertions(+), 6 deletions(-)
diff --git a/package.json b/package.json
index 7e4b6fab2..9a08831b7 100644
--- a/package.json
+++ b/package.json
@@ -41,7 +41,6 @@
"vue-router": "^3.1.6",
"vuedraggable": "^2.23.2",
"vuex": "^3.1.0",
- "webpack-bundle-analyzer": "^3.8.0",
"xlsx": "^0.14.2",
"zrender": "^4.0.4"
},
diff --git a/vue.config.js b/vue.config.js
index e83d6bda5..9b52b7b4c 100644
--- a/vue.config.js
+++ b/vue.config.js
@@ -6,8 +6,8 @@ const defaultSettings = require('./src/settings.js');
const CopyWebpackPlugin = require('copy-webpack-plugin');
const webpack = require('webpack');
-const BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin;
-// http://127.0.0.1:8888/
+// const BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin;
+// http://127.0.0.1:8888/ 分析打包模块可视化
// const CompressionPlugin = require('compression-webpack-plugin');
// const productionGzipExtensions = ['js', 'css'];
@@ -109,9 +109,7 @@ module.exports = {
ignore: ['.*']
}
]));
- if (process.env.NODE_ENV == 'production') {
- config.plugins.push(new BundleAnalyzerPlugin());
- }
+ // config.plugins.push(new BundleAnalyzerPlugin());
const externalsConfig = {
// 'vue': 'Vue',
// 'vuex': 'Vuex',
From 16513c64d5fcb535aada97b0ed882212a20c2d3d Mon Sep 17 00:00:00 2001
From: joylink_cuiweidong <364937672@qq.com>
Date: Fri, 22 May 2020 09:07:39 +0800
Subject: [PATCH 4/9] =?UTF-8?q?=E5=89=A7=E6=9C=AC=E7=BC=96=E5=88=B6?=
=?UTF-8?q?=E4=BB=A3=E7=A0=81=E8=B0=83=E6=95=B4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/views/newMap/jointTrainingNew/menuDemon.vue | 2 +-
src/views/scriptManage/scriptRecord/addRole.vue | 3 +++
2 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/src/views/newMap/jointTrainingNew/menuDemon.vue b/src/views/newMap/jointTrainingNew/menuDemon.vue
index 4d315fdd2..86e926928 100644
--- a/src/views/newMap/jointTrainingNew/menuDemon.vue
+++ b/src/views/newMap/jointTrainingNew/menuDemon.vue
@@ -13,7 +13,7 @@
结束
- 结束
+ 返回
{{ $t('global.back') }}
diff --git a/src/views/scriptManage/scriptRecord/addRole.vue b/src/views/scriptManage/scriptRecord/addRole.vue
index e16fae786..336b61a35 100644
--- a/src/views/scriptManage/scriptRecord/addRole.vue
+++ b/src/views/scriptManage/scriptRecord/addRole.vue
@@ -41,6 +41,9 @@ export default {
if (val) {
this.initData();
}
+ },
+ '$store.state.map.runPlanStatus':function (val) {
+ this.initData();
}
},
mounted() {
From 87c52581f2e485aa4aaa0ea4fc39d68243607af4 Mon Sep 17 00:00:00 2001
From: sunzhenyu
Date: Fri, 22 May 2020 09:32:09 +0800
Subject: [PATCH 5/9] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=B8=89=E7=BB=B4?=
=?UTF-8?q?=E8=AE=BE=E5=A4=87=E8=B4=B4=E5=9B=BE=E9=85=8D=E7=BD=AEbug?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/jlmap3d/jl3ddevice/jl3ddeviceNew.js | 6 ++----
src/jlmap3d/jl3ddevice/standtextureload.js | 5 ++---
2 files changed, 4 insertions(+), 7 deletions(-)
diff --git a/src/jlmap3d/jl3ddevice/jl3ddeviceNew.js b/src/jlmap3d/jl3ddevice/jl3ddeviceNew.js
index cd4ad75f9..afb5308b6 100644
--- a/src/jlmap3d/jl3ddevice/jl3ddeviceNew.js
+++ b/src/jlmap3d/jl3ddevice/jl3ddeviceNew.js
@@ -143,20 +143,18 @@ export function Jl3ddeviceNew(dom,group,token,skinCode) {
this.modelmanager = new ModelManager();
getPublish3dMapDetail(skinCode).then(netdata => {
- console.log(JSON.parse(netdata.data.stands));
setpsdstationmap(JSON.parse(netdata.data.stands));
Standtextureload(scope,JSON.parse(netdata.data.assets));
- console.log(scope.stationtexture);
scope.modelmanager.loadpromise(Staticmodel, scope.mixers).then(function (data) {
moveanima.initlistnew(scope.modelmanager.switchmodel.mesh);
daochamodel = scope.modelmanager.switchmodel.mesh.getObjectByName("DAOCHA");
scope.modelmanager.standmodel.mesh.getObjectByName("zhantailiebiao").material.map =scope.stationtexture["stationlist"];
scope.modelmanager.standmodel.mesh.getObjectByName("zhantailiebiao").material.map.needsUpdate = true;
+
scope.modelmanager.standmodel.mesh.getObjectByName("pingbimen1").material.map =scope.stationtexture["pingbimen"];
scope.modelmanager.standmodel.mesh.getObjectByName("pingbimen1").material.map.needsUpdate = true;
- console.log(scope.modelmanager);
- // scope.stationtexture
+
animate();
})
});
diff --git a/src/jlmap3d/jl3ddevice/standtextureload.js b/src/jlmap3d/jl3ddevice/standtextureload.js
index 794b094ed..c72c5a133 100644
--- a/src/jlmap3d/jl3ddevice/standtextureload.js
+++ b/src/jlmap3d/jl3ddevice/standtextureload.js
@@ -34,8 +34,8 @@ export function Standtextureload(jlmap3dedit,assettype){
}
if(assettype.stationtexture == "haerbin1"){
if(jlmap3dedit.stationtexture){
- setstationtexture(jlmap3dedit.stationtexture,"stationlist",'../../static/texture/xian3/devicelist.jpg');
- setstationtexture(jlmap3dedit.stationtexture,"pingbimen",'../../static/texture/xian3/pingbimen.jpg');
+ setstationtexture(jlmap3dedit.stationtexture,"stationlist",'../../static/texture/heb/devicelist.jpg');
+ setstationtexture(jlmap3dedit.stationtexture,"pingbimen",'../../static/texture/heb/pingbimen.png');
setstationtexture(jlmap3dedit.stationtexture,"Station5361",'../../static/texture/heb/Station5361.jpg');
setstationtexture(jlmap3dedit.stationtexture,"Station11094",'../../static/texture/heb/Station11094.jpg');
@@ -91,7 +91,6 @@ function settexture(materiallist,name,textureurl){
}
function setstationtexture(stationtexture,name,textureurl){
var loader = new THREE.TextureLoader();
-
// 加载一个资源
loader.load(
// 资源URL
From 480df83efab11a40b14c93115cdf1e831fa2dd31 Mon Sep 17 00:00:00 2001
From: joylink_cuiweidong <364937672@qq.com>
Date: Fri, 22 May 2020 09:32:48 +0800
Subject: [PATCH 6/9] =?UTF-8?q?=E7=AB=9E=E8=B5=9B=E8=A3=81=E5=88=A4?=
=?UTF-8?q?=E7=B3=BB=E7=BB=9F=E4=BB=A3=E7=A0=81=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/views/newMap/jointTrainingNew/menuDemon.vue | 5 +++++
2 files changed, 9 insertions(+)
diff --git a/src/store/modules/socket.js b/src/store/modules/socket.js
index 5adb8568c..470488e82 100644
--- a/src/store/modules/socket.js
+++ b/src/store/modules/socket.js
@@ -32,6 +32,9 @@ function handle(state, data) {
case 'Competition_Practical': // 竞赛裁判系统裁判员开始考试推送消息
state.competitionStart++; // 竞赛裁判系统裁判员开始考试推送消息
break;
+ case 'Simulation_Over': // 用户退出仿真推送消息
+ state.simulationOver++; // 用户退出仿真推送消息
+ break;
case 'Simulation_Script_Finish': // 剧本执行完成推送消息
state.scriptFinish++; // 剧本执行完成推送消息
break;
@@ -208,6 +211,7 @@ const socket = {
trainStationList: [], // 仿真-列车实际到发车站消息
simulationError: '', // 仿真-异常消息
simulationStart: '', // 仿真-开始消息
+ simulationOver:0, // 退出仿真推送消息
simulationReset: '', // 仿真-异常消息
simulationText: {}, // 仿真-用户交互消息(聊天/命令)
// coversitionList:{}, // 历史仿真-用户消息列表
diff --git a/src/views/newMap/jointTrainingNew/menuDemon.vue b/src/views/newMap/jointTrainingNew/menuDemon.vue
index 86e926928..2b55fdb33 100644
--- a/src/views/newMap/jointTrainingNew/menuDemon.vue
+++ b/src/views/newMap/jointTrainingNew/menuDemon.vue
@@ -130,6 +130,11 @@ export default {
if (val) {
this.startCompetition();
}
+ },
+ '$store.state.socket.simulationOver':function(val) {
+ if (val && this.project === 'refereeJsxt') {
+ this.$router.go(-1);
+ }
}
},
async mounted() {
From 35208da27fb25bba03b8c162766d8f3bc4b90442 Mon Sep 17 00:00:00 2001
From: zyy <1787816799@qq.com>
Date: Fri, 22 May 2020 10:13:13 +0800
Subject: [PATCH 7/9] =?UTF-8?q?=E8=B0=83=E6=95=B4=E6=89=93=E5=8C=85?=
=?UTF-8?q?=E6=96=B9=E5=BC=8F=E5=8C=BA=E5=88=86=E5=8E=8B=E7=BC=A9=20?=
=?UTF-8?q?=E6=9C=AA=E5=8E=8B=E7=BC=A9?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.env.native | 2 +-
.env.staging | 2 +-
vue.config.js | 90 +++++++++++++++++----------------------------------
3 files changed, 31 insertions(+), 63 deletions(-)
diff --git a/.env.native b/.env.native
index d1152d456..af5c4a6d3 100644
--- a/.env.native
+++ b/.env.native
@@ -1,5 +1,5 @@
# just a flag
-NODE_ENV = 'Local'
+NODE_ENV = 'production'
VUE_APP_PRO = 'local'
# base api
diff --git a/.env.staging b/.env.staging
index 605ec30ae..41dbe65d7 100644
--- a/.env.staging
+++ b/.env.staging
@@ -1,5 +1,5 @@
# just a flag
-NODE_ENV = 'test'
+NODE_ENV = 'production'
# base api
VUE_APP_BASE_API = 'https://test.joylink.club/jlcloud'
diff --git a/vue.config.js b/vue.config.js
index 9b52b7b4c..83f60744f 100644
--- a/vue.config.js
+++ b/vue.config.js
@@ -9,13 +9,6 @@ const webpack = require('webpack');
// const BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin;
// http://127.0.0.1:8888/ 分析打包模块可视化
-// const CompressionPlugin = require('compression-webpack-plugin');
-// const productionGzipExtensions = ['js', 'css'];
-// const isProduction = process.env.NODE_ENV === 'production';
-
-// let { version } = require('./package.json');
-// version = version.replace(/\./g, '_');
-
const name = defaultSettings.title; // page title
const port = 9527; // dev port
@@ -32,7 +25,6 @@ module.exports = {
outputDir: 'dist',
assetsDir: 'static', // 相对于outputDir的静态资源(js、css、img、fonts)目录
lintOnSave: false,
- // filenameHashing: true,
productionSourceMap: false, // 项目打包后是否压缩
devServer: {
port: port,
@@ -64,44 +56,35 @@ module.exports = {
// },
// parallel: require('os').cpus().length > 1, // 是否为 Babel 或 TypeScript 使用 thread-loader。该选项在系统的 CPU 有多于一个内核时自动启用,仅作用于生产构建。
configureWebpack: config => {
- // if (process.env.NODE_ENV === 'production') {
- // // 为生产环境修改配置...
- // config.mode = 'production';
-
- // Object.assign(config, {
- // output:{
- // ...config.output,
- // filename: `static/js/[name].[chunkhash].${version}.js`,
- // chunkFilename: `static/js/[name].[chunkhash].${version}.js`
- // }
- // });
- // // config.plugins = [
- // // ...config.plugins,
- // // new CompressionPlugin({
- // // test:/\.js$|\.html$|.\css/, // 匹配文件名
- // // threshold: 10240, // 对超过10k的数据压缩
- // // deleteOriginalAssets: false // 不删除源文件
- // // })
- // // ];
-
- // } else {
- // // 为开发环境修改配置...
- // config.mode = 'development';
- // }
- config.name = name;
- config.resolve = {
- extensions: ['.js', '.vue', '.json'],
- // modules: [path.resolve(__dirname, './node_modules')],
- alias: { // 添加别名
- '@': path.resolve('src')
- }
- };
- const appTarget = process.env.NODE_ENV === 'Local' || process.env.VUE_APP_PRO === 'local' ? 'HYD' : 'Common';
+ const appTarget = process.env.VUE_APP_PRO == 'local' ? 'HYD' : 'Common'; // 其他环境变量 区分配置
config.plugins.push(new webpack.NormalModuleReplacementPlugin(/(.*)_APP_TARGET(\.*)/,
function (resourse) {
resourse.request = resourse.request.replace(/APP_TARGET/, `${appTarget}`);
})
);
+ if (process.env.NODE_ENV != 'development') {
+ config.mode = 'production';
+
+ Object.assign(config, {
+ output:{
+ ...config.output,
+ filename: `static/js/[name].[hash:6].js`,
+ chunkFilename: `static/js/[name].[chunkhash:6].js`
+ }
+ });
+ } else {
+ // 为开发环境修改配置...
+ config.mode = 'development';
+ config.name = name;
+ }
+
+ config.resolve = {
+ extensions: ['.js', '.vue', '.json'],
+ alias: { // 添加别名
+ '@': path.resolve('src')
+ }
+ };
+
config.plugins.push(new CopyWebpackPlugin([
{
from: path.resolve(__dirname, './static'),
@@ -110,15 +93,7 @@ module.exports = {
}
]));
// config.plugins.push(new BundleAnalyzerPlugin());
- const externalsConfig = {
- // 'vue': 'Vue',
- // 'vuex': 'Vuex',
- // 'vue-router': 'VueRouter',
- // 'nprogress': 'NProgress',
- // 'echarts': 'echarts',
- // 'element-ui': 'ELEMENT'
- };
- config.externals = process.env.NODE_ENV === 'Local' || process.env.VUE_APP_PRO === 'local' ? {} : externalsConfig; // 配置CDN使用
+ config.externals = {}; // 配置CDN使用
},
// webpack配置
chainWebpack(config) {
@@ -184,39 +159,32 @@ module.exports = {
test: /[\\/]node_modules[\\/]/,
name(module) {
const packageName = module.context.match(/[\\/]node_modules[\\/](.*?)([\\/]|$)/)[1];
- return `chunk.${packageName.replace('@', '')}`;
+ return `split-chunk.${packageName.replace('@', '')}`;
},
priority: 10, // 缓存组优先级 数字越⼤大,优先级越⾼高
reuseExistingChunk: true // 如果当前代码块包含的模块已经有了,就不在产生一个新的代码块
},
jlmap: {
- name: 'jlmap',
+ name: 'split-jlmap',
test: path.resolve(__dirname, './src/jmap'),
priority: 8,
minChunks: 1,
reuseExistingChunk: true
},
jmapNew: {
- name: 'jmapNew',
+ name: 'split-jmapNew',
test: path.resolve(__dirname, './src/jmapNew'),
priority: 9,
minChunks: 1,
reuseExistingChunk: true
},
jlmap3d: {
- name: 'jlmap3d',
+ name: 'split-jlmap3d',
test: path.resolve(__dirname, './src/jlmap3d'),
priority: 7,
minChunks: 1,
reuseExistingChunk: true
}
- // ibp: {
- // name: 'ibp',
- // test: path.resolve(__dirname, './src/ibp'),
- // priority: -10,
- // minChunks: 1,
- // reuseExistingChunk: true
- // }
}
});
config.optimization.runtimeChunk('single');
From 3b81436fbb5ef6a1556518acee11e021d8bad3ba Mon Sep 17 00:00:00 2001
From: joylink_cuiweidong <364937672@qq.com>
Date: Fri, 22 May 2020 10:43:23 +0800
Subject: [PATCH 8/9] =?UTF-8?q?=E7=AB=9E=E8=B5=9B=E8=A3=81=E5=88=A4?=
=?UTF-8?q?=E7=B3=BB=E7=BB=9F=E4=BB=A3=E7=A0=81=E8=B0=83=E6=95=B4=20?=
=?UTF-8?q?=E7=BB=BC=E5=90=88=E6=BC=94=E7=BB=83=20=E4=BB=BF=E7=9C=9F?=
=?UTF-8?q?=E5=BC=80=E5=A7=8B=20=E4=BF=AE=E6=94=B9=E6=88=90=E5=91=98?=
=?UTF-8?q?=E8=A7=92=E8=89=B2=E4=BB=A3=E7=A0=81=E8=B0=83=E6=95=B4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/views/demonstration/detail/index.vue | 1 +
.../newMap/jointTrainingNew/menuDemon.vue | 3 ++-
src/views/trainRoom/e-role.vue | 8 +++++---
src/views/trainRoom/e-roles.vue | 20 ++++++++++++++++---
4 files changed, 25 insertions(+), 7 deletions(-)
diff --git a/src/views/demonstration/detail/index.vue b/src/views/demonstration/detail/index.vue
index 1ef7878f2..efb22487e 100644
--- a/src/views/demonstration/detail/index.vue
+++ b/src/views/demonstration/detail/index.vue
@@ -155,6 +155,7 @@ export default {
} catch (error) {
if (error.code == 30001) {
const url = localStore.get('orignalTrainingPlatformRoute' + this.$store.state.user.id);
+ localStore.remove();
if (url) {
this.$router.push(url);
}
diff --git a/src/views/newMap/jointTrainingNew/menuDemon.vue b/src/views/newMap/jointTrainingNew/menuDemon.vue
index 2b55fdb33..a8d0da08f 100644
--- a/src/views/newMap/jointTrainingNew/menuDemon.vue
+++ b/src/views/newMap/jointTrainingNew/menuDemon.vue
@@ -13,7 +13,7 @@
结束
- 返回
+ 返回
{{ $t('global.back') }}
@@ -133,6 +133,7 @@ export default {
},
'$store.state.socket.simulationOver':function(val) {
if (val && this.project === 'refereeJsxt') {
+ debugger;
this.$router.go(-1);
}
}
diff --git a/src/views/trainRoom/e-role.vue b/src/views/trainRoom/e-role.vue
index 62f7ae5d8..3adb0d796 100644
--- a/src/views/trainRoom/e-role.vue
+++ b/src/views/trainRoom/e-role.vue
@@ -19,7 +19,7 @@
v-model="node.deviceCode"
size="mini"
:placeholder="$t('global.choose')"
- :disabled="isDisable"
+ :disabled="isDisable || starting"
:options="deviceList"
@change="handleUpdUser(node, index)"
/>
@@ -28,8 +28,7 @@
v-model="node.deviceCode"
:placeholder="$t('global.choose')"
size="mini"
- :disabled="isDisable"
- s
+ :disabled="isDisable || starting"
@change="handleUpdUser(node, index)"
>
{ return { id: elem.id, nickName: elem.nickName, userRole: roleType.toUpperCase() }; });
}
- await putUserRolesNew(list, this.group);
+ try {
+ await putUserRolesNew(list, this.group);
+ } catch (error) {
+ this.$message(error.message);
+ }
+
} else {
list = userList.map(elem => { return { id: elem.id, nickName: elem.nickName, userRole: roleType }; });
await putUserRoles(list, this.group);
From 4210599f6b03eabba1734aef53b4171d86b19619 Mon Sep 17 00:00:00 2001
From: joylink_cuiweidong <364937672@qq.com>
Date: Fri, 22 May 2020 11:07:10 +0800
Subject: [PATCH 9/9] =?UTF-8?q?=E7=AB=9E=E8=B5=9B=E8=A3=81=E5=88=A4?=
=?UTF-8?q?=E7=B3=BB=E7=BB=9F=E4=BB=A3=E7=A0=81=E8=B0=83=E6=95=B4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/App.vue | 2 +-
src/views/newMap/jointTrainingNew/menuDemon.vue | 1 -
2 files changed, 1 insertion(+), 2 deletions(-)
diff --git a/src/App.vue b/src/App.vue
index 5d80eafd4..37e4c4697 100644
--- a/src/App.vue
+++ b/src/App.vue
@@ -82,7 +82,7 @@ export default {
},
subscribeMessage(res) {
if (this.$refs.deomonTopic && !window.location.href.includes('trainroom')) {
- if (getSessionStorage('project') != 'refereeJsxt') {
+ if (getSessionStorage('project') != 'refereeJsxt' && getSessionStorage('project') != 'jsxt') {
this.$refs.deomonTopic.doShow(res);
}
this.$store.dispatch('socket/setRoomInvite');
diff --git a/src/views/newMap/jointTrainingNew/menuDemon.vue b/src/views/newMap/jointTrainingNew/menuDemon.vue
index a8d0da08f..7a32b40b4 100644
--- a/src/views/newMap/jointTrainingNew/menuDemon.vue
+++ b/src/views/newMap/jointTrainingNew/menuDemon.vue
@@ -133,7 +133,6 @@ export default {
},
'$store.state.socket.simulationOver':function(val) {
if (val && this.project === 'refereeJsxt') {
- debugger;
this.$router.go(-1);
}
}