Merge branch 'test' of https://git.code.tencent.com/lian-cbtc/jl-client into test
Before Width: | Height: | Size: 9.2 KiB After Width: | Height: | Size: 9.2 KiB |
Before Width: | Height: | Size: 3.5 KiB After Width: | Height: | Size: 3.5 KiB |
Before Width: | Height: | Size: 5.1 KiB After Width: | Height: | Size: 5.1 KiB |
Before Width: | Height: | Size: 4.4 KiB After Width: | Height: | Size: 4.4 KiB |
@ -42,6 +42,10 @@ import iscsRAFEAFGray from '@/assets/iscs_picture/iscs-RAF-EAF_gray.png';
|
||||
import iscsSEF from '@/assets/iscs_picture/iscs-SEF.png';
|
||||
import iscsValue from '@/assets/iscs_picture/iscs-value.png';
|
||||
import fanCoil from '@/assets/iscs_picture/fanCoil.png';
|
||||
import iscsSensor from '@/assets/iscs_picture/iscs-sensor.png';
|
||||
import iscsDangwei from '@/assets/iscs_picture/iscs-dangwei.png';
|
||||
import iscsDibian from '@/assets/iscs_picture/iscs-dibian.png';
|
||||
import iscsPt1 from '@/assets/iscs_picture/iscs-pt1.png';
|
||||
|
||||
const pictureObj = {
|
||||
'psdLeft': psdLeft,
|
||||
@ -84,7 +88,11 @@ const pictureObj = {
|
||||
iscsRAFEAFGray,
|
||||
iscsSEF,
|
||||
iscsValue,
|
||||
fanCoil
|
||||
fanCoil,
|
||||
iscsSensor,
|
||||
iscsDangwei,
|
||||
iscsDibian,
|
||||
iscsPt1
|
||||
};
|
||||
export default class Picture extends Group {
|
||||
constructor(device) {
|
||||
|
@ -21,7 +21,7 @@ export default class rect extends Group {
|
||||
this.iscsRect = new Rect({
|
||||
zlevel: model.zlevel,
|
||||
z: model.z,
|
||||
z2: model.z2||0,
|
||||
z2: model.z2 || 0,
|
||||
shape: {
|
||||
x: 0,
|
||||
y: 0,
|
||||
@ -38,6 +38,10 @@ export default class rect extends Group {
|
||||
this.grouper.add(this.iscsRect);
|
||||
this.add(this.grouper);
|
||||
}
|
||||
setState(model) {
|
||||
this.iscsRect.setStyle('fill', model.fillColor);
|
||||
this.iscsRect.setStyle('stroke', model.strokeColor);
|
||||
}
|
||||
setModel(dx, dy) {
|
||||
this.model.point.x += dx;
|
||||
this.model.point.y += dy;
|
||||
|
@ -49,6 +49,10 @@ export default class text extends Group {
|
||||
this.model.point.x += dx;
|
||||
this.model.point.y += dy;
|
||||
}
|
||||
setState(model) {
|
||||
this.textName.setStyle('text', model.context);
|
||||
this.textName.setStyle('textBackgroundColor', model.gbColor);
|
||||
}
|
||||
setSize(width, height) {
|
||||
this.model.width = width;
|
||||
this.model.height = height;
|
||||
|
6
src/iscs/status/elType.js
Normal file
@ -0,0 +1,6 @@
|
||||
export default {
|
||||
Fixed: 'Fixed', // 固定值
|
||||
A: 'a', // 远
|
||||
B: 'b', // 红框 阀门
|
||||
C: 'c' // 数组
|
||||
};
|
3
src/iscs/status/grType.js
Normal file
@ -0,0 +1,3 @@
|
||||
export default {
|
||||
A: 'a' // 远 红框 阀门
|
||||
};
|
41
src/iscs/status/mapElement.js
Normal file
@ -0,0 +1,41 @@
|
||||
import elType from './elType';
|
||||
|
||||
export default {
|
||||
[elType.A]: {
|
||||
defval: 'stateA',
|
||||
stateMap: {
|
||||
stateA: {
|
||||
gbColor: 'rgba(157, 171, 0, 1)',
|
||||
context: '远'
|
||||
},
|
||||
stateB: {
|
||||
gbColor: 'rgba(157, 171, 0, 1)',
|
||||
context: '近'
|
||||
}
|
||||
}
|
||||
}, // 远
|
||||
[elType.B]: {
|
||||
defval: 'stateA',
|
||||
stateMap: {
|
||||
stateA: {
|
||||
fillColor: 'red',
|
||||
strokeColor: 'red'
|
||||
},
|
||||
stateB: {
|
||||
fillColor: 'rgba(0, 255, 13, 1)',
|
||||
strokeColor: 'rgba(0, 255, 13, 1)'
|
||||
}
|
||||
}
|
||||
}, // 红框 阀门
|
||||
[elType.C]: {
|
||||
defval: 'stateA',
|
||||
stateMap: {
|
||||
stateA: {
|
||||
context: '8.3'
|
||||
},
|
||||
stateB: {
|
||||
context: '7.6'
|
||||
}
|
||||
}
|
||||
} // 数组
|
||||
};
|
13
src/iscs/status/mapGroup.js
Normal file
@ -0,0 +1,13 @@
|
||||
import elType from './elType';
|
||||
import grType from './grType';
|
||||
|
||||
export default {
|
||||
[grType.A]: {
|
||||
name: '',
|
||||
elemList: [
|
||||
{type: elType.A},
|
||||
{type: elType.B},
|
||||
{type: elType.C}
|
||||
]
|
||||
}
|
||||
};
|
@ -96,7 +96,9 @@ export default {
|
||||
{label: '通号', value: 'MAINTAINER', enLabel: 'Repairman '},
|
||||
{label: '车辆段调度', value: 'DEPOT_DISPATCHER', enLabel: 'Depot dispatcher '},
|
||||
{label: '工电调度', value: 'ELECTRIC_DISPATCHER', enLabel: 'Electric dispatcher'},
|
||||
{label: '行调', value: 'DISPATCHER', enLabel: 'Dispatcher '}
|
||||
{label: '行调', value: 'DISPATCHER', enLabel: 'Dispatcher '},
|
||||
{label: '上级部门', value: 'PARENT_DEPARTMENT', enLabel: 'Parent_department'}
|
||||
|
||||
],
|
||||
SimulationType: [
|
||||
{ label: '实训', value: 'Training'},
|
||||
|
@ -96,7 +96,11 @@ export default {
|
||||
{ name: '排烟风机(箭头)-绿色', value: 'iscsRAFEAFGreen' },
|
||||
{ name: '排烟风机', value: 'iscsSEF' },
|
||||
{ name: '阀门', value: 'iscsValue' },
|
||||
{ name: '风扇机', value: 'fanCoil'}
|
||||
{ name: '风扇机', value: 'fanCoil'},
|
||||
{ name: '烟杆传感器', value: 'iscsSensor' },
|
||||
{ name: '抵挡图', value: 'iscsDangwei' },
|
||||
{ name: '地变图', value: 'iscsDibian' },
|
||||
{ name: 'PT1', value: 'iscsPt1' }
|
||||
],
|
||||
|
||||
rules: {
|
||||
|
@ -87,7 +87,7 @@ export default {
|
||||
this.showDeleteButton = true;
|
||||
this.isUpdate = true;
|
||||
this.form.code = model.code;
|
||||
this.form.z2 = model.z2||0;
|
||||
this.form.z2 = model.z2 || 0;
|
||||
this.form.fillColor = model.fillColor;
|
||||
this.form.borderWidth = model.borderWidth;
|
||||
this.form.strokeColor = model.strokeColor;
|
||||
|
@ -82,7 +82,7 @@ export default {
|
||||
this.scaleRate = window.innerWidth / 2000;
|
||||
params.userInterface = 'catenary';
|
||||
} else {
|
||||
const tractionList = ['象峰站', '罗汉山站', '树兜站', '东街口站', '达道站', '三叉街站', '葫芦阵站', '城门站', '胪雷站'];
|
||||
const tractionList = ['象峰站', '罗汉山站', '树兜站', '东街口站', '达道站', '三叉街站', '葫芦阵站', '城门站', '胪雷站', '安平站', '梁厝站', '三江口站'];
|
||||
if (tractionList.includes(this.stationName)) {
|
||||
this.title = this.stationName + ' 牵引降压混合变电所主接线图';
|
||||
params.userInterface = 'combined';
|
||||
|
@ -81,7 +81,7 @@ export default {
|
||||
return {
|
||||
selectStation: 'mainHouseOne',
|
||||
stationList:[],
|
||||
tractionList:['象峰站', '罗汉山站', '树兜站', '东街口站', '达道站', '三叉街站', '葫芦阵站', '城门站', '胪雷站'],
|
||||
tractionList:['象峰站', '罗汉山站', '树兜站', '东街口站', '达道站', '三叉街站', '葫芦阵站', '城门站', '胪雷站', '安平站', '梁厝站', '三江口站'],
|
||||
group:'',
|
||||
lineCode:'',
|
||||
buttonId:'substation',
|
||||
|
@ -158,6 +158,10 @@ export default {
|
||||
member.label = '通号' + (member.name ? member.name : '');
|
||||
break;
|
||||
}
|
||||
case 'PARENT_DEPARTMENT': {
|
||||
member.label = '上级部门' + (member.name ? member.name : '');
|
||||
break;
|
||||
}
|
||||
}
|
||||
// if (member.type === 'DISPATCHER') {
|
||||
// this.memberId = member.id;
|
||||
|
@ -217,6 +217,11 @@ export default {
|
||||
id: 'depotDispatcher',
|
||||
type: 'role',
|
||||
children: result.deviceListData[4]
|
||||
}, {
|
||||
label: '上级部门',
|
||||
id: 'parentDepartment',
|
||||
type: 'role',
|
||||
children: result.deviceListData[5]
|
||||
}];
|
||||
const lastMemberList = result.lastMemberList;
|
||||
this.$emit('setTreeData', treeData);
|
||||
|
@ -193,15 +193,22 @@ export default {
|
||||
id: 'depotDispatcher',
|
||||
type: 'role',
|
||||
children: result.deviceListData[4]
|
||||
}];
|
||||
}, {
|
||||
label: '上级部门',
|
||||
id: 'parentDepartment',
|
||||
type: 'role',
|
||||
children: result.deviceListData[5]
|
||||
}
|
||||
// PARENT_DEPARTMENT
|
||||
];
|
||||
this.memberData = result.lastMemberList;
|
||||
// 设置当前角色
|
||||
const member = resp.data.find(mem=>{
|
||||
return mem.userId != '' && mem.userId != undefined;
|
||||
});
|
||||
if (member) {
|
||||
const memberType = ['STATION_SUPERVISOR', 'DISPATCHER', 'DRIVER', 'MAINTAINER', 'DEPOT_DISPATCHER'];
|
||||
const prdTypeList = ['01', '02', '04', '', ''];
|
||||
const memberType = ['STATION_SUPERVISOR', 'DISPATCHER', 'DRIVER', 'MAINTAINER', 'DEPOT_DISPATCHER', 'PARENT_DEPARTMENT'];
|
||||
const prdTypeList = ['01', '02', '04', '', '', ''];
|
||||
const index = memberType.indexOf(member.type);
|
||||
let prdType;
|
||||
if (index >= 0) {
|
||||
@ -300,7 +307,7 @@ export default {
|
||||
// this.$refs.chatbox.resetCoversition();
|
||||
},
|
||||
changeTreeData({newRole, oldRole}) {
|
||||
const deviceTypeList = ['DISPATCHER', 'STATION_SUPERVISOR', 'DRIVER', 'MAINTAINER', 'DEPOT_DISPATCHER'];
|
||||
const deviceTypeList = ['DISPATCHER', 'STATION_SUPERVISOR', 'DRIVER', 'MAINTAINER', 'DEPOT_DISPATCHER', 'PARENT_DEPARTMENT'];
|
||||
if (oldRole.id) {
|
||||
const oldIndex = deviceTypeList.indexOf(oldRole.type);
|
||||
if (oldIndex >= 0) {
|
||||
@ -333,7 +340,7 @@ export default {
|
||||
},
|
||||
addScriptMember(member) {
|
||||
this.memberData.push(member);
|
||||
const deviceTypeList = ['行调', '行值', '司机', '通号', '车辆段调度'];
|
||||
const deviceTypeList = ['行调', '行值', '司机', '通号', '车辆段调度', '上级部门'];
|
||||
const index = deviceTypeList.indexOf(member.type);
|
||||
if (index >= 0) {
|
||||
const treeDataIn = this.treeData[index];
|
||||
|
@ -15,7 +15,7 @@ export function covertMemberData (activeTrainList, resp) {
|
||||
lastData = JSON.parse(lastData);
|
||||
const lastMemberList = [];
|
||||
// const electricDispatcherList = [];
|
||||
const deviceListData = [[], [], [], [], []];
|
||||
const deviceListData = [[], [], [], [], [], []];
|
||||
const driverList = [];
|
||||
lastData.forEach((member, index)=>{
|
||||
if (member.userId && member.userId == store.state.user.id) {
|
||||
@ -37,8 +37,7 @@ export function covertMemberData (activeTrainList, resp) {
|
||||
member.label = member.type + name + userName;
|
||||
member.normalName = member.type + name;
|
||||
}
|
||||
|
||||
const deviceType = ['行调', '通号', '行值', '司机', '车辆段调度'];
|
||||
const deviceType = ['行调', '通号', '行值', '司机', '车辆段调度', '上级部门'];
|
||||
const deviceTypeIndex = deviceType.indexOf(member.type);
|
||||
if (deviceTypeIndex >= 0) {
|
||||
if (deviceTypeIndex == 3) {
|
||||
|
@ -124,10 +124,14 @@ export default {
|
||||
}
|
||||
});
|
||||
this.openWindow = window.open(routeData.href);
|
||||
} else if (role.type == '车辆段') {
|
||||
} else if (role.type == '车辆段调度') {
|
||||
prdType = '05';
|
||||
role.type = 'DEPOT_DISPATCHER';
|
||||
this.$store.dispatch('training/setRoles', 'DEPOT_DISPATCHER');
|
||||
} else if (role.type == '上级部门') {
|
||||
prdType = '';
|
||||
role.type = 'PARENT_DEPARTMENT';
|
||||
this.$store.dispatch('training/setRoles', 'PARENT_DEPARTMENT');
|
||||
} else {
|
||||
prdType = '';
|
||||
}
|
||||
|
@ -341,8 +341,8 @@ export default {
|
||||
new_member.userId = this.$store.state.user.id;
|
||||
new_member.disabled = true;
|
||||
this.quickChangeMember.list = [new_member];
|
||||
const deviceList = ['行值', '行调', '司机', '通号', '车辆段'];
|
||||
const deviceType = ['STATION_SUPERVISOR', 'DISPATCHER', 'DRIVER', 'MAINTAINER', 'DEPOT_DISPATCHER'];
|
||||
const deviceList = ['行值', '行调', '司机', '通号', '车辆段', '上级部门'];
|
||||
const deviceType = ['STATION_SUPERVISOR', 'DISPATCHER', 'DRIVER', 'MAINTAINER', 'DEPOT_DISPATCHER', 'PARENT_DEPARTMENT'];
|
||||
const new_index = deviceList.indexOf(new_member.type);
|
||||
const old_index = deviceList.indexOf(old_member.type);
|
||||
let oldType, newType;
|
||||
|