Merge branch 'test_dispaly' of https://git.code.tencent.com/lian-cbtc/jl-client into test_dispaly1
This commit is contained in:
commit
3f4da53695
@ -186,7 +186,9 @@ export default {
|
||||
isDisabled: (signal, work) => {
|
||||
return false;
|
||||
},
|
||||
isShow: (signal, work) => work === 'dispatchWork'
|
||||
isShow: (signal, work, lineCode) => {
|
||||
return work === 'dispatchWork' || lineCode == '11';
|
||||
}
|
||||
},
|
||||
{
|
||||
label: '进路交ATS自动控',
|
||||
@ -195,7 +197,9 @@ export default {
|
||||
isDisabled: (signal, work) => {
|
||||
return false;
|
||||
},
|
||||
isShow: (signal, work) => work === 'dispatchWork'
|
||||
isShow: (signal, work, lineCode) => {
|
||||
return work === 'dispatchWork' || lineCode == '11';
|
||||
}
|
||||
},
|
||||
{
|
||||
label: '查询进路状态',
|
||||
@ -236,6 +240,9 @@ export default {
|
||||
]),
|
||||
group() {
|
||||
return this.$route.query.group;
|
||||
},
|
||||
lineCode() {
|
||||
return this.$route.query.lineCode;
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
@ -269,7 +276,7 @@ export default {
|
||||
this.menuNormal.forEach(menuItem => {
|
||||
const status = judgeStationControl(this.selected.belongStationCode, this.selected.stationCode, this.work);
|
||||
menuItem.disabled = menuItem.isDisabled ? menuItem.isDisabled(this.selected, this.work) || !status : false;
|
||||
menuItem.show = menuItem.isShow ? menuItem.isShow(this.selected, this.work) : true;
|
||||
menuItem.show = menuItem.isShow ? menuItem.isShow(this.selected, this.work, this.lineCode) : true;
|
||||
this.menu.push(menuItem);
|
||||
});
|
||||
// 故障模式菜单列表
|
||||
|
@ -254,15 +254,19 @@ export default {
|
||||
initData(row) {
|
||||
getDeviceDetail(row.id).then(resp => {
|
||||
if (resp.data.config && resp.data.type === 'VR_IBP') {
|
||||
this.formIbp = {part: '', deviceCode: '', roleCode:'', client:''};
|
||||
const form = JSON.parse(resp.data.config);
|
||||
this.formIbp = Object.assign(this.formIbp, form);
|
||||
} else if (resp.data.config && resp.data.type === 'LW') {
|
||||
this.formLw = {stationCode: '', roleCode:'', client:''};
|
||||
const form = JSON.parse(resp.data.config);
|
||||
this.formLw = Object.assign(this.formLw, form);
|
||||
} else if (resp.data.config && ['IM', 'CW', 'DRIVE', 'DEPOT'].includes(resp.data.type)) {
|
||||
this.formIm = { roleCode:'', client:''};
|
||||
const form = JSON.parse(resp.data.config);
|
||||
this.formIm = Object.assign(this.formIm, form);
|
||||
} else if (resp.data.config && (resp.data.type === 'ISCS_LW' || resp.data.type === 'ISCS_CW')) {
|
||||
this.formIscs = {deviceCode: '', picture: '', stationCode: '', roleCode:'', client:''};
|
||||
const form = JSON.parse(resp.data.config);
|
||||
this.formIscs = Object.assign(this.formIscs, form);
|
||||
}
|
||||
@ -296,6 +300,7 @@ export default {
|
||||
getBackProjectConfigByCode(row.project).then(res=>{
|
||||
const data = res.data;
|
||||
this.dialogVisible = true;
|
||||
this.roleList = [];
|
||||
if (data.functionId) {
|
||||
if (data.mapId) { this.mapIdChange(data.mapId, data.functionId); }
|
||||
} else {
|
||||
@ -374,6 +379,10 @@ export default {
|
||||
this.dialogVisible = false;
|
||||
this.data = {};
|
||||
this.lwList = [];
|
||||
this.formIbp = {part: '', deviceCode: '', roleCode:'', client:''};
|
||||
this.formLw = {stationCode: '', roleCode:'', client:''};
|
||||
this.formIm = { roleCode:'', client:''};
|
||||
this.formIscs = {deviceCode: '', picture: '', stationCode: '', roleCode:'', client:''};
|
||||
this.$refs.formIbp.resetFields();
|
||||
this.$refs.formLw.resetFields();
|
||||
this.$refs.formIscs.resetFields();
|
||||
|
@ -146,6 +146,7 @@ export default {
|
||||
initData(row) {
|
||||
this.jsonConfig = '{}';
|
||||
getDeviceDetail(row.id).then(resp => {
|
||||
this.formPis = {roleCode:'', client:''};
|
||||
if (resp.data.config) {
|
||||
// this.formModel = JSON.parse(resp.data.config);
|
||||
const config = JSON.parse(resp.data.config);
|
||||
@ -157,6 +158,7 @@ export default {
|
||||
getBackProjectConfigByCode(row.project).then(res=>{
|
||||
const data = res.data;
|
||||
this.dialogVisible = true;
|
||||
this.roleList = [];
|
||||
if (config.roleCode) { this.formPis.roleCode = config.roleCode; }
|
||||
if (config.client) { this.formPis.client = config.client; }
|
||||
if (data.functionId) {
|
||||
|
@ -159,13 +159,12 @@ export default {
|
||||
quadrant: data.quadrant,
|
||||
deviceCode: data.deviceCode,
|
||||
psdCode: data.psdCode,
|
||||
// mapId:data.mapId,
|
||||
roleCode:data.roleCode,
|
||||
client:data.client,
|
||||
roleCode:data.roleCode || '',
|
||||
client:data.client || '',
|
||||
addr: data.addr,
|
||||
quantity: data.quantity
|
||||
};
|
||||
if (['VR_PSD', 'LSW', 'CCTV', 'SANDBOX'].includes(row.type)) {
|
||||
if (['VR_PSD', 'LSW', 'CCTV', 'SANDBOX', 'ILW'].includes(row.type)) {
|
||||
// getPublishMapListOnline().then(resp => {
|
||||
// if (resp.data && resp.data.length) {
|
||||
// this.mapList = resp.data;
|
||||
@ -177,6 +176,7 @@ export default {
|
||||
getBackProjectConfigByCode(row.project).then(res=>{
|
||||
const data = res.data;
|
||||
this.dialogVisible = true;
|
||||
this.roleList = [];
|
||||
if (data.functionId) {
|
||||
if (data.mapId) { this.mapIdChange(data.mapId, data.functionId); }
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user