新版绘图 高级数据 交路 生成站间运行时间 接口调整

This commit is contained in:
joylink_cuiweidong 2020-04-26 13:18:25 +08:00
parent 7234f95b7d
commit 4d1f6a6a9d
4 changed files with 32 additions and 2 deletions

View File

@ -290,6 +290,14 @@ export function updateRoutingData(data) {
});
}
/** 根据地图起始-终点车站站台区段生成站间运行等级(新版)*/
export function generateStationRunData(routingId) {
return request({
url: `/api/draftMap/runLevel/generate/${routingId}`,
method: 'post'
});
}
// 创建自动信号 old旧数据
export function postAutoSignal(data) {
return request({

View File

@ -535,6 +535,8 @@ export default {
blockCodingClomn: 'Block coding',
routing: 'Pay the way',
generateStationRunDataSuccess:'Generate station run data success',
generateStationRunDataFailed:'Generate station run data failed',
linkageSwitchList: 'Linkage switch list',

View File

@ -530,6 +530,8 @@ export default {
blockCodingClomn: '区段编码',
routing: '交路',
generateStationRunDataSuccess:'站间运行数据生成成功',
generateStationRunDataFailed:'站间运行数据生成失败',
linkageSwitchList: '联动道岔列表',

View File

@ -15,7 +15,7 @@
<script>
import { mapGetters } from 'vuex';
import { listMap } from '@/api/jmap/mapdraft';
import { listRoutingData, deleteRoutingData, getRoutingData } from '@/api/jmap/mapdraft';
import { listRoutingData, deleteRoutingData, getRoutingData, generateStationRunData } from '@/api/jmap/mapdraft';
import PreViewField from './preview';
export default {
@ -113,7 +113,7 @@ export default {
{
type: 'button',
title: this.$t('map.operation'),
width: '200',
width: '300',
buttons: [
{
name: this.$t('map.compile'),
@ -123,6 +123,11 @@ export default {
name: this.$t('map.deleteObj'),
handleClick: this.deleteObj,
type: 'danger'
},
{
name: '生成站间运行数据',
handleClick: this.generateData,
type: 'danger'
}
]
}
@ -222,6 +227,19 @@ export default {
});
}
},
generateData(index, row) {
if (this.mapInfo && this.mapInfo.id && row) {
// -
generateStationRunData(row.id).then(response => {
this.$message.success(this.$t('map.generateStationRunDataSuccess'));
//
this.reloadTable();
}).catch(() => {
//
this.$messageBox(this.$t('map.generateStationRunDataFailed'));
});
}
},
sectionDetail(index, row) {
const sectionDict = {};
const stationDict = {};