Ajout des infos Modbus aux fichiers de passage
-Modification des fichiers de passage pour inclure les infos supplémentaires obtenus par Modbus (type et composition du train)
This commit is contained in:
@@ -519,13 +519,32 @@ void CLogsListPage::ShowItemSummary(CLogElement *Element)
|
||||
}
|
||||
|
||||
|
||||
Summary.sprintf("Statistiques du passage:\n\nDate: %s\nHeure: %s\nTrain : %s\nNombre d'éléments: %d\nVitesse moyenne : %f mph\nPassage problématique: %s\n\nDéclenchements: \n",
|
||||
ZT1LogElement->mPassageDateTime.toString("yyyy/MM/dd").toAscii().data(),
|
||||
ZT1LogElement->mPassageDateTime.toString("hh:mm:ss").toAscii().data(),
|
||||
CZTData::GetTrainTypeString(ZT1LogElement->mTrainType),
|
||||
ZT1LogElement->mNbElements,
|
||||
MeanSpeed,
|
||||
Problem.toUtf8().data());
|
||||
QString Composition("Inconnue");
|
||||
if(ZT1LogElement->mFlags.mTrainCompo1 != 0) //if compo is valid, this will be != 0...
|
||||
{
|
||||
Composition = QString("%1 - %2 - %3").arg(ZT1LogElement->mFlags.mTrainCompo1).arg(ZT1LogElement->mFlags.mTrainCompo2).arg(ZT1LogElement->mFlags.mTrainCompo3);
|
||||
}
|
||||
QString TrainType = CZTData::GetTrainTypeString(ZT1LogElement->mTrainType);
|
||||
if(ZT1LogElement->mFlags.mModbusTrainType != MODBUS_CC_TRAIN_TYPE_INVALID_NOT_UPDATED)
|
||||
{
|
||||
TrainType = CZTData::GetModbusTrainTypeString(ZT1LogElement->mFlags.mModbusTrainType);
|
||||
}
|
||||
|
||||
// Summary.sprintf("Statistiques du passage:\n\nDate: %s\nHeure: %s\nTrain : %s\nNombre d'éléments: %d\nVitesse moyenne : %f mph\nPassage problématique: %s\n\nDéclenchements: \n",
|
||||
// ZT1LogElement->mPassageDateTime.toString("yyyy/MM/dd").toAscii().data(),
|
||||
// ZT1LogElement->mPassageDateTime.toString("hh:mm:ss").toAscii().data(),
|
||||
// CZTData::GetTrainTypeString(ZT1LogElement->mTrainType),
|
||||
// ZT1LogElement->mNbElements,
|
||||
// MeanSpeed,
|
||||
// Problem.toUtf8().data());
|
||||
|
||||
Summary = QString("Statistiques du passage:\n\nDate: %1\nHeure: %2\nTrain : %3\nNombre d'éléments: %4\nComposition : %5\nPassage problématique: %6\n\nDéclenchements: \n")\
|
||||
.arg(ZT1LogElement->mPassageDateTime.toString("yyyy/MM/dd"))\
|
||||
.arg(ZT1LogElement->mPassageDateTime.toString("hh:mm:ss"))\
|
||||
.arg(TrainType)\
|
||||
.arg(ZT1LogElement->mNbElements)\
|
||||
.arg(Composition)\
|
||||
.arg(Problem.toUtf8().data());
|
||||
|
||||
if(ZT1LogElement->mZTDetections.size() > 0)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user