diff --git a/src/views/newMap/displayNew/bigLPFStrategy.vue b/src/views/newMap/displayNew/bigLPFStrategy.vue index be693bb5a..741c9e8f6 100644 --- a/src/views/newMap/displayNew/bigLPFStrategy.vue +++ b/src/views/newMap/displayNew/bigLPFStrategy.vue @@ -6,20 +6,47 @@
-
客流策略
- +
+ 客流策略 + 【 推算时长:{{ recoimemmandTime }}分钟 】 +
-
+
暂无策略
-
+ + + + +
策略{{ index+1 }}:{{ eachLPFstrategy.description }}
指标数据:
- 时刻表偏移指标: {{ eachLPFstrategy.target1 }} - 乘客等待指标: {{ eachLPFstrategy.target2 }} + 影响的列车数量: {{ eachLPFstrategy.effectTrainNum }} + 时刻表总偏移量: {{ eachLPFstrategy.scheduleOffset }}秒 +
+ +
+ 可多载离的乘客数量(累计的): {{ eachLPFstrategy.extraNum }}
-
综合指标: {{ eachLPFstrategy.coTarget }}
+ + + + + +
退出
@@ -38,11 +65,14 @@ export default { return { group:'', myChart: null, + activeName:'first', LPFstrategyList:[], + recoimemmandTime:0, bigLPFStrategyId:'bigLPFStrategyId', upStandList:[], downStandList:[], - stationNameList:[] + stationNameList:[], + LPFstandList:[] }; }, computed: { @@ -51,48 +81,65 @@ export default { 'stationStandList', 'mapConfig' ]) - // maxWidth() { - // return this.$store.state.app.width > 1920 ? 1920 * 0.66 : this.$store.state.app.width * 0.66; - // }, - // maxHeight() { - // return this.$store.state.app.height > 1080 ? 1080 - 40 : this.$store.state.app.height - 40; - // } }, watch: { '$store.state.socket.LPFstrategy':function(val) { if (val && val.recommendList && val.recommendList.length > 0) { this.LPFstrategyList = []; + this.recoimemmandTime = val.duration; val.recommendList.forEach(strategy=>{ const eachStrategy = {}; switch (strategy.type) { case 'JUMP': { - const stand = this.$store.getters['map/getDeviceByCode'](strategy.standCode); - const station = this.$store.getters['map/getDeviceByCode'](stand.stationCode); - eachStrategy.description = '为列车[' + strategy.groupNumber + - '-' + strategy.serviceNumber + '|' + strategy.tripNumber + - '],设置站台' + station.name + '-' + (stand.right ? '右行' : '左行') + - stand.name + ' (' + stand.code + ') 跳停'; - eachStrategy.target1 = strategy.target1; - eachStrategy.target2 = strategy.target2; - eachStrategy.coTarget = strategy.coTarget; + // {"type":"JUMP","description":"为列车[132056],设置罗汉山-上行站台跳停", + // "effectTrainSet":["004"],"effectTrainNum":1,"scheduleOffset":-50, + // "extraNum":0,"groupNumber":"004","serviceNumber":"13","tripNumber":"2056","standCode":"PF61848"}]} + // const stand = this.$store.getters['map/getDeviceByCode'](strategy.standCode); + // const station = this.$store.getters['map/getDeviceByCode'](stand.stationCode); + // eachStrategy.description = '为列车[' + strategy.groupNumber + + // '-' + strategy.serviceNumber + '|' + strategy.tripNumber + + // '],设置站台' + station.name + '-' + (stand.right ? '右行' : '左行') + + // stand.name + ' (' + stand.code + ') 跳停'; // 为列车[005-02|2057],设置站台秀山-右行-PF42(PF44165)跳停", - // eachStrategy.description = strategy.description; + eachStrategy.description = strategy.description; break; } + // "type":"PARK_TIME", + // "description":"福州火车站-上行站台设置停站时间[85]", + // "effectTrainSet":["012","004","005","009"],"effectTrainNum":4, + // "scheduleOffset":160,"extraNum":2540,"time":85,"standCode":"PF83991" case 'PARK_TIME': { - const stand = this.$store.getters['map/getDeviceByCode'](strategy.standCode); - const station = this.$store.getters['map/getDeviceByCode'](stand.stationCode); - // eachStrategy.description = strategy.description; - eachStrategy.target1 = strategy.target1; - eachStrategy.target2 = strategy.target2; - eachStrategy.coTarget = strategy.coTarget; - eachStrategy.description = '为站台[' + station.name + '-' + (stand.right ? '右行' : '左行') + - stand.name + '(' + stand.code + ') 设置停站时间,' + strategy.time + '秒'; + // const stand = this.$store.getters['map/getDeviceByCode'](strategy.standCode); + // const station = this.$store.getters['map/getDeviceByCode'](stand.stationCode); + eachStrategy.description = strategy.description; + // eachStrategy.description = '为站台[' + station.name + '-' + (stand.right ? '右行' : '左行') + + // stand.name + '(' + stand.code + ')] 设置停站时间,' + strategy.time + '秒'; break; } + case 'J_P': { + // const stand = this.$store.getters['map/getDeviceByCode'](strategy.standCode); + // const station = this.$store.getters['map/getDeviceByCode'](stand.stationCode); + // eachStrategy.description = '为列车[' + strategy.groupNumber + + // '-' + strategy.serviceNumber + '|' + strategy.tripNumber + + // '],设置站台' + station.name + '-' + (stand.right ? '右行' : '左行') + + // stand.name + ' (' + stand.code + ') 跳停,并且为站台[' + station.name + '-' + (stand.right ? '右行' : '左行') + + // stand.name + '(' + stand.code + ')] 设置停站时间,' + strategy.time + '秒'; + eachStrategy.description = strategy.description; } + } + eachStrategy.effectTrainNum = strategy.effectTrainNum; + eachStrategy.scheduleOffset = strategy.scheduleOffset; + eachStrategy.extraNum = strategy.extraNum; + eachStrategy.effectTrainSet = strategy.effectTrainSet; this.LPFstrategyList.push(eachStrategy); }); + this.LPFstandList = []; + val.lpfList.forEach(standInfo=>{ + const stand = this.$store.getters['map/getDeviceByCode'](standInfo.standCode); + const station = this.$store.getters['map/getDeviceByCode'](stand.stationCode); + this.LPFstandList.push({name:station.name + '-' + (stand.right ? '右行' : '左行') + + stand.name + '(' + stand.code + ')', wait:standInfo.wait}); + }); } }, '$store.state.socket.simulationOver':function(val) { @@ -276,7 +323,7 @@ export default { this.myChart = echarts.init(document.getElementById(this.bigLPFStrategyId)); if (this.myChart) { this.myChart.setOption(option); - this.reSize({ width: this.$store.state.app.width * 0.66, height: this.$store.state.app.height - 40 }); + this.reSize({ width: this.$store.state.app.width * 0.74, height: this.$store.state.app.height - 40 }); } resolve(true); } catch (error) { @@ -285,7 +332,7 @@ export default { }); }, setWindowSize() { - this.reSize({ width: this.$store.state.app.width * 0.66, height: this.$store.state.app.height - 40 }); + this.reSize({ width: this.$store.state.app.width * 0.74, height: this.$store.state.app.height - 40 }); }, reSize(opt) { if (this.myChart) { @@ -319,8 +366,9 @@ export default { background: #fff; font-size: 14px; margin-left: 2%; + border-radius: 5px; } -.LPFstrategyTop,.bigLPFStrategyLTitle{ +.LPFstrategyTop{ background:#fff; height: 40px; border-bottom: 1px #d4d4d4 solid; @@ -330,14 +378,22 @@ export default { left:0; } .bigLPFStrategyLTitle{ - padding: 10px; + padding: 15px 20px 0px 20px; font-size: 15px; + background: #fff; + height: 40px; + width: 100%; + position: absolute; + top: 0; + left: 0; } .LPFstrategyTitle{ float: left; + width:100%; padding-top: 10px; - padding-left: 10px; + padding-left: 15px; font-size: 15px; + padding-right: 20px; } .LPFstrategyClose{ float: right; @@ -345,11 +401,11 @@ export default { padding: 5px; margin-top: 5px; } -.LPFstrategyListOut{ +#LPFstrategyListOut{ height: 100%; overflow: auto; background: #f1f1f1; - padding-bottom: 10px; + padding-bottom:20px; border-bottom: 1px #d4d4d4 solid; &::-webkit-scrollbar { width: 5px; @@ -376,18 +432,20 @@ export default { margin-left:50px; } .bigLPFStrategyL{ - width: 66%; + width: 74%; float: left; height: 100%; padding: 40px 0px 0px 0px; + position: relative; } .bigLPFStrategyR{ - width: 34%; + width: 26%; float: right; border-left: 1px #eee solid; height: 100%; padding: 40px 0px; position: relative; + box-shadow: -5px 0px 5px #dedede; } .bigLPFStrategy{ width:100%; @@ -408,9 +466,45 @@ export default { padding-top: 5px; padding-bottom: 5px; } -.bigLPFStrategyLChart{} #bigLPFStrategyId{ width:100%; height:100%; } +.LPFstrategyTitleL{} +.LPFstrategyTitleR{ + // float:right +} +.LPFstrategyListIn{height:100%;overflow:hidden;padding-top: 41px;position:relative;} + +