运行图 代码调整
This commit is contained in:
parent
70260cfbe3
commit
82f8db41d1
@ -57,7 +57,9 @@ const runPlan = {
|
|||||||
const trainList = service.tripNumberDataList;
|
const trainList = service.tripNumberDataList;
|
||||||
state.initialPlanData[service.serviceNumber] = { oldIndex: i, serviceNumber: service.serviceNumber, backup: service.backup, trainMap: {} };
|
state.initialPlanData[service.serviceNumber] = { oldIndex: i, serviceNumber: service.serviceNumber, backup: service.backup, trainMap: {} };
|
||||||
trainList.forEach((train, j) => {
|
trainList.forEach((train, j) => {
|
||||||
state.initialPlanData[service.serviceNumber].trainMap[`${train.tripNumber}`] = { oldIndex: j, tripNumber: train.tripNumber, directionCode: train.directionCode, reentry: train.reentry, stationTimeList: train.stationTimeList };
|
state.initialPlanData[service.serviceNumber].trainMap[`${train.tripNumber}`] = { oldIndex: j, tripNumber: train.tripNumber, right:train.right,
|
||||||
|
directionCode: train.directionCode, reentry: train.reentry, stationTimeList: train.stationTimeList, endSecondTime:train.endSecondTime,
|
||||||
|
startSecondTime: train.startSecondTime };
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -71,7 +73,10 @@ const runPlan = {
|
|||||||
const trainList = service.tripNumberDataList;
|
const trainList = service.tripNumberDataList;
|
||||||
state.editData[service.serviceNumber] = { oldIndex: i, serviceNumber: service.serviceNumber, backup: service.backup, trainMap: {} };
|
state.editData[service.serviceNumber] = { oldIndex: i, serviceNumber: service.serviceNumber, backup: service.backup, trainMap: {} };
|
||||||
trainList.forEach((train, j) => {
|
trainList.forEach((train, j) => {
|
||||||
state.editData[service.serviceNumber].trainMap[`${train.tripNumber}`] = { oldIndex: j, tripNumber: train.tripNumber, directionCode: train.directionCode, reentry: train.reentry, stationTimeList: train.stationTimeList };
|
state.editData[service.serviceNumber].trainMap[`${train.tripNumber}`] =
|
||||||
|
{ oldIndex: j, tripNumber: train.tripNumber, directionCode: train.directionCode, right:train.right,
|
||||||
|
reentry: train.reentry, stationTimeList: train.stationTimeList, endSecondTime:train.endSecondTime,
|
||||||
|
startSecondTime: train.startSecondTime};
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -86,7 +91,9 @@ const runPlan = {
|
|||||||
const trainList = service.tripNumberDataList;
|
const trainList = service.tripNumberDataList;
|
||||||
state.draftEditData[service.serviceNumber] = { oldIndex: i, serviceNumber: service.serviceNumber, backup: service.backup, trainMap: {} };
|
state.draftEditData[service.serviceNumber] = { oldIndex: i, serviceNumber: service.serviceNumber, backup: service.backup, trainMap: {} };
|
||||||
trainList.forEach((train, j) => {
|
trainList.forEach((train, j) => {
|
||||||
state.draftEditData[service.serviceNumber].trainMap[`${train.tripNumber}`] = { oldIndex: j, tripNumber: train.tripNumber, directionCode: train.directionCode, reentry: train.reentry, stationTimeList: train.stationTimeList };
|
state.draftEditData[service.serviceNumber].trainMap[`${train.tripNumber}`] = { oldIndex: j, tripNumber: train.tripNumber, right:train.right,
|
||||||
|
directionCode: train.directionCode, reentry: train.reentry, stationTimeList: train.stationTimeList, endSecondTime:train.endSecondTime,
|
||||||
|
startSecondTime: train.startSecondTime};
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -118,12 +118,13 @@ export default {
|
|||||||
startTbFront:resp.data.startTbFront
|
startTbFront:resp.data.startTbFront
|
||||||
};
|
};
|
||||||
if (resp.data.startTbFront == false) {
|
if (resp.data.startTbFront == false) {
|
||||||
|
taskObj.startTime = formatTime(trainInfo.startSecondTime + 7200);
|
||||||
const newModel = {
|
const newModel = {
|
||||||
sectionCode:resp.data.parkSectionCodeList[0].sectionCode,
|
sectionCode:resp.data.parkSectionCodeList[0].sectionCode,
|
||||||
stationCode:resp.data.startStationCode,
|
stationCode:resp.data.startStationCode,
|
||||||
// // speedLevel:'默认',
|
// // speedLevel:'默认',
|
||||||
departureTime: formatTime(trainInfo.stationTimeList[0].secondTime + 7200),
|
departureTime: formatTime(trainInfo.startSecondTime + 7200),
|
||||||
arriveTime: formatTime(trainInfo.stationTimeList[0].secondTime + 7200),
|
arriveTime: formatTime(trainInfo.startSecondTime + 7200),
|
||||||
stopTime:0
|
stopTime:0
|
||||||
};
|
};
|
||||||
taskObj.arriveConfigList.push(newModel);
|
taskObj.arriveConfigList.push(newModel);
|
||||||
@ -160,13 +161,14 @@ export default {
|
|||||||
taskObj.arriveConfigList.push(newModel);
|
taskObj.arriveConfigList.push(newModel);
|
||||||
});
|
});
|
||||||
if (resp.data.endTbFront == false) {
|
if (resp.data.endTbFront == false) {
|
||||||
|
taskObj.endTime = formatTime(trainInfo.endSecondTime + 7200);
|
||||||
const length = resp.data.parkSectionCodeList.length - 1;
|
const length = resp.data.parkSectionCodeList.length - 1;
|
||||||
const newModel = {
|
const newModel = {
|
||||||
sectionCode:resp.data.parkSectionCodeList[length].sectionCode,
|
sectionCode:resp.data.parkSectionCodeList[length].sectionCode,
|
||||||
stationCode:resp.data.endStationCode,
|
stationCode:resp.data.endStationCode,
|
||||||
// // speedLevel:'默认',
|
// // speedLevel:'默认',
|
||||||
departureTime: formatTime(trainInfo.stationTimeList[length].secondTime + 7200),
|
departureTime: formatTime(trainInfo.endSecondTime + 7200),
|
||||||
arriveTime: formatTime(trainInfo.stationTimeList[length].secondTime + 7200),
|
arriveTime: formatTime(trainInfo.endSecondTime + 7200),
|
||||||
stopTime:0
|
stopTime:0
|
||||||
};
|
};
|
||||||
taskObj.arriveConfigList.push(newModel);
|
taskObj.arriveConfigList.push(newModel);
|
||||||
|
Loading…
Reference in New Issue
Block a user