+
+
+
+ {{ index2UnicodeList[i] }}、{{ el.title }}
+
+
+
考试总分:
@@ -13,9 +15,13 @@
+
From 6f0cc20a42d7f0dca2bdf59f037a57e1c4aef5b0 Mon Sep 17 00:00:00 2001
From: joylink_cuiweidong <364937672@qq.com>
Date: Fri, 5 Jun 2020 14:12:22 +0800
Subject: [PATCH 3/4] =?UTF-8?q?=E6=96=B0=E7=89=88=E5=89=A7=E6=9C=AC?=
=?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=AF=B9=E8=AF=9D=E4=BB=A3=E7=A0=81=E8=B0=83?=
=?UTF-8?q?=E6=95=B4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/api/simulation.js | 10 ++++
.../scriptManage/scriptRecord/addAction.vue | 49 +++++++++++++------
.../scriptManage/scriptRecord/getAction.vue | 10 ++--
3 files changed, 48 insertions(+), 21 deletions(-)
diff --git a/src/api/simulation.js b/src/api/simulation.js
index 43ecc026c..be1d41e60 100644
--- a/src/api/simulation.js
+++ b/src/api/simulation.js
@@ -385,6 +385,15 @@ export function modifyScriptAction(group, actionId, data) {
});
}
+/** 修改剧本动作(新版) */
+export function modifyScriptActionNew(group, data) {
+ return request({
+ url: `/api/scriptSimulation/${group}/action/update`,
+ method: 'put',
+ data
+ });
+}
+
/** 分页查询存在的仿真 */
export function getExistingSimulation(params) {
return request({
@@ -709,3 +718,4 @@ export function getMemberInfo(group, memberId) {
method: 'get'
});
}
+
diff --git a/src/views/scriptManage/scriptRecord/addAction.vue b/src/views/scriptManage/scriptRecord/addAction.vue
index 66bb76afc..46d315955 100644
--- a/src/views/scriptManage/scriptRecord/addAction.vue
+++ b/src/views/scriptManage/scriptRecord/addAction.vue
@@ -75,7 +75,7 @@ import Vue from 'vue';
import Cookies from 'js-cookie';
import ConstConfig from '@/scripts/ConstConfig';
import CommandOperation from './command';
-import {addScriptAction, addScriptActionNew, modifyScriptAction, getAvailableDeviceCommand, getScriptPlayMember, getScriptPlayMemberNew} from '@/api/simulation';
+import {addScriptAction, addScriptActionNew, modifyScriptAction, modifyScriptActionNew, getAvailableDeviceCommand, getScriptPlayMember, getScriptPlayMemberNew} from '@/api/simulation';
export default {
name: 'AddAction',
components:{
@@ -451,20 +451,39 @@ export default {
} else {
const actionId = this.modalData.actionVO.id;
- modifyScriptAction(group, actionId, data).then(response=>{
- this.modifying = false;
- this.isNotModify = true;
- this.$emit('setDisabled', this.isNotModify);
- this.buttonName = this.$t('scriptRecord.addConversitionButton');
- this.operateType = 'add';
- this.$message.success(this.$t('scriptRecord.modifyConversitionSuccess'));
- this.$emit('create');
- // this.$parent.$parent.$refs['addRole'].resetData([this.modalData.action.memberId,this.modalData.action.targetId]);
- this.initActionData();
- }).catch(error => {
- this.modifying = false;
- this.$messageBox(`${this.$t('scriptRecord.modifyConversitionFail')}: ${error.message}`);
- });
+ if (this.drawWay) {
+ data.id = actionId;
+ modifyScriptActionNew(group, data).then(response=>{
+ this.modifying = false;
+ this.isNotModify = true;
+ this.$emit('setDisabled', this.isNotModify);
+ this.buttonName = this.$t('scriptRecord.addConversitionButton');
+ this.operateType = 'add';
+ this.$message.success(this.$t('scriptRecord.modifyConversitionSuccess'));
+ this.$emit('create');
+ // this.$parent.$parent.$refs['addRole'].resetData([this.modalData.action.memberId,this.modalData.action.targetId]);
+ this.initActionData();
+ }).catch(error => {
+ this.modifying = false;
+ this.$messageBox(`${this.$t('scriptRecord.modifyConversitionFail')}: ${error.message}`);
+ });
+ } else {
+ modifyScriptAction(group, actionId, data).then(response=>{
+ this.modifying = false;
+ this.isNotModify = true;
+ this.$emit('setDisabled', this.isNotModify);
+ this.buttonName = this.$t('scriptRecord.addConversitionButton');
+ this.operateType = 'add';
+ this.$message.success(this.$t('scriptRecord.modifyConversitionSuccess'));
+ this.$emit('create');
+ // this.$parent.$parent.$refs['addRole'].resetData([this.modalData.action.memberId,this.modalData.action.targetId]);
+ this.initActionData();
+ }).catch(error => {
+ this.modifying = false;
+ this.$messageBox(`${this.$t('scriptRecord.modifyConversitionFail')}: ${error.message}`);
+ });
+ }
+
}
} else {
console.log('error submit!!');
diff --git a/src/views/scriptManage/scriptRecord/getAction.vue b/src/views/scriptManage/scriptRecord/getAction.vue
index 3de960ade..0d78946cd 100644
--- a/src/views/scriptManage/scriptRecord/getAction.vue
+++ b/src/views/scriptManage/scriptRecord/getAction.vue
@@ -20,7 +20,7 @@
- {{ $t('scriptRecord.modifyConversitionButton') }}
+ {{ $t('scriptRecord.modifyConversitionButton') }}
@@ -158,8 +158,8 @@ export default {
// memberVOList = memberVOList.replace(new RegExp(rolename, 'g'), element.label);
// });
// memberVOList = JSON.parse(memberVOList);
- const lastData = JSON.stringify(response.data);
- const memberVOList = this.covert(lastData, ConstConfig.ConstSelect.roleTypeNew);
+ const lastData = JSON.stringify(response.data.memberVOList);
+ const memberVOList = this.covert(lastData, ConstConfig.ConstSelect.roleType);
const actionList = response.data.actionVOList;
@@ -218,9 +218,7 @@ export default {
this.loadInitData();
},
modifyAction(row) {
- if (!this.drawWay) {
- this.$emit('setAction', row);
- }
+ this.$emit('setAction', row);
}
}
};
From 377473ea4c1a705274d7e2ec9750564663599fa5 Mon Sep 17 00:00:00 2001
From: joylink_cuiweidong <364937672@qq.com>
Date: Fri, 5 Jun 2020 14:22:46 +0800
Subject: [PATCH 4/4] =?UTF-8?q?=E6=96=B0=E7=89=88=E5=89=A7=E6=9C=AC?=
=?UTF-8?q?=E5=A2=9E=E5=8A=A0=E8=A7=92=E8=89=B2=E8=B0=83=E6=95=B4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/scripts/ConstConfig.js | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/src/scripts/ConstConfig.js b/src/scripts/ConstConfig.js
index a462dc7b9..73f6f7ee7 100644
--- a/src/scripts/ConstConfig.js
+++ b/src/scripts/ConstConfig.js
@@ -90,11 +90,13 @@ export default {
roleTypeNew:[
{label: '管理员', value: 'ADMIN', enLabel: 'Admin '},
{label: '教员', value: 'Instructor', enLabel: 'Instructor '},
- {label: '行调', value: 'DISPATCHER', enLabel: 'Dispatcher '},
{label: '行值', value: 'STATION_SUPERVISOR', enLabel: 'Attendant '},
{label: '观众', value: 'AUDIENCE', enLabel: 'Audience '},
{label: '司机', value: 'DRIVER', enLabel: 'Driver '},
- {label: '通号', value: 'MAINTAINER', enLabel: 'Repairman '}
+ {label: '通号', value: 'MAINTAINER', enLabel: 'Repairman '},
+ {label: '车辆段调度', value: 'DEPOT_DISPATCHER', enLabel: 'Depot dispatcher '},
+ {label: '工电调度', value: 'ELECTRIC_DISPATCHER', enLabel: 'Electric dispatcher'},
+ {label: '行调', value: 'DISPATCHER', enLabel: 'Dispatcher '}
],
SimulationType: [
{ label: '实训', value: 'Training'},