This commit is contained in:
joylink_cuiweidong 2021-06-01 17:29:33 +08:00
commit 56ea29660f
6 changed files with 60 additions and 28 deletions

View File

@ -137,8 +137,9 @@ class SkinCode extends defaultStyle {
standardLength: 6, // 高柱长度 standardLength: 6, // 高柱长度
standardHeight: 6, // 灯柱高度 standardHeight: 6, // 灯柱高度
standardColor: '#C0C0C0', // 灯柱颜色 standardColor: '#C0C0C0', // 灯柱颜色
standardVerticalWidth: 2, // 灯柱竖杆宽度 standardVerticalWidth: 2, // 灯柱竖杆宽度
standardRailWidth: 2 // 灯柱横杆宽度 standardRailWidth: 2, // 灯柱横杆宽度
approachLockColor: '#FFFF00' // 接近锁闭灯柱颜色
}, },
text: { text: {
show: true, // 信号机名称显示 show: true, // 信号机名称显示
@ -256,7 +257,7 @@ class SkinCode extends defaultStyle {
yellowColor: 'yellow', // 控制模式黄色 yellowColor: 'yellow', // 控制模式黄色
stroke: '#FFFFFF', // 框的颜色 stroke: '#FFFFFF', // 框的颜色
fill: 'rgba(0,0,0,0)', // 填充色 fill: 'rgba(0,0,0,0)', // 填充色
textColorNoChange: true textColorNoChange: true
}, },
emergencyControl: { // 紧急站控 emergencyControl: { // 紧急站控
show: true, show: true,
@ -353,8 +354,8 @@ class SkinCode extends defaultStyle {
borderBackgroundColor: '#22DFDF', // 边框背景色 borderBackgroundColor: '#22DFDF', // 边框背景色
borderColor: '#fff', // 边框颜色 borderColor: '#fff', // 边框颜色
textShadowColor: '#22DFDF', // 字体阴影颜色 textShadowColor: '#22DFDF', // 字体阴影颜色
coreBackgroundColor: '#00BFFF', // 岔芯颜色 浅蓝色 coreBackgroundColor: '#00BFFF', // 岔芯颜色 浅蓝色
coreBackgroundColorOver: '#001AFC', // 岔芯颜色 深蓝色 coreBackgroundColorOver: '#001AFC' // 岔芯颜色 深蓝色
} }
}; };
@ -858,7 +859,7 @@ class SkinCode extends defaultStyle {
}; };
this[deviceType.FloodGate] = {}; this[deviceType.FloodGate] = {};
this[deviceType.DirectionRod] = {}; this[deviceType.DirectionRod] = {};
this[deviceType.IndicatorLight] = {}; this[deviceType.IndicatorLight] = {};
} }
} }

View File

@ -733,7 +733,12 @@ class Signal extends Group {
// this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.blueColor); // this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.blueColor);
// this.lamps[1] && this.lamps[1].setColor(this.style.Signal.lamp.blueColor); // this.lamps[1] && this.lamps[1].setColor(this.style.Signal.lamp.blueColor);
// } // }
// 信号机接近锁闭
handleApproachLock() {
if (this.style.Signal.post.approachLockColor) { // 设置底座颜色
this.sigPost.setColor(this.style.Signal.post.approachLockColor);
}
}
fault() { fault() {
if (this.style.Signal.lamp.faultType == 'flash') { if (this.style.Signal.lamp.faultType == 'flash') {
this.lamps[0].faultShow(); this.lamps[0].faultShow();
@ -1032,6 +1037,7 @@ class Signal extends Group {
if (model.hasSelected) { if (model.hasSelected) {
this.sigName && this.sigName.setAnimationStart(this.style.Signal.text.defaultColor); this.sigName && this.sigName.setAnimationStart(this.style.Signal.text.defaultColor);
} }
model.approachLock && this.handleApproachLock();
// 信号机故障 // 信号机故障
model.fault && this.fault(); model.fault && this.fault();
if (model.guideTime) { if (model.guideTime) {

View File

@ -17,7 +17,7 @@
<el-form ref="form" :model="formModel" :rules="rules"> <el-form ref="form" :model="formModel" :rules="rules">
<el-col :span="24"> <el-col :span="24">
<el-form-item prop="targetDeviceCode" label="目的地:"> <el-form-item prop="targetDeviceCode" label="目的地:">
<el-select ref="faultSelect1" v-model="formModel.targetDeviceCode" size="small" style="width: 165px;height: 32px;line-height: 32px;" placeholder="请选择"> <el-select ref="faultSelect1" v-model="formModel.targetDeviceCode" size="small" style="height: 32px;line-height: 32px;" placeholder="请选择">
<el-option <el-option
v-for="item in selectedList" v-for="item in selectedList"
:key="item.code" :key="item.code"
@ -25,11 +25,11 @@
:value="item.code" :value="item.code"
/> />
</el-select> </el-select>
<el-button <!--<el-button-->
:type="field == 'selectedCode' ? 'danger' : 'primary'" <!--:type="field == 'selectedCode' ? 'danger' : 'primary'"-->
size="small" <!--size="small"-->
@click="hover('selectedCode')" <!--@click="hover('selectedCode')"-->
>激活</el-button> <!--&gt;激活</el-button>-->
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-form> </el-form>
@ -109,7 +109,7 @@ export default {
targetDeviceCode: '' targetDeviceCode: ''
}, },
groupNumber: '', groupNumber: '',
field: '', field: 'selectedCode',
selected: null, selected: null,
rules: { rules: {
faultType: [ faultType: [
@ -125,11 +125,11 @@ export default {
]), ]),
selectedList() { selectedList() {
let list = []; let list = [];
let sectionList = []; // let sectionList = [];
if (this.sectionList && this.sectionList.length) { // if (this.sectionList && this.sectionList.length) {
sectionList = this.sectionList.filter(elem => { return (elem.standTrack || elem.reentryTrack || elem.transferTrack); }); // sectionList = this.sectionList.filter(elem => { return (elem.standTrack || elem.reentryTrack || elem.transferTrack); });
} // }
list = [...sectionList, ...this.trainList]; list = [...this.sectionList, ...this.trainList];
return list; return list;
}, },
show() { show() {
@ -147,7 +147,7 @@ export default {
} else if (this.operation == OperationEvent.MixinCommand.cancelStoppage.menu.operation) { } else if (this.operation == OperationEvent.MixinCommand.cancelStoppage.menu.operation) {
return '取消故障'; return '取消故障';
} else if (this.operation == OperationEvent.MixinCommand.collocation.menu.operation) { } else if (this.operation == OperationEvent.MixinCommand.collocation.menu.operation) {
return '设置托管'; return '驾驶至';
} }
return ''; return '';
} }
@ -160,7 +160,7 @@ export default {
}, },
'$store.state.menuOperation.selectedCount':function(em) { '$store.state.menuOperation.selectedCount':function(em) {
const device = this.$store.state.menuOperation.selected; const device = this.$store.state.menuOperation.selected;
if (device && device.code && this.judge && this.field) { if (device && device.code && this.judge && this.field && this.show) {
if (device._type == 'Section' || device._type == 'Train') { if (device._type == 'Section' || device._type == 'Train') {
this.deviceSelect(device); this.deviceSelect(device);
} }
@ -168,9 +168,9 @@ export default {
} }
}, },
methods: { methods: {
hover(field) { // hover(field) {
this.field = field == this.field ? '' : field; // this.field = field == this.field ? '' : field;
}, // },
doShow(operate, selected, judge) { doShow(operate, selected, judge) {
this.$root.$emit('dialogOpen', selected); this.$root.$emit('dialogOpen', selected);
this.selected = selected; this.selected = selected;
@ -302,10 +302,10 @@ export default {
deviceSelect(em) { deviceSelect(em) {
if (this.field == 'selectedCode' && em._type == 'Section') { if (this.field == 'selectedCode' && em._type == 'Section') {
this.formModel.targetDeviceCode = em.code; this.formModel.targetDeviceCode = em.code;
this.field = ''; // this.field = '';
} else if (this.field == 'selectedCode' && em._type == 'Train') { } else if (this.field == 'selectedCode' && em._type == 'Train') {
this.formModel.targetDeviceCode = em.code; this.formModel.targetDeviceCode = em.code;
this.field = ''; // this.field = '';
} }
} }
} }

View File

@ -222,6 +222,11 @@ export default {
{ name: '固定应答器', value: 'FB'}, { name: '固定应答器', value: 'FB'},
{ name: '可变应答器', value: 'VB'}, { name: '可变应答器', value: 'VB'},
{ name: '填充应答器', value: 'IB'} { name: '填充应答器', value: 'IB'}
],
loadRuleList: [
{ label: '每日加载', value:'EVERY_DAY' },
{ label: '周内加载', value: 'WITHIN_A_WEEK' },
{ label: '周末加载', value: 'WEEKEND' }
] ]
} }
}; };

View File

@ -22,6 +22,11 @@
</el-col> </el-col>
</el-row> </el-row>
</el-form-item> </el-form-item>
<el-form-item label="加载规则" prop="loadRule">
<el-select v-model="model.loadRule">
<el-option v-for="item in loadRuleList" :key="item.value" :label="item.label" :value="item.value" />
</el-select>
</el-form-item>
</el-form> </el-form>
</div> </div>
</div> </div>
@ -39,6 +44,7 @@
import { getPublishMapListOnline } from '@/api/jmap/map'; import { getPublishMapListOnline } from '@/api/jmap/map';
import { createRunPlanCommon } from '@/api/runplan'; import { createRunPlanCommon } from '@/api/runplan';
import ChooseTemplatePlan from './chooseTemplatePlan'; import ChooseTemplatePlan from './chooseTemplatePlan';
import ConstConfig from '@/scripts/ConstConfig';
export default { export default {
name: 'CommonPlanDraft', name: 'CommonPlanDraft',
@ -50,10 +56,12 @@ export default {
display: 1, display: 1,
loading: false, loading: false,
mapList: [], mapList: [],
loadRuleList: ConstConfig.ConstSelect.loadRuleList,
model: { model: {
mapId: '', mapId: '',
planId: '', planId: '',
planName: '' planName: '',
loadRule: ''
} }
}; };
}, },
@ -71,6 +79,9 @@ export default {
], ],
planId: [ planId: [
{ required: true, message: this.$t('rules.inputTemplateRunPlan'), trigger: 'change' } { required: true, message: this.$t('rules.inputTemplateRunPlan'), trigger: 'change' }
],
loadRule: [
{ required: true, message: '请选择加载规则', trigger: 'change' }
] ]
}; };
@ -98,7 +109,8 @@ export default {
buildModel() { buildModel() {
return { return {
mapId: this.model.mapId, mapId: this.model.mapId,
templatePlanId: this.model.planId templatePlanId: this.model.planId,
loadRule: this.model.loadRule
}; };
}, },
create() { create() {

View File

@ -10,6 +10,7 @@ import { superAdmin } from '@/router/index';
import { getRunPlanLoadList, listAllTempLateRunPlan, deleteDailyRunPlanLoad, postDailyRunPlanLoadGenerate, postSchedulingCommonGenerate } from '@/api/runplan'; import { getRunPlanLoadList, listAllTempLateRunPlan, deleteDailyRunPlanLoad, postDailyRunPlanLoadGenerate, postSchedulingCommonGenerate } from '@/api/runplan';
import { UrlConfig } from '@/scripts/ConstDic'; import { UrlConfig } from '@/scripts/ConstDic';
import CopyMap from './copyMap'; import CopyMap from './copyMap';
import ConstConfig from '@/scripts/ConstConfig';
import { getPublishMapListOnline } from '@/api/jmap/map'; import { getPublishMapListOnline } from '@/api/jmap/map';
export default { export default {
@ -57,6 +58,13 @@ export default {
columnValue: (row) => { return this.$convertField(row.templatePlanId, this.templatePlanList, ['id', 'name']); }, columnValue: (row) => { return this.$convertField(row.templatePlanId, this.templatePlanList, ['id', 'name']); },
tagType: (row) => { return 'success'; } tagType: (row) => { return 'success'; }
}, },
{
title: '加载规则',
prop: 'loadRule',
type: 'tag',
columnValue: (row) => { return this.$convertField(row.loadRule, ConstConfig.ConstSelect.loadRuleList, ['value', 'label']); },
tagType: (row) => { return 'success'; }
},
{ {
type: 'button', type: 'button',
title: this.$t('global.operate'), title: this.$t('global.operate'),