BatchResults.WaterMeters eliminated, Batch.WaterMeters are used instead ... many changes

This commit is contained in:
Milan Hanajik
2020-02-05 10:33:32 +01:00
parent 51523ea577
commit dc31e833ee
58 changed files with 574 additions and 490 deletions
@@ -849,13 +849,16 @@ namespace TBF.BenchControl.TestMethods.DiverterTest
/// Update water meter error flags
if (ErrorFlagsComp != null)
{
for (int i = 0; i < BatchRslts.WMPositionsCount; i++)
if (BatchRslts.Batch != null && BatchRslts.Batch.WaterMeters != null)
{
if (BatchRslts.WaterMeters[i] != null)
for (int i = 0; i < BatchRslts.WMPositionsCount; i++)
{
long _infoFlags;
BatchRslts.WaterMeters[i].ErrorFlags = ErrorFlagsComp.GetWMtrErrorFlags(BatchRslts.WaterMeters[i].MeterTestRslts, out _infoFlags);
BatchRslts.WaterMeters[i].InfoFlags = infoFlags;
if (BatchRslts.Batch.WaterMeters[i] != null && !BatchRslts.Batch.WaterMeters[i].Disabled)
{
long wmInfoFlags;
BatchRslts.Batch.WaterMeters[i].ErrorFlags = ErrorFlagsComp.GetWMtrErrorFlags(BatchRslts.Batch.WaterMeters[i].MeterTestRslts, out wmInfoFlags);
BatchRslts.Batch.WaterMeters[i].InfoFlags = wmInfoFlags;
}
}
}
}