哈尔滨设备登陆 车辆段 运行图编辑 报错调整
This commit is contained in:
parent
fefbf97c99
commit
b96b77e927
@ -325,7 +325,12 @@ export default {
|
||||
this.analyticalTripNumber(serviceObj.trainMap || {});
|
||||
},
|
||||
tripNumberChange(row) {
|
||||
const serviceNumber = this.$store.state.runPlan.selected.serviceNumber;
|
||||
let serviceNumber;
|
||||
if (this.loadRunPlanId) {
|
||||
serviceNumber = this.$store.state.runPlan.draftSelected.serviceNumber;
|
||||
} else {
|
||||
serviceNumber = this.$store.state.runPlan.selected.serviceNumber;
|
||||
}
|
||||
let tripNumber = null;
|
||||
if (row) {
|
||||
const data = [];
|
||||
@ -367,7 +372,6 @@ export default {
|
||||
}, 50);
|
||||
|
||||
}
|
||||
|
||||
if (this.loadRunPlanId) {
|
||||
this.$store.dispatch('runPlan/setDraftSelected', { serviceNumber: serviceNumber, tripNumber: tripNumber });
|
||||
} else {
|
||||
@ -433,7 +437,11 @@ export default {
|
||||
// });
|
||||
// } else {
|
||||
getPublishMapInfo(this.$route.query.mapId).then(resp => {
|
||||
this.mapName = `${resp.data.name} (${this.$route.query.planName || this.loadRunPlanName || ''})`;
|
||||
if (this.loadRunPlanId) {
|
||||
this.mapName = this.$route.query.planName || this.loadRunPlanName || '';
|
||||
} else {
|
||||
this.mapName = `${resp.data.name} (${this.$route.query.planName || this.loadRunPlanName || ''})`;
|
||||
}
|
||||
});
|
||||
// }
|
||||
|
||||
@ -654,7 +662,12 @@ export default {
|
||||
},
|
||||
refreshRunPlanName(name) {
|
||||
getPublishMapInfo(this.$route.query.mapId).then(resp => {
|
||||
this.mapName = `${resp.data.name} (${name})`;
|
||||
if (this.loadRunPlanId) {
|
||||
this.mapName = name;
|
||||
} else {
|
||||
this.mapName = `${resp.data.name} (${name})`;
|
||||
}
|
||||
|
||||
this.myChart.setOption({
|
||||
title: {
|
||||
text: this.mapName,
|
||||
|
@ -212,6 +212,7 @@ export default {
|
||||
},
|
||||
refreshRunPlanName(name) {
|
||||
this.$refs.schedule.refreshRunPlanName(name);
|
||||
this.refreshRunPlanList(this.loadRunPlanId);
|
||||
this.$router.replace({ path: this.$route.path, query: { ...this.$route.query, planName: name }});
|
||||
}
|
||||
}
|
||||
|
@ -595,7 +595,7 @@ export default {
|
||||
handleDeletePlanningTrain() {
|
||||
const serviceNumber = this.$store.state.runPlan.draftSelected.serviceNumber;
|
||||
if (serviceNumber) {
|
||||
this.$emit('dispatchDialog', {
|
||||
this.$emit('dispatchDialog', {
|
||||
name: 'offLine', params: {
|
||||
type: 'warning',
|
||||
width: 260,
|
||||
|
@ -73,7 +73,7 @@ export default {
|
||||
},
|
||||
// 删除计划
|
||||
handleDeletePlanningTrain() {
|
||||
const serviceNumber = this.$store.state.runPlan.selected.serviceNumber;
|
||||
const serviceNumber = this.$store.state.runPlan.draftSelected.serviceNumber;
|
||||
if (serviceNumber) {
|
||||
this.$emit('dispatchDialog', {
|
||||
name: 'offLine', params: {
|
||||
@ -90,7 +90,7 @@ export default {
|
||||
}
|
||||
},
|
||||
handleMovePlanningTrain() {
|
||||
const serviceNumber = this.$store.state.runPlan.selected.serviceNumber;
|
||||
const serviceNumber = this.$store.state.runPlan.draftSelected.serviceNumber;
|
||||
if (serviceNumber) {
|
||||
this.$emit('dispatchDialog', { name: 'movePlaningTrain', params: { serviceNumber } });
|
||||
} else {
|
||||
@ -99,7 +99,7 @@ export default {
|
||||
},
|
||||
// 复制计划
|
||||
handleDuplicateTrain() {
|
||||
const serviceNumber = this.$store.state.runPlan.selected.serviceNumber;
|
||||
const serviceNumber = this.$store.state.runPlan.draftSelected.serviceNumber;
|
||||
if (serviceNumber) {
|
||||
this.$emit('dispatchDialog', { name: 'duplicateTrain', params: { serviceNumber } });
|
||||
} else {
|
||||
@ -108,7 +108,7 @@ export default {
|
||||
},
|
||||
// 添加任务
|
||||
handleAddTask() {
|
||||
const params = this.$store.state.runPlan.selected;
|
||||
const params = this.$store.state.runPlan.draftSelected;
|
||||
if (params.serviceNumber && params.tripNumber) {
|
||||
this.$emit('dispatchDialog', { name: 'addTask', params });
|
||||
} else {
|
||||
@ -117,7 +117,7 @@ export default {
|
||||
},
|
||||
// 删除任务
|
||||
handleDeleteTask() {
|
||||
const params = this.$store.state.runPlan.selected;
|
||||
const params = this.$store.state.runPlan.draftSelected;
|
||||
if (params.serviceNumber && params.tripNumber) {
|
||||
this.$emit('dispatchDialog', { name: 'deleteTask', params });
|
||||
} else {
|
||||
@ -126,7 +126,7 @@ export default {
|
||||
},
|
||||
// 修改任务
|
||||
handleModifyingTask() {
|
||||
const params = this.$store.state.runPlan.selected;
|
||||
const params = this.$store.state.runPlan.draftSelected;
|
||||
if (params.serviceNumber && params.tripNumber) {
|
||||
this.$emit('dispatchDialog', { name: 'modifyingTask', params });
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user