TestData.IsFromToInPct and TestRslt.Qdetected added, TestRslt.Qfrom() / Qto() rewritten, CombinedWithDetectionSeq bug fix.
This commit is contained in:
@@ -3,9 +3,9 @@
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.IO;
|
||||
using Common;
|
||||
using SharedDatabase.Mappings;
|
||||
|
||||
namespace SharedDatabase.Entities
|
||||
{
|
||||
@@ -44,7 +44,7 @@ namespace SharedDatabase.Entities
|
||||
public virtual double DensityLine { get; set; } /// [kg/m3]
|
||||
public virtual double DensityDiv { get; set; } /// [kg/m3]
|
||||
public virtual double MassOfEvapWater { get; set; } /// [kg]
|
||||
public virtual double SpareDbl { get; set; }
|
||||
public virtual double Qdetected { get; set; }
|
||||
public virtual double Flow { get; set; } /// [m3/h] calculated from conventional true value
|
||||
public virtual double VolumeCTV { get; set; } /// [l] Volume conventional true value
|
||||
public virtual double VolumeMaster { get; set; } /// [l] Volume from the master flow meter
|
||||
@@ -150,9 +150,21 @@ namespace SharedDatabase.Entities
|
||||
public virtual string Name() { return Common.Utils.GetTestName(TestData.Name, TestData.Repeats, RepetitionNr); }
|
||||
public virtual string Key() { return string.Format("{0}~{1}~{2}~{3}", TestData.Name, Part, TestData.Repeats, RepetitionNr); } /// Unique key
|
||||
public virtual int Repeats() { return TestData.Repeats; }
|
||||
public virtual double Qfrom() { return TestData.Qfrom; }
|
||||
public virtual double Qto() { return TestData.Qto; }
|
||||
public virtual double TargetVolume() { return TestData.TargetVolume; }
|
||||
public virtual double Qfrom()
|
||||
{
|
||||
return (TestData == null) ? 0
|
||||
: !TestData.IsFromToInPct ? TestData.Qfrom
|
||||
: (TestData.Qtg >= 0) ? TestData.Qfrom * TestData.Qtg / 100
|
||||
: TestData.Qfrom * Qdetected / 100;
|
||||
}
|
||||
public virtual double Qto()
|
||||
{
|
||||
return (TestData == null) ? 0
|
||||
: !TestData.IsFromToInPct ? TestData.Qto
|
||||
: (TestData.Qtg >= 0) ? TestData.Qto * TestData.Qtg / 100
|
||||
: TestData.Qto * Qdetected / 100;
|
||||
}
|
||||
public virtual double TargetVolume() { return TestData.TargetVolume; }
|
||||
public virtual double TargetTime() { return TestData.TargetTime; }
|
||||
public virtual string Method() { return TestData.Method; }
|
||||
public virtual string RefFlowmeter() { return (Components != null && Components.Flowmeter != null) ? Components.Flowmeter : string.Empty; }
|
||||
@@ -278,7 +290,7 @@ namespace SharedDatabase.Entities
|
||||
DensityLine = src.DensityLine;
|
||||
DensityDiv = src.DensityDiv;
|
||||
MassOfEvapWater = src.MassOfEvapWater;
|
||||
SpareDbl = src.SpareDbl;
|
||||
Qdetected = src.Qdetected;
|
||||
Flow = src.Flow;
|
||||
VolumeCTV = src.VolumeCTV;
|
||||
VolumeMaster = src.VolumeMaster;
|
||||
@@ -416,7 +428,7 @@ namespace SharedDatabase.Entities
|
||||
return string.Format("TestRslt: Part={0} RepetitionNr={1} TestDone={2} Remark={3} StartTime={4} EndTime={5} FlowSetTime={6} TestTime={7} PulsesMaster={8} ConstMaster={9} MassStartRaw={10} MassStart={11} MassEndRaw={12} MassEnd={13} DensityIn={14} DensityOut={15} DensityDiv={16} MassOfEvapWaater={17} FlowMass={18} FlowVolume={19} VolumeCTV={20} VolumeMaster={21} ErrorMaster={22} DiverterStart={85} DiverterEnd={86} ErrorFlags={23} InfoFlags={24} AmbTempMean={25} AmbTempStart={26} AmbTempEnd={27} AmbTempMin={28} AmbTempMax={29} AmbPressMean={30} AmbPressStart={31} AmbPressEnd={32} AmbPressMin={33} AmbPressMax={34} AmbHumiMean={35} AmbHumiStart={36} AmbHumiEnd={37} AmbHumiMin={38} AmbHumiMax={39} PressUpMean={40} PressUpStart={41} PressUpEnd={42} PressUpMin={43} PressUpMax={44} PressDownMean={45} PressDownStart={46} PressDownEnd={47} PressDownMin={48} PressDownMax={49} PressDeltaMean={50} PressDeltaStart={51} PressDeltaEnd={52} PressDeltaMin={53} PressDeltaMax={54} TempUpMean={55} TempUpStart={56} TempUpEnd={57} TempUpMin={58} TempUpMax={59} TempDownMean={60} TempDownStart={61} TempDownEnd={62} TempDownMin={63} TempDownMax={64} TempDivMean={65} TempDivStart={66} TempDivEnd={67} TempDivMin={68} TempDivMax={69} FlowMean={70} FlowStart={71} FlowEnd={72} FlowMin={73} FlowMax={74} Custom1={75} Custom2={76} Custom3={77} Custom4={78} Custom5={79} Custom6={80} Custom7={81} Custom8={82} Custom9={83} Custom10={84}",
|
||||
Part, RepetitionNr, TestDone, Remark, StartTime, EndTime, FlowSetTime, TestTime,
|
||||
PulsesMaster, ConstMaster, MassStartRaw, MassStart, MassEndRaw, MassEnd,
|
||||
DensityIn, DensityLine, DensityDiv, MassOfEvapWater, SpareDbl, Flow,
|
||||
DensityIn, DensityLine, DensityDiv, MassOfEvapWater, Qdetected, Flow,
|
||||
VolumeCTV, VolumeMaster, ErrorMaster, ErrorFlags, InfoFlags,
|
||||
AmbTempMean, AmbTempStart, AmbTempEnd, AmbTempMin, AmbTempMax,
|
||||
AmbPressMean, AmbPressStart, AmbPressEnd, AmbPressMin, AmbPressMax,
|
||||
@@ -485,7 +497,7 @@ namespace SharedDatabase.Entities
|
||||
writer.Write(DensityLine);
|
||||
writer.Write(DensityDiv);
|
||||
writer.Write(MassOfEvapWater);
|
||||
writer.Write(SpareDbl);
|
||||
writer.Write(Qdetected);
|
||||
writer.Write(Flow);
|
||||
writer.Write(VolumeCTV);
|
||||
writer.Write(VolumeMaster);
|
||||
@@ -626,7 +638,7 @@ namespace SharedDatabase.Entities
|
||||
DensityLine = reader.ReadDouble();
|
||||
DensityDiv = reader.ReadDouble();
|
||||
MassOfEvapWater = reader.ReadDouble();
|
||||
SpareDbl = reader.ReadDouble();
|
||||
Qdetected = reader.ReadDouble();
|
||||
Flow = reader.ReadDouble();
|
||||
VolumeCTV = reader.ReadDouble();
|
||||
VolumeMaster = reader.ReadDouble();
|
||||
|
||||
Reference in New Issue
Block a user