Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f0df91c4ac |
+4
-18
@@ -1,21 +1,7 @@
|
||||
Config/bin/
|
||||
Config/obj/
|
||||
DeviceTest/bin/
|
||||
DeviceTest/obj/
|
||||
Dirichlet.Numerics/bin
|
||||
Dirichlet.Numerics/obj
|
||||
Results/bin/
|
||||
Results/obj/
|
||||
ResultsBrowser/bin/
|
||||
ResultsBrowser/obj/
|
||||
TestBenchFramework/bin/
|
||||
TestBenchFramework/obj/
|
||||
TBFSetup/Debug/
|
||||
TBFSetup/Release/
|
||||
Users/bin/
|
||||
Users/obj/
|
||||
UserManagement/bin/
|
||||
UserManagement/obj/
|
||||
ResultsBrowser/bin/
|
||||
ResultsBrowser/obj/
|
||||
TBFSetup/
|
||||
Doc/
|
||||
*.suo
|
||||
*.bak
|
||||
*.suo
|
||||
@@ -1,148 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProductVersion>8.0.30703</ProductVersion>
|
||||
<SchemaVersion>2.0</SchemaVersion>
|
||||
<ProjectGuid>{743DF7DB-C7B6-42EB-986D-0F485E5588E4}</ProjectGuid>
|
||||
<OutputType>Library</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>Config</RootNamespace>
|
||||
<AssemblyName>Config</AssemblyName>
|
||||
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<DefineConstants>TRACE;DEBUG;MUNICH</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<AllowUnsafeBlocks>false</AllowUnsafeBlocks>
|
||||
<PlatformTarget>x86</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>TRACE;MUNICH</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="FluentNHibernate">
|
||||
<HintPath>..\packages\FluentNHibernate.2.0.3.0\lib\net40\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.0.4000\lib\net40\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="log4net">
|
||||
<HintPath>..\packages\log4net.2.0.2\lib\net40-full\log4net.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="MySql.Data">
|
||||
<HintPath>..\packages\MySql.Data.6.6.5\lib\net40\MySql.Data.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="NHibernate">
|
||||
<HintPath>..\packages\NHibernate.4.0.4.4000\lib\net40\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Data.SQLite">
|
||||
<HintPath>..\packages\System.Data.SQLite.1.0.90.0\lib\net40\System.Data.SQLite.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System.Data.SQLite.Linq">
|
||||
<HintPath>..\packages\System.Data.SQLite.1.0.90.0\lib\net40\System.Data.SQLite.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System.Windows.Forms" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
<Reference Include="System.Data" />
|
||||
<Reference Include="System.Xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Data.cs" />
|
||||
<Compile Include="DatabaseSettings.cs" />
|
||||
<Compile Include="Entities\BenchPath.cs" />
|
||||
<Compile Include="Entities\Component.cs" />
|
||||
<Compile Include="Entities\ComponentProcedure.cs" />
|
||||
<Compile Include="Entities\ComponentTest.cs" />
|
||||
<Compile Include="Entities\Enums.cs" />
|
||||
<Compile Include="Entities\FeedingPath.cs" />
|
||||
<Compile Include="Entities\Group.cs" />
|
||||
<Compile Include="Entities\HeatMetersPath.cs" />
|
||||
<Compile Include="Entities\IHasItemNr.cs" />
|
||||
<Compile Include="Entities\IHasValves.cs" />
|
||||
<Compile Include="Entities\MeasurementCorrection.cs" />
|
||||
<Compile Include="Entities\MetersPath.cs" />
|
||||
<Compile Include="Entities\MeterTestResult.cs" />
|
||||
<Compile Include="Entities\OutputPath.cs" />
|
||||
<Compile Include="Entities\Procedure.cs" />
|
||||
<Compile Include="Entities\ProcedureHistory.cs" />
|
||||
<Compile Include="Entities\Test.cs" />
|
||||
<Compile Include="Entities\TestResult.cs" />
|
||||
<Compile Include="Entities\TransitionSequence.cs" />
|
||||
<Compile Include="Entities\TransitionStep.cs" />
|
||||
<Compile Include="Entities\User.cs" />
|
||||
<Compile Include="Entities\VirtualBenchSequence.cs" />
|
||||
<Compile Include="Entities\VirtualBenchStep.cs" />
|
||||
<Compile Include="Entities\Watermeter.cs" />
|
||||
<Compile Include="Entities\WMType.cs" />
|
||||
<Compile Include="FluentCommon.cs" />
|
||||
<Compile Include="Mappings\BenchPathMap.cs" />
|
||||
<Compile Include="Mappings\ComponentMap.cs" />
|
||||
<Compile Include="Mappings\ComponentProcedureMap.cs" />
|
||||
<Compile Include="Mappings\ComponentTestMap.cs" />
|
||||
<Compile Include="Mappings\FeedingPathMap.cs" />
|
||||
<Compile Include="Mappings\GroupMap.cs" />
|
||||
<Compile Include="Mappings\HeatMetersPathMap.cs" />
|
||||
<Compile Include="Mappings\MeasurementCorrectionMap.cs" />
|
||||
<Compile Include="Mappings\MetersPathMap.cs" />
|
||||
<Compile Include="Mappings\MeterTestResultMap.cs" />
|
||||
<Compile Include="Mappings\OutputPathMap.cs" />
|
||||
<Compile Include="Mappings\ProcedureMap.cs" />
|
||||
<Compile Include="Mappings\TestMap.cs" />
|
||||
<Compile Include="Mappings\TestResultMap.cs" />
|
||||
<Compile Include="Mappings\TransitionSequenceMap.cs" />
|
||||
<Compile Include="Mappings\TransitionStepMap.cs" />
|
||||
<Compile Include="Mappings\UserMap.cs" />
|
||||
<Compile Include="Mappings\VirtualBenchSequenceMap.cs" />
|
||||
<Compile Include="Mappings\VirtualBenchStepMap.cs" />
|
||||
<Compile Include="Mappings\WatermeterMap.cs" />
|
||||
<Compile Include="Mappings\WMTypeMap.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<Compile Include="Resources\Strings.Designer.cs">
|
||||
<AutoGen>True</AutoGen>
|
||||
<DesignTime>True</DesignTime>
|
||||
<DependentUpon>Strings.resx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Units.cs" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<EmbeddedResource Include="Resources\Strings.cs.resx" />
|
||||
<EmbeddedResource Include="Resources\Strings.de.resx" />
|
||||
<EmbeddedResource Include="Resources\Strings.pl.resx" />
|
||||
<EmbeddedResource Include="Resources\Strings.resx">
|
||||
<SubType>Designer</SubType>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Resources\Strings.ru.resx" />
|
||||
<EmbeddedResource Include="Resources\Strings.zh-CN.resx" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\Users\Users.csproj">
|
||||
<Project>{6E5CB0E9-E1B6-4E5D-AC6E-B1049E180F2B}</Project>
|
||||
<Name>Users</Name>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||
Other similar extension points exist, see Microsoft.Common.targets.
|
||||
<Target Name="BeforeBuild">
|
||||
</Target>
|
||||
<Target Name="AfterBuild">
|
||||
</Target>
|
||||
-->
|
||||
</Project>
|
||||
@@ -1,78 +0,0 @@
|
||||
using System;
|
||||
|
||||
namespace Config
|
||||
{
|
||||
public class Data : Users.GlobalData
|
||||
{
|
||||
public const string AdminUsername = "admin";
|
||||
public const string AdminPassword = "staratura";
|
||||
public const string SQLiteDbFName = "SQLite.db";
|
||||
|
||||
#if MUNICH
|
||||
public const int WMsCount = 3;
|
||||
public const int LineSize = 1;
|
||||
public const int CompoundWMsCount = 1;
|
||||
public const int HeatMetersCount = 0;
|
||||
public const int MaxPartNr = 3;
|
||||
#elif DN100 || BADGER_VELKA_TRAT
|
||||
public const int WMsCount = 3;
|
||||
public const int LineSize = 3;
|
||||
public const int CompoundWMsCount = 1;
|
||||
public const int HeatMetersCount = 0;
|
||||
public const int MaxPartNr = WMsCount / LineSize;
|
||||
#elif FUZHOU300 || FUZHOU150 || PT200IL || PUCHONG_PT200 || GENESIS || BERLIN
|
||||
public const int WMsCount = 6;
|
||||
public const int LineSize = 6;
|
||||
public const int CompoundWMsCount = 3;
|
||||
public const int HeatMetersCount = 0;
|
||||
public const int MaxPartNr = 3;
|
||||
#elif TORINO50 || BADGER_MALA_TRAT
|
||||
public const int WMsCount = 6;
|
||||
public const int LineSize = 6;
|
||||
public const int CompoundWMsCount = 1;
|
||||
public const int HeatMetersCount = 0;
|
||||
public const int MaxPartNr = 1;
|
||||
#elif TORUN_PT50_2015 || CEVAK_PT40_272 || MURES_PT40 || FUZHOU_40
|
||||
public const int WMsCount = 20;
|
||||
public const int LineSize = 10;
|
||||
public const int CompoundWMsCount = 1;
|
||||
public const int HeatMetersCount = 0;
|
||||
public const int MaxPartNr = WMsCount / LineSize;
|
||||
#elif TURA_IPERL
|
||||
public const int WMsCount = 40;
|
||||
public const int LineSize = 20;
|
||||
public const int CompoundWMsCount = 1;
|
||||
public const int HeatMetersCount = 0;
|
||||
public const int MaxPartNr = WMsCount / LineSize;
|
||||
#elif TURA_SPECIAL
|
||||
public const int WMsCount = 6;
|
||||
public const int LineSize = 6;
|
||||
public const int CompoundWMsCount = 1;
|
||||
public const int HeatMetersCount = 0;
|
||||
public const int MaxPartNr = WMsCount / LineSize;
|
||||
#elif SLM_50
|
||||
public const int WMsCount = 12;
|
||||
public const int LineSize = 12;
|
||||
public const int CompoundWMsCount = 1;
|
||||
public const int HeatMetersCount = 6;
|
||||
public const int MaxPartNr = WMsCount / LineSize;
|
||||
#elif SLM_END || WARSAW_END
|
||||
public const int WMsCount = 10;
|
||||
public const int LineSize = 5;
|
||||
public const int CompoundWMsCount = 1;
|
||||
public const int HeatMetersCount = 0;
|
||||
public const int MaxPartNr = 4;
|
||||
#elif MALTA_WSD25
|
||||
public const int WMsCount = 6;
|
||||
public const int LineSize = 6;
|
||||
public const int CompoundWMsCount = 0;
|
||||
public const int HeatMetersCount = 0;
|
||||
public const int MaxPartNr = WMsCount / LineSize;
|
||||
#endif
|
||||
|
||||
///
|
||||
/// Database related: This object reference is set after a successful user login
|
||||
///
|
||||
public static DatabaseSettings CurrentBench;
|
||||
}
|
||||
}
|
||||
@@ -1,54 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2013-2017 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System.Text;
|
||||
using System.Xml.Serialization;
|
||||
|
||||
namespace Config
|
||||
{
|
||||
/// <summary>
|
||||
/// Test bench database settings, contains bench name and settings od several databases
|
||||
/// </summary>
|
||||
public class DatabaseSettings : ICloneable
|
||||
{
|
||||
// Public fields
|
||||
public string BenchName;
|
||||
public bool IsRealBench;
|
||||
public Users.DBSettings ProceduresDBSettings; /// Config database settings
|
||||
public Users.DBSettings WaterMetersDBSettings; /// Results database settings
|
||||
public Users.DBSettings UsersDBSettings; /// Users database settings
|
||||
|
||||
// Constructor
|
||||
public DatabaseSettings()
|
||||
{
|
||||
BenchName = String.Empty; /// Empty string (avoid null)
|
||||
IsRealBench = false;
|
||||
ProceduresDBSettings = new Users.DBSettings(Users.Entities.DBType.MySql, string.Empty);
|
||||
WaterMetersDBSettings = new Users.DBSettings(Users.Entities.DBType.MySql, string.Empty);
|
||||
UsersDBSettings = new Users.DBSettings(Users.Entities.DBType.MySql, string.Empty);
|
||||
}
|
||||
|
||||
public object Clone()
|
||||
{
|
||||
DatabaseSettings result = new DatabaseSettings();
|
||||
|
||||
result.BenchName = BenchName;
|
||||
result.IsRealBench = IsRealBench;
|
||||
result.ProceduresDBSettings = (Users.DBSettings)ProceduresDBSettings.Clone();
|
||||
result.WaterMetersDBSettings = (Users.DBSettings)WaterMetersDBSettings.Clone();
|
||||
result.UsersDBSettings = (Users.DBSettings)ProceduresDBSettings.Clone();
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
public override string ToString()
|
||||
{
|
||||
return string.Format("{0} config={1} results={2} users={3}",
|
||||
BenchName,
|
||||
ProceduresDBSettings.ConnectionString,
|
||||
WaterMetersDBSettings.ConnectionString,
|
||||
UsersDBSettings.ConnectionString);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,60 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2013-2016 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace Config.Entities
|
||||
{
|
||||
public class BenchPath : IHasItemNr, IHasValves
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
public virtual int ItemNr { get; set; }
|
||||
public virtual string Name { get; set; }
|
||||
public virtual float Qfrom { get; set; } /// Water flow in [m3/h]
|
||||
public virtual float Qto { get; set; } /// Water flow in [m3/h]
|
||||
public virtual string TempMtrUp { get; set; }
|
||||
public virtual string TempMtrDown { get; set; }
|
||||
public virtual string PressMtrUp { get; set; }
|
||||
public virtual string PressMtrDown { get; set; }
|
||||
public virtual string PressMtrDelta { get; set; }
|
||||
public virtual string StopBFValve { get; set; }
|
||||
|
||||
/// Valves
|
||||
public virtual string ValvesOpen { get; set; }
|
||||
public virtual string ValvesClose { get; set; }
|
||||
|
||||
/// ------------- Additional stuff not mapped into the database -------------
|
||||
|
||||
public BenchPath()
|
||||
{
|
||||
ValvesOpen = string.Empty;
|
||||
ValvesClose = string.Empty;
|
||||
}
|
||||
|
||||
public BenchPath(string name, int itemNr)
|
||||
: this()
|
||||
{
|
||||
Name = name;
|
||||
ItemNr = itemNr;
|
||||
}
|
||||
|
||||
public virtual BenchPath Clone(string name, int itemNr)
|
||||
{
|
||||
BenchPath result = new BenchPath(name, itemNr);
|
||||
|
||||
result.Qfrom = Qfrom;
|
||||
result.Qto = Qto;
|
||||
result.TempMtrUp = TempMtrUp;
|
||||
result.TempMtrDown = TempMtrDown;
|
||||
result.PressMtrUp = PressMtrUp;
|
||||
result.PressMtrDown = PressMtrDown;
|
||||
result.PressMtrDelta = PressMtrDelta;
|
||||
result.StopBFValve = StopBFValve;
|
||||
result.ValvesOpen = ValvesOpen;
|
||||
result.ValvesClose = ValvesClose;
|
||||
|
||||
return result;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,357 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2013-2017 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Reflection;
|
||||
|
||||
namespace Config.Entities
|
||||
{
|
||||
/// <summary>
|
||||
/// Helper class to assign descriptions to enum values
|
||||
/// </summary>
|
||||
public class Description : Attribute
|
||||
{
|
||||
public string Text;
|
||||
public Description(string t)
|
||||
{
|
||||
Text = t;
|
||||
}
|
||||
}
|
||||
|
||||
public static class GetDescription
|
||||
{
|
||||
/// Extension method for enum-s
|
||||
public static string ToDescription(this Enum en)
|
||||
{
|
||||
Type type = en.GetType();
|
||||
MemberInfo[] memInfo = type.GetMember(en.ToString());
|
||||
|
||||
if (memInfo != null && memInfo.Length > 0)
|
||||
{
|
||||
object[] attrs = memInfo[0].GetCustomAttributes(typeof(Description), false);
|
||||
if (attrs != null && attrs.Length > 0)
|
||||
return ((Description)attrs[0]).Text;
|
||||
}
|
||||
|
||||
return en.ToString(); /// Return ToString() value in case there is no description
|
||||
}
|
||||
}
|
||||
|
||||
public enum ProcedureState
|
||||
{
|
||||
Active,
|
||||
History,
|
||||
Template,
|
||||
Count,
|
||||
}
|
||||
|
||||
/// <summary> Kind of meters for the procedure / test </summary>
|
||||
public enum MetersKind
|
||||
{
|
||||
Single,
|
||||
Combined,
|
||||
HeatMeter,
|
||||
}
|
||||
|
||||
public enum CompoundMeterId : byte
|
||||
{
|
||||
Single,
|
||||
CompoundMain,
|
||||
CompoundAux,
|
||||
Compound,
|
||||
HeatMeterVolume,
|
||||
HeatMeterEnergy,
|
||||
SingleOrCompound, /// Only used when querying results
|
||||
}
|
||||
|
||||
public enum Medium
|
||||
{
|
||||
[Description("")] NotSpecified,
|
||||
ColdWater,
|
||||
HotWater,
|
||||
Count
|
||||
}
|
||||
|
||||
public enum Mounting
|
||||
{
|
||||
#if LANG_DE
|
||||
[Description("")] NotSpecified,
|
||||
[Description("H")] H, /// horizontal
|
||||
[Description("V")] V, /// vertical
|
||||
[Description("STR")] S, /// standrohre
|
||||
[Description("F")] F, /// fall
|
||||
#else
|
||||
[Description("")] NotSpecified,
|
||||
[Description("H")] H, /// horizontal
|
||||
[Description("V")] V, /// vertical
|
||||
[Description("S")] S, /// steig
|
||||
[Description("F")] F, /// fall
|
||||
#endif
|
||||
Count
|
||||
}
|
||||
|
||||
public enum TemperatureClass
|
||||
{
|
||||
[Description("")] NotSpecified,
|
||||
[Description("T30")] T30,
|
||||
[Description("T50")] T50,
|
||||
[Description("T70")] T70,
|
||||
[Description("T90")] T90,
|
||||
[Description("T130")] T130,
|
||||
[Description("T180")] T180,
|
||||
[Description("T30/70")] T30_70,
|
||||
[Description("T30/90")] T30_90,
|
||||
[Description("T30/130")] T30_130,
|
||||
[Description("T30/180")] T30_180,
|
||||
[Description("30")] t30,
|
||||
[Description("50")] t50,
|
||||
[Description("70")] t70,
|
||||
[Description("90")] t90,
|
||||
[Description("130")] t130,
|
||||
[Description("180")] t180,
|
||||
Count
|
||||
}
|
||||
|
||||
public enum FlowProfileSensitivityClass
|
||||
{
|
||||
[Description("")] NotSpecified,
|
||||
[Description("U0")] U0, /// ?
|
||||
[Description("D0")] D0, /// ?
|
||||
Count
|
||||
}
|
||||
|
||||
public enum PressureLossClass
|
||||
{
|
||||
[Description("")] NotSpecified,
|
||||
[Description("dp63")] dp63, /// 0.063 MPa = 0.63 bar, TODO: Change to "Δp63"
|
||||
[Description("dp40")] dp40, /// 0.040 MPa = 0.40 bar
|
||||
[Description("dp25")] dp25, /// 0.025 MPa = 0.25 bar
|
||||
[Description("dp16")] dp16, /// 0.016 MPa = 0.16 bar
|
||||
[Description("dp10")] dp10, /// 0.010 MPa = 0.10 bar
|
||||
Count
|
||||
}
|
||||
|
||||
/// <summary> Maximum Admissible Pressure </summary>
|
||||
public enum MaxAdmissiblePressure
|
||||
{
|
||||
[Description("")] NotSpecified,
|
||||
[Description("MAP6")] MAP6,
|
||||
[Description("MAP10")] MAP10,
|
||||
[Description("MAP16")] MAP16,
|
||||
[Description("MAP25")] MAP25,
|
||||
[Description("MAP40")] MAP40,
|
||||
Count
|
||||
}
|
||||
|
||||
/// <summary> Transition step is finished when this condition is fulfilled </summary>
|
||||
public enum StepCondition
|
||||
{
|
||||
None,
|
||||
Scale1Empty,
|
||||
Scale2Empty,
|
||||
Scale3Empty,
|
||||
AllScalesEmpty,
|
||||
Count
|
||||
}
|
||||
|
||||
public enum Publish : sbyte
|
||||
{
|
||||
#if LANG_DE
|
||||
/// nemecky
|
||||
[Description("nie")] Never = 0,
|
||||
[Description("immer")] Always = 1,
|
||||
[Description("Bildschirm")] OnScreen = 2,
|
||||
[Description("intern")] Internal = 3,
|
||||
#elif LANG_CS
|
||||
/// cesky
|
||||
[Description("nikdy")] Never = 0,
|
||||
[Description("vždy")] Always = 1,
|
||||
[Description("na obrazovku")] OnScreen = 2,
|
||||
[Description("interně")] Internal = 3,
|
||||
#elif LANG_SK
|
||||
/// slovensky
|
||||
[Description("nikdy")] Never = 0,
|
||||
[Description("vždy")] Always = 1,
|
||||
[Description("na obrazovku")] OnScreen = 2,
|
||||
[Description("interne")] Internal = 3,
|
||||
#elif LANG_PL
|
||||
/// polsky
|
||||
[Description("nigdy")] Never = 0,
|
||||
[Description("zawsze")] Always = 1,
|
||||
[Description("na ekranie")] OnScreen = 2,
|
||||
[Description("wewnętrznie")] Internal = 3,
|
||||
#else
|
||||
[Description("Never")] Never = 0,
|
||||
[Description("Always")] Always = 1,
|
||||
[Description("On screen")] OnScreen = 2,
|
||||
[Description("Internal")] Internal = 3,
|
||||
#endif
|
||||
Count
|
||||
}
|
||||
|
||||
public enum MassMethod : byte
|
||||
{
|
||||
#if LANG_DE
|
||||
/// nemecky
|
||||
[Description("Waage")] Scale,
|
||||
[Description("Spanne")] Spread,
|
||||
[Description("Standardabw.")] StdDev,
|
||||
#elif LANG_CS
|
||||
/// cesky
|
||||
[Description("váhou")] Scale,
|
||||
[Description("max.rozdíl")] Spread,
|
||||
[Description("std.dev.")] StdDev,
|
||||
#else
|
||||
[Description("Scale")] Scale,
|
||||
[Description("Spread")] Spread,
|
||||
[Description("Std.dev.")] StdDev,
|
||||
#endif
|
||||
Count
|
||||
}
|
||||
|
||||
public enum TestRedType
|
||||
{
|
||||
Fix,
|
||||
/// etc.
|
||||
Count,
|
||||
}
|
||||
|
||||
public enum FQC1
|
||||
{
|
||||
FQC1,
|
||||
FQP1,
|
||||
Count,
|
||||
}
|
||||
|
||||
public enum Progress
|
||||
{
|
||||
JustStarted,
|
||||
TransitionBefore,
|
||||
SwitchingFlowDetection,
|
||||
FlowSetting,
|
||||
Test,
|
||||
TransitionAfter,
|
||||
Completed,
|
||||
Count,
|
||||
}
|
||||
|
||||
public enum Device
|
||||
{
|
||||
Screen,
|
||||
Printer,
|
||||
Disk,
|
||||
}
|
||||
|
||||
public enum PageOrientation
|
||||
{
|
||||
Portrait,
|
||||
Landscape,
|
||||
Count,
|
||||
}
|
||||
|
||||
public enum ItemCategory
|
||||
{
|
||||
#if LANG_DE
|
||||
[Description("Allgemein")] Other,
|
||||
[Description("Prüfstanddaten")] BenchData,
|
||||
[Description("Prüfstandergebnisse")] BenchResult,
|
||||
[Description("Prüfpunktdaten")] TestData,
|
||||
[Description("Prüfpunktergebnisse")] TestResult,
|
||||
[Description("Wasserzelledaten")] MeterData,
|
||||
[Description("Wasserzelleergebnisse")] MeterResult,
|
||||
#else
|
||||
[Description("Other")] Other,
|
||||
[Description("Bench data")] BenchData,
|
||||
[Description("Bench result")] BenchResult,
|
||||
[Description("Test data")] TestData,
|
||||
[Description("Test result")] TestResult,
|
||||
[Description("Meter data")] MeterData,
|
||||
[Description("Meter result")] MeterResult,
|
||||
#endif
|
||||
Count,
|
||||
}
|
||||
|
||||
/// <summary> Possible modes of operation of components and devices. </summary>
|
||||
public enum DebugMode
|
||||
{
|
||||
#if LANG_DE
|
||||
[Description("Erkennen-aus")] DetectedOff = -2,
|
||||
[Description("Erkennen-ein")] DetectedOn = -1,
|
||||
[Description("Normal")] Normal = 0, /// Normal operation
|
||||
[Description("Auto-erkennen")] AutoDetect, /// The component (device) will be auto-detected
|
||||
[Description("Fehler")] FailureDuringOperation, /// Failure during operation -> disabled
|
||||
[Description("Aus")] Off, /// The component is off
|
||||
[Description("Aufzeichnen")] Record,
|
||||
[Description("Reply")] Reply,
|
||||
[Description("Simuliert")] Simulate, /// Test bench simulation, this mode does not require any hardware
|
||||
[Description("Geerbt")] Inherit,
|
||||
#else
|
||||
[Description("Detected off")] DetectedOff = -2,
|
||||
[Description("Detected on")] DetectedOn = -1,
|
||||
[Description("Normal")] Normal = 0, /// Normal operation
|
||||
[Description("Auto detect")] AutoDetect, /// The component (device) will be auto-detected
|
||||
[Description("Run-time error")] FailureDuringOperation, /// Failure during operation -> disabled
|
||||
[Description("Off")] Off, /// The component is off
|
||||
[Description("Record")] Record,
|
||||
[Description("Reply")] Reply,
|
||||
[Description("Simulate")] Simulate, /// Test bench simulation, this mode does not require any hardware
|
||||
[Description("Inherit")] Inherit,
|
||||
#endif
|
||||
Count,
|
||||
}
|
||||
|
||||
public enum LogLevel
|
||||
{
|
||||
#if LANG_DE
|
||||
[Description("Aus")] Off,
|
||||
[Description("Schwerwiegend")] Fatal,
|
||||
[Description("Fehler")] Error,
|
||||
[Description("Warnung")] Warn,
|
||||
[Description("Info")] Info,
|
||||
[Description("Debug")] Debug,
|
||||
[Description("Alles")] All,
|
||||
#else
|
||||
[Description("Off")] Off,
|
||||
[Description("Fatal")] Fatal,
|
||||
[Description("Error")] Error,
|
||||
[Description("Warn")] Warn,
|
||||
[Description("Info")] Info,
|
||||
[Description("Debug")] Debug,
|
||||
[Description("All")] All,
|
||||
#endif
|
||||
Count,
|
||||
}
|
||||
|
||||
|
||||
/// <summary> Arrangement of tests </summary>
|
||||
public enum TestsArrangement
|
||||
{
|
||||
Rows,
|
||||
Columns,
|
||||
}
|
||||
|
||||
/// <summary> Arrangement of meters </summary>
|
||||
public enum MetersArrangement
|
||||
{
|
||||
Vertically,
|
||||
Horizontally,
|
||||
}
|
||||
|
||||
public enum Alignment
|
||||
{
|
||||
#if LANG_DE
|
||||
[Description("links")] Left,
|
||||
[Description("zentriert")] Center,
|
||||
[Description("rechts")] Right,
|
||||
[Description("angepasst")] Justified,
|
||||
#else
|
||||
[Description("Left")] Left,
|
||||
[Description("Center")] Center,
|
||||
[Description("Right")] Right,
|
||||
[Description("Justified")] Justified,
|
||||
#endif
|
||||
Count
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,64 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2016 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
|
||||
namespace Config.Entities
|
||||
{
|
||||
public class HeatMetersPath : IHasItemNr
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
public virtual int ItemNr { get; set; }
|
||||
public virtual string Name { get; set; }
|
||||
|
||||
public virtual float TempWarmFrom { get; set; } /// Warm temperature range from [°C]
|
||||
public virtual float TempWarmTo { get; set; } /// Warm temperature range to [°C]
|
||||
public virtual float TempColdFrom { get; set; } /// Cold temperature range from [°C]
|
||||
public virtual float TempColdTo { get; set; } /// Cold temperature renge to [°C]
|
||||
|
||||
public virtual string TMeterRefWarm1 { get; set; }
|
||||
public virtual string TMeterRefWarm2 { get; set; }
|
||||
public virtual string TMeterRefCold1 { get; set; }
|
||||
public virtual string TMeterRefCold2 { get; set; }
|
||||
|
||||
public virtual string TMeterWorkWarm1 { get; set; }
|
||||
public virtual string TMeterWorkWarm2 { get; set; }
|
||||
public virtual string TMeterWorkCold1 { get; set; }
|
||||
public virtual string TMeterWorkCold2 { get; set; }
|
||||
|
||||
/// ------------- Additional stuff not mapped into the database -------------
|
||||
|
||||
public HeatMetersPath()
|
||||
{
|
||||
}
|
||||
|
||||
public HeatMetersPath(string name, int itemNr)
|
||||
: this()
|
||||
{
|
||||
Name = name;
|
||||
ItemNr = itemNr;
|
||||
}
|
||||
|
||||
public virtual HeatMetersPath Clone(string name, int itemNr)
|
||||
{
|
||||
HeatMetersPath result = new HeatMetersPath(name, itemNr);
|
||||
|
||||
result.TempWarmFrom = TempWarmFrom;
|
||||
result.TempWarmTo = TempWarmTo;
|
||||
result.TempColdFrom = TempColdFrom;
|
||||
result.TempColdTo = TempColdTo;
|
||||
|
||||
result.TMeterRefWarm1 = TMeterRefWarm1;
|
||||
result.TMeterRefWarm2 = TMeterRefWarm2;
|
||||
result.TMeterRefCold1 = TMeterRefCold1;
|
||||
result.TMeterRefCold2 = TMeterRefCold2;
|
||||
|
||||
result.TMeterWorkWarm1 = TMeterWorkWarm1;
|
||||
result.TMeterWorkWarm2 = TMeterWorkWarm2;
|
||||
result.TMeterWorkCold1 = TMeterWorkCold1;
|
||||
result.TMeterWorkCold2 = TMeterWorkCold2;
|
||||
|
||||
return result;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,151 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2013-2015 Sensus Metering Systems
|
||||
/// Author: Milan Hanajik
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace Config.Entities
|
||||
{
|
||||
/// <summary>
|
||||
/// Test, consisting of one or more repetitions of the test 'SingleTest'.
|
||||
/// </summary>
|
||||
public class Test : IHasItemNr
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
public virtual int ItemNr { get; set; }
|
||||
public virtual string Name { get; set; }
|
||||
public virtual int Part { get; set; } /// Part=0 ... test of all WM-s
|
||||
/// Part>0 ... part of a set of tests with the same Name: subset of WM-s is given by MetersPath
|
||||
public virtual sbyte Publish { get; set; } /// 0=no, 1=in all protocols, 2=on screen, 3=internal
|
||||
public virtual bool Evaluate { get; set; }
|
||||
public virtual float Qfrom { get; set; } /// Water flow low limit in [m3/h]
|
||||
public virtual float Qto { get; set; } /// Water flow high limit in [m3/h]
|
||||
public virtual float Volume { get; set; } /// Test volume (target) in [l]
|
||||
public virtual float TstTime { get; set; } /// Test time (estimate) in [s]
|
||||
public virtual string Method { get; set; }
|
||||
public virtual float ErrLimLo { get; set; } /// in [%] (usually < 0)
|
||||
public virtual float ErrLimHi { get; set; } /// in [%] (usually > 0)
|
||||
public virtual float Uncertainty { get; set; } /// int [%] makes error limits tighter: 0 <= Uncertainty <= abs(ErrLimXx)
|
||||
public virtual int Repeats { get; set; }
|
||||
public virtual bool Emptying { get; set; }
|
||||
public virtual bool Zeroing { get; set; }
|
||||
public virtual float PumpPower { get; set; } /// Power of the pump in [%] in the range 0 .. 100.0f, use values 0% and 100% for non-FM pumps
|
||||
public virtual int MassRepeats { get; set; } /// Number of mass. measurements at the beginning/end of test, 0 = default (=5)
|
||||
public virtual float MassSpread { get; set; } /// Max spread of mass. measurements at the beginning/end of test, 0 = default
|
||||
public virtual MassMethod MassMethod { get; set; } /// method of mass. measurement at the beginning/end of test: false=slow (precise), true=using immediate mass measurement and evaluation
|
||||
public virtual int TimeBeforeFlow { get; set; } /// Delay time before the start of flow control in [s]
|
||||
public virtual int TimeFlow2Mass { get; set; } /// Delay time from the flow stable to the 1st mass measurement in [s]
|
||||
public virtual int TimePump2StartV { get; set; } /// Delay time from the start of the pump to opening the start valve in [s]
|
||||
public virtual int TimeStop2Mass { get; set; } /// Delay time from the test end (diverted) to the 2nd mass measuremen in [s]
|
||||
public virtual double TolerRed { get; set; } /// = Filter
|
||||
public virtual TestRedType RedType { get; set; }
|
||||
public virtual string FeedingPath { get; set; }
|
||||
public virtual string BenchPath { get; set; }
|
||||
public virtual string OutputPath { get; set; }
|
||||
public virtual string MetersPath { get; set; }
|
||||
#if HEAT_METERS
|
||||
public virtual string HeatMetersPath { get; set; }
|
||||
#endif
|
||||
public virtual string RelTransBefore { get; set; }
|
||||
public virtual string RelTransBetween { get; set; }
|
||||
public virtual string RelTransAfter { get; set; }
|
||||
public virtual string TransitionAfter { get; set; }
|
||||
|
||||
public virtual IList<ComponentTest> MoreParams { get; set; }
|
||||
|
||||
public virtual Procedure Procedure { get; set; }
|
||||
|
||||
/// ------------- Additional stuff not mapped into the database -------------
|
||||
|
||||
public Test()
|
||||
{
|
||||
MoreParams = new List<ComponentTest>();
|
||||
|
||||
///
|
||||
/// Default values
|
||||
///
|
||||
Publish = (sbyte)Config.Entities.Publish.Always;
|
||||
Evaluate = true;
|
||||
Repeats = 1;
|
||||
Emptying = false;
|
||||
Zeroing = false;
|
||||
ErrLimLo = -2.0f; /// [%] lower error limit
|
||||
ErrLimHi = 2.0f; /// [%] upper error limit
|
||||
Uncertainty = 0;
|
||||
PumpPower = 60.0f; /// [%]
|
||||
MassRepeats = 0; /// default
|
||||
MassSpread = 0; /// default
|
||||
MassMethod = MassMethod.Scale; /// default
|
||||
TimeBeforeFlow = 10; /// [s] time before the start of flow control in [s]
|
||||
TimeFlow2Mass = 5; /// [s] time from the flow stable to the 1st mass measurement in [s]
|
||||
TimePump2StartV = 1; /// [s] time from the 1st mass measurement to the test start in [s]
|
||||
TimeStop2Mass = 5; /// [s] between the test end and the final mass measurement
|
||||
TolerRed = 0; /// = Filter parameter
|
||||
RelTransBefore = string.Empty;
|
||||
RelTransBetween = string.Empty;
|
||||
RelTransAfter = string.Empty;
|
||||
TransitionAfter = string.Empty;
|
||||
}
|
||||
|
||||
public Test(string name, int itemNr, Procedure procedure)
|
||||
: this()
|
||||
{
|
||||
Name = name;
|
||||
ItemNr = itemNr;
|
||||
Procedure = procedure;
|
||||
}
|
||||
|
||||
// Makes a new copy of this object (not just a reference)
|
||||
public virtual Test Clone()
|
||||
{
|
||||
Test result = new Test(Name, ItemNr, Procedure);
|
||||
|
||||
result.Part = Part;
|
||||
result.Publish = Publish;
|
||||
result.Evaluate = Evaluate;
|
||||
result.Qfrom = Qfrom;
|
||||
result.Qto = Qto;
|
||||
result.Volume = Volume;
|
||||
result.TstTime = TstTime;
|
||||
result.Repeats = Repeats;
|
||||
result.Emptying = Emptying;
|
||||
result.Zeroing = Zeroing;
|
||||
result.PumpPower = PumpPower;
|
||||
result.MassRepeats = MassRepeats;
|
||||
result.MassSpread = MassSpread;
|
||||
result.MassMethod = MassMethod;
|
||||
result.TimeBeforeFlow = TimeBeforeFlow;
|
||||
result.TimeFlow2Mass = TimeFlow2Mass;
|
||||
result.TimePump2StartV = TimePump2StartV;
|
||||
result.TimeStop2Mass = TimeStop2Mass;
|
||||
result.Method = Method;
|
||||
result.ErrLimLo = ErrLimLo;
|
||||
result.ErrLimHi = ErrLimHi;
|
||||
result.Uncertainty = Uncertainty;
|
||||
result.TolerRed = TolerRed;
|
||||
result.RedType = RedType;
|
||||
result.FeedingPath = FeedingPath;
|
||||
result.BenchPath = BenchPath;
|
||||
result.OutputPath = OutputPath;
|
||||
result.MetersPath = MetersPath;
|
||||
#if HEAT_METERS
|
||||
result.HeatMetersPath = HeatMetersPath;
|
||||
#endif
|
||||
result.RelTransBefore = RelTransBefore;
|
||||
result.RelTransBetween = RelTransBetween;
|
||||
result.RelTransAfter = RelTransAfter;
|
||||
result.TransitionAfter = TransitionAfter;
|
||||
foreach (var prms in MoreParams) { result.MoreParams.Add(prms.Clone()); }
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
public override string ToString()
|
||||
{
|
||||
string partStr = (Part > 0) ? string.Format(", part {0}", Part) : string.Empty;
|
||||
|
||||
return string.Format("{0}(P.{1},{2}){3}", Name, ((Publish)Publish).ToString(), Evaluate ? "E" : "-", partStr);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,176 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2013-2015 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace Config.Entities
|
||||
{
|
||||
public class TestResult
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
public virtual string Name { get; set; }
|
||||
public virtual int BatchNr { get; set; }
|
||||
public virtual string PurchaseOrder { get; set; }
|
||||
public virtual MetersKind MetersKind { get; set; }
|
||||
public virtual IList<MeterTestResult> Meters { get; set; }
|
||||
public virtual IList<MeterTestResult> CombinedMeters { get; set; }
|
||||
|
||||
/// Value copied from the procedure (Entities.Procedure)
|
||||
public virtual string ProcedureName { get; set; }
|
||||
public virtual string ProtocolTitle { get; set; }
|
||||
|
||||
/// Values copied from the test (Entities.Test)
|
||||
public virtual int TestId { get; set; } /// Test entity ID to distinguish between tests with the same name
|
||||
public virtual string TestName { get; set; }
|
||||
public virtual int Part { get; set; }
|
||||
public virtual bool DoNotEvaluate { get; set; } /// Not mapped to the database
|
||||
public virtual bool DoNotPublish { get; set; } /// Not mapped to the database
|
||||
public virtual float Qfrom { get; set; } /// [m3/h] Water flow low limit
|
||||
public virtual float Qto { get; set; } /// [m3/h] Water flow high limit
|
||||
public virtual float Volume { get; set; } /// [l] Target test volume
|
||||
public virtual float TstTime { get; set; } /// [s] Test time estimate
|
||||
public virtual int Repeats { get; set; }
|
||||
public virtual bool Emptying { get; set; }
|
||||
public virtual bool Zeroing { get; set; }
|
||||
public virtual float PumpPower { get; set; } /// Power of the pump in [%] in the range 0 .. 100.0f, use values 0% and 100% for non-FM pumps
|
||||
public virtual int Time2MassMsrmt { get; set; }
|
||||
public virtual string Method { get; set; }
|
||||
public virtual float ErrLimLo { get; set; } /// [%] Lower error limit (usually < 0)
|
||||
public virtual float ErrLimHi { get; set; } /// [%] Upper error limit (usually > 0)
|
||||
public virtual float Uncertainty { get; set; } /// [%] Makes error limits tighter: 0 <= Uncertainty <= abs(ErrLimXx)
|
||||
|
||||
/// To be replaced by the virtual bench component parameters
|
||||
public virtual string FeedingPath { get; set; }
|
||||
public virtual string BenchPath { get; set; }
|
||||
public virtual string OutputPath { get; set; }
|
||||
public virtual string MetersPath { get; set; }
|
||||
|
||||
/// Results
|
||||
public virtual DateTime TimeStart { get; set; } /// Date and time of the test start
|
||||
public virtual DateTime TimeEnd { get; set; } /// Date and time of the test end
|
||||
public virtual int RepetitionNr { get; set; } /// Repetition number from the set of repeated tests (1...)
|
||||
public virtual float AmbientTempAve { get; set; } /// [deg.C] Average ambient air temperature
|
||||
public virtual float AmbientPressAve { get; set; } /// Average ambient air pressure
|
||||
public virtual float AmbientHumiAve { get; set; } /// [%] Average ambient air relative humidity
|
||||
public virtual float PressInAvrg { get; set; } /// [Bar] Input water pressure (average)
|
||||
public virtual float PressInStart { get; set; } /// [Bar]
|
||||
public virtual float PressInEnd { get; set; } /// [Bar]
|
||||
public virtual float PressOutAvrg { get; set; } /// [Bar]
|
||||
public virtual float PressOutStart { get; set; } /// [Bar]
|
||||
public virtual float PressOutEnd { get; set; } /// [Bar]
|
||||
public virtual float TempInAvrg { get; set; } /// [deg.C]
|
||||
public virtual float TempInStart { get; set; } /// [deg.C]
|
||||
public virtual float TempInEnd { get; set; } /// [deg.C]
|
||||
public virtual float TempOutAvrg { get; set; } /// [deg.C]
|
||||
public virtual float TempOutStart { get; set; } /// [deg.C]
|
||||
public virtual float TempOutEnd { get; set; } /// [deg.C]
|
||||
public virtual float TempDivAvrg { get; set; } /// [deg.C]
|
||||
public virtual float TempDivStart { get; set; } /// [deg.C]
|
||||
public virtual float TempDivEnd { get; set; } /// [deg.C]
|
||||
public virtual float MassStartRaw { get; set; } /// [kg]
|
||||
public virtual float MassStart { get; set; } /// [kg]
|
||||
public virtual float MassEndRaw { get; set; } /// [kg]
|
||||
public virtual float MassEnd { get; set; } /// [kg]
|
||||
public virtual float MassDiff { get; set; } /// [kg]
|
||||
public virtual float DensityIn { get; set; } /// [kg/m3]
|
||||
public virtual float DensityOut { get; set; } /// [kg/m3]
|
||||
public virtual float DensityDiv { get; set; } /// [kg/m3]
|
||||
public virtual float Buoyancy { get; set; } ///TODO -> map
|
||||
public virtual float FlowMass { get; set; } /// [kg/h] calculated from conventional true value
|
||||
public virtual float FlowVolume { get; set; } /// [l/h] calculated from conventional true value
|
||||
public virtual float VolumeCTV { get; set; } /// [l] Volume conventional true value
|
||||
public virtual float VolumeMaster { get; set; } /// [l] Volume from the master flow meter
|
||||
public virtual float Time { get; set; } /// [s] Measurement time in seconds
|
||||
public virtual float ErrorMaster { get; set; } /// [%]
|
||||
public virtual float PulsesMaster { get; set; }
|
||||
public virtual float ConstMaster { get; set; } /// [pls/l] Pulses per liter master flow meter
|
||||
public virtual float QRise { get; set; } /// Detected Q_rise of a composed meter
|
||||
public virtual float QFall { get; set; } /// Detected Q_fall of a composed meter
|
||||
public virtual float TimeDivStart0 { get; set; }
|
||||
public virtual float TimeDivStart1 { get; set; }
|
||||
public virtual float TimeDivStart2 { get; set; }
|
||||
public virtual float TimeDivStart3 { get; set; }
|
||||
public virtual float TimeDivStart4 { get; set; }
|
||||
public virtual float TimeDivStart5 { get; set; }
|
||||
public virtual float TimeDivEnd0 { get; set; }
|
||||
public virtual float TimeDivEnd1 { get; set; }
|
||||
public virtual float TimeDivEnd2 { get; set; }
|
||||
public virtual float TimeDivEnd3 { get; set; }
|
||||
public virtual float TimeDivEnd4 { get; set; }
|
||||
public virtual float TimeDivEnd5 { get; set; }
|
||||
|
||||
public TestResult()
|
||||
{
|
||||
Meters = new List<MeterTestResult>();
|
||||
CombinedMeters = new List<MeterTestResult>();
|
||||
}
|
||||
|
||||
public TestResult(MetersKind kind)
|
||||
: this()
|
||||
{
|
||||
MetersKind = kind;
|
||||
|
||||
if (kind == MetersKind.Single)
|
||||
{
|
||||
for (int i = 0; i < Config.Data.WMsCount; i++) Meters.Add(new MeterTestResult(this));
|
||||
}
|
||||
else if (kind == MetersKind.Combined)
|
||||
{
|
||||
for (int i = 0; i < 2 * Config.Data.CompoundWMsCount; i++) Meters.Add(new MeterTestResult(this));
|
||||
for (int i = 0; i < Config.Data.CompoundWMsCount; i++) CombinedMeters.Add(new MeterTestResult(this));
|
||||
}
|
||||
else if (kind == MetersKind.HeatMeter)
|
||||
{
|
||||
/// TODO: Verify if this is OK
|
||||
for (int i = 0; i < Config.Data.WMsCount; i++) Meters.Add(new MeterTestResult(this));
|
||||
}
|
||||
}
|
||||
|
||||
public TestResult(Test test, int repetitionNr, MetersKind kind)
|
||||
: this(kind)
|
||||
{
|
||||
if (test.Repeats == 1)
|
||||
{
|
||||
Name = test.Name;
|
||||
}
|
||||
else
|
||||
{
|
||||
Name = string.Format("{0} ({1}/{2})", test.Name, repetitionNr, test.Repeats);
|
||||
}
|
||||
RepetitionNr = repetitionNr;
|
||||
|
||||
/// Copy test parameters from Entities.Procedure object
|
||||
ProcedureName = test.Procedure.Name;
|
||||
ProtocolTitle = test.Procedure.ProtocolTitle;
|
||||
|
||||
/// Copy test parameters from Entities.Test object
|
||||
TestId = test.Id;
|
||||
TestName = test.Name;
|
||||
Part = test.Part;
|
||||
Qfrom = test.Qfrom;
|
||||
Qto = test.Qto;
|
||||
Volume = test.Volume;
|
||||
TstTime = test.TstTime;
|
||||
Repeats = test.Repeats;
|
||||
Emptying = test.Emptying;
|
||||
Zeroing = test.Zeroing;
|
||||
PumpPower = PumpPower;
|
||||
Time2MassMsrmt = test.TimeStop2Mass;
|
||||
Method = test.Method;
|
||||
ErrLimLo = test.ErrLimLo;
|
||||
ErrLimHi = test.ErrLimHi;
|
||||
Uncertainty = test.Uncertainty;
|
||||
|
||||
FeedingPath = test.FeedingPath;
|
||||
BenchPath = test.BenchPath;
|
||||
OutputPath = test.OutputPath;
|
||||
MetersPath = test.MetersPath;
|
||||
}
|
||||
|
||||
public override string ToString()
|
||||
{
|
||||
return string.Format("batch={0}, procedure={1}, test={2}, {3} {4}", BatchNr, ProcedureName, TestName, TimeStart.ToShortDateString(), TimeStart.ToShortTimeString());
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,24 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2013-2017 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace Config.Entities
|
||||
{
|
||||
public class User //: Users.IUser
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
public virtual string UserName { get; set; } /// = name, alias, abbreviation
|
||||
public virtual string FullName { get; set; } /// = description
|
||||
public virtual int Number { get; set; }
|
||||
public virtual string Password { get; set; }
|
||||
public virtual DateTime LastPwChange { get; set; }
|
||||
public virtual IList<Group> Groups { get; set; } //User can be a member of a list of groups
|
||||
|
||||
public User()
|
||||
{
|
||||
Groups = new List<Group>();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,236 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2013-2015 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System.Windows.Forms;
|
||||
using FluentNHibernate.Cfg;
|
||||
using FluentNHibernate.Cfg.Db;
|
||||
using NHibernate;
|
||||
using NHibernate.Cfg;
|
||||
using NHibernate.Tool.hbm2ddl;
|
||||
using Config.Resources;
|
||||
|
||||
namespace Config
|
||||
{
|
||||
public static class FluentCommon
|
||||
{
|
||||
/// <summary>
|
||||
/// Session factories for regular sessions.
|
||||
/// </summary>
|
||||
public static ISessionFactory[] SessionFactories = new ISessionFactory[(int)Users.Entities.DBKind.Count];
|
||||
|
||||
/// <summary>
|
||||
/// NHibernate session factory (to create the database session 'SessionFactory')
|
||||
/// </summary>
|
||||
/// <returns>A database session</returns>
|
||||
static ISessionFactory CreateSessionFactory(Users.Entities.DBKind database)
|
||||
{
|
||||
Users.Entities.DBType dbType;
|
||||
string connectionString;
|
||||
|
||||
switch (database)
|
||||
{
|
||||
default:
|
||||
case Users.Entities.DBKind.Config:
|
||||
dbType = Data.CurrentBench.ProceduresDBSettings.DbType;
|
||||
connectionString = Data.CurrentBench.ProceduresDBSettings.ConnectionString;
|
||||
break;
|
||||
case Users.Entities.DBKind.Results:
|
||||
dbType = Data.CurrentBench.WaterMetersDBSettings.DbType;
|
||||
connectionString = Data.CurrentBench.WaterMetersDBSettings.ConnectionString;
|
||||
break;
|
||||
}
|
||||
|
||||
return CreateSessionFactory(database, dbType, connectionString, false);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// NHibernate session factory (to create the database session 'SessionFactory')
|
||||
/// </summary>
|
||||
/// <returns>A database session</returns>
|
||||
public static ISessionFactory CreateSessionFactory(Users.Entities.DBKind database, Users.Entities.DBType dbType, string connectionString, bool createDB)
|
||||
{
|
||||
try
|
||||
{
|
||||
FluentConfiguration cfg = Fluently.Configure();
|
||||
|
||||
switch (dbType)
|
||||
{
|
||||
default:
|
||||
case Users.Entities.DBType.SQLite:
|
||||
cfg = cfg.Database(SQLiteConfiguration.Standard.UsingFile(connectionString));
|
||||
break;
|
||||
case Users.Entities.DBType.MySql:
|
||||
cfg = cfg.Database(MySQLConfiguration.Standard.ConnectionString(connectionString));
|
||||
break;
|
||||
}
|
||||
|
||||
switch (database)
|
||||
{
|
||||
default:
|
||||
case Users.Entities.DBKind.Config:
|
||||
cfg = cfg.Mappings(m => m.FluentMappings.AddFromAssemblyOf<Data>());
|
||||
break;
|
||||
case Users.Entities.DBKind.Results:
|
||||
cfg = cfg.Mappings(m => m.FluentMappings.AddFromAssemblyOf<Data>());
|
||||
break;
|
||||
}
|
||||
|
||||
if (createDB)
|
||||
{
|
||||
return cfg.ExposeConfiguration(BuildSchemaCreate).BuildSessionFactory();
|
||||
}
|
||||
else
|
||||
{
|
||||
return cfg.ExposeConfiguration(BuildSchema).BuildSessionFactory();
|
||||
}
|
||||
}
|
||||
catch (Exception exc)
|
||||
{
|
||||
MessageBox.Show(string.Format(Strings.Cannot_open_DB_Cause_0, exc.Message),
|
||||
Strings.Error,
|
||||
MessageBoxButtons.OK,
|
||||
MessageBoxIcon.Error);
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
public delegate void BuildSchemaDlgt(Configuration config);
|
||||
|
||||
static void BuildSchema(Configuration config)
|
||||
{
|
||||
/// This NHibernate tool takes a configuration (with mapping info in)
|
||||
/// and exports a database schema from it
|
||||
new SchemaExport(config).SetOutputFile("db_schema");
|
||||
}
|
||||
|
||||
static void BuildSchemaCreate(Configuration config)
|
||||
{
|
||||
/// This NHibernate tool takes a configuration (with mapping info in)
|
||||
/// and exports a database schema from it
|
||||
new SchemaExport(config).Create(true, true);
|
||||
}
|
||||
|
||||
/// Create a NHibernate session for the given database
|
||||
public static ISession CreateSession(Users.Entities.DBKind database)
|
||||
{
|
||||
int ix = (int)database;
|
||||
if (ix < 0 || ix >= (int)Users.Entities.DBKind.Count) return null;
|
||||
|
||||
if (SessionFactories[ix] == null) SessionFactories[ix] = CreateSessionFactory(database);
|
||||
|
||||
return SessionFactories[ix].OpenSession();
|
||||
}
|
||||
|
||||
public static void SaveToDb(Users.Entities.DBKind database, object obj)
|
||||
{
|
||||
SaveToDb(CreateSession(database), obj);
|
||||
}
|
||||
|
||||
public static void SaveToDb(ISession session, object obj)
|
||||
{
|
||||
using (var transaction = session.BeginTransaction())
|
||||
{
|
||||
session.SaveOrUpdate(obj);
|
||||
try { transaction.Commit(); }
|
||||
catch { }
|
||||
}
|
||||
}
|
||||
|
||||
public static void DeleteFromDb(Users.Entities.DBKind database, object obj)
|
||||
{
|
||||
DeleteFromDb(CreateSession(database), obj);
|
||||
}
|
||||
|
||||
public static void DeleteFromDb(ISession session, object obj)
|
||||
{
|
||||
using (var transaction = session.BeginTransaction())
|
||||
{
|
||||
session.Delete(obj);
|
||||
transaction.Commit();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Create an empty users database.
|
||||
/// Database contains only the user 'admin' and the control board component 'CB'.
|
||||
/// </summary>
|
||||
/// <param name="dbType">DBType.SQLite or DBType.MySql</param>
|
||||
/// <param name="connectionString">Connection string</param>
|
||||
/// <returns>true=success, false=error</returns>
|
||||
public static bool CreateEmptyConfigDB(Users.Entities.DBType dbType, string connectionString)
|
||||
{
|
||||
ISessionFactory sessionFactory = CreateSessionFactory(Users.Entities.DBKind.Config, dbType, connectionString, true);
|
||||
if (sessionFactory == null) return false;
|
||||
|
||||
/// Populate the database
|
||||
using (var session = sessionFactory.OpenSession())
|
||||
{
|
||||
using (var transaction = session.BeginTransaction())
|
||||
{
|
||||
///
|
||||
/// Prepare all groups
|
||||
///
|
||||
var testers = new Users.Entities.Group((int)Users.Grp.GID.Testers, Strings.Tester);
|
||||
var testingSpecialists = new Users.Entities.Group((int)Users.Grp.GID.TestingSpecialists, Strings.Testing_Specialist);
|
||||
var headOfLab = new Users.Entities.Group((int)Users.Grp.GID.HeadOfLab, Strings.Head_of_Lab);
|
||||
var maintenanceSpecialists = new Users.Entities.Group((int)Users.Grp.GID.MaintenanceSpecialists, Strings.Maintenance_Specialist);
|
||||
var metrologists = new Users.Entities.Group((int)Users.Grp.GID.Metrologists, Strings.Metrologist);
|
||||
var calibrationSpecialists = new Users.Entities.Group((int)Users.Grp.GID.CalibrationSpecialists, Strings.Calibration_Specialist);
|
||||
var administrators = new Users.Entities.Group((int)Users.Grp.GID.Administrators, Strings.Administrator);
|
||||
|
||||
/// Create the user 'admin' add his groups
|
||||
var admin = new Users.Entities.User
|
||||
{
|
||||
UserName = Data.AdminUsername,
|
||||
FullName = Strings.Administrator,
|
||||
LastPwChange = DateTime.Now
|
||||
};
|
||||
admin.SetPassword(Data.AdminPassword);
|
||||
admin.AddGroup(testers);
|
||||
admin.AddGroup(testingSpecialists);
|
||||
admin.AddGroup(headOfLab);
|
||||
admin.AddGroup(maintenanceSpecialists);
|
||||
admin.AddGroup(metrologists);
|
||||
admin.AddGroup(calibrationSpecialists);
|
||||
admin.AddGroup(administrators);
|
||||
|
||||
session.SaveOrUpdate(admin);
|
||||
|
||||
///// Create the control board component
|
||||
//var cmpnt = (new BenchControl.Elde.ControlBoardCfg(new BenchControl.Elde.ControlBoardFactory())).CreateDbEntity();
|
||||
//session.SaveOrUpdate(cmpnt);
|
||||
|
||||
transaction.Commit();
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Create an empty water meters database
|
||||
/// </summary>
|
||||
/// <param name="dbType">DBType.SQLite or DBType.MySql</param>
|
||||
/// <param name="connectionString">Connection string</param>
|
||||
/// <returns>true=success, false=error</returns>
|
||||
public static bool CreateEmptyResultsDB(Users.Entities.DBType dbType, string connectionString)
|
||||
{
|
||||
ISessionFactory sessionFactory = CreateSessionFactory(Users.Entities.DBKind.Results, dbType, connectionString, true);
|
||||
if (sessionFactory == null) return false;
|
||||
|
||||
/// Populate the database
|
||||
//using (var session = sessionFactory.OpenSession())
|
||||
//{
|
||||
// using (var transaction = session.BeginTransaction())
|
||||
// {
|
||||
// /// Create one component
|
||||
// var cmpnt = (new BenchControl.Elde.ControlBoardCfg("CB", 1)).CreateDbEntity();
|
||||
// session.SaveOrUpdate(cmpnt);
|
||||
// transaction.Commit();
|
||||
// }
|
||||
//}
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,35 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2016 Sensus Metering Systems
|
||||
///
|
||||
using FluentNHibernate.Mapping;
|
||||
using Config.Entities;
|
||||
|
||||
namespace Config.Mappings
|
||||
{
|
||||
#if HEAT_METERS
|
||||
class HeatMetersPathMap : ClassMap<HeatMetersPath>
|
||||
{
|
||||
public HeatMetersPathMap()
|
||||
{
|
||||
Id(x => x.Id);
|
||||
Map(x => x.ItemNr);
|
||||
Map(x => x.Name);
|
||||
|
||||
Map(x => x.TempWarmFrom);
|
||||
Map(x => x.TempWarmTo);
|
||||
Map(x => x.TempColdFrom);
|
||||
Map(x => x.TempColdTo);
|
||||
|
||||
Map(x => x.TMeterRefWarm1);
|
||||
Map(x => x.TMeterRefWarm2);
|
||||
Map(x => x.TMeterRefCold1);
|
||||
Map(x => x.TMeterRefCold2);
|
||||
|
||||
Map(x => x.TMeterWorkWarm1);
|
||||
Map(x => x.TMeterWorkWarm2);
|
||||
Map(x => x.TMeterWorkCold1);
|
||||
Map(x => x.TMeterWorkCold2);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
}
|
||||
@@ -1,61 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2013-2015 Sensus Metering Systems
|
||||
///
|
||||
using FluentNHibernate.Mapping;
|
||||
using Config.Entities;
|
||||
|
||||
namespace Config.Mappings
|
||||
{
|
||||
class MetersPathMap : ClassMap<MetersPath>
|
||||
{
|
||||
public MetersPathMap()
|
||||
{
|
||||
Id(x => x.Id);
|
||||
Map(x => x.ItemNr);
|
||||
Map(x => x.Name);
|
||||
|
||||
#pragma warning disable
|
||||
if (Config.Data.WMsCount >= 1) Map(x => x.Sensor1);
|
||||
if (Config.Data.WMsCount >= 2) Map(x => x.Sensor2);
|
||||
if (Config.Data.WMsCount >= 3) Map(x => x.Sensor3);
|
||||
if (Config.Data.WMsCount >= 4) Map(x => x.Sensor4);
|
||||
if (Config.Data.WMsCount >= 5) Map(x => x.Sensor5);
|
||||
if (Config.Data.WMsCount >= 6) Map(x => x.Sensor6);
|
||||
if (Config.Data.WMsCount >= 7) Map(x => x.Sensor7);
|
||||
if (Config.Data.WMsCount >= 8) Map(x => x.Sensor8);
|
||||
if (Config.Data.WMsCount >= 9) Map(x => x.Sensor9);
|
||||
if (Config.Data.WMsCount >= 10) Map(x => x.Sensor10);
|
||||
if (Config.Data.WMsCount >= 11) Map(x => x.Sensor11);
|
||||
if (Config.Data.WMsCount >= 12) Map(x => x.Sensor12);
|
||||
if (Config.Data.WMsCount >= 13) Map(x => x.Sensor13);
|
||||
if (Config.Data.WMsCount >= 14) Map(x => x.Sensor14);
|
||||
if (Config.Data.WMsCount >= 15) Map(x => x.Sensor15);
|
||||
if (Config.Data.WMsCount >= 16) Map(x => x.Sensor16);
|
||||
if (Config.Data.WMsCount >= 17) Map(x => x.Sensor17);
|
||||
if (Config.Data.WMsCount >= 18) Map(x => x.Sensor18);
|
||||
if (Config.Data.WMsCount >= 19) Map(x => x.Sensor19);
|
||||
if (Config.Data.WMsCount >= 20) Map(x => x.Sensor20);
|
||||
if (Config.Data.WMsCount >= 21) Map(x => x.Sensor21);
|
||||
if (Config.Data.WMsCount >= 22) Map(x => x.Sensor22);
|
||||
if (Config.Data.WMsCount >= 23) Map(x => x.Sensor23);
|
||||
if (Config.Data.WMsCount >= 24) Map(x => x.Sensor24);
|
||||
if (Config.Data.WMsCount >= 25) Map(x => x.Sensor25);
|
||||
if (Config.Data.WMsCount >= 26) Map(x => x.Sensor26);
|
||||
if (Config.Data.WMsCount >= 27) Map(x => x.Sensor27);
|
||||
if (Config.Data.WMsCount >= 28) Map(x => x.Sensor28);
|
||||
if (Config.Data.WMsCount >= 29) Map(x => x.Sensor29);
|
||||
if (Config.Data.WMsCount >= 30) Map(x => x.Sensor30);
|
||||
if (Config.Data.WMsCount >= 31) Map(x => x.Sensor31);
|
||||
if (Config.Data.WMsCount >= 32) Map(x => x.Sensor32);
|
||||
if (Config.Data.WMsCount >= 33) Map(x => x.Sensor33);
|
||||
if (Config.Data.WMsCount >= 34) Map(x => x.Sensor34);
|
||||
if (Config.Data.WMsCount >= 35) Map(x => x.Sensor35);
|
||||
if (Config.Data.WMsCount >= 36) Map(x => x.Sensor36);
|
||||
if (Config.Data.WMsCount >= 37) Map(x => x.Sensor37);
|
||||
if (Config.Data.WMsCount >= 38) Map(x => x.Sensor38);
|
||||
if (Config.Data.WMsCount >= 39) Map(x => x.Sensor39);
|
||||
if (Config.Data.WMsCount >= 40) Map(x => x.Sensor40);
|
||||
#pragma warning restore
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,36 +0,0 @@
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
// General Information about an assembly is controlled through the following
|
||||
// set of attributes. Change these attribute values to modify the information
|
||||
// associated with an assembly.
|
||||
[assembly: AssemblyTitle("Config")]
|
||||
[assembly: AssemblyDescription("")]
|
||||
[assembly: AssemblyConfiguration("")]
|
||||
[assembly: AssemblyCompany("Sensus")]
|
||||
[assembly: AssemblyProduct("Config")]
|
||||
[assembly: AssemblyCopyright("Copyright © 2013 - 2016 Sensus Slovensko a.s.")]
|
||||
[assembly: AssemblyTrademark("")]
|
||||
[assembly: AssemblyCulture("")]
|
||||
|
||||
// Setting ComVisible to false makes the types in this assembly not visible
|
||||
// to COM components. If you need to access a type in this assembly from
|
||||
// COM, set the ComVisible attribute to true on that type.
|
||||
[assembly: ComVisible(false)]
|
||||
|
||||
// The following GUID is for the ID of the typelib if this project is exposed to COM
|
||||
[assembly: Guid("3fc3ff67-7386-4aff-9855-bef33d5fa0d3")]
|
||||
|
||||
// Version information for an assembly consists of the following four values:
|
||||
//
|
||||
// Major Version
|
||||
// Minor Version
|
||||
// Build Number
|
||||
// Revision
|
||||
//
|
||||
// You can specify all the values or you can default the Build and Revision Numbers
|
||||
// by using the '*' as shown below:
|
||||
// [assembly: AssemblyVersion("1.0.*")]
|
||||
[assembly: AssemblyVersion("2.12.499.0")]
|
||||
[assembly: AssemblyFileVersion("2.12.499.0")]
|
||||
Generated
-164
@@ -1,164 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
// Runtime Version:4.0.30319.42000
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Config.Resources {
|
||||
using System;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// A strongly-typed resource class, for looking up localized strings, etc.
|
||||
/// </summary>
|
||||
// This class was auto-generated by the StronglyTypedResourceBuilder
|
||||
// class via a tool like ResGen or Visual Studio.
|
||||
// To add or remove a member, edit your .ResX file then rerun ResGen
|
||||
// with the /str option, or rebuild your VS project.
|
||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
|
||||
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||
internal class Strings {
|
||||
|
||||
private static global::System.Resources.ResourceManager resourceMan;
|
||||
|
||||
private static global::System.Globalization.CultureInfo resourceCulture;
|
||||
|
||||
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
|
||||
internal Strings() {
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Returns the cached ResourceManager instance used by this class.
|
||||
/// </summary>
|
||||
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||
internal static global::System.Resources.ResourceManager ResourceManager {
|
||||
get {
|
||||
if (object.ReferenceEquals(resourceMan, null)) {
|
||||
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("Config.Resources.Strings", typeof(Strings).Assembly);
|
||||
resourceMan = temp;
|
||||
}
|
||||
return resourceMan;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Overrides the current thread's CurrentUICulture property for all
|
||||
/// resource lookups using this strongly typed resource class.
|
||||
/// </summary>
|
||||
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||
internal static global::System.Globalization.CultureInfo Culture {
|
||||
get {
|
||||
return resourceCulture;
|
||||
}
|
||||
set {
|
||||
resourceCulture = value;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Administrator.
|
||||
/// </summary>
|
||||
internal static string Administrator {
|
||||
get {
|
||||
return ResourceManager.GetString("Administrator", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Calibration Specialist.
|
||||
/// </summary>
|
||||
internal static string Calibration_Specialist {
|
||||
get {
|
||||
return ResourceManager.GetString("Calibration_Specialist", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Cannot open DB Cause 0.
|
||||
/// </summary>
|
||||
internal static string Cannot_open_DB_Cause_0 {
|
||||
get {
|
||||
return ResourceManager.GetString("Cannot_open_DB_Cause_0", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Error.
|
||||
/// </summary>
|
||||
internal static string Error
|
||||
{
|
||||
get
|
||||
{
|
||||
return ResourceManager.GetString("Error", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Failed.
|
||||
/// </summary>
|
||||
internal static string Failed {
|
||||
get {
|
||||
return ResourceManager.GetString("Failed", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Head of Lab.
|
||||
/// </summary>
|
||||
internal static string Head_of_Lab {
|
||||
get {
|
||||
return ResourceManager.GetString("Head_of_Lab", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Maintenance Specialist.
|
||||
/// </summary>
|
||||
internal static string Maintenance_Specialist {
|
||||
get {
|
||||
return ResourceManager.GetString("Maintenance_Specialist", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Metrologist.
|
||||
/// </summary>
|
||||
internal static string Metrologist {
|
||||
get {
|
||||
return ResourceManager.GetString("Metrologist", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Passed.
|
||||
/// </summary>
|
||||
internal static string Passed {
|
||||
get {
|
||||
return ResourceManager.GetString("Passed", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Tester.
|
||||
/// </summary>
|
||||
internal static string Tester {
|
||||
get {
|
||||
return ResourceManager.GetString("Tester", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Testing Specialist.
|
||||
/// </summary>
|
||||
internal static string Testing_Specialist {
|
||||
get {
|
||||
return ResourceManager.GetString("Testing_Specialist", resourceCulture);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,123 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<data name="Error" xml:space="preserve">
|
||||
<value>Chyba</value>
|
||||
</data>
|
||||
</root>
|
||||
@@ -1,153 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<data name="Administrator" xml:space="preserve">
|
||||
<value>Administrator</value>
|
||||
</data>
|
||||
<data name="Calibration_Specialist" xml:space="preserve">
|
||||
<value>Kalibriertechniker</value>
|
||||
</data>
|
||||
<data name="Head_of_Lab" xml:space="preserve">
|
||||
<value>Laborleiter</value>
|
||||
</data>
|
||||
<data name="Maintenance_Specialist" xml:space="preserve">
|
||||
<value>Wartungstechniker</value>
|
||||
</data>
|
||||
<data name="Metrologist" xml:space="preserve">
|
||||
<value>Messtechniker</value>
|
||||
</data>
|
||||
<data name="Tester" xml:space="preserve">
|
||||
<value>Prüfer</value>
|
||||
</data>
|
||||
<data name="Testing_Specialist" xml:space="preserve">
|
||||
<value>Prüftechniker</value>
|
||||
</data>
|
||||
<data name="Failed" xml:space="preserve">
|
||||
<value>NiO</value>
|
||||
</data>
|
||||
<data name="Passed" xml:space="preserve">
|
||||
<value>iO</value>
|
||||
</data>
|
||||
<data name="Error" xml:space="preserve">
|
||||
<value>Fehler</value>
|
||||
</data>
|
||||
<data name="Cannot_open_DB_Cause_0" xml:space="preserve">
|
||||
<value>Datenbank kann nicht geöffnet.\\r\\nUrsache:\\r\\n{0}</value>
|
||||
</data>
|
||||
</root>
|
||||
@@ -1,153 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<data name="Administrator" xml:space="preserve">
|
||||
<value>Administrator</value>
|
||||
</data>
|
||||
<data name="Calibration_Specialist" xml:space="preserve">
|
||||
<value>Specjalista ds. kalibracji</value>
|
||||
</data>
|
||||
<data name="Head_of_Lab" xml:space="preserve">
|
||||
<value>Kierownik Laboratorium</value>
|
||||
</data>
|
||||
<data name="Maintenance_Specialist" xml:space="preserve">
|
||||
<value>Konserwator</value>
|
||||
</data>
|
||||
<data name="Metrologist" xml:space="preserve">
|
||||
<value>Metrolog</value>
|
||||
</data>
|
||||
<data name="Tester" xml:space="preserve">
|
||||
<value>Pracownik przeprowadzający testy</value>
|
||||
</data>
|
||||
<data name="Testing_Specialist" xml:space="preserve">
|
||||
<value>Specjalista ds. testów</value>
|
||||
</data>
|
||||
<data name="Failed" xml:space="preserve">
|
||||
<value>Niepowodzenie</value>
|
||||
</data>
|
||||
<data name="Passed" xml:space="preserve">
|
||||
<value>OK</value>
|
||||
</data>
|
||||
<data name="Cannot_open_DB_Cause_0" xml:space="preserve">
|
||||
<value>Nie można otworzyć \\r\\nCause:\\r\\n{0}</value>
|
||||
</data>
|
||||
<data name="Error" xml:space="preserve">
|
||||
<value>Błąd</value>
|
||||
</data>
|
||||
</root>
|
||||
@@ -1,153 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<data name="Administrator" xml:space="preserve">
|
||||
<value>Administrator</value>
|
||||
</data>
|
||||
<data name="Calibration_Specialist" xml:space="preserve">
|
||||
<value>Calibration Specialist</value>
|
||||
</data>
|
||||
<data name="Head_of_Lab" xml:space="preserve">
|
||||
<value>Head of Lab</value>
|
||||
</data>
|
||||
<data name="Maintenance_Specialist" xml:space="preserve">
|
||||
<value>Maintenance Specialist</value>
|
||||
</data>
|
||||
<data name="Metrologist" xml:space="preserve">
|
||||
<value>Metrologist</value>
|
||||
</data>
|
||||
<data name="Tester" xml:space="preserve">
|
||||
<value>Tester</value>
|
||||
</data>
|
||||
<data name="Testing_Specialist" xml:space="preserve">
|
||||
<value>Testing Specialist</value>
|
||||
</data>
|
||||
<data name="Failed" xml:space="preserve">
|
||||
<value>NOK</value>
|
||||
</data>
|
||||
<data name="Passed" xml:space="preserve">
|
||||
<value>OK</value>
|
||||
</data>
|
||||
<data name="Cannot_open_DB_Cause_0" xml:space="preserve">
|
||||
<value>Cannot open database.\\r\\nCause:\\r\\n{0}</value>
|
||||
</data>
|
||||
<data name="Error" xml:space="preserve">
|
||||
<value>Error</value>
|
||||
</data>
|
||||
</root>
|
||||
@@ -1,153 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<data name="Administrator" xml:space="preserve">
|
||||
<value>Администратор</value>
|
||||
</data>
|
||||
<data name="Calibration_Specialist" xml:space="preserve">
|
||||
<value>Специалист по калибровке</value>
|
||||
</data>
|
||||
<data name="Head_of_Lab" xml:space="preserve">
|
||||
<value>Руководитель лаборатории</value>
|
||||
</data>
|
||||
<data name="Maintenance_Specialist" xml:space="preserve">
|
||||
<value>Специалист по техобслуживанию</value>
|
||||
</data>
|
||||
<data name="Metrologist" xml:space="preserve">
|
||||
<value>Метролог</value>
|
||||
</data>
|
||||
<data name="Tester" xml:space="preserve">
|
||||
<value>Контролер</value>
|
||||
</data>
|
||||
<data name="Testing_Specialist" xml:space="preserve">
|
||||
<value>Специалист по тестированию</value>
|
||||
</data>
|
||||
<data name="Failed" xml:space="preserve">
|
||||
<value>NOK</value>
|
||||
</data>
|
||||
<data name="Passed" xml:space="preserve">
|
||||
<value>OK</value>
|
||||
</data>
|
||||
<data name="Cannot_open_DB_Cause_0" xml:space="preserve">
|
||||
<value>Не удается открыть БД.\\r\\nCause:\\r\\n{0}</value>
|
||||
</data>
|
||||
<data name="Error" xml:space="preserve">
|
||||
<value>Ошибка</value>
|
||||
</data>
|
||||
</root>
|
||||
@@ -1,128 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 1.3
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">1.3</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1">this is my long string</data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
[base64 mime encoded serialized .NET Framework object]
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
[base64 mime encoded string representing a byte array form of the .NET Framework object]
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>1.3</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.3500.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.3500.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<data name="Administrator" xml:space="preserve">
|
||||
<value>管理员</value>
|
||||
</data>
|
||||
<data name="Calibration_Specialist" xml:space="preserve">
|
||||
<value>校准专员</value>
|
||||
</data>
|
||||
<data name="Failed" xml:space="preserve">
|
||||
<value>NOK</value>
|
||||
</data>
|
||||
<data name="Head_of_Lab" xml:space="preserve">
|
||||
<value>实验室负责人</value>
|
||||
</data>
|
||||
<data name="Maintenance_Specialist" xml:space="preserve">
|
||||
<value>维护专员</value>
|
||||
</data>
|
||||
<data name="Metrologist" xml:space="preserve">
|
||||
<value>计量者</value>
|
||||
</data>
|
||||
<data name="Passed" xml:space="preserve">
|
||||
<value>好</value>
|
||||
</data>
|
||||
<data name="Tester" xml:space="preserve">
|
||||
<value>测试仪</value>
|
||||
</data>
|
||||
<data name="Testing_Specialist" xml:space="preserve">
|
||||
<value>测试专员</value>
|
||||
</data>
|
||||
</root>
|
||||
-399
@@ -1,399 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2016 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System.Reflection;
|
||||
using Config.Entities;
|
||||
|
||||
namespace Config
|
||||
{
|
||||
public enum Unit
|
||||
{
|
||||
[Description("---")] None,
|
||||
|
||||
[Description("l")] l, /// * 1 liter
|
||||
[Description("m3")] m3, /// 1000 l
|
||||
[Description("gal(UK)")] gal_UK, /// 1 gal(UK) = 4.54609 l
|
||||
[Description("gal(US)")] gal_US, /// 1 gal(US) = 3.78541178 l
|
||||
|
||||
[Description("l/h")] lph, /// 1 liter/h
|
||||
[Description("m3/h")] m3ph, /// * 1 m3/h = 1000 l/h
|
||||
|
||||
[Description("g")] g, /// 0.001 kg
|
||||
[Description("kg")] kg, /// * 1 kilogram
|
||||
[Description("t")] t, /// 1000 kg
|
||||
[Description("lb")] lb, /// 0.45359237 kg
|
||||
|
||||
[Description("s")] s, /// * 1 second
|
||||
[Description("min")] min, /// 1 min = 60 s
|
||||
[Description("hr")] hour, /// 1 hour = 60 min = 3600 s
|
||||
[Description("ms")] ms, /// 1 ms = 0.001 s
|
||||
|
||||
[Description("°C")] C, /// * degree Celsius
|
||||
[Description("°F")] F, /// degree Fahrenheit
|
||||
[Description("K")] K, /// degree Kelvin
|
||||
|
||||
[Description("Pa")] Pa, /// 1 Pa = 0.01 hPa
|
||||
[Description("hPa")] hPa, /// 1 hPa = 100 Pa
|
||||
[Description("kPa")] kPa, /// 1 kPa = 10 HPa
|
||||
[Description("MPa")] MPa, /// 1 MPa = 10000 hPa
|
||||
[Description("mbar")] mbar, /// 1 mbar = 1 hPa = 100 Pa
|
||||
[Description("bar")] bar, /// * 1 Bar = 1000 mbar = 0.1 MPa = 100000 Pa
|
||||
[Description("inHg")] inHg, /// 1 inHg = 33.864 hPa
|
||||
|
||||
[Description("R%")] RPct, /// * 1 R%
|
||||
|
||||
[Description("%")] Pct, /// * 1 %
|
||||
[Description("promile")] Promile, /// 1 promile = 0.1 %
|
||||
|
||||
[Description("mm")] mm, /// * 1 millimeter
|
||||
[Description("cm")] cm, /// 1 cm = 10 mm
|
||||
[Description("m")] m, /// 1 m = 1000 mm
|
||||
[Description("in")] inch, /// 1 inch = 25.4 mm
|
||||
|
||||
[Description("kg/m3")] kgpm3, /// * 1 kg/m3 = 0.001 kg/l
|
||||
[Description("kg/l")] kgpl, /// 1 kg/l = 1000 kg/m3
|
||||
|
||||
[Description("J")] J, /// * 1 Joul
|
||||
[Description("kJ")] kJ, /// 1 kJ = 1000 J
|
||||
[Description("MJ")] MJ, /// 1 MJ = 1000000 J
|
||||
[Description("Wh")] Wh, /// 1 Wh = 3600 J
|
||||
[Description("kWh")] kWh, /// 1 kWh = 3600000 J
|
||||
[Description("MWh")] MWh, /// 1 MWh = 3600000000 J
|
||||
|
||||
[Description("pulse/l")] ppl, /// * 1 pulse/l
|
||||
///
|
||||
[Description("pulse/kWh")] ppkWh, /// * 1 pulse/kWh
|
||||
|
||||
Count
|
||||
}
|
||||
|
||||
public enum Quantity
|
||||
{
|
||||
/// Quantities with units and conversions (double -> double)
|
||||
#if LANG_DE
|
||||
[Description("Volumen")] Volume,
|
||||
[Description("Durchfluss")] Flow,
|
||||
[Description("Masse")] Mass,
|
||||
[Description("Zeit")] Time,
|
||||
[Description("Temperatur")] Temperature,
|
||||
[Description("Druck")] Pressure,
|
||||
[Description("Feuchtigkeit")] Humidity,
|
||||
[Description("Fehler")] Error,
|
||||
[Description("Länge")] Length,
|
||||
[Description("Dichte")] Density,
|
||||
[Description("Energie")] Energy,
|
||||
[Description("Impulse/l")] PulsePerLtr,
|
||||
[Description("Impulse/kWh")] PulsePerKWh,
|
||||
|
||||
/// Quantities without units and conversions
|
||||
[Description("Nummer")] Number,
|
||||
[Description("Text")] String,
|
||||
[Description("Boolean")] Boolean,
|
||||
[Description("Datum und Uhrzeit")] DateTime,
|
||||
#elif LANG_PL
|
||||
[Description("Objętość")] Volume,
|
||||
[Description("Przepływ")] Flow,
|
||||
[Description("Masa")] Mass,
|
||||
[Description("Czas")] Time,
|
||||
[Description("Temperatura")] Temperature,
|
||||
[Description("Ciśnienie")] Pressure,
|
||||
[Description("Wilgotność")] Humidity,
|
||||
[Description("Błąd")] Error,
|
||||
[Description("Długość")] Length,
|
||||
[Description("Gęstość")] Density,
|
||||
[Description("Energia")] Energy,
|
||||
[Description("Impulsy/litr")] PulsePerLtr,
|
||||
[Description("Impulsy/kWh")] PulsePerKWh,
|
||||
|
||||
/// Quantities without units and conversions
|
||||
[Description("Numer")] Number,
|
||||
[Description("Tekst")] String,
|
||||
[Description("Boolean")] Boolean,
|
||||
[Description("Data i czas")] DateTime,
|
||||
#elif LANG_CS
|
||||
[Description("Objem")] Volume,
|
||||
[Description("Průtok")] Flow,
|
||||
[Description("Hmotnost")] Mass,
|
||||
[Description("Čas")] Time,
|
||||
[Description("Teplota")] Temperature,
|
||||
[Description("Tlak")] Pressure,
|
||||
[Description("Vlhkost")] Humidity,
|
||||
[Description("Chyba")] Error,
|
||||
[Description("Délka")] Length,
|
||||
[Description("Hustota")] Density,
|
||||
[Description("Energie")] Energy,
|
||||
[Description("Pulzy/litr")] PulsePerLtr,
|
||||
[Description("Pulzy/kWh")] PulsePerKWh,
|
||||
|
||||
/// Quantities without units and conversions
|
||||
[Description("Počet")] Number,
|
||||
[Description("Text")] String,
|
||||
[Description("Boolean")] Boolean,
|
||||
[Description("Datum a čas")] DateTime,
|
||||
#else
|
||||
[Description("Volume")] Volume,
|
||||
[Description("Flow")] Flow,
|
||||
[Description("Mass")] Mass,
|
||||
[Description("Time")] Time,
|
||||
[Description("Temperature")] Temperature,
|
||||
[Description("Pressure")] Pressure,
|
||||
[Description("Humidity")] Humidity,
|
||||
[Description("Error")] Error,
|
||||
[Description("Length")] Length,
|
||||
[Description("Density")] Density,
|
||||
[Description("Energy")] Energy,
|
||||
[Description("Pulses/liter")] PulsePerLtr,
|
||||
[Description("Pulses/kWh")] PulsePerKWh,
|
||||
|
||||
/// Quantities without units and conversions
|
||||
[Description("Number")] Number,
|
||||
[Description("String")] String,
|
||||
[Description("Boolean")] Boolean,
|
||||
[Description("Date and time")] DateTime,
|
||||
#endif
|
||||
Count,
|
||||
}
|
||||
|
||||
public static class Units
|
||||
{
|
||||
public static bool IsUnitless(Quantity quantity)
|
||||
{
|
||||
return quantity >= Quantity.Number;
|
||||
}
|
||||
|
||||
public static bool IsDefaultUnit(Unit unit)
|
||||
{
|
||||
return unit == Unit.l || unit == Unit.m3ph || unit == Unit.kg || unit == Unit.s || unit == Unit.C || unit == Unit.bar || unit == Unit.RPct ||
|
||||
unit == Unit.Pct || unit == Unit.mm || unit == Unit.kgpm3 || unit == Unit.J || unit == Unit.ppl || unit == Unit.ppkWh;
|
||||
}
|
||||
|
||||
public static bool IsQuantity(Unit units, Quantity quantity)
|
||||
{
|
||||
return (quantity == GetQuantity(units));
|
||||
}
|
||||
|
||||
public static Quantity GetQuantity(Unit units)
|
||||
{
|
||||
switch (units)
|
||||
{
|
||||
case Unit.l:
|
||||
case Unit.m3:
|
||||
case Unit.gal_UK:
|
||||
case Unit.gal_US:
|
||||
return Config.Quantity.Volume;
|
||||
|
||||
case Unit.lph:
|
||||
case Unit.m3ph:
|
||||
return Config.Quantity.Flow;
|
||||
|
||||
case Unit.g:
|
||||
case Unit.kg:
|
||||
case Unit.t:
|
||||
case Unit.lb:
|
||||
return Config.Quantity.Mass;
|
||||
|
||||
case Unit.s:
|
||||
case Unit.min:
|
||||
case Unit.hour:
|
||||
case Unit.ms:
|
||||
return Config.Quantity.Time;
|
||||
|
||||
case Unit.C:
|
||||
case Unit.F:
|
||||
case Unit.K:
|
||||
return Config.Quantity.Temperature;
|
||||
|
||||
case Unit.Pa:
|
||||
case Unit.hPa:
|
||||
case Unit.mbar:
|
||||
case Unit.kPa:
|
||||
case Unit.bar:
|
||||
case Unit.MPa:
|
||||
case Unit.inHg:
|
||||
return Config.Quantity.Pressure;
|
||||
|
||||
case Unit.RPct:
|
||||
return Config.Quantity.Humidity;
|
||||
|
||||
case Unit.Pct:
|
||||
case Unit.Promile:
|
||||
return Config.Quantity.Error;
|
||||
|
||||
case Unit.mm:
|
||||
case Unit.cm:
|
||||
case Unit.m:
|
||||
case Unit.inch:
|
||||
return Config.Quantity.Length;
|
||||
|
||||
case Unit.kgpm3:
|
||||
case Unit.kgpl:
|
||||
return Config.Quantity.Density;
|
||||
|
||||
case Unit.J:
|
||||
case Unit.kJ:
|
||||
case Unit.MJ:
|
||||
case Unit.Wh:
|
||||
case Unit.kWh:
|
||||
case Unit.MWh:
|
||||
return Config.Quantity.Energy;
|
||||
|
||||
case Unit.ppl:
|
||||
return Config.Quantity.PulsePerLtr;
|
||||
|
||||
case Unit.ppkWh:
|
||||
return Config.Quantity.PulsePerKWh;
|
||||
|
||||
default:
|
||||
return Config.Quantity.Number;
|
||||
}
|
||||
}
|
||||
|
||||
public static bool IsVolume(Unit units) { return IsQuantity(units, Config.Quantity.Volume); }
|
||||
public static bool IsFlow(Unit units) { return IsQuantity(units, Config.Quantity.Flow); }
|
||||
public static bool IsMass(Unit units) { return IsQuantity(units, Config.Quantity.Mass); }
|
||||
public static bool IsTime(Unit units) { return IsQuantity(units, Config.Quantity.Time); }
|
||||
public static bool IsTemperature(Unit units) { return IsQuantity(units, Config.Quantity.Temperature); }
|
||||
public static bool IsPressure(Unit units) { return IsQuantity(units, Config.Quantity.Pressure); }
|
||||
public static bool IsHumidity(Unit units) { return IsQuantity(units, Config.Quantity.Humidity); }
|
||||
public static bool IsError(Unit units) { return IsQuantity(units, Config.Quantity.Error); }
|
||||
public static bool IsLength(Unit units) { return IsQuantity(units, Config.Quantity.Length); }
|
||||
public static bool IsDensity(Unit units) { return IsQuantity(units, Config.Quantity.Density); }
|
||||
public static bool IsEnergy(Unit units) { return IsQuantity(units, Config.Quantity.Energy); }
|
||||
public static bool IsPulsePerLtr(Unit units) { return IsQuantity(units, Config.Quantity.PulsePerLtr); }
|
||||
public static bool IsPulsePerKWh(Unit units) { return IsQuantity(units, Config.Quantity.PulsePerKWh); }
|
||||
|
||||
|
||||
public static double ConvertTo(Unit units, double v)
|
||||
{
|
||||
switch (units)
|
||||
{
|
||||
/// Volume: internal representation in l
|
||||
case Unit.l: return v; /// 1 liter
|
||||
case Unit.m3: return 0.001 * v; /// 1 m3 = 1000 l
|
||||
case Unit.gal_UK: return 0.21996925 * v; /// 1 gal(UK) = 4.54609 l
|
||||
case Unit.gal_US: return 0.26417205 * v; /// 1 gal(US) = 3.78541178 l
|
||||
|
||||
/// Flow: internal representation in m3/h
|
||||
case Unit.lph: return 1000 * v; /// 1 liter/h
|
||||
case Unit.m3ph: return v; /// 1 m3/h = 1000 l/h
|
||||
|
||||
/// Mass: internal representation in kg
|
||||
case Unit.g: return 1000 * v; /// 1 g = 0.001 kg
|
||||
case Unit.kg: return v; /// 1 kilogram
|
||||
case Unit.t: return 0.001 * v; /// 1 t = 1000 kg
|
||||
case Unit.lb: return 2.2046226 * v; /// 1 lb = 0.45359237 kg
|
||||
|
||||
/// Time or duration: internal representation in seconds [s]
|
||||
case Unit.s: return v;
|
||||
case Unit.min: return v / 60;
|
||||
case Unit.hour: return v / 3600;
|
||||
case Unit.ms: return 1000 * v;
|
||||
|
||||
/// Temperature: internal representation in degree C
|
||||
case Unit.C: return v; /// degree Celsius
|
||||
case Unit.F: return 1.8 * v + 32; /// degree Fahrenheit
|
||||
case Unit.K: return v + 273.15; /// degree Kelvin
|
||||
|
||||
/// Pressure: internal representation in bar = 0.1 MPa
|
||||
case Unit.Pa: return 100000 * v; /// 1 hPa = 100 Pa
|
||||
case Unit.hPa: return 1000 * v; /// 1 hPa = 100 Pa
|
||||
case Unit.mbar: return 1000 * v; /// 1 mbar = 1 hPa = 100 Pa
|
||||
case Unit.kPa: return 100 * v; /// 1 kPa = 10 HPa
|
||||
case Unit.bar: return v; /// 1 bar = 1000 mbar = 100000 Pa
|
||||
case Unit.MPa: return 0.1 * v; /// 1 MPa = 10000 hPa
|
||||
case Unit.inHg: return 29.53 * v; /// 1 inHg = 33.864 hPa
|
||||
|
||||
/// Error: internal representation in %
|
||||
case Unit.Pct: return v; /// 1 %
|
||||
case Unit.Promile: return 10 * v; /// 1 promile = 0.1 %
|
||||
|
||||
/// Diameter, length: internal representation in mm
|
||||
case Unit.mm: return v; /// 1 mm
|
||||
case Unit.cm: return 0.1 * v; /// 1 cm = 10 mm
|
||||
case Unit.m: return 0.001 * v; /// 1 m = 1000 mm
|
||||
case Unit.inch: return v / 25.4; /// 1 inch = 25.4 mm
|
||||
|
||||
/// Density: internal representation in kg/m3
|
||||
case Unit.kgpm3: return v;
|
||||
case Unit.kgpl: return 0.001 * v;
|
||||
|
||||
/// Energy, internal representation in Joul
|
||||
case Unit.J: return v; /// 1 Joul
|
||||
case Unit.kJ: return 0.001 * v; /// 1 kJ = 1000 J
|
||||
case Unit.MJ: return 0.000001 * v; /// 1 kJ = 1000000 J
|
||||
case Unit.Wh: return v / 3600.0; /// 1 Wh = 3600 J
|
||||
case Unit.kWh: return v / 3600000.0; /// 1 kWh = 3600000 J
|
||||
case Unit.MWh: return v / 3600000000.0;/// 1 MWh = 3600000000 J
|
||||
|
||||
default: return v;
|
||||
}
|
||||
}
|
||||
|
||||
public static double ConvertFrom(Unit units, double v)
|
||||
{
|
||||
switch (units)
|
||||
{
|
||||
/// Volume: internal representation in l
|
||||
case Unit.l: return v; /// 1 liter
|
||||
case Unit.m3: return 1000 * v; /// 1000 l
|
||||
case Unit.gal_UK: return 4.54609 * v; /// 1 gal(UK) = 4.54609 l
|
||||
case Unit.gal_US: return 3.78541178 * v; /// 1 gal(US) = 3.78541178 l
|
||||
|
||||
/// Flow: internal representation in m3/h
|
||||
case Unit.lph: return 0.001 * v; /// 1 liter/h
|
||||
case Unit.m3ph: return v; /// 1 m3/h = 1000 l/h
|
||||
|
||||
/// Mass: internal representation in kg
|
||||
case Unit.g: return 0.001 * v; /// 1 g = 0.001 kg
|
||||
case Unit.kg: return v; /// 1 kilogram
|
||||
case Unit.t: return 1000 * v; /// 1 t = 1000 kg
|
||||
case Unit.lb: return 0.45359237 * v; /// 1 lb = 0.45359237 kg
|
||||
|
||||
/// Time or duration: internal representation in seconds [s]
|
||||
case Unit.s: return v;
|
||||
case Unit.min: return 60 * v;
|
||||
case Unit.hour: return 3600 * v;
|
||||
case Unit.ms: return v / 1000;
|
||||
|
||||
/// Temperature: internal representation in degree C
|
||||
case Unit.C: return v; /// degree Celsius
|
||||
case Unit.F: return 5 * (v-32) / 9; /// degree Fahrenheit
|
||||
case Unit.K: return v - 273.15; /// degree Kelvin
|
||||
|
||||
/// Pressure: internal representation in bar = 0.1 MPa
|
||||
case Unit.Pa: return 0.00001 * v; /// 1 hPa = 100 Pa
|
||||
case Unit.hPa: return 0.001 * v; /// 1 hPa = 100 Pa
|
||||
case Unit.mbar: return 0.001 * v; /// 1 mbar = 1 hPa = 100 Pa
|
||||
case Unit.kPa: return 0.01 * v; /// 1 kPa = 10 HPa
|
||||
case Unit.bar: return v; /// 1 bar = 1000 mbar = 100000 Pa
|
||||
case Unit.MPa: return 10 * v; /// 1 MPa = 10000 hPa
|
||||
case Unit.inHg: return 0.033864 * v; /// 1 inHg = 33.864 hPa
|
||||
|
||||
/// Error: internal representation in %
|
||||
case Unit.Pct: return v; /// 1 %
|
||||
case Unit.Promile: return 0.1 * v; /// 1 promile = 0.1 %
|
||||
|
||||
/// Diameter, length: internal representation in mm
|
||||
case Unit.mm: return v; /// 1 mm
|
||||
case Unit.cm: return 10 * v; /// 1 cm = 10 mm
|
||||
case Unit.m: return 1000 * v; /// 1 m = 1000 mm
|
||||
case Unit.inch: return 25.4 * v; /// 1 inch = 25.4 mm
|
||||
|
||||
/// Density: internal representation in kg/m3
|
||||
case Unit.kgpm3: return v;
|
||||
case Unit.kgpl: return 1000 * v;
|
||||
|
||||
/// Energy, internal representation in Joul
|
||||
case Unit.J: return v; /// 1 Joul
|
||||
case Unit.kJ: return 1000 * v; /// 1 kJ = 1000 J
|
||||
case Unit.MJ: return 1000000 * v; /// 1 kJ = 1000000 J
|
||||
case Unit.Wh: return 3600 * v; /// 1 Wh = 3600 J
|
||||
case Unit.kWh: return 3600000 * v; /// 1 kWh = 3600000 J
|
||||
case Unit.MWh: return 3600000000 * v; /// 1 kWh = 3600000000 J
|
||||
|
||||
default: return v;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,108 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
|
||||
<ProductVersion>8.0.30703</ProductVersion>
|
||||
<SchemaVersion>2.0</SchemaVersion>
|
||||
<ProjectGuid>{6D3384DC-4638-4A92-91A8-F39D900377C6}</ProjectGuid>
|
||||
<OutputType>WinExe</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>DeviceTest</RootNamespace>
|
||||
<AssemblyName>DeviceTest</AssemblyName>
|
||||
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
|
||||
<TargetFrameworkProfile>
|
||||
</TargetFrameworkProfile>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
|
||||
<PlatformTarget>x86</PlatformTarget>
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
|
||||
<PlatformTarget>x86</PlatformTarget>
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<StartupObject>DeviceTest.Program</StartupObject>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="log4net, Version=1.2.12.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>..\packages\log4net.2.0.2\lib\net40-full\log4net.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
<Reference Include="System.Data" />
|
||||
<Reference Include="System.Deployment" />
|
||||
<Reference Include="System.Drawing" />
|
||||
<Reference Include="System.Windows.Forms" />
|
||||
<Reference Include="System.Xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="DeviceTestDlg.cs">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
<Compile Include="DeviceTestDlg.Designer.cs">
|
||||
<DependentUpon>DeviceTestDlg.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="LocalSettings.cs" />
|
||||
<Compile Include="Program.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<EmbeddedResource Include="DeviceTestDlg.resx">
|
||||
<DependentUpon>DeviceTestDlg.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Properties\Resources.resx">
|
||||
<Generator>ResXFileCodeGenerator</Generator>
|
||||
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
|
||||
<SubType>Designer</SubType>
|
||||
</EmbeddedResource>
|
||||
<Compile Include="Properties\Resources.Designer.cs">
|
||||
<AutoGen>True</AutoGen>
|
||||
<DependentUpon>Resources.resx</DependentUpon>
|
||||
<DesignTime>True</DesignTime>
|
||||
</Compile>
|
||||
<None Include="app.config" />
|
||||
<None Include="Properties\Settings.settings">
|
||||
<Generator>SettingsSingleFileGenerator</Generator>
|
||||
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
|
||||
</None>
|
||||
<Compile Include="Properties\Settings.Designer.cs">
|
||||
<AutoGen>True</AutoGen>
|
||||
<DependentUpon>Settings.settings</DependentUpon>
|
||||
<DesignTimeSharedInput>True</DesignTimeSharedInput>
|
||||
</Compile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\Config\Config.csproj">
|
||||
<Project>{743DF7DB-C7B6-42EB-986D-0F485E5588E4}</Project>
|
||||
<Name>Config</Name>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\TestBenchFramework\TBF.csproj">
|
||||
<Project>{8648FD92-CDA1-4C3A-B5F9-FE547CE1FA48}</Project>
|
||||
<Name>TBF</Name>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||
Other similar extension points exist, see Microsoft.Common.targets.
|
||||
<Target Name="BeforeBuild">
|
||||
</Target>
|
||||
<Target Name="AfterBuild">
|
||||
</Target>
|
||||
-->
|
||||
</Project>
|
||||
Generated
-584
@@ -1,584 +0,0 @@
|
||||
namespace DeviceTest
|
||||
{
|
||||
partial class DeviceTestDlg
|
||||
{
|
||||
/// <summary>
|
||||
/// Required designer variable.
|
||||
/// </summary>
|
||||
private System.ComponentModel.IContainer components = null;
|
||||
|
||||
/// <summary>
|
||||
/// Clean up any resources being used.
|
||||
/// </summary>
|
||||
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
|
||||
protected override void Dispose(bool disposing)
|
||||
{
|
||||
if (disposing && (components != null))
|
||||
{
|
||||
components.Dispose();
|
||||
}
|
||||
base.Dispose(disposing);
|
||||
}
|
||||
|
||||
#region Windows Form Designer generated code
|
||||
|
||||
/// <summary>
|
||||
/// Required method for Designer support - do not modify
|
||||
/// the contents of this method with the code editor.
|
||||
/// </summary>
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.parentClassNameComboBox = new System.Windows.Forms.ComboBox();
|
||||
this.classLabel = new System.Windows.Forms.Label();
|
||||
this.nameLabel = new System.Windows.Forms.Label();
|
||||
this.parentNameTextBox = new System.Windows.Forms.TextBox();
|
||||
this.configureParentButton = new System.Windows.Forms.Button();
|
||||
this.startButton = new System.Windows.Forms.Button();
|
||||
this.groupBox1 = new System.Windows.Forms.GroupBox();
|
||||
this.groupBox2 = new System.Windows.Forms.GroupBox();
|
||||
this.configureComponent1Button = new System.Windows.Forms.Button();
|
||||
this.componentNameTextBox = new System.Windows.Forms.TextBox();
|
||||
this.label1 = new System.Windows.Forms.Label();
|
||||
this.label2 = new System.Windows.Forms.Label();
|
||||
this.component1ClassNameComboBox = new System.Windows.Forms.ComboBox();
|
||||
this.radioButton4 = new System.Windows.Forms.RadioButton();
|
||||
this.radioButton3 = new System.Windows.Forms.RadioButton();
|
||||
this.radioButton2 = new System.Windows.Forms.RadioButton();
|
||||
this.radioButton1 = new System.Windows.Forms.RadioButton();
|
||||
this.radioButton0 = new System.Windows.Forms.RadioButton();
|
||||
this.stopButton = new System.Windows.Forms.Button();
|
||||
this.groupBox3 = new System.Windows.Forms.GroupBox();
|
||||
this.configureComponent2Button = new System.Windows.Forms.Button();
|
||||
this.component2NameTextBox = new System.Windows.Forms.TextBox();
|
||||
this.label3 = new System.Windows.Forms.Label();
|
||||
this.label4 = new System.Windows.Forms.Label();
|
||||
this.component2ClassNameComboBox = new System.Windows.Forms.ComboBox();
|
||||
this.radioButton24 = new System.Windows.Forms.RadioButton();
|
||||
this.radioButton23 = new System.Windows.Forms.RadioButton();
|
||||
this.radioButton22 = new System.Windows.Forms.RadioButton();
|
||||
this.radioButton21 = new System.Windows.Forms.RadioButton();
|
||||
this.groupBox4 = new System.Windows.Forms.GroupBox();
|
||||
this.radioButton34 = new System.Windows.Forms.RadioButton();
|
||||
this.radioButton33 = new System.Windows.Forms.RadioButton();
|
||||
this.radioButton32 = new System.Windows.Forms.RadioButton();
|
||||
this.radioButton31 = new System.Windows.Forms.RadioButton();
|
||||
this.groupBox5 = new System.Windows.Forms.GroupBox();
|
||||
this.configureComponent3Button = new System.Windows.Forms.Button();
|
||||
this.component3NameTextBox = new System.Windows.Forms.TextBox();
|
||||
this.label5 = new System.Windows.Forms.Label();
|
||||
this.label6 = new System.Windows.Forms.Label();
|
||||
this.component3ClassNameComboBox = new System.Windows.Forms.ComboBox();
|
||||
this.groupBox1.SuspendLayout();
|
||||
this.groupBox2.SuspendLayout();
|
||||
this.groupBox3.SuspendLayout();
|
||||
this.groupBox4.SuspendLayout();
|
||||
this.groupBox5.SuspendLayout();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// parentClassNameComboBox
|
||||
//
|
||||
this.parentClassNameComboBox.FormattingEnabled = true;
|
||||
this.parentClassNameComboBox.Location = new System.Drawing.Point(77, 19);
|
||||
this.parentClassNameComboBox.Name = "parentClassNameComboBox";
|
||||
this.parentClassNameComboBox.Size = new System.Drawing.Size(299, 21);
|
||||
this.parentClassNameComboBox.TabIndex = 0;
|
||||
//
|
||||
// classLabel
|
||||
//
|
||||
this.classLabel.AutoSize = true;
|
||||
this.classLabel.Location = new System.Drawing.Point(11, 22);
|
||||
this.classLabel.Name = "classLabel";
|
||||
this.classLabel.Size = new System.Drawing.Size(32, 13);
|
||||
this.classLabel.TabIndex = 1;
|
||||
this.classLabel.Text = "Class";
|
||||
//
|
||||
// nameLabel
|
||||
//
|
||||
this.nameLabel.AutoSize = true;
|
||||
this.nameLabel.Location = new System.Drawing.Point(11, 47);
|
||||
this.nameLabel.Name = "nameLabel";
|
||||
this.nameLabel.Size = new System.Drawing.Size(35, 13);
|
||||
this.nameLabel.TabIndex = 2;
|
||||
this.nameLabel.Text = "Name";
|
||||
//
|
||||
// parentNameTextBox
|
||||
//
|
||||
this.parentNameTextBox.Enabled = false;
|
||||
this.parentNameTextBox.Location = new System.Drawing.Point(77, 44);
|
||||
this.parentNameTextBox.Name = "parentNameTextBox";
|
||||
this.parentNameTextBox.Size = new System.Drawing.Size(299, 20);
|
||||
this.parentNameTextBox.TabIndex = 3;
|
||||
//
|
||||
// configureParentButton
|
||||
//
|
||||
this.configureParentButton.Location = new System.Drawing.Point(395, 19);
|
||||
this.configureParentButton.Name = "configureParentButton";
|
||||
this.configureParentButton.Size = new System.Drawing.Size(73, 45);
|
||||
this.configureParentButton.TabIndex = 4;
|
||||
this.configureParentButton.Text = "Configure";
|
||||
this.configureParentButton.UseVisualStyleBackColor = true;
|
||||
this.configureParentButton.Click += new System.EventHandler(this.configureParentButton_Click);
|
||||
//
|
||||
// startButton
|
||||
//
|
||||
this.startButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.startButton.Location = new System.Drawing.Point(520, 19);
|
||||
this.startButton.Name = "startButton";
|
||||
this.startButton.Size = new System.Drawing.Size(73, 45);
|
||||
this.startButton.TabIndex = 7;
|
||||
this.startButton.Text = "Start";
|
||||
this.startButton.UseVisualStyleBackColor = true;
|
||||
this.startButton.Click += new System.EventHandler(this.startButton_Click);
|
||||
//
|
||||
// groupBox1
|
||||
//
|
||||
this.groupBox1.Controls.Add(this.configureParentButton);
|
||||
this.groupBox1.Controls.Add(this.parentNameTextBox);
|
||||
this.groupBox1.Controls.Add(this.nameLabel);
|
||||
this.groupBox1.Controls.Add(this.classLabel);
|
||||
this.groupBox1.Controls.Add(this.parentClassNameComboBox);
|
||||
this.groupBox1.Location = new System.Drawing.Point(12, 12);
|
||||
this.groupBox1.Name = "groupBox1";
|
||||
this.groupBox1.Size = new System.Drawing.Size(486, 75);
|
||||
this.groupBox1.TabIndex = 8;
|
||||
this.groupBox1.TabStop = false;
|
||||
this.groupBox1.Text = "Parent component";
|
||||
//
|
||||
// groupBox2
|
||||
//
|
||||
this.groupBox2.Controls.Add(this.configureComponent1Button);
|
||||
this.groupBox2.Controls.Add(this.componentNameTextBox);
|
||||
this.groupBox2.Controls.Add(this.label1);
|
||||
this.groupBox2.Controls.Add(this.label2);
|
||||
this.groupBox2.Controls.Add(this.component1ClassNameComboBox);
|
||||
this.groupBox2.Location = new System.Drawing.Point(12, 93);
|
||||
this.groupBox2.Name = "groupBox2";
|
||||
this.groupBox2.Size = new System.Drawing.Size(486, 75);
|
||||
this.groupBox2.TabIndex = 9;
|
||||
this.groupBox2.TabStop = false;
|
||||
this.groupBox2.Text = "Component 1";
|
||||
//
|
||||
// configureComponentButton
|
||||
//
|
||||
this.configureComponent1Button.Location = new System.Drawing.Point(395, 19);
|
||||
this.configureComponent1Button.Name = "configureComponentButton";
|
||||
this.configureComponent1Button.Size = new System.Drawing.Size(73, 45);
|
||||
this.configureComponent1Button.TabIndex = 4;
|
||||
this.configureComponent1Button.Text = "Configure";
|
||||
this.configureComponent1Button.UseVisualStyleBackColor = true;
|
||||
this.configureComponent1Button.Click += new System.EventHandler(this.configureComponent1Button_Click);
|
||||
//
|
||||
// componentNameTextBox
|
||||
//
|
||||
this.componentNameTextBox.Enabled = false;
|
||||
this.componentNameTextBox.Location = new System.Drawing.Point(77, 44);
|
||||
this.componentNameTextBox.Name = "componentNameTextBox";
|
||||
this.componentNameTextBox.Size = new System.Drawing.Size(299, 20);
|
||||
this.componentNameTextBox.TabIndex = 3;
|
||||
//
|
||||
// label1
|
||||
//
|
||||
this.label1.AutoSize = true;
|
||||
this.label1.Location = new System.Drawing.Point(11, 47);
|
||||
this.label1.Name = "label1";
|
||||
this.label1.Size = new System.Drawing.Size(35, 13);
|
||||
this.label1.TabIndex = 2;
|
||||
this.label1.Text = "Name";
|
||||
//
|
||||
// label2
|
||||
//
|
||||
this.label2.AutoSize = true;
|
||||
this.label2.Location = new System.Drawing.Point(11, 22);
|
||||
this.label2.Name = "label2";
|
||||
this.label2.Size = new System.Drawing.Size(32, 13);
|
||||
this.label2.TabIndex = 1;
|
||||
this.label2.Text = "Class";
|
||||
//
|
||||
// componentClassNameComboBox
|
||||
//
|
||||
this.component1ClassNameComboBox.FormattingEnabled = true;
|
||||
this.component1ClassNameComboBox.Location = new System.Drawing.Point(77, 19);
|
||||
this.component1ClassNameComboBox.Name = "componentClassNameComboBox";
|
||||
this.component1ClassNameComboBox.Size = new System.Drawing.Size(299, 21);
|
||||
this.component1ClassNameComboBox.TabIndex = 0;
|
||||
//
|
||||
// radioButton4
|
||||
//
|
||||
this.radioButton4.AutoSize = true;
|
||||
this.radioButton4.Location = new System.Drawing.Point(13, 118);
|
||||
this.radioButton4.Name = "radioButton4";
|
||||
this.radioButton4.Size = new System.Drawing.Size(51, 17);
|
||||
this.radioButton4.TabIndex = 9;
|
||||
this.radioButton4.TabStop = true;
|
||||
this.radioButton4.Text = "spare";
|
||||
this.radioButton4.UseVisualStyleBackColor = true;
|
||||
this.radioButton4.CheckedChanged += new System.EventHandler(this.radioButton4_CheckedChanged);
|
||||
//
|
||||
// radioButton3
|
||||
//
|
||||
this.radioButton3.AutoSize = true;
|
||||
this.radioButton3.Location = new System.Drawing.Point(13, 95);
|
||||
this.radioButton3.Name = "radioButton3";
|
||||
this.radioButton3.Size = new System.Drawing.Size(51, 17);
|
||||
this.radioButton3.TabIndex = 8;
|
||||
this.radioButton3.TabStop = true;
|
||||
this.radioButton3.Text = "spare";
|
||||
this.radioButton3.UseVisualStyleBackColor = true;
|
||||
this.radioButton3.CheckedChanged += new System.EventHandler(this.radioButton3_CheckedChanged);
|
||||
//
|
||||
// radioButton2
|
||||
//
|
||||
this.radioButton2.AutoSize = true;
|
||||
this.radioButton2.Location = new System.Drawing.Point(13, 72);
|
||||
this.radioButton2.Name = "radioButton2";
|
||||
this.radioButton2.Size = new System.Drawing.Size(51, 17);
|
||||
this.radioButton2.TabIndex = 7;
|
||||
this.radioButton2.TabStop = true;
|
||||
this.radioButton2.Text = "spare";
|
||||
this.radioButton2.UseVisualStyleBackColor = true;
|
||||
this.radioButton2.CheckedChanged += new System.EventHandler(this.radioButton2_CheckedChanged);
|
||||
//
|
||||
// radioButton1
|
||||
//
|
||||
this.radioButton1.AutoSize = true;
|
||||
this.radioButton1.Location = new System.Drawing.Point(13, 49);
|
||||
this.radioButton1.Name = "radioButton1";
|
||||
this.radioButton1.Size = new System.Drawing.Size(106, 17);
|
||||
this.radioButton1.TabIndex = 6;
|
||||
this.radioButton1.TabStop = true;
|
||||
this.radioButton1.Text = "ReadPressureOp";
|
||||
this.radioButton1.UseVisualStyleBackColor = true;
|
||||
this.radioButton1.CheckedChanged += new System.EventHandler(this.radioButton1_CheckedChanged);
|
||||
//
|
||||
// radioButton0
|
||||
//
|
||||
this.radioButton0.AutoSize = true;
|
||||
this.radioButton0.Location = new System.Drawing.Point(13, 26);
|
||||
this.radioButton0.Name = "radioButton0";
|
||||
this.radioButton0.Size = new System.Drawing.Size(94, 17);
|
||||
this.radioButton0.TabIndex = 5;
|
||||
this.radioButton0.TabStop = true;
|
||||
this.radioButton0.Text = "Stop operation";
|
||||
this.radioButton0.UseVisualStyleBackColor = true;
|
||||
this.radioButton0.CheckedChanged += new System.EventHandler(this.radioButton0_CheckedChanged);
|
||||
//
|
||||
// stopButton
|
||||
//
|
||||
this.stopButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.stopButton.Location = new System.Drawing.Point(520, 77);
|
||||
this.stopButton.Name = "stopButton";
|
||||
this.stopButton.Size = new System.Drawing.Size(73, 45);
|
||||
this.stopButton.TabIndex = 10;
|
||||
this.stopButton.Text = "Stop";
|
||||
this.stopButton.UseVisualStyleBackColor = true;
|
||||
this.stopButton.Click += new System.EventHandler(this.stopButton_Click);
|
||||
//
|
||||
// groupBox3
|
||||
//
|
||||
this.groupBox3.Controls.Add(this.configureComponent2Button);
|
||||
this.groupBox3.Controls.Add(this.component2NameTextBox);
|
||||
this.groupBox3.Controls.Add(this.label3);
|
||||
this.groupBox3.Controls.Add(this.label4);
|
||||
this.groupBox3.Controls.Add(this.component2ClassNameComboBox);
|
||||
this.groupBox3.Location = new System.Drawing.Point(12, 174);
|
||||
this.groupBox3.Name = "groupBox3";
|
||||
this.groupBox3.Size = new System.Drawing.Size(486, 75);
|
||||
this.groupBox3.TabIndex = 11;
|
||||
this.groupBox3.TabStop = false;
|
||||
this.groupBox3.Text = "Component 2";
|
||||
//
|
||||
// configureComponent2Button
|
||||
//
|
||||
this.configureComponent2Button.Location = new System.Drawing.Point(395, 19);
|
||||
this.configureComponent2Button.Name = "configureComponent2Button";
|
||||
this.configureComponent2Button.Size = new System.Drawing.Size(73, 45);
|
||||
this.configureComponent2Button.TabIndex = 4;
|
||||
this.configureComponent2Button.Text = "Configure";
|
||||
this.configureComponent2Button.UseVisualStyleBackColor = true;
|
||||
this.configureComponent2Button.Click += new System.EventHandler(this.configureComponent2Button_Click);
|
||||
//
|
||||
// component2NameTextBox
|
||||
//
|
||||
this.component2NameTextBox.Enabled = false;
|
||||
this.component2NameTextBox.Location = new System.Drawing.Point(77, 44);
|
||||
this.component2NameTextBox.Name = "component2NameTextBox";
|
||||
this.component2NameTextBox.Size = new System.Drawing.Size(299, 20);
|
||||
this.component2NameTextBox.TabIndex = 3;
|
||||
//
|
||||
// label3
|
||||
//
|
||||
this.label3.AutoSize = true;
|
||||
this.label3.Location = new System.Drawing.Point(11, 47);
|
||||
this.label3.Name = "label3";
|
||||
this.label3.Size = new System.Drawing.Size(35, 13);
|
||||
this.label3.TabIndex = 2;
|
||||
this.label3.Text = "Name";
|
||||
//
|
||||
// label4
|
||||
//
|
||||
this.label4.AutoSize = true;
|
||||
this.label4.Location = new System.Drawing.Point(11, 22);
|
||||
this.label4.Name = "label4";
|
||||
this.label4.Size = new System.Drawing.Size(32, 13);
|
||||
this.label4.TabIndex = 1;
|
||||
this.label4.Text = "Class";
|
||||
//
|
||||
// component2ClassNameComboBox
|
||||
//
|
||||
this.component2ClassNameComboBox.FormattingEnabled = true;
|
||||
this.component2ClassNameComboBox.Location = new System.Drawing.Point(77, 19);
|
||||
this.component2ClassNameComboBox.Name = "component2ClassNameComboBox";
|
||||
this.component2ClassNameComboBox.Size = new System.Drawing.Size(299, 21);
|
||||
this.component2ClassNameComboBox.TabIndex = 0;
|
||||
//
|
||||
// radioButton24
|
||||
//
|
||||
this.radioButton24.AutoSize = true;
|
||||
this.radioButton24.Location = new System.Drawing.Point(212, 118);
|
||||
this.radioButton24.Name = "radioButton24";
|
||||
this.radioButton24.Size = new System.Drawing.Size(51, 17);
|
||||
this.radioButton24.TabIndex = 9;
|
||||
this.radioButton24.TabStop = true;
|
||||
this.radioButton24.Text = "spare";
|
||||
this.radioButton24.UseVisualStyleBackColor = true;
|
||||
this.radioButton24.CheckedChanged += new System.EventHandler(this.radioButton24_CheckedChanged);
|
||||
//
|
||||
// radioButton23
|
||||
//
|
||||
this.radioButton23.AutoSize = true;
|
||||
this.radioButton23.Location = new System.Drawing.Point(212, 95);
|
||||
this.radioButton23.Name = "radioButton23";
|
||||
this.radioButton23.Size = new System.Drawing.Size(51, 17);
|
||||
this.radioButton23.TabIndex = 8;
|
||||
this.radioButton23.TabStop = true;
|
||||
this.radioButton23.Text = "spare";
|
||||
this.radioButton23.UseVisualStyleBackColor = true;
|
||||
this.radioButton23.CheckedChanged += new System.EventHandler(this.radioButton23_CheckedChanged);
|
||||
//
|
||||
// radioButton22
|
||||
//
|
||||
this.radioButton22.AutoSize = true;
|
||||
this.radioButton22.Location = new System.Drawing.Point(212, 72);
|
||||
this.radioButton22.Name = "radioButton22";
|
||||
this.radioButton22.Size = new System.Drawing.Size(51, 17);
|
||||
this.radioButton22.TabIndex = 7;
|
||||
this.radioButton22.TabStop = true;
|
||||
this.radioButton22.Text = "spare";
|
||||
this.radioButton22.UseVisualStyleBackColor = true;
|
||||
this.radioButton22.CheckedChanged += new System.EventHandler(this.radioButton22_CheckedChanged);
|
||||
//
|
||||
// radioButton21
|
||||
//
|
||||
this.radioButton21.AutoSize = true;
|
||||
this.radioButton21.Location = new System.Drawing.Point(212, 49);
|
||||
this.radioButton21.Name = "radioButton21";
|
||||
this.radioButton21.Size = new System.Drawing.Size(106, 17);
|
||||
this.radioButton21.TabIndex = 6;
|
||||
this.radioButton21.TabStop = true;
|
||||
this.radioButton21.Text = "ReadPressureOp";
|
||||
this.radioButton21.UseVisualStyleBackColor = true;
|
||||
this.radioButton21.CheckedChanged += new System.EventHandler(this.radioButton21_CheckedChanged);
|
||||
//
|
||||
// groupBox4
|
||||
//
|
||||
this.groupBox4.Controls.Add(this.radioButton34);
|
||||
this.groupBox4.Controls.Add(this.radioButton33);
|
||||
this.groupBox4.Controls.Add(this.radioButton32);
|
||||
this.groupBox4.Controls.Add(this.radioButton31);
|
||||
this.groupBox4.Controls.Add(this.radioButton24);
|
||||
this.groupBox4.Controls.Add(this.radioButton4);
|
||||
this.groupBox4.Controls.Add(this.radioButton23);
|
||||
this.groupBox4.Controls.Add(this.radioButton0);
|
||||
this.groupBox4.Controls.Add(this.radioButton22);
|
||||
this.groupBox4.Controls.Add(this.radioButton3);
|
||||
this.groupBox4.Controls.Add(this.radioButton21);
|
||||
this.groupBox4.Controls.Add(this.radioButton1);
|
||||
this.groupBox4.Controls.Add(this.radioButton2);
|
||||
this.groupBox4.Location = new System.Drawing.Point(12, 349);
|
||||
this.groupBox4.Name = "groupBox4";
|
||||
this.groupBox4.Size = new System.Drawing.Size(581, 145);
|
||||
this.groupBox4.TabIndex = 12;
|
||||
this.groupBox4.TabStop = false;
|
||||
this.groupBox4.Text = "Operations";
|
||||
//
|
||||
// radioButton34
|
||||
//
|
||||
this.radioButton34.AutoSize = true;
|
||||
this.radioButton34.Location = new System.Drawing.Point(405, 118);
|
||||
this.radioButton34.Name = "radioButton34";
|
||||
this.radioButton34.Size = new System.Drawing.Size(51, 17);
|
||||
this.radioButton34.TabIndex = 13;
|
||||
this.radioButton34.TabStop = true;
|
||||
this.radioButton34.Text = "spare";
|
||||
this.radioButton34.UseVisualStyleBackColor = true;
|
||||
this.radioButton34.CheckedChanged += new System.EventHandler(this.radioButton34_CheckedChanged);
|
||||
//
|
||||
// radioButton33
|
||||
//
|
||||
this.radioButton33.AutoSize = true;
|
||||
this.radioButton33.Location = new System.Drawing.Point(405, 95);
|
||||
this.radioButton33.Name = "radioButton33";
|
||||
this.radioButton33.Size = new System.Drawing.Size(51, 17);
|
||||
this.radioButton33.TabIndex = 12;
|
||||
this.radioButton33.TabStop = true;
|
||||
this.radioButton33.Text = "spare";
|
||||
this.radioButton33.UseVisualStyleBackColor = true;
|
||||
this.radioButton33.CheckedChanged += new System.EventHandler(this.radioButton33_CheckedChanged);
|
||||
//
|
||||
// radioButton32
|
||||
//
|
||||
this.radioButton32.AutoSize = true;
|
||||
this.radioButton32.Location = new System.Drawing.Point(405, 72);
|
||||
this.radioButton32.Name = "radioButton32";
|
||||
this.radioButton32.Size = new System.Drawing.Size(51, 17);
|
||||
this.radioButton32.TabIndex = 11;
|
||||
this.radioButton32.TabStop = true;
|
||||
this.radioButton32.Text = "spare";
|
||||
this.radioButton32.UseVisualStyleBackColor = true;
|
||||
this.radioButton32.CheckedChanged += new System.EventHandler(this.radioButton32_CheckedChanged);
|
||||
//
|
||||
// radioButton31
|
||||
//
|
||||
this.radioButton31.AutoSize = true;
|
||||
this.radioButton31.Location = new System.Drawing.Point(405, 49);
|
||||
this.radioButton31.Name = "radioButton31";
|
||||
this.radioButton31.Size = new System.Drawing.Size(106, 17);
|
||||
this.radioButton31.TabIndex = 10;
|
||||
this.radioButton31.TabStop = true;
|
||||
this.radioButton31.Text = "ReadPressureOp";
|
||||
this.radioButton31.UseVisualStyleBackColor = true;
|
||||
this.radioButton31.CheckedChanged += new System.EventHandler(this.radioButton31_CheckedChanged);
|
||||
//
|
||||
// groupBox5
|
||||
//
|
||||
this.groupBox5.Controls.Add(this.configureComponent3Button);
|
||||
this.groupBox5.Controls.Add(this.component3NameTextBox);
|
||||
this.groupBox5.Controls.Add(this.label5);
|
||||
this.groupBox5.Controls.Add(this.label6);
|
||||
this.groupBox5.Controls.Add(this.component3ClassNameComboBox);
|
||||
this.groupBox5.Location = new System.Drawing.Point(12, 255);
|
||||
this.groupBox5.Name = "groupBox5";
|
||||
this.groupBox5.Size = new System.Drawing.Size(486, 75);
|
||||
this.groupBox5.TabIndex = 13;
|
||||
this.groupBox5.TabStop = false;
|
||||
this.groupBox5.Text = "Component 3";
|
||||
//
|
||||
// configureComponent3Button
|
||||
//
|
||||
this.configureComponent3Button.Location = new System.Drawing.Point(395, 19);
|
||||
this.configureComponent3Button.Name = "configureComponent3Button";
|
||||
this.configureComponent3Button.Size = new System.Drawing.Size(73, 45);
|
||||
this.configureComponent3Button.TabIndex = 4;
|
||||
this.configureComponent3Button.Text = "Configure";
|
||||
this.configureComponent3Button.UseVisualStyleBackColor = true;
|
||||
this.configureComponent3Button.Click += new System.EventHandler(this.configureComponent3Button_Click);
|
||||
//
|
||||
// component3NameTextBox
|
||||
//
|
||||
this.component3NameTextBox.Enabled = false;
|
||||
this.component3NameTextBox.Location = new System.Drawing.Point(77, 44);
|
||||
this.component3NameTextBox.Name = "component3NameTextBox";
|
||||
this.component3NameTextBox.Size = new System.Drawing.Size(299, 20);
|
||||
this.component3NameTextBox.TabIndex = 3;
|
||||
//
|
||||
// label5
|
||||
//
|
||||
this.label5.AutoSize = true;
|
||||
this.label5.Location = new System.Drawing.Point(11, 47);
|
||||
this.label5.Name = "label5";
|
||||
this.label5.Size = new System.Drawing.Size(35, 13);
|
||||
this.label5.TabIndex = 2;
|
||||
this.label5.Text = "Name";
|
||||
//
|
||||
// label6
|
||||
//
|
||||
this.label6.AutoSize = true;
|
||||
this.label6.Location = new System.Drawing.Point(11, 22);
|
||||
this.label6.Name = "label6";
|
||||
this.label6.Size = new System.Drawing.Size(32, 13);
|
||||
this.label6.TabIndex = 1;
|
||||
this.label6.Text = "Class";
|
||||
//
|
||||
// component3ClassNameComboBox
|
||||
//
|
||||
this.component3ClassNameComboBox.FormattingEnabled = true;
|
||||
this.component3ClassNameComboBox.Location = new System.Drawing.Point(77, 19);
|
||||
this.component3ClassNameComboBox.Name = "component3ClassNameComboBox";
|
||||
this.component3ClassNameComboBox.Size = new System.Drawing.Size(299, 21);
|
||||
this.component3ClassNameComboBox.TabIndex = 0;
|
||||
//
|
||||
// DeviceTestDlg
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(613, 502);
|
||||
this.Controls.Add(this.groupBox5);
|
||||
this.Controls.Add(this.groupBox4);
|
||||
this.Controls.Add(this.groupBox3);
|
||||
this.Controls.Add(this.stopButton);
|
||||
this.Controls.Add(this.groupBox2);
|
||||
this.Controls.Add(this.startButton);
|
||||
this.Controls.Add(this.groupBox1);
|
||||
this.Name = "DeviceTestDlg";
|
||||
this.Text = "Device test";
|
||||
this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.DeviceTestDlg_FormClosing);
|
||||
this.Load += new System.EventHandler(this.DeviceTestDlg_Load);
|
||||
this.groupBox1.ResumeLayout(false);
|
||||
this.groupBox1.PerformLayout();
|
||||
this.groupBox2.ResumeLayout(false);
|
||||
this.groupBox2.PerformLayout();
|
||||
this.groupBox3.ResumeLayout(false);
|
||||
this.groupBox3.PerformLayout();
|
||||
this.groupBox4.ResumeLayout(false);
|
||||
this.groupBox4.PerformLayout();
|
||||
this.groupBox5.ResumeLayout(false);
|
||||
this.groupBox5.PerformLayout();
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private System.Windows.Forms.ComboBox parentClassNameComboBox;
|
||||
private System.Windows.Forms.Label classLabel;
|
||||
private System.Windows.Forms.Label nameLabel;
|
||||
private System.Windows.Forms.TextBox parentNameTextBox;
|
||||
private System.Windows.Forms.Button configureParentButton;
|
||||
private System.Windows.Forms.Button startButton;
|
||||
private System.Windows.Forms.GroupBox groupBox1;
|
||||
private System.Windows.Forms.GroupBox groupBox2;
|
||||
private System.Windows.Forms.Button configureComponent1Button;
|
||||
private System.Windows.Forms.TextBox componentNameTextBox;
|
||||
private System.Windows.Forms.Label label1;
|
||||
private System.Windows.Forms.Label label2;
|
||||
private System.Windows.Forms.ComboBox component1ClassNameComboBox;
|
||||
private System.Windows.Forms.RadioButton radioButton4;
|
||||
private System.Windows.Forms.RadioButton radioButton3;
|
||||
private System.Windows.Forms.RadioButton radioButton2;
|
||||
private System.Windows.Forms.RadioButton radioButton1;
|
||||
private System.Windows.Forms.RadioButton radioButton0;
|
||||
private System.Windows.Forms.Button stopButton;
|
||||
private System.Windows.Forms.GroupBox groupBox3;
|
||||
private System.Windows.Forms.RadioButton radioButton24;
|
||||
private System.Windows.Forms.RadioButton radioButton23;
|
||||
private System.Windows.Forms.RadioButton radioButton22;
|
||||
private System.Windows.Forms.RadioButton radioButton21;
|
||||
private System.Windows.Forms.Button configureComponent2Button;
|
||||
private System.Windows.Forms.TextBox component2NameTextBox;
|
||||
private System.Windows.Forms.Label label3;
|
||||
private System.Windows.Forms.Label label4;
|
||||
private System.Windows.Forms.ComboBox component2ClassNameComboBox;
|
||||
private System.Windows.Forms.GroupBox groupBox4;
|
||||
private System.Windows.Forms.GroupBox groupBox5;
|
||||
private System.Windows.Forms.Button configureComponent3Button;
|
||||
private System.Windows.Forms.TextBox component3NameTextBox;
|
||||
private System.Windows.Forms.Label label5;
|
||||
private System.Windows.Forms.Label label6;
|
||||
private System.Windows.Forms.ComboBox component3ClassNameComboBox;
|
||||
private System.Windows.Forms.RadioButton radioButton34;
|
||||
private System.Windows.Forms.RadioButton radioButton33;
|
||||
private System.Windows.Forms.RadioButton radioButton32;
|
||||
private System.Windows.Forms.RadioButton radioButton31;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,835 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
using System.IO;
|
||||
using System.Text;
|
||||
using System.Threading;
|
||||
using System.Windows.Forms;
|
||||
using TBF.BenchControl;
|
||||
using TBF.BenchControl.Generic;
|
||||
using TBF.BenchControl.GenericDevices;
|
||||
using System.Xml.Serialization;
|
||||
|
||||
|
||||
namespace DeviceTest
|
||||
{
|
||||
public partial class DeviceTestDlg : Form
|
||||
{
|
||||
IList<string> compClasses;
|
||||
|
||||
IComponentFactory parentFactory;
|
||||
IComponentFactory component1Factory;
|
||||
IComponentFactory component2Factory;
|
||||
IComponentFactory component3Factory;
|
||||
|
||||
IComponentCfg parentCfg;
|
||||
IComponentCfg component1Cfg;
|
||||
IComponentCfg component2Cfg;
|
||||
IComponentCfg component3Cfg;
|
||||
|
||||
static IList<TBF.BenchControl.Generic.IDevice> tbfDevices;
|
||||
static IList<TBF.BenchControl.Generic.IComponent> tbfComponents;
|
||||
static TBF.BenchControl.Generic.IComponent tbfComponent1forOp;
|
||||
static TBF.BenchControl.Generic.IComponent tbfComponent2forOp;
|
||||
static TBF.BenchControl.Generic.IComponent tbfComponent3forOp;
|
||||
|
||||
static Thread workerThread;
|
||||
static bool workerThreadRunning;
|
||||
|
||||
|
||||
static int activeOperationId;
|
||||
|
||||
static IOperation operation1;
|
||||
static IOperation operation2;
|
||||
static IOperation operation3;
|
||||
static IOperation operation4;
|
||||
|
||||
static IOperation operation21;
|
||||
static IOperation operation22;
|
||||
static IOperation operation23;
|
||||
static IOperation operation24;
|
||||
|
||||
static IOperation operation31;
|
||||
static IOperation operation32;
|
||||
static IOperation operation33;
|
||||
static IOperation operation34;
|
||||
|
||||
|
||||
static TBF.Boxes.FloatBox floatBox;
|
||||
static Event evnt;
|
||||
|
||||
|
||||
static DeviceTestDlg()
|
||||
{
|
||||
floatBox = new TBF.Boxes.FloatBox();
|
||||
floatBox.Format = "F2";
|
||||
}
|
||||
|
||||
public DeviceTestDlg()
|
||||
{
|
||||
InitializeComponent();
|
||||
compClasses = new List<string>();
|
||||
radioButton0.Checked = true;
|
||||
stopButton.Enabled = false;
|
||||
|
||||
foreach (var componentFactory in TbfComponents.Factories)
|
||||
{
|
||||
compClasses.Add(componentFactory.ClassName);
|
||||
}
|
||||
|
||||
tbfComponents = new List<TBF.BenchControl.Generic.IComponent>();
|
||||
tbfDevices = new List<IDevice>();
|
||||
}
|
||||
|
||||
private void DeviceTestDlg_Load(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
foreach (var clName in compClasses)
|
||||
{
|
||||
parentClassNameComboBox.Items.Add(clName);
|
||||
component1ClassNameComboBox.Items.Add(clName);
|
||||
component2ClassNameComboBox.Items.Add(clName);
|
||||
component3ClassNameComboBox.Items.Add(clName);
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
if (!string.IsNullOrEmpty(Program.LocalSettings.ParentClassName) &&
|
||||
!string.IsNullOrEmpty(Program.LocalSettings.ParentName) &&
|
||||
!string.IsNullOrEmpty(Program.LocalSettings.ParentSettings))
|
||||
{
|
||||
FactoryFromClassName(Program.LocalSettings.ParentClassName, ref parentFactory);
|
||||
|
||||
using (var reader = new StringReader(Program.LocalSettings.ParentSettings))
|
||||
{
|
||||
IComponentCfg config = (IComponentCfg)(new XmlSerializer(parentFactory.DefaultConfig().GetType())).Deserialize(reader);
|
||||
config.Name = Program.LocalSettings.ParentName;
|
||||
config.ParentName = string.Empty;
|
||||
config.ItemNr = 0;
|
||||
config.DebugLevel = Config.Entities.DebugMode.Normal;
|
||||
config.LogLevel = Config.Entities.LogLevel.Debug;
|
||||
config.Corrections = null;
|
||||
config.Factory = parentFactory;
|
||||
parentCfg = config;
|
||||
}
|
||||
|
||||
parentClassNameComboBox.Text = Program.LocalSettings.ParentClassName;
|
||||
parentNameTextBox.Text = Program.LocalSettings.ParentName;
|
||||
}
|
||||
}
|
||||
catch
|
||||
{
|
||||
parentFactory = null;
|
||||
parentCfg = null;
|
||||
parentClassNameComboBox.Text = string.Empty;
|
||||
parentNameTextBox.Text = string.Empty;
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
if (!string.IsNullOrEmpty(Program.LocalSettings.ComponentClassName) &&
|
||||
!string.IsNullOrEmpty(Program.LocalSettings.ComponentName) &&
|
||||
!string.IsNullOrEmpty(Program.LocalSettings.ComponentSettings))
|
||||
{
|
||||
FactoryFromClassName(Program.LocalSettings.ComponentClassName, ref component1Factory);
|
||||
|
||||
using (var reader = new StringReader(Program.LocalSettings.ComponentSettings))
|
||||
{
|
||||
IComponentCfg config = (IComponentCfg)(new XmlSerializer(component1Factory.DefaultConfig().GetType())).Deserialize(reader);
|
||||
config.Name = Program.LocalSettings.ComponentName;
|
||||
config.ParentName = string.IsNullOrEmpty(Program.LocalSettings.ComponentParentName) ? string.Empty : Program.LocalSettings.ComponentParentName;
|
||||
config.ItemNr = 1;
|
||||
config.DebugLevel = Config.Entities.DebugMode.Normal;
|
||||
config.LogLevel = Config.Entities.LogLevel.Debug;
|
||||
config.Corrections = null;
|
||||
config.Factory = component1Factory;
|
||||
component1Cfg = config;
|
||||
}
|
||||
|
||||
component1ClassNameComboBox.Text = Program.LocalSettings.ComponentClassName;
|
||||
componentNameTextBox.Text = Program.LocalSettings.ComponentName;
|
||||
|
||||
UpdateOperations(component1ClassNameComboBox.Text);
|
||||
}
|
||||
}
|
||||
catch
|
||||
{
|
||||
component1Factory = null;
|
||||
component1Cfg = null;
|
||||
component1ClassNameComboBox.Text = string.Empty;
|
||||
componentNameTextBox.Text = string.Empty;
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
if (!string.IsNullOrEmpty(Program.LocalSettings.Component2ClassName) &&
|
||||
!string.IsNullOrEmpty(Program.LocalSettings.Component2Name) &&
|
||||
!string.IsNullOrEmpty(Program.LocalSettings.Component2Settings))
|
||||
{
|
||||
FactoryFromClassName(Program.LocalSettings.Component2ClassName, ref component2Factory);
|
||||
|
||||
using (var reader = new StringReader(Program.LocalSettings.Component2Settings))
|
||||
{
|
||||
IComponentCfg config = (IComponentCfg)(new XmlSerializer(component2Factory.DefaultConfig().GetType())).Deserialize(reader);
|
||||
config.Name = Program.LocalSettings.Component2Name;
|
||||
config.ParentName = string.IsNullOrEmpty(Program.LocalSettings.Component2ParentName) ? string.Empty : Program.LocalSettings.Component2ParentName;
|
||||
config.ItemNr = 2;
|
||||
config.DebugLevel = Config.Entities.DebugMode.Normal;
|
||||
config.LogLevel = Config.Entities.LogLevel.Debug;
|
||||
config.Corrections = null;
|
||||
config.Factory = component2Factory;
|
||||
component2Cfg = config;
|
||||
}
|
||||
|
||||
component2ClassNameComboBox.Text = Program.LocalSettings.Component2ClassName;
|
||||
component2NameTextBox.Text = Program.LocalSettings.Component2Name;
|
||||
|
||||
UpdateOperations2(component2ClassNameComboBox.Text);
|
||||
}
|
||||
}
|
||||
catch
|
||||
{
|
||||
component2Factory = null;
|
||||
component2Cfg = null;
|
||||
component2ClassNameComboBox.Text = string.Empty;
|
||||
component2NameTextBox.Text = string.Empty;
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
if (!string.IsNullOrEmpty(Program.LocalSettings.Component3ClassName) &&
|
||||
!string.IsNullOrEmpty(Program.LocalSettings.Component3Name) &&
|
||||
!string.IsNullOrEmpty(Program.LocalSettings.Component3Settings))
|
||||
{
|
||||
FactoryFromClassName(Program.LocalSettings.Component3ClassName, ref component3Factory);
|
||||
|
||||
using (var reader = new StringReader(Program.LocalSettings.Component3Settings))
|
||||
{
|
||||
IComponentCfg config = (IComponentCfg)(new XmlSerializer(component3Factory.DefaultConfig().GetType())).Deserialize(reader);
|
||||
config.Name = Program.LocalSettings.Component3Name;
|
||||
config.ParentName = string.IsNullOrEmpty(Program.LocalSettings.Component3ParentName) ? string.Empty : Program.LocalSettings.Component3ParentName;
|
||||
config.ItemNr = 3;
|
||||
config.DebugLevel = Config.Entities.DebugMode.Normal;
|
||||
config.LogLevel = Config.Entities.LogLevel.Debug;
|
||||
config.Corrections = null;
|
||||
config.Factory = component3Factory;
|
||||
component3Cfg = config;
|
||||
}
|
||||
|
||||
component3ClassNameComboBox.Text = Program.LocalSettings.Component3ClassName;
|
||||
component3NameTextBox.Text = Program.LocalSettings.Component3Name;
|
||||
|
||||
UpdateOperations3(component3ClassNameComboBox.Text);
|
||||
}
|
||||
}
|
||||
catch
|
||||
{
|
||||
component3Factory = null;
|
||||
component3Cfg = null;
|
||||
component3ClassNameComboBox.Text = string.Empty;
|
||||
component3NameTextBox.Text = string.Empty;
|
||||
}
|
||||
}
|
||||
|
||||
void SaveSettings()
|
||||
{
|
||||
Program.LocalSettings.ParentClassName = parentClassNameComboBox.Text;
|
||||
Program.LocalSettings.ParentName = parentNameTextBox.Text;
|
||||
Program.LocalSettings.ParentSettings = (parentCfg != null) ? parentCfg.CreateDbEntity().Parameters : string.Empty;
|
||||
|
||||
Program.LocalSettings.ComponentClassName = component1ClassNameComboBox.Text;
|
||||
Program.LocalSettings.ComponentName = componentNameTextBox.Text;
|
||||
Program.LocalSettings.ComponentParentName = (component1Cfg != null) ? component1Cfg.ParentName : string.Empty;
|
||||
Program.LocalSettings.ComponentSettings = (component1Cfg != null) ? component1Cfg.CreateDbEntity().Parameters : string.Empty;
|
||||
|
||||
Program.LocalSettings.Component2ClassName = component2ClassNameComboBox.Text;
|
||||
Program.LocalSettings.Component2Name = component2NameTextBox.Text;
|
||||
Program.LocalSettings.Component2ParentName = (component2Cfg != null) ? component2Cfg.ParentName : string.Empty;
|
||||
Program.LocalSettings.Component2Settings = (component2Cfg != null) ? component2Cfg.CreateDbEntity().Parameters : string.Empty;
|
||||
|
||||
Program.LocalSettings.Component3ClassName = component3ClassNameComboBox.Text;
|
||||
Program.LocalSettings.Component3Name = component3NameTextBox.Text;
|
||||
Program.LocalSettings.Component3ParentName = (component3Cfg != null) ? component3Cfg.ParentName : string.Empty;
|
||||
Program.LocalSettings.Component3Settings = (component3Cfg != null) ? component3Cfg.CreateDbEntity().Parameters : string.Empty;
|
||||
|
||||
Program.LocalSettings.Save();
|
||||
}
|
||||
|
||||
|
||||
void UpdateOperations(string className)
|
||||
{
|
||||
if (className == "Keithley.TempMeter") radioButton1.Text = "ReadPressureOp";
|
||||
else if (className == "Network.Camera.CLP1611") radioButton1.Text = "Livestream";
|
||||
else if (className == "Network.Camera.Roi") radioButton1.Text = "RoiDetection";
|
||||
else if (className == "Modbus.Easytherm")
|
||||
{
|
||||
radioButton1.Text = "SetTemperature(10)";
|
||||
radioButton2.Text = "SetTemperature(20)";
|
||||
}
|
||||
else if (className == "Modbus.TankSelector")
|
||||
{
|
||||
radioButton1.Text = "SelectTank 1";
|
||||
radioButton2.Text = "SelectTank 2";
|
||||
radioButton3.Text = "SelectTank 3";
|
||||
radioButton4.Text = "SelectTank -";
|
||||
}
|
||||
else radioButton1.Text = "spare";
|
||||
}
|
||||
///
|
||||
void UpdateOperations2(string className)
|
||||
{
|
||||
if (className == "Keithley.TempMeter") radioButton21.Text = "ReadPressureOp";
|
||||
else if (className == "Network.Camera.CLP1611") radioButton21.Text = "Livestream";
|
||||
else if (className == "Network.Camera.Roi") radioButton21.Text = "RoiDetection";
|
||||
else if (className == "Modbus.Easytherm")
|
||||
{
|
||||
radioButton21.Text = "SetTemperature(10)";
|
||||
radioButton22.Text = "SetTemperature(20)";
|
||||
}
|
||||
else if (className == "Modbus.TankSelector")
|
||||
{
|
||||
radioButton21.Text = "SelectTank 1";
|
||||
radioButton22.Text = "SelectTank 2";
|
||||
radioButton23.Text = "SelectTank 3";
|
||||
radioButton24.Text = "SelectTank -";
|
||||
}
|
||||
else radioButton21.Text = "spare";
|
||||
}
|
||||
///
|
||||
void UpdateOperations3(string className)
|
||||
{
|
||||
if (className == "Keithley.TempMeter") radioButton31.Text = "ReadPressureOp";
|
||||
else if (className == "Network.Camera.CLP1611") radioButton31.Text = "Livestream";
|
||||
else if (className == "Network.Camera.Roi") radioButton31.Text = "RoiDetection";
|
||||
else if (className == "Modbus.Easytherm")
|
||||
{
|
||||
radioButton31.Text = "SetTemperature(10)";
|
||||
radioButton32.Text = "SetTemperature(20)";
|
||||
}
|
||||
else if (className == "Modbus.TankSelector")
|
||||
{
|
||||
radioButton31.Text = "SelectTank 1";
|
||||
radioButton32.Text = "SelectTank 2";
|
||||
radioButton33.Text = "SelectTank 3";
|
||||
radioButton34.Text = "SelectTank -";
|
||||
}
|
||||
else radioButton31.Text = "spare";
|
||||
}
|
||||
|
||||
|
||||
int GetActiveOperationId()
|
||||
{
|
||||
if (radioButton1.Checked) { return 1; }
|
||||
else if (radioButton2.Checked) { return 2; }
|
||||
else if (radioButton3.Checked) { return 3; }
|
||||
else if (radioButton4.Checked) { return 4; }
|
||||
else if (radioButton21.Checked) { return 21; }
|
||||
else if (radioButton22.Checked) { return 22; }
|
||||
else if (radioButton23.Checked) { return 23; }
|
||||
else if (radioButton24.Checked) { return 24; }
|
||||
else if (radioButton31.Checked) { return 31; }
|
||||
else if (radioButton32.Checked) { return 32; }
|
||||
else if (radioButton33.Checked) { return 33; }
|
||||
else if (radioButton34.Checked) { return 34; }
|
||||
else return 0; /// stopOperationRadioButton.Checked
|
||||
}
|
||||
|
||||
|
||||
private void radioButton0_CheckedChanged(object sender, EventArgs e) { activeOperationId = GetActiveOperationId(); }
|
||||
private void radioButton1_CheckedChanged(object sender, EventArgs e) { activeOperationId = GetActiveOperationId(); }
|
||||
private void radioButton2_CheckedChanged(object sender, EventArgs e) { activeOperationId = GetActiveOperationId(); }
|
||||
private void radioButton3_CheckedChanged(object sender, EventArgs e) { activeOperationId = GetActiveOperationId(); }
|
||||
private void radioButton4_CheckedChanged(object sender, EventArgs e) { activeOperationId = GetActiveOperationId(); }
|
||||
///
|
||||
private void radioButton21_CheckedChanged(object sender, EventArgs e) { activeOperationId = GetActiveOperationId(); }
|
||||
private void radioButton22_CheckedChanged(object sender, EventArgs e) { activeOperationId = GetActiveOperationId(); }
|
||||
private void radioButton23_CheckedChanged(object sender, EventArgs e) { activeOperationId = GetActiveOperationId(); }
|
||||
private void radioButton24_CheckedChanged(object sender, EventArgs e) { activeOperationId = GetActiveOperationId(); }
|
||||
///
|
||||
private void radioButton31_CheckedChanged(object sender, EventArgs e) { activeOperationId = GetActiveOperationId(); }
|
||||
private void radioButton32_CheckedChanged(object sender, EventArgs e) { activeOperationId = GetActiveOperationId(); }
|
||||
private void radioButton33_CheckedChanged(object sender, EventArgs e) { activeOperationId = GetActiveOperationId(); }
|
||||
private void radioButton34_CheckedChanged(object sender, EventArgs e) { activeOperationId = GetActiveOperationId(); }
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Updates component factory
|
||||
/// </summary>
|
||||
/// <param name="className">Component class name</param>
|
||||
/// <param name="factory">Reference to a factory</param>
|
||||
/// <returns>true when factory changed</returns>
|
||||
bool FactoryFromClassName(string className, ref IComponentFactory factory)
|
||||
{
|
||||
foreach (var fac in TbfComponents.Factories)
|
||||
{
|
||||
if (className == fac.ClassName)
|
||||
{
|
||||
if (factory != fac)
|
||||
{
|
||||
factory = fac;
|
||||
return true;
|
||||
}
|
||||
else
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (factory != null)
|
||||
{
|
||||
factory = null;
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
private void configureParentButton_Click(object sender, EventArgs e)
|
||||
{
|
||||
bool factoryChanged = FactoryFromClassName(parentClassNameComboBox.Text, ref parentFactory);
|
||||
if (parentFactory == null)
|
||||
{
|
||||
MessageBox.Show("Invalid parent class", "Error", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
|
||||
return;
|
||||
}
|
||||
|
||||
if (factoryChanged || parentCfg == null)
|
||||
{
|
||||
parentCfg = parentFactory.DefaultConfig();
|
||||
}
|
||||
IComponentCfgCtrl cfgControl = parentCfg.GetControl();
|
||||
cfgControl.Config = parentCfg;
|
||||
cfgControl.Config.ItemNr = 0;
|
||||
|
||||
TBF.ComponentParametersDlg cfgForm = new TBF.ComponentParametersDlg();
|
||||
cfgForm.TbfComponents = new List<Config.Entities.Component>();
|
||||
|
||||
cfgForm.ComponentCfgCtrl = cfgControl;
|
||||
cfgForm.UnlockAfterStart = true;
|
||||
DialogResult dr = cfgForm.ShowDialog();
|
||||
if (dr != DialogResult.OK) return;
|
||||
|
||||
parentNameTextBox.Text = parentCfg.Name;
|
||||
}
|
||||
|
||||
|
||||
private void configureComponent1Button_Click(object sender, EventArgs e)
|
||||
{
|
||||
bool factoryChanged = FactoryFromClassName(component1ClassNameComboBox.Text, ref component1Factory);
|
||||
if (component1Factory == null)
|
||||
{
|
||||
MessageBox.Show("Invalid component class", "Error", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
|
||||
return;
|
||||
}
|
||||
|
||||
if (factoryChanged || component1Cfg == null)
|
||||
{
|
||||
component1Cfg = component1Factory.DefaultConfig();
|
||||
}
|
||||
IComponentCfgCtrl cfgControl = component1Cfg.GetControl();
|
||||
cfgControl.Config = component1Cfg;
|
||||
cfgControl.Config.ItemNr = 1;
|
||||
|
||||
TBF.ComponentParametersDlg cfgForm = new TBF.ComponentParametersDlg();
|
||||
///
|
||||
IList<Config.Entities.Component> compEntities = new List<Config.Entities.Component>();
|
||||
if (parentFactory != null && parentCfg != null) compEntities.Add(parentCfg.CreateDbEntity());
|
||||
cfgForm.TbfComponents = compEntities;
|
||||
|
||||
cfgForm.ComponentCfgCtrl = cfgControl;
|
||||
cfgForm.UnlockAfterStart = true;
|
||||
DialogResult dr = cfgForm.ShowDialog();
|
||||
if (dr != DialogResult.OK) return;
|
||||
|
||||
componentNameTextBox.Text = component1Cfg.Name;
|
||||
|
||||
UpdateOperations(component1ClassNameComboBox.Text);
|
||||
}
|
||||
|
||||
|
||||
private void configureComponent2Button_Click(object sender, EventArgs e)
|
||||
{
|
||||
bool factoryChanged = FactoryFromClassName(component2ClassNameComboBox.Text, ref component2Factory);
|
||||
if (component2Factory == null)
|
||||
{
|
||||
MessageBox.Show("Invalid component class", "Error", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
|
||||
return;
|
||||
}
|
||||
|
||||
if (factoryChanged || component2Cfg == null)
|
||||
{
|
||||
component2Cfg = component2Factory.DefaultConfig();
|
||||
}
|
||||
IComponentCfgCtrl cfgControl = component2Cfg.GetControl();
|
||||
cfgControl.Config = component2Cfg;
|
||||
cfgControl.Config.ItemNr = 1;
|
||||
|
||||
TBF.ComponentParametersDlg cfgForm = new TBF.ComponentParametersDlg();
|
||||
///
|
||||
IList<Config.Entities.Component> compEntities = new List<Config.Entities.Component>();
|
||||
if (parentFactory != null && parentCfg != null) compEntities.Add(parentCfg.CreateDbEntity());
|
||||
if (component1Factory != null && component1Cfg != null) compEntities.Add(component1Cfg.CreateDbEntity());
|
||||
cfgForm.TbfComponents = compEntities;
|
||||
|
||||
cfgForm.ComponentCfgCtrl = cfgControl;
|
||||
cfgForm.UnlockAfterStart = true;
|
||||
DialogResult dr = cfgForm.ShowDialog();
|
||||
if (dr != DialogResult.OK) return;
|
||||
|
||||
component2NameTextBox.Text = component2Cfg.Name;
|
||||
|
||||
UpdateOperations2(component2ClassNameComboBox.Text);
|
||||
}
|
||||
|
||||
|
||||
private void configureComponent3Button_Click(object sender, EventArgs e)
|
||||
{
|
||||
bool factoryChanged = FactoryFromClassName(component3ClassNameComboBox.Text, ref component3Factory);
|
||||
if (component3Factory == null)
|
||||
{
|
||||
MessageBox.Show("Invalid component class", "Error", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
|
||||
return;
|
||||
}
|
||||
|
||||
if (factoryChanged || component3Cfg == null)
|
||||
{
|
||||
component3Cfg = component3Factory.DefaultConfig();
|
||||
}
|
||||
IComponentCfgCtrl cfgControl = component3Cfg.GetControl();
|
||||
cfgControl.Config = component3Cfg;
|
||||
cfgControl.Config.ItemNr = 1;
|
||||
|
||||
TBF.ComponentParametersDlg cfgForm = new TBF.ComponentParametersDlg();
|
||||
///
|
||||
IList<Config.Entities.Component> compEntities = new List<Config.Entities.Component>();
|
||||
if (parentFactory != null && parentCfg != null) compEntities.Add(parentCfg.CreateDbEntity());
|
||||
if (component1Factory != null && component1Cfg != null) compEntities.Add(component1Cfg.CreateDbEntity());
|
||||
if (component2Factory != null && component2Cfg != null) compEntities.Add(component2Cfg.CreateDbEntity());
|
||||
cfgForm.TbfComponents = compEntities;
|
||||
|
||||
cfgForm.ComponentCfgCtrl = cfgControl;
|
||||
cfgForm.UnlockAfterStart = true;
|
||||
DialogResult dr = cfgForm.ShowDialog();
|
||||
if (dr != DialogResult.OK) return;
|
||||
|
||||
component3NameTextBox.Text = component3Cfg.Name;
|
||||
|
||||
UpdateOperations3(component3ClassNameComboBox.Text);
|
||||
}
|
||||
|
||||
|
||||
private void startButton_Click(object sender, EventArgs e)
|
||||
{
|
||||
tbfComponents.Clear();
|
||||
tbfDevices.Clear();
|
||||
tbfComponent1forOp = null;
|
||||
operation1 = null;
|
||||
operation2 = null;
|
||||
operation3 = null;
|
||||
operation4 = null;
|
||||
tbfComponent2forOp = null;
|
||||
operation21 = null;
|
||||
operation22 = null;
|
||||
operation23 = null;
|
||||
operation24 = null;
|
||||
tbfComponent3forOp = null;
|
||||
operation31 = null;
|
||||
operation32 = null;
|
||||
operation33 = null;
|
||||
operation34 = null;
|
||||
workerThreadRunning = false;
|
||||
|
||||
string initializedDeviceName = "none";
|
||||
try
|
||||
{
|
||||
if (parentFactory != null && parentCfg != null)
|
||||
{
|
||||
TBF.BenchControl.Generic.IComponent component = parentFactory.GetComponent(parentCfg, tbfComponents);
|
||||
tbfComponents.Add(component);
|
||||
IDevice dev = component as IDevice;
|
||||
if (dev != null)
|
||||
{
|
||||
initializedDeviceName = dev.Name;
|
||||
dev.Initialize();
|
||||
tbfDevices.Add(dev);
|
||||
}
|
||||
}
|
||||
if (component1Factory != null && component1Cfg != null)
|
||||
{
|
||||
TBF.BenchControl.Generic.IComponent component = component1Factory.GetComponent(component1Cfg, tbfComponents);
|
||||
tbfComponents.Add(component);
|
||||
tbfComponent1forOp = component;
|
||||
IDevice dev = component as IDevice;
|
||||
if (dev != null)
|
||||
{
|
||||
initializedDeviceName = dev.Name;
|
||||
dev.Initialize();
|
||||
tbfDevices.Add(dev);
|
||||
}
|
||||
}
|
||||
if (component2Factory != null && component2Cfg != null)
|
||||
{
|
||||
TBF.BenchControl.Generic.IComponent component2 = component2Factory.GetComponent(component2Cfg, tbfComponents);
|
||||
tbfComponents.Add(component2);
|
||||
tbfComponent2forOp = component2;
|
||||
IDevice dev = component2 as IDevice;
|
||||
if (dev != null)
|
||||
{
|
||||
initializedDeviceName = dev.Name;
|
||||
dev.Initialize();
|
||||
tbfDevices.Add(dev);
|
||||
}
|
||||
}
|
||||
if (component3Factory != null && component3Cfg != null)
|
||||
{
|
||||
TBF.BenchControl.Generic.IComponent component3 = component3Factory.GetComponent(component3Cfg, tbfComponents);
|
||||
tbfComponents.Add(component3);
|
||||
tbfComponent3forOp = component3;
|
||||
IDevice dev = component3 as IDevice;
|
||||
if (dev != null)
|
||||
{
|
||||
initializedDeviceName = dev.Name;
|
||||
dev.Initialize();
|
||||
tbfDevices.Add(dev);
|
||||
}
|
||||
}
|
||||
|
||||
if (tbfComponents.Count == 0) throw new Exception("There are no components");
|
||||
|
||||
SaveSettings(); /// Save settings after successful initialization
|
||||
|
||||
workerThread = new Thread(Worker);
|
||||
workerThread.CurrentCulture = Thread.CurrentThread.CurrentCulture;
|
||||
workerThread.CurrentUICulture = Thread.CurrentThread.CurrentUICulture;
|
||||
workerThreadRunning = true;
|
||||
workerThread.Start();
|
||||
|
||||
startButton.Enabled = false;
|
||||
stopButton.Enabled = true;
|
||||
configureComponent2Button.Enabled = false;
|
||||
configureComponent1Button.Enabled = false;
|
||||
configureParentButton.Enabled = false;
|
||||
}
|
||||
catch (Exception exc)
|
||||
{
|
||||
workerThreadRunning = false;
|
||||
workerThread = null;
|
||||
|
||||
MessageBox.Show(exc.Message,
|
||||
string.Format("'{0}' initialization failed", initializedDeviceName),
|
||||
MessageBoxButtons.OK,
|
||||
MessageBoxIcon.Exclamation);
|
||||
|
||||
foreach (var dev in tbfDevices) dev.StopDevice();
|
||||
tbfDevices.Clear();
|
||||
|
||||
startButton.Enabled = true;
|
||||
stopButton.Enabled = false;
|
||||
configureComponent2Button.Enabled = true;
|
||||
configureComponent1Button.Enabled = true;
|
||||
configureParentButton.Enabled = true;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static void Worker()
|
||||
{
|
||||
int activeOperationLocal = 0;
|
||||
int previousOperation = 0;
|
||||
|
||||
|
||||
if (tbfComponent1forOp is TBF.BenchControl.Modbus.PressureMeter.Meret.PressureMeter)
|
||||
{
|
||||
operation1 = (tbfComponent1forOp as TBF.BenchControl.Modbus.PressureMeter.Meret.PressureMeter).ReadPressureOp(ref floatBox);
|
||||
}
|
||||
else if (tbfComponent1forOp is TBF.BenchControl.Network.Camera.CLP1611.Camera)
|
||||
{
|
||||
operation1 = (tbfComponent1forOp as TBF.BenchControl.Network.Camera.CLP1611.Camera).LiveStreamOp(false);
|
||||
operation2 = (tbfComponent1forOp as TBF.BenchControl.Network.Camera.CLP1611.Camera).LiveStreamOp(true);
|
||||
}
|
||||
else if (tbfComponent1forOp is TBF.BenchControl.Network.Camera.Roi.Roi)
|
||||
{
|
||||
operation1 = (tbfComponent1forOp as TBF.BenchControl.Network.Camera.Roi.Roi).RoiDetectionOp();
|
||||
}
|
||||
else if (tbfComponent1forOp is TBF.BenchControl.Modbus.Easytherm.Easytherm)
|
||||
{
|
||||
operation1 = (tbfComponent1forOp as TBF.BenchControl.Modbus.Easytherm.Easytherm).SetTemperatureOp(10);
|
||||
operation2 = (tbfComponent1forOp as TBF.BenchControl.Modbus.Easytherm.Easytherm).SetTemperatureOp(20);
|
||||
}
|
||||
else if (tbfComponent1forOp is TBF.BenchControl.Modbus.TankSelector.TankSelector)
|
||||
{
|
||||
//operation1 = (tbfComponent1forOp as TBF.BenchControl.Modbus.TankSelector.TankSelector).SelectTankOp(1);
|
||||
//operation2 = (tbfComponent1forOp as TBF.BenchControl.Modbus.TankSelector.TankSelector).SelectTankOp(2);
|
||||
//operation3 = (tbfComponent1forOp as TBF.BenchControl.Modbus.TankSelector.TankSelector).SelectTankOp(3);
|
||||
//operation4 = (tbfComponent1forOp as TBF.BenchControl.Modbus.TankSelector.TankSelector).SelectTankOp(0);
|
||||
}
|
||||
|
||||
|
||||
if (tbfComponent2forOp is TBF.BenchControl.Modbus.PressureMeter.Meret.PressureMeter)
|
||||
{
|
||||
operation21 = (tbfComponent2forOp as TBF.BenchControl.Modbus.PressureMeter.Meret.PressureMeter).ReadPressureOp(ref floatBox);
|
||||
}
|
||||
else if (tbfComponent2forOp is TBF.BenchControl.Network.Camera.CLP1611.Camera)
|
||||
{
|
||||
operation21 = (tbfComponent2forOp as TBF.BenchControl.Network.Camera.CLP1611.Camera).LiveStreamOp(false);
|
||||
operation22 = (tbfComponent2forOp as TBF.BenchControl.Network.Camera.CLP1611.Camera).LiveStreamOp(true);
|
||||
}
|
||||
else if (tbfComponent2forOp is TBF.BenchControl.Network.Camera.Roi.Roi)
|
||||
{
|
||||
operation21 = (tbfComponent2forOp as TBF.BenchControl.Network.Camera.Roi.Roi).RoiDetectionOp();
|
||||
}
|
||||
else if (tbfComponent2forOp is TBF.BenchControl.Modbus.Easytherm.Easytherm)
|
||||
{
|
||||
operation21 = (tbfComponent1forOp as TBF.BenchControl.Modbus.Easytherm.Easytherm).SetTemperatureOp(10);
|
||||
operation22 = (tbfComponent1forOp as TBF.BenchControl.Modbus.Easytherm.Easytherm).SetTemperatureOp(20);
|
||||
}
|
||||
else if (tbfComponent2forOp is TBF.BenchControl.Modbus.TankSelector.TankSelector)
|
||||
{
|
||||
//operation21 = (tbfComponent2forOp as TBF.BenchControl.Modbus.TankSelector.TankSelector).SelectTankOp(1);
|
||||
//operation22 = (tbfComponent2forOp as TBF.BenchControl.Modbus.TankSelector.TankSelector).SelectTankOp(2);
|
||||
//operation23 = (tbfComponent2forOp as TBF.BenchControl.Modbus.TankSelector.TankSelector).SelectTankOp(3);
|
||||
//operation24 = (tbfComponent2forOp as TBF.BenchControl.Modbus.TankSelector.TankSelector).SelectTankOp(0);
|
||||
}
|
||||
|
||||
|
||||
if (tbfComponent3forOp is TBF.BenchControl.Modbus.PressureMeter.Meret.PressureMeter)
|
||||
{
|
||||
operation31 = (tbfComponent3forOp as TBF.BenchControl.Modbus.PressureMeter.Meret.PressureMeter).ReadPressureOp(ref floatBox);
|
||||
}
|
||||
else if (tbfComponent3forOp is TBF.BenchControl.Network.Camera.CLP1611.Camera)
|
||||
{
|
||||
operation31 = (tbfComponent3forOp as TBF.BenchControl.Network.Camera.CLP1611.Camera).LiveStreamOp(false);
|
||||
operation33 = (tbfComponent3forOp as TBF.BenchControl.Network.Camera.CLP1611.Camera).LiveStreamOp(true);
|
||||
}
|
||||
else if (tbfComponent3forOp is TBF.BenchControl.Network.Camera.Roi.Roi)
|
||||
{
|
||||
operation31 = (tbfComponent3forOp as TBF.BenchControl.Network.Camera.Roi.Roi).RoiDetectionOp();
|
||||
}
|
||||
else if (tbfComponent3forOp is TBF.BenchControl.Modbus.Easytherm.Easytherm)
|
||||
{
|
||||
operation31 = (tbfComponent1forOp as TBF.BenchControl.Modbus.Easytherm.Easytherm).SetTemperatureOp(10);
|
||||
operation32 = (tbfComponent1forOp as TBF.BenchControl.Modbus.Easytherm.Easytherm).SetTemperatureOp(20);
|
||||
}
|
||||
else if (tbfComponent3forOp is TBF.BenchControl.Modbus.TankSelector.TankSelector)
|
||||
{
|
||||
//operation31 = (tbfComponent3forOp as TBF.BenchControl.Modbus.TankSelector.TankSelector).SelectTankOp(1);
|
||||
//operation32 = (tbfComponent3forOp as TBF.BenchControl.Modbus.TankSelector.TankSelector).SelectTankOp(2);
|
||||
//operation33 = (tbfComponent3forOp as TBF.BenchControl.Modbus.TankSelector.TankSelector).SelectTankOp(3);
|
||||
//operation34 = (tbfComponent3forOp as TBF.BenchControl.Modbus.TankSelector.TankSelector).SelectTankOp(0);
|
||||
}
|
||||
|
||||
|
||||
while (workerThreadRunning)
|
||||
{
|
||||
Thread.Sleep(1000);
|
||||
|
||||
if (workerThreadRunning)
|
||||
{
|
||||
foreach (var d in tbfDevices) d.RunDeviceBefore();
|
||||
|
||||
if (tbfComponent1forOp != null)
|
||||
{
|
||||
previousOperation = activeOperationLocal;
|
||||
activeOperationLocal = activeOperationId;
|
||||
if (previousOperation == 0 && activeOperationLocal != 0)
|
||||
{
|
||||
switch (activeOperationLocal)
|
||||
{
|
||||
case 1: if (operation1 != null) operation1.Start(); Debug.WriteLine("op1.Start()"); break;
|
||||
case 2: if (operation2 != null) operation2.Start(); Debug.WriteLine("op2.Start()"); break;
|
||||
case 3: if (operation3 != null) operation3.Start(); Debug.WriteLine("op3.Start()"); break;
|
||||
case 4: if (operation4 != null) operation4.Start(); Debug.WriteLine("op4.Start()"); break;
|
||||
case 21: if (operation21 != null) operation21.Start(); Debug.WriteLine("op21.Start()"); break;
|
||||
case 22: if (operation22 != null) operation22.Start(); Debug.WriteLine("op22.Start()"); break;
|
||||
case 23: if (operation23 != null) operation23.Start(); Debug.WriteLine("op23.Start()"); break;
|
||||
case 24: if (operation24 != null) operation24.Start(); Debug.WriteLine("op24.Start()"); break;
|
||||
case 31: if (operation31 != null) operation31.Start(); Debug.WriteLine("op31.Start()"); break;
|
||||
case 32: if (operation32 != null) operation32.Start(); Debug.WriteLine("op32.Start()"); break;
|
||||
case 33: if (operation33 != null) operation33.Start(); Debug.WriteLine("op33.Start()"); break;
|
||||
case 34: if (operation34 != null) operation34.Start(); Debug.WriteLine("op34.Start()"); break;
|
||||
}
|
||||
}
|
||||
else if (previousOperation == activeOperationLocal && activeOperationLocal != 0)
|
||||
{
|
||||
switch (activeOperationLocal)
|
||||
{
|
||||
case 1: if (operation1 != null) evnt = operation1.Run(); Debug.WriteLine("op1.Run() -> {0}", evnt); break;
|
||||
case 2: if (operation2 != null) evnt = operation2.Run(); Debug.WriteLine("op2.Run() -> {0}", evnt); break;
|
||||
case 3: if (operation3 != null) evnt = operation3.Run(); Debug.WriteLine("op3.Run() -> {0}", evnt); break;
|
||||
case 4: if (operation4 != null) evnt = operation4.Run(); Debug.WriteLine("op4.Run() -> {0}", evnt); break;
|
||||
case 21: if (operation21 != null) evnt = operation21.Run(); Debug.WriteLine("op21.Run() -> {0}", evnt); break;
|
||||
case 22: if (operation22 != null) evnt = operation22.Run(); Debug.WriteLine("op22.Run() -> {0}", evnt); break;
|
||||
case 23: if (operation23 != null) evnt = operation23.Run(); Debug.WriteLine("op23.Run() -> {0}", evnt); break;
|
||||
case 24: if (operation24 != null) evnt = operation24.Run(); Debug.WriteLine("op24.Run() -> {0}", evnt); break;
|
||||
case 31: if (operation31 != null) evnt = operation31.Run(); Debug.WriteLine("op31.Run() -> {0}", evnt); break;
|
||||
case 32: if (operation32 != null) evnt = operation32.Run(); Debug.WriteLine("op32.Run() -> {0}", evnt); break;
|
||||
case 33: if (operation33 != null) evnt = operation33.Run(); Debug.WriteLine("op33.Run() -> {0}", evnt); break;
|
||||
case 34: if (operation34 != null) evnt = operation34.Run(); Debug.WriteLine("op34.Run() -> {0}", evnt); break;
|
||||
default: evnt = Event.None; break;
|
||||
}
|
||||
}
|
||||
else if (previousOperation != 0 && activeOperationLocal == 0)
|
||||
{
|
||||
switch (previousOperation)
|
||||
{
|
||||
case 1: if (operation1 != null) operation1.Stop(); Debug.WriteLine("op1.Stop()"); break;
|
||||
case 2: if (operation2 != null) operation2.Stop(); Debug.WriteLine("op2.Stop()"); break;
|
||||
case 3: if (operation3 != null) operation3.Stop(); Debug.WriteLine("op3.Stop()"); break;
|
||||
case 4: if (operation4 != null) operation4.Stop(); Debug.WriteLine("op4.Stop()"); break;
|
||||
case 21: if (operation21 != null) operation21.Stop(); Debug.WriteLine("op21.Stop()"); break;
|
||||
case 22: if (operation22 != null) operation22.Stop(); Debug.WriteLine("op22.Stop()"); break;
|
||||
case 23: if (operation23 != null) operation23.Stop(); Debug.WriteLine("op23.Stop()"); break;
|
||||
case 24: if (operation24 != null) operation24.Stop(); Debug.WriteLine("op24.Stop()"); break;
|
||||
case 31: if (operation31 != null) operation31.Stop(); Debug.WriteLine("op31.Stop()"); break;
|
||||
case 32: if (operation32 != null) operation32.Stop(); Debug.WriteLine("op32.Stop()"); break;
|
||||
case 33: if (operation33 != null) operation33.Stop(); Debug.WriteLine("op33.Stop()"); break;
|
||||
case 34: if (operation34 != null) operation34.Stop(); Debug.WriteLine("op34.Stop()"); break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
foreach (var d in tbfDevices) d.RunDeviceAfter();
|
||||
}
|
||||
}
|
||||
|
||||
foreach (var d in tbfDevices) d.StopDevice();
|
||||
}
|
||||
|
||||
private void stopButton_Click(object sender, EventArgs e)
|
||||
{
|
||||
Cursor = Cursors.WaitCursor;
|
||||
|
||||
workerThreadRunning = false;
|
||||
workerThread.Join(5000);
|
||||
workerThread = null;
|
||||
|
||||
Cursor = Cursors.Default;
|
||||
|
||||
startButton.Enabled = true;
|
||||
stopButton.Enabled = false;
|
||||
configureParentButton.Enabled = true;
|
||||
configureComponent1Button.Enabled = true;
|
||||
configureComponent2Button.Enabled = true;
|
||||
configureComponent3Button.Enabled = true;
|
||||
}
|
||||
|
||||
private void DeviceTestDlg_FormClosing(object sender, FormClosingEventArgs e)
|
||||
{
|
||||
Cursor = Cursors.WaitCursor;
|
||||
|
||||
if (workerThread != null)
|
||||
{
|
||||
workerThreadRunning = false;
|
||||
workerThread.Join(3000);
|
||||
workerThread = null;
|
||||
}
|
||||
|
||||
Cursor = Cursors.Default;
|
||||
|
||||
SaveSettings();
|
||||
|
||||
Cursor = Cursors.Default;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,126 +0,0 @@
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Text;
|
||||
using System.Xml.Serialization;
|
||||
|
||||
namespace DeviceTest
|
||||
{
|
||||
/// <summary>
|
||||
/// Class to be serialized to an XML file...
|
||||
/// </summary>
|
||||
[XmlRootAttribute("DeviceTest")]
|
||||
public class LocalSettings
|
||||
{
|
||||
public string ParentClassName;
|
||||
public string ParentName;
|
||||
public string ParentSettings;
|
||||
|
||||
public string ComponentClassName;
|
||||
public string ComponentName;
|
||||
public string ComponentParentName;
|
||||
public string ComponentSettings;
|
||||
|
||||
public string Component2ClassName;
|
||||
public string Component2Name;
|
||||
public string Component2ParentName;
|
||||
public string Component2Settings;
|
||||
|
||||
public string Component3ClassName;
|
||||
public string Component3Name;
|
||||
public string Component3ParentName;
|
||||
public string Component3Settings;
|
||||
|
||||
public LocalSettings()
|
||||
{
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Load public fields of this class from the XML file.
|
||||
/// </summary>
|
||||
/// <returns>LocalSettings object or null when Load() fails</returns>
|
||||
public static LocalSettings Load(string fileName)
|
||||
{
|
||||
try
|
||||
{
|
||||
using (TextReader reader = new StreamReader(fileName))
|
||||
{
|
||||
LocalSettings ls = (new XmlSerializer(typeof(LocalSettings))).Deserialize(reader) as LocalSettings;
|
||||
// Copy the settings just in case De-serialize() completes OK
|
||||
return ls;
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
string msg = e.Message;
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Save public fields of this class to the XML file.
|
||||
/// </summary>
|
||||
public void Save()
|
||||
{
|
||||
try
|
||||
{
|
||||
using (TextWriter writer = new StreamWriter(Program.LocalSettingsFileName))
|
||||
{
|
||||
(new XmlSerializer(typeof(LocalSettings))).Serialize(writer, this);
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
string msg = e.Message;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Updates history stored in a string array by a new latest string.
|
||||
/// </summary>
|
||||
/// <param name="lastStrValue">Last entered string</param>
|
||||
/// <returns>true = updated and saved</returns>
|
||||
public bool UpdateHistory(string lastStrValue, ref string[] history)
|
||||
{
|
||||
const int MaxHistoryLen = 10;
|
||||
|
||||
if (string.IsNullOrEmpty(lastStrValue)) return false;
|
||||
|
||||
int currentHistoryLength = (history != null) ? history.Length : 0;
|
||||
|
||||
int match = -1;
|
||||
for (int i = 0; i < currentHistoryLength; i++)
|
||||
{
|
||||
if (history[i] == lastStrValue)
|
||||
{
|
||||
match = i;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (match >= 0 || currentHistoryLength >= MaxHistoryLen)
|
||||
{
|
||||
/// History does not have to be extended (because of a match) or should not be extended (because of the lenght)
|
||||
if (match < 0) match = currentHistoryLength - 1;
|
||||
|
||||
for (int j = match; j > 0; j--)
|
||||
{
|
||||
history[j] = history[j - 1];
|
||||
}
|
||||
history[0] = lastStrValue;
|
||||
}
|
||||
else
|
||||
{
|
||||
/// History will be extended, new item inserted at the beginning
|
||||
string[] newHistory = new string[currentHistoryLength + 1];
|
||||
newHistory[0] = lastStrValue;
|
||||
for (int j = 1; j <= currentHistoryLength; j++)
|
||||
{
|
||||
newHistory[j] = history[j - 1];
|
||||
}
|
||||
history = newHistory;
|
||||
}
|
||||
Save();
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,111 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2016-2017 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Windows.Forms;
|
||||
using log4net;
|
||||
|
||||
namespace DeviceTest
|
||||
{
|
||||
static class Program
|
||||
{
|
||||
/// Program information
|
||||
public static string Version; /// version string
|
||||
public static DateTime BuildDateTime; /// date and time of program build
|
||||
|
||||
/// log4net
|
||||
static ILog log;
|
||||
const string log4netConfigFName = "log4netConfig.xml";
|
||||
|
||||
/// Local settings
|
||||
public static readonly string LocAppDataDir;
|
||||
public static readonly string LocalSettingsFileName;
|
||||
public static readonly string LocalSettingsBackupName;
|
||||
public static LocalSettings LocalSettings;
|
||||
|
||||
static Program()
|
||||
{
|
||||
/// Program version string
|
||||
System.Reflection.Assembly thisAssembly = System.Reflection.Assembly.GetExecutingAssembly();
|
||||
Version ver = thisAssembly.GetName().Version;
|
||||
Version = string.Format("{0}.{1}.{2}", ver.Major, ver.Minor, ver.Build);
|
||||
BuildDateTime = new System.IO.FileInfo(thisAssembly.Location).LastWriteTime;
|
||||
|
||||
/// Local program configuration directory including the trailing backslash
|
||||
LocAppDataDir = Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData) +
|
||||
Path.DirectorySeparatorChar + "TestBenchFramework" + Path.DirectorySeparatorChar;
|
||||
LocalSettingsFileName = LocAppDataDir + "DeviceTest.xml";
|
||||
LocalSettingsBackupName = LocAppDataDir + "DeviceTest.backup.xml";
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// The main entry point for the application.
|
||||
/// </summary>
|
||||
[STAThread]
|
||||
static void Main()
|
||||
{
|
||||
///
|
||||
/// Load the local settings
|
||||
///
|
||||
Program.LocalSettings = LocalSettings.Load(Program.LocalSettingsFileName);
|
||||
if (Program.LocalSettings == null)
|
||||
{
|
||||
/// Loading local seetings from regular config file failed. Use the backup
|
||||
Program.LocalSettings = LocalSettings.Load(Program.LocalSettingsBackupName);
|
||||
if (Program.LocalSettings == null)
|
||||
{
|
||||
MessageBox.Show("Na tomto počítači nebol tento program ani raz spustený.\r\nPoužijú sa základné nastavenia.", "Upozornenie", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
|
||||
Program.LocalSettings = new LocalSettings();
|
||||
Directory.CreateDirectory(LocAppDataDir);
|
||||
Program.LocalSettings.Save();
|
||||
}
|
||||
else
|
||||
{
|
||||
LocalSettings.Save(); /// Save the settings to overwrite the wrong file
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
/// Loading local seetings from the regular config file was successful. Update the backup
|
||||
File.Copy(Program.LocalSettingsFileName, Program.LocalSettingsBackupName, true);
|
||||
}
|
||||
|
||||
/// Configure and start logging
|
||||
log4net.Config.XmlConfigurator.Configure(new System.IO.FileInfo(LocAppDataDir + log4netConfigFName));
|
||||
log = LogManager.GetLogger(typeof(Program));
|
||||
log.Fatal("--------------------------------------------------------------------------------");
|
||||
log.Fatal(string.Format("TBF ver.{0}", Version));
|
||||
|
||||
Application.EnableVisualStyles();
|
||||
Application.SetCompatibleTextRenderingDefault(false);
|
||||
|
||||
try
|
||||
{
|
||||
DeviceTestDlg dlg = new DeviceTestDlg();
|
||||
Application.Run(dlg);
|
||||
}
|
||||
catch (Exception exc)
|
||||
{
|
||||
LogException(log, "Exception in Application.Run(DeviceTestDlg)", exc);
|
||||
MessageBox.Show("Program havaroval:" +
|
||||
Environment.NewLine + Environment.NewLine + exc.Message +
|
||||
((exc.InnerException == null) ? string.Empty : (Environment.NewLine + exc.InnerException.Message)) +
|
||||
Environment.NewLine + exc.StackTrace,
|
||||
"Pozor!", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
|
||||
}
|
||||
}
|
||||
|
||||
static void LogException(ILog log, string description, Exception e)
|
||||
{
|
||||
log.FatalFormat("---------------( {0} )---------------", description);
|
||||
log.FatalFormat("Message : {0}", e.Message);
|
||||
if (e.InnerException != null)
|
||||
{
|
||||
log.FatalFormat("InnerMessage : {0}", e.InnerException.Message);
|
||||
}
|
||||
log.FatalFormat("StackTrace : {0}{1}", Environment.NewLine, e.StackTrace);
|
||||
log.Fatal("--------------------------------------");
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,36 +0,0 @@
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
// General Information about an assembly is controlled through the following
|
||||
// set of attributes. Change these attribute values to modify the information
|
||||
// associated with an assembly.
|
||||
[assembly: AssemblyTitle("DeviceTest")]
|
||||
[assembly: AssemblyDescription("")]
|
||||
[assembly: AssemblyConfiguration("")]
|
||||
[assembly: AssemblyCompany("")]
|
||||
[assembly: AssemblyProduct("DeviceTest")]
|
||||
[assembly: AssemblyCopyright("Copyright © 2016")]
|
||||
[assembly: AssemblyTrademark("")]
|
||||
[assembly: AssemblyCulture("")]
|
||||
|
||||
// Setting ComVisible to false makes the types in this assembly not visible
|
||||
// to COM components. If you need to access a type in this assembly from
|
||||
// COM, set the ComVisible attribute to true on that type.
|
||||
[assembly: ComVisible(false)]
|
||||
|
||||
// The following GUID is for the ID of the typelib if this project is exposed to COM
|
||||
[assembly: Guid("a3e8ad92-6617-4f5c-88ce-346d28120fb7")]
|
||||
|
||||
// Version information for an assembly consists of the following four values:
|
||||
//
|
||||
// Major Version
|
||||
// Minor Version
|
||||
// Build Number
|
||||
// Revision
|
||||
//
|
||||
// You can specify all the values or you can default the Build and Revision Numbers
|
||||
// by using the '*' as shown below:
|
||||
// [assembly: AssemblyVersion("1.0.*")]
|
||||
[assembly: AssemblyVersion("1.0.0.0")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.0")]
|
||||
-63
@@ -1,63 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
// Runtime Version:4.0.30319.42000
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace DeviceTest.Properties {
|
||||
using System;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// A strongly-typed resource class, for looking up localized strings, etc.
|
||||
/// </summary>
|
||||
// This class was auto-generated by the StronglyTypedResourceBuilder
|
||||
// class via a tool like ResGen or Visual Studio.
|
||||
// To add or remove a member, edit your .ResX file then rerun ResGen
|
||||
// with the /str option, or rebuild your VS project.
|
||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
|
||||
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||
internal class Resources {
|
||||
|
||||
private static global::System.Resources.ResourceManager resourceMan;
|
||||
|
||||
private static global::System.Globalization.CultureInfo resourceCulture;
|
||||
|
||||
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
|
||||
internal Resources() {
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Returns the cached ResourceManager instance used by this class.
|
||||
/// </summary>
|
||||
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||
internal static global::System.Resources.ResourceManager ResourceManager {
|
||||
get {
|
||||
if (object.ReferenceEquals(resourceMan, null)) {
|
||||
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("DeviceTest.Properties.Resources", typeof(Resources).Assembly);
|
||||
resourceMan = temp;
|
||||
}
|
||||
return resourceMan;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Overrides the current thread's CurrentUICulture property for all
|
||||
/// resource lookups using this strongly typed resource class.
|
||||
/// </summary>
|
||||
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||
internal static global::System.Globalization.CultureInfo Culture {
|
||||
get {
|
||||
return resourceCulture;
|
||||
}
|
||||
set {
|
||||
resourceCulture = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,117 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
</root>
|
||||
-26
@@ -1,26 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
// Runtime Version:4.0.30319.42000
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace DeviceTest.Properties {
|
||||
|
||||
|
||||
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "10.0.0.0")]
|
||||
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {
|
||||
|
||||
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
|
||||
|
||||
public static Settings Default {
|
||||
get {
|
||||
return defaultInstance;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,7 +0,0 @@
|
||||
<?xml version='1.0' encoding='utf-8'?>
|
||||
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)">
|
||||
<Profiles>
|
||||
<Profile Name="(Default)" />
|
||||
</Profiles>
|
||||
<Settings />
|
||||
</SettingsFile>
|
||||
@@ -1,3 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<configuration>
|
||||
<startup><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.0"/></startup></configuration>
|
||||
@@ -1,51 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProductVersion>8.0.30703</ProductVersion>
|
||||
<SchemaVersion>2.0</SchemaVersion>
|
||||
<ProjectGuid>{439D0878-C76E-452B-B17D-209A89E91D36}</ProjectGuid>
|
||||
<OutputType>Library</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>Dirichlet.Numerics</RootNamespace>
|
||||
<AssemblyName>Dirichlet.Numerics</AssemblyName>
|
||||
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
<TargetFrameworkProfile>Client</TargetFrameworkProfile>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Numerics" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Int128.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<Compile Include="UInt128.cs" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||
Other similar extension points exist, see Microsoft.Common.targets.
|
||||
<Target Name="BeforeBuild">
|
||||
</Target>
|
||||
<Target Name="AfterBuild">
|
||||
</Target>
|
||||
-->
|
||||
</Project>
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,36 +0,0 @@
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
// General Information about an assembly is controlled through the following
|
||||
// set of attributes. Change these attribute values to modify the information
|
||||
// associated with an assembly.
|
||||
[assembly: AssemblyTitle("Dirichlet.Numerics")]
|
||||
[assembly: AssemblyDescription("")]
|
||||
[assembly: AssemblyConfiguration("")]
|
||||
[assembly: AssemblyCompany("")]
|
||||
[assembly: AssemblyProduct("Dirichlet.Numerics")]
|
||||
[assembly: AssemblyCopyright("Copyright © 2012")]
|
||||
[assembly: AssemblyTrademark("")]
|
||||
[assembly: AssemblyCulture("")]
|
||||
|
||||
// Setting ComVisible to false makes the types in this assembly not visible
|
||||
// to COM components. If you need to access a type in this assembly from
|
||||
// COM, set the ComVisible attribute to true on that type.
|
||||
[assembly: ComVisible(false)]
|
||||
|
||||
// The following GUID is for the ID of the typelib if this project is exposed to COM
|
||||
[assembly: Guid("a588abc0-c631-4475-9eab-4163d9f81fed")]
|
||||
|
||||
// Version information for an assembly consists of the following four values:
|
||||
//
|
||||
// Major Version
|
||||
// Minor Version
|
||||
// Build Number
|
||||
// Revision
|
||||
//
|
||||
// You can specify all the values or you can default the Build and Revision Numbers
|
||||
// by using the '*' as shown below:
|
||||
// [assembly: AssemblyVersion("1.0.*")]
|
||||
[assembly: AssemblyVersion("1.0.0.0")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.0")]
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,13 +0,0 @@
|
||||
Copyright 2014 Rick Sladkey
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
@@ -1 +0,0 @@
|
||||
Test StartTime: when? Start of flow set or start of real test?
|
||||
@@ -1,192 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using Results.Entities;
|
||||
|
||||
namespace Results
|
||||
{
|
||||
public class BatchResults
|
||||
{
|
||||
public readonly int WMPositionsCount;
|
||||
|
||||
public IList<Entities.TestData> TestDataList;
|
||||
public IList<Entities.Components> ComponentsList;
|
||||
public IList<Entities.WaterMeterData> WaterMeterDataList;
|
||||
|
||||
private BatchResults(int wmPositionsCount)
|
||||
{
|
||||
WMPositionsCount = wmPositionsCount;
|
||||
|
||||
TestDataList = new List<Entities.TestData>();
|
||||
ComponentsList = new List<Entities.Components>();
|
||||
WaterMeterDataList = new List<Entities.WaterMeterData>();
|
||||
}
|
||||
|
||||
|
||||
public Batch Batch;
|
||||
public WaterMeter[] WaterMeters;
|
||||
|
||||
public static BatchResults NewFromProcedure(int batchNr, int benchId, string user, int userNr, string programVer,
|
||||
Config.Entities.Procedure procedure,
|
||||
WaterMeterData[] waterMeterDatas, int[] waterMeterParts)
|
||||
{
|
||||
BatchResults d = new BatchResults(waterMeterDatas.Length);
|
||||
int year = DateTime.Now.Year;
|
||||
|
||||
/// Create new batch
|
||||
d.Batch = new Batch()
|
||||
{
|
||||
TestBenchId = benchId,
|
||||
BatchNr = batchNr,
|
||||
ProgramVersion = programVer,
|
||||
UserName = user,
|
||||
UserNumber = userNr,
|
||||
ProcedureName = procedure.Name,
|
||||
ProcedureDescription = procedure.Description,
|
||||
WatermetersStr = procedure.Watermeters,
|
||||
ProcedureRevision = procedure.Revision,
|
||||
ProtocolTitle = procedure.ProtocolTitle,
|
||||
StartTime = DateTime.Now,
|
||||
Compound = (procedure.MetersKind == Config.Entities.MetersKind.Combined),
|
||||
#if HEAT_METERS
|
||||
HeatMeter = (procedure.MetersKind == Config.Entities.MetersKind.HeatMeter),
|
||||
#endif
|
||||
};
|
||||
|
||||
///
|
||||
/// Add watermeter to an array, array index is WM position.
|
||||
/// AddWaterMetersToBatch() has to be used before saving results.
|
||||
///
|
||||
d.WaterMeters = new WaterMeter[d.WMPositionsCount];
|
||||
for (int i = 0; i < d.WMPositionsCount; i++)
|
||||
{
|
||||
if (waterMeterDatas[i] == null) continue;
|
||||
WaterMeterData wmd = WaterMeterData.UpdateList(d.WaterMeterDataList, waterMeterDatas[i]);
|
||||
d.WaterMeters[i] = new WaterMeter()
|
||||
{
|
||||
Batch = d.Batch,
|
||||
WaterMeterData = wmd,
|
||||
WMPosition = i + 1,
|
||||
YearOfProduction = year,
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
foreach (var t in procedure.Tests)
|
||||
{
|
||||
if (t.Publish != (byte)Config.Entities.Publish.Never)
|
||||
{
|
||||
TestData td = TestData.UpdateList(d.TestDataList, new TestData(t));
|
||||
|
||||
for (int rnr = 1; rnr <= t.Repeats; rnr++)
|
||||
{
|
||||
/// Create an empty test result and add it to the list
|
||||
TestRslt tr = new TestRslt(d.Batch, td, t.Part, rnr);
|
||||
d.Batch.TestRslts.Add(tr);
|
||||
|
||||
for (int i = 0; i < d.WMPositionsCount; i++)
|
||||
{
|
||||
if (d.WaterMeters[i] == null) continue;
|
||||
|
||||
if (t.Part != 0 && waterMeterParts[i] != 0 && t.Part != waterMeterParts[i]) continue;
|
||||
|
||||
///
|
||||
/// Create empty watermeter test results and add them to the list and to dictionaries
|
||||
///
|
||||
IList<MeterTestRslt> wmtrs = d.WaterMeters[i].MeterTestRslts;
|
||||
if (d.Batch.Compound)
|
||||
{
|
||||
/// Compound water meter
|
||||
wmtrs.Add(new MeterTestRslt(d.WaterMeters[i], tr, Config.Entities.CompoundMeterId.CompoundMain));
|
||||
wmtrs.Add(new MeterTestRslt(d.WaterMeters[i], tr, Config.Entities.CompoundMeterId.CompoundAux));
|
||||
wmtrs.Add(new MeterTestRslt(d.WaterMeters[i], tr, Config.Entities.CompoundMeterId.Compound));
|
||||
}
|
||||
else if (d.Batch.HeatMeter)
|
||||
{
|
||||
/// Heat meter
|
||||
wmtrs.Add(new MeterTestRslt(d.WaterMeters[i], tr, Config.Entities.CompoundMeterId.HeatMeterVolume));
|
||||
wmtrs.Add(new MeterTestRslt(d.WaterMeters[i], tr, Config.Entities.CompoundMeterId.HeatMeterEnergy));
|
||||
}
|
||||
else
|
||||
{
|
||||
/// Water meter
|
||||
wmtrs.Add(new MeterTestRslt(d.WaterMeters[i], tr, Config.Entities.CompoundMeterId.Single));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return d;
|
||||
}
|
||||
|
||||
public static BatchResults FromBatch(Batch batch)
|
||||
{
|
||||
int wmCount = batch.WaterMeters.Count;
|
||||
if (wmCount == 0) return null;
|
||||
|
||||
BatchResults batchResults = new BatchResults(wmCount);
|
||||
batchResults.Batch = batch;
|
||||
batchResults.WaterMeters = new WaterMeter[wmCount];
|
||||
for (int i = 0; i < wmCount; i++) batchResults.WaterMeters[i] = batch.WaterMeters[i];
|
||||
|
||||
return batchResults;
|
||||
}
|
||||
|
||||
public TestRslt GetTestRslt(string name, int part)
|
||||
{
|
||||
return Batch.GetTestRslt(name, part);
|
||||
}
|
||||
|
||||
public MeterTestRslt GetMeterTestRslt(string name, int wmnr0, Config.Entities.CompoundMeterId meterId)
|
||||
{
|
||||
if (WaterMeters[wmnr0] != null)
|
||||
{
|
||||
return WaterMeters[wmnr0].GetMeterTestRslt(name, meterId);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Returns true when all tests were done
|
||||
/// </summary>
|
||||
/// <returns>true = all tests done</returns>
|
||||
public bool AllTestsDone()
|
||||
{
|
||||
for (int i = 0; i < WMPositionsCount; i++)
|
||||
{
|
||||
if (WaterMeters[i] != null)
|
||||
{
|
||||
foreach (var mtr in WaterMeters[i].MeterTestRslts)
|
||||
{
|
||||
if (!mtr.TestDone) return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Adds non-null water meters from an array to a Batch water meters list.
|
||||
/// This method should be used when results are prepared and
|
||||
/// all disabled water meters are deleted.
|
||||
/// </summary>
|
||||
public void AddWaterMetersToBatch()
|
||||
{
|
||||
for (int i = 0; i < WMPositionsCount; i++)
|
||||
{
|
||||
if (WaterMeters[i] != null)
|
||||
{
|
||||
WaterMeters[i].Passed = WaterMeters[i].PassedFromTests();
|
||||
if (!WaterMeters[i].Disabled)
|
||||
{
|
||||
Batch.WaterMeters.Add(WaterMeters[i]);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
-274
@@ -1,274 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2013-2016 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using FluentNHibernate.Cfg;
|
||||
using FluentNHibernate.Cfg.Db;
|
||||
using log4net;
|
||||
using NHibernate;
|
||||
using NHibernate.Cfg;
|
||||
using NHibernate.Tool.hbm2ddl;
|
||||
using Results.Entities;
|
||||
|
||||
namespace Results
|
||||
{
|
||||
public static class DB
|
||||
{
|
||||
static readonly ILog log = LogManager.GetLogger(typeof(DB));
|
||||
|
||||
/// <summary> Session factory for all regular sessions, not for CreateEmptyResultsDB(). </summary>
|
||||
public static ISessionFactory SessionFactory;
|
||||
|
||||
/// <summary> Connection string for all sessions </summary>
|
||||
private static string connectionString;
|
||||
///
|
||||
public static string ConnectionString
|
||||
{
|
||||
get { return connectionString; }
|
||||
set { connectionString = value; SessionFactory = null; }
|
||||
}
|
||||
|
||||
/// <summary> Database type (MySQL or SQLite) for all sessions </summary>
|
||||
private static Users.Entities.DBType dbType;
|
||||
///
|
||||
public static Users.Entities.DBType DbType
|
||||
{
|
||||
get { return dbType; }
|
||||
set { dbType = value; SessionFactory = null; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// NHibernate session factory (to create the database session 'SessionFactory')
|
||||
/// </summary>
|
||||
/// <returns>A database session</returns>
|
||||
static ISessionFactory CreateSessionFactory()
|
||||
{
|
||||
return CreateSessionFactory(false);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// NHibernate session factory (to create the database session 'SessionFactory')
|
||||
/// </summary>
|
||||
/// <param name="createDB">true = Create a new DB, false = Regular DB</param>
|
||||
/// <returns>A database session</returns>
|
||||
public static ISessionFactory CreateSessionFactory(bool createDB)
|
||||
{
|
||||
FluentConfiguration cfg = Fluently.Configure();
|
||||
|
||||
switch (dbType)
|
||||
{
|
||||
default:
|
||||
case Users.Entities.DBType.SQLite:
|
||||
cfg = cfg.Database(SQLiteConfiguration.Standard.UsingFile(connectionString));
|
||||
break;
|
||||
case Users.Entities.DBType.MySql:
|
||||
cfg = cfg.Database(MySQLConfiguration.Standard.ConnectionString(connectionString));
|
||||
break;
|
||||
}
|
||||
|
||||
cfg = cfg.Mappings(m => m.FluentMappings.AddFromAssemblyOf<Entities.WaterMeterData>());
|
||||
|
||||
if (createDB)
|
||||
{
|
||||
return cfg.ExposeConfiguration(BuildSchemaCreate).BuildSessionFactory();
|
||||
}
|
||||
else
|
||||
{
|
||||
return cfg.ExposeConfiguration(BuildSchema).BuildSessionFactory();
|
||||
}
|
||||
}
|
||||
|
||||
static void BuildSchema(Configuration config)
|
||||
{
|
||||
/// This NHibernate tool takes a configuration with mapping info and exports a database schema
|
||||
new SchemaExport(config).SetOutputFile("db_schema");
|
||||
}
|
||||
|
||||
static void BuildSchemaCreate(Configuration config)
|
||||
{
|
||||
/// This NHibernate tool takes a configuration with mapping info and exports a database schema
|
||||
new SchemaExport(config).Create(true, true);
|
||||
}
|
||||
|
||||
/// Create a NHibernate session for the given database
|
||||
public static ISession CreateSession()
|
||||
{
|
||||
if (string.IsNullOrEmpty(connectionString))
|
||||
{
|
||||
throw new Exception("Connection string was not specified");
|
||||
}
|
||||
|
||||
if (SessionFactory == null) SessionFactory = CreateSessionFactory();
|
||||
|
||||
return SessionFactory.OpenSession();
|
||||
}
|
||||
|
||||
|
||||
public static void SaveObject(object obj)
|
||||
{
|
||||
SaveObject(CreateSession(), obj);
|
||||
}
|
||||
///
|
||||
public static void SaveObject(ISession session, object obj)
|
||||
{
|
||||
using (var transaction = session.BeginTransaction())
|
||||
{
|
||||
session.SaveOrUpdate(obj);
|
||||
try { transaction.Commit(); }
|
||||
catch { }
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public static void DeleteObject(object obj)
|
||||
{
|
||||
DeleteObject(CreateSession(), obj);
|
||||
}
|
||||
///
|
||||
public static void DeleteObject(ISession session, object obj)
|
||||
{
|
||||
using (var transaction = session.BeginTransaction())
|
||||
{
|
||||
session.Delete(obj);
|
||||
transaction.Commit();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Create an empty users database.
|
||||
/// Database contains only the user 'admin' and the control board component 'CB'.
|
||||
/// </summary>
|
||||
/// <param name="dbType">DBType.SQLite or DBType.MySql</param>
|
||||
/// <param name="connectionString">Connection string</param>
|
||||
/// <returns>true=success, false=error</returns>
|
||||
public static bool CreateEmptyDB()
|
||||
{
|
||||
ISessionFactory sessionFactory = CreateSessionFactory(true);
|
||||
if (sessionFactory == null) return false;
|
||||
|
||||
/// Populate the database
|
||||
using (var session = sessionFactory.OpenSession())
|
||||
{
|
||||
using (var transaction = session.BeginTransaction())
|
||||
{
|
||||
transaction.Commit();
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Shared data
|
||||
/// </summary>
|
||||
public static IList<Entities.TestData> TestDataList;
|
||||
public static IList<Entities.Components> ComponentsList;
|
||||
public static IList<Entities.WaterMeterData> WaterMeterDataList;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Loads shared data from the database
|
||||
/// </summary>
|
||||
/// <exception>Throws NHibernate exceptions</exception>
|
||||
public static void LoadSharedData()
|
||||
{
|
||||
ISession session = DB.CreateSession();
|
||||
|
||||
TestDataList = session.QueryOver<TestData>().List();
|
||||
ComponentsList = session.QueryOver<Components>().List();
|
||||
WaterMeterDataList = session.QueryOver<WaterMeterData>().List();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Loads shared data from the database
|
||||
/// </summary>
|
||||
/// <exception>Throws NHibernate exceptions</exception>
|
||||
public static int GetMaxSavedBatchNr()
|
||||
{
|
||||
ISession session = DB.CreateSession();
|
||||
IList<Entities.Batch> batches = session.QueryOver<Batch>().List();
|
||||
|
||||
int maxBatchNr = 0;
|
||||
foreach (var b in batches)
|
||||
{
|
||||
if (b.BatchNr > maxBatchNr) maxBatchNr = b.BatchNr;
|
||||
}
|
||||
return maxBatchNr;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Update TestData, Components and WaterMeterData fo tests and water meters in batch results
|
||||
/// with existing data in static lists TestDataList, ComponentsList and WaterMeterDataList.
|
||||
/// </summary>
|
||||
/// <param name="batch">Batch results</param>
|
||||
/// <returns>true when any data modiifed</returns>
|
||||
public static bool UpdateBatchData(Entities.Batch batch)
|
||||
{
|
||||
ISession session = DB.CreateSession();
|
||||
|
||||
if (session == null) return false;
|
||||
|
||||
foreach (var tr in batch.TestRslts)
|
||||
{
|
||||
/// Search in TestDataList and update test data in the new batch
|
||||
TestData td = TestData.UpdateList(TestDataList, tr.TestData);
|
||||
tr.TestData = td;
|
||||
|
||||
/// Search in ComponentsList and update components in the new batch
|
||||
Components cd = Components.UpdateList(ComponentsList, tr.Components);
|
||||
tr.Components = cd;
|
||||
}
|
||||
|
||||
foreach (var wm in batch.WaterMeters)
|
||||
{
|
||||
/// Search in WaterMeterDataList and update water meter data in the new batch
|
||||
WaterMeterData wmd = WaterMeterData.UpdateList(WaterMeterDataList, wm.WaterMeterData);
|
||||
wm.WaterMeterData = wmd;
|
||||
}
|
||||
|
||||
return true; /// TODO: Really check for modifications
|
||||
}
|
||||
|
||||
|
||||
public static bool SaveNewBatch(Entities.Batch batch)
|
||||
{
|
||||
ISession session = DB.CreateSession();
|
||||
if (session == null) return false;
|
||||
|
||||
TestDataList = session.QueryOver<TestData>().List();
|
||||
ComponentsList = session.QueryOver<Components>().List();
|
||||
WaterMeterDataList = session.QueryOver<WaterMeterData>().List();
|
||||
|
||||
UpdateBatchData(batch);
|
||||
|
||||
ITransaction transaction = session.BeginTransaction();
|
||||
if (transaction == null) return false;
|
||||
|
||||
try
|
||||
{
|
||||
foreach (var td in TestDataList) if (td.Id == 0) session.SaveOrUpdate(td);
|
||||
foreach (var cd in ComponentsList) if (cd.Id == 0) session.SaveOrUpdate(cd);
|
||||
foreach (var wd in WaterMeterDataList) if (wd.Id == 0) session.SaveOrUpdate(wd);
|
||||
|
||||
session.SaveOrUpdate(batch);
|
||||
|
||||
transaction.Commit();
|
||||
}
|
||||
catch (Exception exc)
|
||||
{
|
||||
transaction.Rollback();
|
||||
log.FatalFormat("Saving results of batch #{0} into the results DB failed: {1}", batch.BatchNr, exc.Message);
|
||||
return false;
|
||||
}
|
||||
|
||||
session.Flush();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -1,81 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2015-2016 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace Results.Entities
|
||||
{
|
||||
public class Batch
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
public virtual int BatchNr { get; set; }
|
||||
public virtual int TestBenchId { get; set; }
|
||||
public virtual string ProgramVersion { get; set; }
|
||||
public virtual string UserName { get; set; }
|
||||
public virtual int UserNumber { get; set; }
|
||||
public virtual string ProcedureName { get; set; }
|
||||
public virtual string ProcedureDescription { get; set; } /// CEVAK, not mapped to DB
|
||||
public virtual int ProcedureRevision { get; set; }
|
||||
public virtual string WatermetersStr { get; set; } /// CEVAK, not mapped to DB
|
||||
public virtual string ProtocolTitle { get; set; }
|
||||
public virtual string Remark { get; set; }
|
||||
public virtual float Custom1 { get; set; }
|
||||
public virtual float Custom2 { get; set; }
|
||||
public virtual float Custom3 { get; set; }
|
||||
public virtual DateTime StartTime { get; set; }
|
||||
public virtual DateTime EndTime { get; set; }
|
||||
public virtual bool RsltsSent { get; set; }
|
||||
public virtual bool RsltsPrinted { get; set; }
|
||||
public virtual IList<TestData> Tests { get; set; }
|
||||
public virtual IList<WaterMeter> WaterMeters { get; set; }
|
||||
public virtual IList<TestRslt> TestRslts { get; set; }
|
||||
public virtual bool Compound { get; set; } /// Not mapped to DB now
|
||||
public virtual bool HeatMeter { get; set; } /// Not mapped to DB now
|
||||
|
||||
public Batch()
|
||||
{
|
||||
Tests = new List<TestData>();
|
||||
WaterMeters = new List<WaterMeter>();
|
||||
TestRslts = new List<TestRslt>();
|
||||
}
|
||||
|
||||
public virtual float AmbientTempAve()
|
||||
{
|
||||
if (TestRslts.Count == 0) return 0;
|
||||
float sum = 0;
|
||||
foreach (var tr in TestRslts) sum += tr.AmbTempMean;
|
||||
return sum / TestRslts.Count;
|
||||
}
|
||||
|
||||
public virtual float AmbientPressAve()
|
||||
{
|
||||
if (TestRslts.Count == 0) return 0;
|
||||
float sum = 0;
|
||||
foreach (var tr in TestRslts) sum += tr.AmbPressMean;
|
||||
return sum / TestRslts.Count;
|
||||
}
|
||||
|
||||
public virtual float AmbientHumiAve()
|
||||
{
|
||||
if (TestRslts.Count == 0) return 0;
|
||||
float sum = 0;
|
||||
foreach (var tr in TestRslts) sum += tr.AmbHumiMean;
|
||||
return sum / TestRslts.Count;
|
||||
}
|
||||
|
||||
public virtual TestRslt GetTestRslt(string name, int part)
|
||||
{
|
||||
foreach (var tr in TestRslts)
|
||||
{
|
||||
if (part == tr.Part && name.Equals(tr.Name())) return tr;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public override string ToString()
|
||||
{
|
||||
return string.Format("Batch #{0}, Start:{1}, End:{2}, Procedure:{3}", BatchNr, StartTime, EndTime, ProcedureName);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,94 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2016 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
|
||||
namespace Results.Entities
|
||||
{
|
||||
public class Components
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
public virtual int TestBenchId { get; set; }
|
||||
public virtual string TestBenchName { get; set; }
|
||||
public virtual string Pump { get; set; }
|
||||
public virtual string RegValve { get; set; }
|
||||
public virtual string Flowmeter { get; set; }
|
||||
public virtual string Diverter { get; set; }
|
||||
public virtual string Scale { get; set; }
|
||||
public virtual string Custom1 { get; set; }
|
||||
public virtual string Custom2 { get; set; }
|
||||
public virtual string Custom3 { get; set; }
|
||||
|
||||
protected Components()
|
||||
{
|
||||
TestBenchId = 0;
|
||||
TestBenchName = string.Empty;
|
||||
Pump = string.Empty;
|
||||
RegValve = string.Empty;
|
||||
Flowmeter = string.Empty;
|
||||
Diverter = string.Empty;
|
||||
Scale = string.Empty;
|
||||
Custom1 = string.Empty;
|
||||
Custom2 = string.Empty;
|
||||
Custom3 = string.Empty;
|
||||
}
|
||||
|
||||
public Components(int benchId, string benchName, string pump, string flowmeter,
|
||||
string scale, string regValve, string diverter)
|
||||
{
|
||||
TestBenchId = benchId;
|
||||
TestBenchName = benchName;
|
||||
Pump = pump;
|
||||
RegValve = regValve;
|
||||
Flowmeter = flowmeter;
|
||||
Diverter = diverter;
|
||||
Scale = scale;
|
||||
Custom1 = string.Empty;
|
||||
Custom2 = string.Empty;
|
||||
Custom3 = string.Empty;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Method to compare the content of two entities
|
||||
/// </summary>
|
||||
/// <param name="wmd">Second entity to compare with</param>
|
||||
/// <returns>first = two entities are equal (except of Id)</returns>
|
||||
public virtual bool Equals(Components bc)
|
||||
{
|
||||
if (TestBenchId != bc.TestBenchId) return false;
|
||||
if (!TestBenchName.Equals(bc.TestBenchName)) return false;
|
||||
if (!Pump.Equals(bc.Pump)) return false;
|
||||
if (!RegValve.Equals(bc.RegValve)) return false;
|
||||
if (!Flowmeter.Equals(bc.Flowmeter)) return false;
|
||||
if (!Diverter.Equals(bc.Diverter)) return false;
|
||||
if (!Scale.Equals(bc.Scale)) return false;
|
||||
if (!Custom1.Equals(bc.Custom1)) return false;
|
||||
if (!Custom2.Equals(bc.Custom2)) return false;
|
||||
if (!Custom3.Equals(bc.Custom3)) return false;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Adds an item to the list if it does not occur there
|
||||
/// </summary>
|
||||
/// <param name="list">List of items</param>
|
||||
/// <param name="item">Item to add to the list or find there</param>
|
||||
/// <returns>Item from the list (existing or added)</returns>
|
||||
public static Components UpdateList(IList<Components> list, Components item)
|
||||
{
|
||||
if (item == null) return null; /// Null item is not stored in the list
|
||||
|
||||
Components found = list.FirstOrDefault<Components>(x => x.Equals(item));
|
||||
|
||||
if (found != null) return found; /// The same item found in the list, The found item returned
|
||||
|
||||
list.Add(item); /// Item not fund in the list, it is added to the list
|
||||
return item;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,93 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2013-2016 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
|
||||
namespace Results.Entities
|
||||
{
|
||||
public class MeterTestRslt
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
|
||||
public virtual byte CompoundMeterId { get; set; } /// 0=single, 1=compound/main, 2=compound/aux., 3=compound/overal, 4=heat meter volume, 5=heat meter energy
|
||||
public virtual double PulsesMeter { get; set; } /// # of water meter or heat meter pulses
|
||||
public virtual double PulsesMaster { get; set; } /// # of reference flowmeter pulses (gated by this water meter pulses)
|
||||
public virtual double PulsesPerLiter { get; set; } /// [l ^ -1], in case of heat meters (CompoundMeterId==5) pulses per kWh in [kWh ^ -1]
|
||||
public virtual double VolumeStart { get; set; } /// Volume or energy (CompoundMeterId==5) on test start in [l] or [J]
|
||||
public virtual double VolumeEnd { get; set; } /// Volume or energy (CompoundMeterId==5) on test end in [l] or [J]
|
||||
public virtual double VolumeMeter { get; set; } /// Measured volume or energy (CompoundMeterId==5) in [l] or [J]
|
||||
public virtual double VolumeRef { get; set; } /// Reference volume or energy (CompoundMeterId==5) in [l] or [J]
|
||||
public virtual double TimestampStart { get; set; } /// [s]
|
||||
public virtual double TimestampEnd { get; set; } /// [s]
|
||||
public virtual double TestTime { get; set; } /// [s]
|
||||
|
||||
/// Main result
|
||||
public virtual double Error { get; set; } /// [%]
|
||||
public virtual bool TestDone { get; set; } /// true = test was completed
|
||||
public virtual bool Passed { get; set; } /// true = test passed, water meter is OK
|
||||
|
||||
public virtual WaterMeter WaterMeter { get; set; } /// reference to the WaterMeter entity
|
||||
public virtual TestRslt TestRslt { get; set; } /// reference to the TestRslt entity
|
||||
|
||||
/// Wrappers
|
||||
public virtual string Name() { return TestRslt.Name(); }
|
||||
public virtual DateTime StartTime() { return TestRslt.StartTime; }
|
||||
public virtual DateTime EndTime() { return TestRslt.EndTime; }
|
||||
public virtual double FlowSetTime() { return TestRslt.FlowSetTime; } /// [s]
|
||||
public virtual double FlowMass() { return TestRslt.FlowMass; } /// [kg/h]
|
||||
public virtual double FlowVolume() { return TestRslt.FlowVolume; } /// [m3/h]
|
||||
public virtual double ErrorMaster() { return TestRslt.ErrorMaster; } /// [%]
|
||||
public virtual double DensityOut() { return TestRslt.DensityOut; }
|
||||
public virtual Components Components(){ return TestRslt.Components; }
|
||||
///
|
||||
protected virtual TestData TestData() { return TestRslt.TestData; }
|
||||
///
|
||||
public virtual int Repeats() { return TestData().Repeats; }
|
||||
public virtual double Qfrom() { return TestData().Qfrom; } /// [m3/h]
|
||||
public virtual double Qto() { return TestData().Qto; } /// [m3/h]
|
||||
public virtual double TargetVolume() { return TestData().TargetVolume; } /// [l]
|
||||
public virtual double TargetTime() { return TestData().TargetTime; } /// [s]
|
||||
public virtual string Method() { return TestData().Method; }
|
||||
public virtual double ErrLimLo() { return TestData().ErrLimLo; } /// [%]
|
||||
public virtual double ErrLimHi() { return TestData().ErrLimHi; } /// [%]
|
||||
public virtual double Uncertainty() { return TestData().Uncertainty; } /// [%]
|
||||
|
||||
public virtual string ProcedureName() { return WaterMeter.Batch.ProcedureName; }
|
||||
public virtual int BatchNr() { return WaterMeter.Batch.BatchNr; }
|
||||
public virtual string SerialNr() { return WaterMeter.SerialNr; }
|
||||
public virtual string EndState() { return WaterMeter.EndState; }
|
||||
public virtual double QRise() { return WaterMeter.QRise; } /// [m3/h]
|
||||
public virtual double QFall() { return WaterMeter.QFall; } /// [m3/h]
|
||||
|
||||
public virtual bool Evaluate() { return TestData().Evaluate; }
|
||||
public virtual Config.Entities.Publish Publish() { return (Config.Entities.Publish)TestData().Publish; }
|
||||
|
||||
public virtual WaterMeterData WaterMeterData() { return WaterMeter.WaterMeterData; }
|
||||
public virtual Batch Batch() { return WaterMeter.Batch; }
|
||||
|
||||
public virtual string PassedColorStr()
|
||||
{
|
||||
#if PUCHONG_PT200
|
||||
if (!Evaluate()) return Passed ? "OK|White" : "NG|White";
|
||||
else return Passed ? "OK|Green" : "NG|Red";
|
||||
#else
|
||||
if (!Evaluate()) return Passed ? "OK|White" : "NOK|White";
|
||||
else return Passed ? "OK|Green" : "NOK|Red";
|
||||
#endif
|
||||
}
|
||||
|
||||
public MeterTestRslt()
|
||||
{
|
||||
TestDone = false;
|
||||
Passed = false;
|
||||
}
|
||||
|
||||
public MeterTestRslt(WaterMeter waterMeterRslt, TestRslt testRslt, Config.Entities.CompoundMeterId compoundMeterId)
|
||||
: this()
|
||||
{
|
||||
WaterMeter = waterMeterRslt;
|
||||
TestRslt = testRslt;
|
||||
CompoundMeterId = (byte)compoundMeterId;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,96 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2016 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
|
||||
namespace Results.Entities
|
||||
{
|
||||
/// <summary>
|
||||
/// Test, consisting of one or more repetitions of the test 'SingleTest'.
|
||||
/// </summary>
|
||||
public class TestData
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
public virtual string Name { get; set; }
|
||||
public virtual int Repeats { get; set; }
|
||||
public virtual double Qfrom { get; set; } /// [m3/h] flow range low limit
|
||||
public virtual double Qto { get; set; } /// [m3/h] flow range high limit
|
||||
public virtual double TargetVolume { get; set; } /// [l] target test volume
|
||||
public virtual double TargetTime { get; set; } /// [s] target test time
|
||||
public virtual string Method { get; set; }
|
||||
public virtual double ErrLimLo { get; set; } /// [%] (usually < 0)
|
||||
public virtual double ErrLimHi { get; set; } /// [%] (usually > 0)
|
||||
public virtual double Uncertainty { get; set; } /// [%] makes error limits tighter: 0 <= Uncertainty <= abs(ErrLimXx)
|
||||
public virtual sbyte Publish { get; set; } /// 0=no, 1=in all protocols, 2=on screen, 3=internal
|
||||
public virtual bool Evaluate { get; set; }
|
||||
|
||||
|
||||
protected TestData()
|
||||
{
|
||||
Name = string.Empty;
|
||||
Method = string.Empty;
|
||||
}
|
||||
|
||||
public TestData(Config.Entities.Test test)
|
||||
: this()
|
||||
{
|
||||
Name = test.Name;
|
||||
Repeats = test.Repeats;
|
||||
Qfrom = (double)test.Qfrom;
|
||||
Qto = (double)test.Qto;
|
||||
TargetVolume = (double)test.Volume;
|
||||
TargetTime = (double)test.TstTime;
|
||||
Method = test.Method;
|
||||
ErrLimLo = (double)test.ErrLimLo;
|
||||
ErrLimHi = (double)test.ErrLimHi;
|
||||
Uncertainty = (double)test.Uncertainty;
|
||||
Publish = test.Publish;
|
||||
Evaluate = test.Evaluate;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Method to compare the content of two entities
|
||||
/// </summary>
|
||||
/// <param name="wmd">Second entity to compare with</param>
|
||||
/// <returns>first = two entities are equal (except of Id)</returns>
|
||||
public virtual bool Equals(TestData td)
|
||||
{
|
||||
if (!Name.Equals(td.Name)) return false;
|
||||
if (Repeats != td.Repeats) return false;
|
||||
if (Qfrom != td.Qfrom) return false;
|
||||
if (Qto != td.Qto) return false;
|
||||
if (TargetVolume != td.TargetVolume) return false;
|
||||
if (TargetTime != td.TargetTime) return false;
|
||||
if (!Method.Equals(td.Method)) return false;
|
||||
if (ErrLimLo != td.ErrLimLo) return false;
|
||||
if (ErrLimHi != td.ErrLimHi) return false;
|
||||
if (Uncertainty != td.Uncertainty) return false;
|
||||
if (Publish != td.Publish) return false;
|
||||
if (Evaluate != td.Evaluate) return false;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Adds an item to the list if it does not occur there
|
||||
/// </summary>
|
||||
/// <param name="list">List of items</param>
|
||||
/// <param name="item">Item to add to the list or find there</param>
|
||||
/// <returns>Item from the list (existing or added)</returns>
|
||||
public static TestData UpdateList(IList<TestData> list, TestData item)
|
||||
{
|
||||
if (item == null) return null; /// Null item is not stored in the list
|
||||
|
||||
TestData found = list.FirstOrDefault<TestData>(x => x.Equals(item));
|
||||
|
||||
if (found != null) return found; /// The same item found in the list, The found item returned
|
||||
|
||||
list.Add(item); /// Item not fund in the list, it is added to the list
|
||||
return item;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,138 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2015-2016 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace Results.Entities
|
||||
{
|
||||
public class TestRslt
|
||||
{
|
||||
/// Identity
|
||||
public virtual int Id { get; protected set; }
|
||||
public virtual Batch Batch { get; set; }
|
||||
public virtual TestData TestData { get; set; }
|
||||
public virtual Components Components { get; set; }
|
||||
public virtual int Part { get; set; }
|
||||
public virtual int RepetitionNr { get; set; } /// Repetition number from the set of repeated tests (1...)
|
||||
|
||||
/// Main results
|
||||
public virtual DateTime StartTime { get; set; } /// Date and time of the test start
|
||||
public virtual DateTime EndTime { get; set; } /// Date and time of the test end
|
||||
public virtual int FlowSetTime { get; set; } /// [s] Measurement time in seconds
|
||||
public virtual double TestTime { get; set; } /// [s] Measurement time in seconds
|
||||
public virtual double PulsesMaster { get; set; }
|
||||
public virtual double ConstMaster { get; set; } /// [pls/l] Pulses per liter master flow meter
|
||||
public virtual double MassStartRaw { get; set; } /// [kg]
|
||||
public virtual double MassStart { get; set; } /// [kg]
|
||||
public virtual double MassEndRaw { get; set; } /// [kg]
|
||||
public virtual double MassEnd { get; set; } /// [kg]
|
||||
public virtual double DensityIn { get; set; } /// [kg/m3]
|
||||
public virtual double DensityOut { get; set; } /// [kg/m3]
|
||||
public virtual double DensityDiv { get; set; } /// [kg/m3]
|
||||
public virtual double Buoyancy { get; set; }
|
||||
public virtual double FlowMass { get; set; } /// [kg/h] calculated from conventional true value
|
||||
public virtual double FlowVolume { get; set; } /// [m3/h]
|
||||
public virtual double VolumeCTV { get; set; } /// [l] Volume conventional true value
|
||||
public virtual double VolumeMaster { get; set; } /// [l] Volume from the master flow meter
|
||||
public virtual double ErrorMaster { get; set; } /// [%]
|
||||
|
||||
/// Main results of heat meters
|
||||
public virtual double RefEnergy { get; set; } /// [J] Joul
|
||||
|
||||
/// Auxiliary results
|
||||
public virtual float AmbTempMean { get; set; } /// [°C] Average ambient air temperature
|
||||
public virtual float AmbTempStart { get; set; } /// [°C] Ambient air temperature on test start
|
||||
public virtual float AmbTempEnd { get; set; } /// [°C] Ambient air temperature on test end
|
||||
public virtual float AmbTempMin { get; set; } /// [°C] Minimum ambient air temperature
|
||||
public virtual float AmbTempMax { get; set; } /// [°C] Maximum ambient air temperature
|
||||
public virtual float AmbPressMean { get; set; } /// [bar] Average ambient air pressure
|
||||
public virtual float AmbPressStart { get; set; } /// [bar] Ambient air pressure on test start
|
||||
public virtual float AmbPressEnd { get; set; } /// [bar] Ambient air pressure on test end
|
||||
public virtual float AmbPressMin { get; set; } /// [bar] Minimum ambient air pressure
|
||||
public virtual float AmbPressMax { get; set; } /// [bar] Maximum ambient air pressure
|
||||
public virtual float AmbHumiMean { get; set; } /// [%] Average ambient air relative humidity
|
||||
public virtual float AmbHumiStart { get; set; } /// [%] Ambient air relative humidity on test start
|
||||
public virtual float AmbHumiEnd { get; set; } /// [%] Ambient air relative humidity on test end
|
||||
public virtual float AmbHumiMin { get; set; } /// [%] Minimum ambient air relative humidity
|
||||
public virtual float AmbHumiMax { get; set; } /// [%] Maximum ambient air relative humidity
|
||||
public virtual float PressUpMean { get; set; } /// [bar] Input water pressure (average)
|
||||
public virtual float PressUpStart { get; set; } /// [bar]
|
||||
public virtual float PressUpEnd { get; set; } /// [bar]
|
||||
public virtual float PressUpMin { get; set; } /// [bar]
|
||||
public virtual float PressUpMax { get; set; } /// [bar]
|
||||
public virtual float PressDownMean { get; set; } /// [bar]
|
||||
public virtual float PressDownStart { get; set; } /// [bar]
|
||||
public virtual float PressDownEnd { get; set; } /// [bar]
|
||||
public virtual float PressDownMin { get; set; } /// [bar]
|
||||
public virtual float PressDownMax { get; set; } /// [bar]
|
||||
public virtual float PressDeltaMean { get; set; } /// [bar]
|
||||
public virtual float PressDeltaStart { get; set; } /// [bar]
|
||||
public virtual float PressDeltaEnd { get; set; } /// [bar]
|
||||
public virtual float PressDeltaMin { get; set; } /// [bar]
|
||||
public virtual float PressDeltaMax { get; set; } /// [bar]
|
||||
public virtual float TempUpMean { get; set; } /// [°C]
|
||||
public virtual float TempUpStart { get; set; } /// [°C]
|
||||
public virtual float TempUpEnd { get; set; } /// [°C]
|
||||
public virtual float TempUpMin { get; set; } /// [°C]
|
||||
public virtual float TempUpMax { get; set; } /// [°C]
|
||||
public virtual float TempDownMean { get; set; } /// [°C]
|
||||
public virtual float TempDownStart { get; set; } /// [°C]
|
||||
public virtual float TempDownEnd { get; set; } /// [°C]
|
||||
public virtual float TempDownMin { get; set; } /// [°C]
|
||||
public virtual float TempDownMax { get; set; } /// [°C]
|
||||
public virtual float TempDivMean { get; set; } /// [°C]
|
||||
public virtual float TempDivStart { get; set; } /// [°C]
|
||||
public virtual float TempDivEnd { get; set; } /// [°C]
|
||||
public virtual float TempDivMin { get; set; } /// [°C]
|
||||
public virtual float TempDivMax { get; set; } /// [°C]
|
||||
public virtual float FlowStart { get; set; } /// [m3/h] minimum flow
|
||||
public virtual float FlowEnd { get; set; } /// [m3/h] maximum flow
|
||||
public virtual float FlowMin { get; set; } /// [m3/h] minimum flow
|
||||
public virtual float FlowMax { get; set; } /// [m3/h] maximum flow
|
||||
|
||||
public virtual float Custom1 { get; set; } /// [°C] T ref hi mean
|
||||
public virtual float Custom2 { get; set; } /// [°C] T ref hi start
|
||||
public virtual float Custom3 { get; set; } /// [°C] T ref hi end
|
||||
public virtual float Custom4 { get; set; } /// [°C] T ref hi min
|
||||
public virtual float Custom5 { get; set; } /// [°C] T ref hi max
|
||||
public virtual float Custom6 { get; set; } /// [°C] T ref lo mean
|
||||
public virtual float Custom7 { get; set; } /// [°C] T ref lo start
|
||||
public virtual float Custom8 { get; set; } /// [°C] T ref lo end
|
||||
public virtual float Custom9 { get; set; } /// [°C] T ref lo min
|
||||
public virtual float Custom10 { get; set; } /// [°C] T ref lo max
|
||||
|
||||
/// Wrappers
|
||||
public virtual string Name() { return Utils.GetTestName(TestData.Name, TestData.Repeats, RepetitionNr); }
|
||||
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 TargetTime() { return TestData.TargetTime; }
|
||||
public virtual string Method() { return TestData.Method; }
|
||||
public virtual double ErrLimLo() { return TestData.ErrLimLo; }
|
||||
public virtual double ErrLimHi() { return TestData.ErrLimHi; }
|
||||
public virtual double Uncertainty() { return TestData.Uncertainty; }
|
||||
public virtual bool Evaluate() { return TestData.Evaluate; }
|
||||
public virtual Config.Entities.Publish Publish() { return (Config.Entities.Publish)TestData.Publish; }
|
||||
|
||||
|
||||
protected TestRslt()
|
||||
{
|
||||
}
|
||||
|
||||
public TestRslt(Batch batch, TestData testData, int part, int repetitionNr)
|
||||
: this()
|
||||
{
|
||||
Batch = batch;
|
||||
TestData = testData;
|
||||
Part = part;
|
||||
RepetitionNr = repetitionNr;
|
||||
}
|
||||
|
||||
public override string ToString()
|
||||
{
|
||||
return string.Format("batch={0}, procedure={1}, test={2}, {3} {4}", Batch.BatchNr, Batch.ProcedureName, Name(), StartTime.ToShortDateString(), StartTime.ToShortTimeString());
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,159 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using Config.Entities;
|
||||
|
||||
namespace Results.Entities
|
||||
{
|
||||
public class WaterMeter
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
public virtual string SerialNr { get; set; } /// Main s/n for compound meters, PCB Number for iPerl water meter
|
||||
public virtual string SerialNrAux { get; set; } /// Aux s/n for compound meters, Serial number for iPerl water meter
|
||||
public virtual string PurchaseOrder { get; set; }
|
||||
public virtual int YearOfProduction { get; set; }
|
||||
public virtual int WMPosition { get; set; }
|
||||
public virtual string EndState { get; set; } /// End state (of the main water meter)
|
||||
public virtual string EndStateAux { get; set; } /// End state of the auxiliary water meter
|
||||
public virtual double QRise { get; set; } /// [m3/h] detected Q_rise of a composed meter
|
||||
public virtual double QFall { get; set; } /// [m3/h] detected Q_fall of a composed meter
|
||||
public virtual bool Passed { get; set; }
|
||||
public virtual int ResultCode { get; set; }
|
||||
|
||||
#if IPERL
|
||||
public virtual int SerialNrEx { get; set; } /// Aux s/n for compound meters, Serial number for iPerl water meter
|
||||
public virtual double OrigCalibFactor { get; set; } /// iPerl calibration factor used during the test
|
||||
public virtual double CalibFactor { get; set; } /// iPerl calibration factor used during the test
|
||||
public virtual double Q2ErrWOCorrection { get; set; }
|
||||
public virtual bool Q2CorrectionDone { get; set; } /// true = iPerl Q2 correction was done
|
||||
public virtual double Q2Correction { get; set; } /// iPerl Q2 correction used during the test
|
||||
public virtual int Q2CorrFlowRight { get; set; } /// 1 = right to left
|
||||
public virtual double Diff2Hz8Hz { get; set; }
|
||||
public virtual bool Hz2CorrectionDone { get; set; } /// true = iPerl Q2 correction was done
|
||||
public virtual int Hz2Correction { get; set; } /// iPerl Q2 correction used during the test
|
||||
#endif
|
||||
#if ORACLE_DB
|
||||
public virtual int Pruefindex { get; set; } /// Not mapped to DB !!! 0=unknown (saving to Oracle failed), >=1 ... pruefindex
|
||||
public virtual int HydrPruefung { get; set; } /// Not mapped to DB !!!
|
||||
#endif
|
||||
public virtual WaterMeterData WaterMeterData { get; set; }
|
||||
public virtual Batch Batch { get; set; }
|
||||
public virtual IList<MeterTestRslt> MeterTestRslts { get; set; }
|
||||
|
||||
///
|
||||
/// Wrappers
|
||||
///
|
||||
public virtual string ProductName() { return WaterMeterData.ProductName; }
|
||||
public virtual string Producer() { return WaterMeterData.Producer; }
|
||||
public virtual string MetrologicalClass() { return WaterMeterData.MetrologicalClass; }
|
||||
public virtual string ApprovalInfo() { return WaterMeterData.ApprovalInfo; }
|
||||
public virtual double Q4_Qmax() { return WaterMeterData.Q4_Qmax; }
|
||||
public virtual double Q3_Qn() { return WaterMeterData.Q3_Qn; }
|
||||
public virtual double Q2_Qt() { return WaterMeterData.Q2_Qt; }
|
||||
public virtual double Q1_Qmin() { return WaterMeterData.Q1_Qmin; }
|
||||
|
||||
public virtual bool Compound() { return WaterMeterData.Compound; }
|
||||
public virtual bool HeatMeter() { return WaterMeterData.HeatMeter; }
|
||||
|
||||
public virtual string ProducerAux() { return WaterMeterData.ProducerAux; }
|
||||
public virtual double Q3_Qn_Aux() { return WaterMeterData.Q3_Qn_Aux; }
|
||||
public virtual string MetrologicalClassAux() { return WaterMeterData.MetrologicalClassAux; }
|
||||
public virtual string ApprovalInfoAux() { return WaterMeterData.ApprovalInfoAux; }
|
||||
|
||||
public virtual int BatchNr() { return Batch.BatchNr; }
|
||||
public virtual int BenchId() { return Batch.TestBenchId; }
|
||||
public virtual string ProcedureName() { return Batch.ProcedureName; }
|
||||
public virtual int ProcedureRevision() { return Batch.ProcedureRevision; }
|
||||
public virtual DateTime StartTime() { return Batch.StartTime; }
|
||||
public virtual DateTime EndTime() { return Batch.EndTime; }
|
||||
|
||||
protected MeterTestRslt lastMeterTestRslts;
|
||||
public virtual MeterTestRslt LastMeterTestRslts() { return lastMeterTestRslts; }
|
||||
|
||||
|
||||
public virtual bool PassedFromTests()
|
||||
{
|
||||
bool passed = true;
|
||||
foreach (var mtr in MeterTestRslts)
|
||||
{
|
||||
if (mtr.Evaluate() && (!mtr.Passed || !mtr.TestDone))
|
||||
{
|
||||
passed = false;
|
||||
break;
|
||||
}
|
||||
}
|
||||
return passed;
|
||||
}
|
||||
|
||||
///
|
||||
/// Not mapped to the database
|
||||
///
|
||||
public virtual bool Disabled { get; set; } /// true = Disabled water meters (not saved into DB)
|
||||
|
||||
|
||||
public virtual MeterTestRslt GetMeterTestRslt(string testName)
|
||||
{
|
||||
return GetMeterTestRslt(testName, CompoundMeterId.SingleOrCompound);
|
||||
}
|
||||
|
||||
public virtual MeterTestRslt GetMeterTestRslt(string testName, Config.Entities.CompoundMeterId meterId)
|
||||
{
|
||||
if (Disabled) return null;
|
||||
string testNameL = testName.ToLower();
|
||||
foreach (var mtr in MeterTestRslts)
|
||||
{
|
||||
if (mtr.Name().ToLower().Equals(testNameL))
|
||||
{
|
||||
if (mtr.CompoundMeterId == (byte)meterId)
|
||||
{
|
||||
return mtr;
|
||||
}
|
||||
else if (meterId == Config.Entities.CompoundMeterId.SingleOrCompound &&
|
||||
mtr.CompoundMeterId == (byte)Config.Entities.CompoundMeterId.Single)
|
||||
{
|
||||
return mtr;
|
||||
}
|
||||
else if (meterId == Config.Entities.CompoundMeterId.SingleOrCompound &&
|
||||
mtr.CompoundMeterId == (byte)Config.Entities.CompoundMeterId.Compound)
|
||||
{
|
||||
return mtr;
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public virtual TestRslt GetTestRslt(string testName)
|
||||
{
|
||||
MeterTestRslt mtr = GetMeterTestRslt(testName);
|
||||
if (mtr != null) return mtr.TestRslt;
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Constructor, initializes a list, used as a base for other constructors
|
||||
/// </summary>
|
||||
public WaterMeter()
|
||||
{
|
||||
MeterTestRslts = new List<MeterTestRslt>();
|
||||
}
|
||||
|
||||
|
||||
public override string ToString()
|
||||
{
|
||||
StringBuilder sb = new StringBuilder(80);
|
||||
#if IPERL
|
||||
sb.AppendFormat("PCB:{0} S/N:{1} ", SerialNr, SerialNrEx);
|
||||
#else
|
||||
sb.AppendFormat("S/N:{0} ", SerialNr);
|
||||
#endif
|
||||
|
||||
foreach (var tr in MeterTestRslts) sb.AppendFormat(" {0}:{1}%", tr.Name(), tr.Error.ToString("F2"));
|
||||
sb.AppendFormat(" test start: {0} {1} batch={2}", StartTime().ToShortDateString(), StartTime().ToShortTimeString(), BatchNr());
|
||||
return sb.ToString();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,132 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2016-2017 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
|
||||
namespace Results.Entities
|
||||
{
|
||||
public class WaterMeterData
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
|
||||
public virtual string ProductName { get; set; }
|
||||
public virtual string Producer { get; set; }
|
||||
|
||||
public virtual double DN { get; set; } /// [mm]
|
||||
public virtual double L { get; set; } /// [mm]
|
||||
public virtual Config.Entities.Mounting Mounting { get; set; } /// H / V / S / F
|
||||
|
||||
public virtual double Q4_Qmax { get; set; } /// [m3/h]
|
||||
public virtual double Q3_Qn { get; set; } /// [m3/h]
|
||||
public virtual double Q2_Qt { get; set; } /// [m3/h]
|
||||
public virtual double Q1_Qmin { get; set; } /// [m3/h]
|
||||
|
||||
public virtual string MetrologicalClass { get; set; }
|
||||
public virtual Config.Entities.TemperatureClass TemperatureClass { get; set; }
|
||||
public virtual Config.Entities.PressureLossClass PressureLossClass { get; set; }
|
||||
public virtual Config.Entities.MaxAdmissiblePressure MaxAdmissiblePressure { get; set; }
|
||||
public virtual Config.Entities.FlowProfileSensitivityClass FlowProfileSensitivityClass { get; set; }
|
||||
|
||||
public virtual string ApprovalInfo { get; set; }
|
||||
public virtual string Certificate { get; set; }
|
||||
|
||||
public virtual double PulsesPerLtr { get; set; }
|
||||
|
||||
/// Concerns compound water meters
|
||||
public virtual string ProducerAux { get; set; }
|
||||
public virtual double Q3_Qn_Aux { get; set; } /// [m3/h]
|
||||
public virtual string MetrologicalClassAux { get; set; }
|
||||
public virtual string ApprovalInfoAux { get; set; }
|
||||
|
||||
public virtual string Text1 { get; set; }
|
||||
public virtual string Text2 { get; set; }
|
||||
public virtual string Text3 { get; set; }
|
||||
public virtual string Text4 { get; set; }
|
||||
public virtual string Text5 { get; set; }
|
||||
|
||||
public virtual bool Compound { get; set; }
|
||||
public virtual bool HeatMeter { get; set; }
|
||||
|
||||
#if ORACLE_DB
|
||||
public virtual int WMTypeId { get; set; }
|
||||
public virtual int WMTypeRev { get; set; }
|
||||
#endif
|
||||
|
||||
public WaterMeterData()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Method to compare the content of two entities
|
||||
/// </summary>
|
||||
/// <param name="wmd">Second entity to compare with</param>
|
||||
/// <returns>first = two entities are equal (except of Id)</returns>
|
||||
public virtual bool Equals(WaterMeterData wmd)
|
||||
{
|
||||
if (!ProductName.Equals(wmd.ProductName)) return false;
|
||||
if (!Producer.Equals(wmd.Producer)) return false;
|
||||
|
||||
if (DN != wmd.DN) return false;
|
||||
if (L != wmd.L) return false;
|
||||
if (Mounting != wmd.Mounting) return false;
|
||||
|
||||
if (Q4_Qmax != wmd.Q4_Qmax) return false;
|
||||
if (Q3_Qn != wmd.Q3_Qn) return false;
|
||||
if (Q2_Qt != wmd.Q2_Qt) return false;
|
||||
if (Q1_Qmin != wmd.Q1_Qmin) return false;
|
||||
|
||||
if (!MetrologicalClass.Equals(wmd.MetrologicalClass)) return false;
|
||||
if (!TemperatureClass.Equals(wmd.TemperatureClass)) return false;
|
||||
if (!PressureLossClass.Equals(wmd.PressureLossClass)) return false;
|
||||
if (!MaxAdmissiblePressure.Equals(wmd.MaxAdmissiblePressure)) return false;
|
||||
if (!FlowProfileSensitivityClass.Equals(wmd.FlowProfileSensitivityClass)) return false;
|
||||
|
||||
if (!ApprovalInfo.Equals(wmd.ApprovalInfo)) return false;
|
||||
if (Certificate != wmd.Certificate) return false;
|
||||
|
||||
if (PulsesPerLtr != wmd.PulsesPerLtr) return false;
|
||||
|
||||
if (ProducerAux != wmd.ProducerAux) return false;
|
||||
if (Q3_Qn_Aux != wmd.Q3_Qn_Aux) return false;
|
||||
if (MetrologicalClassAux != wmd.MetrologicalClassAux) return false;
|
||||
if (ApprovalInfoAux != wmd.ApprovalInfoAux) return false;
|
||||
|
||||
if (Text1 != wmd.Text1) return false;
|
||||
if (Text2 != wmd.Text2) return false;
|
||||
if (Text3 != wmd.Text3) return false;
|
||||
if (Text4 != wmd.Text4) return false;
|
||||
if (Text5 != wmd.Text5) return false;
|
||||
|
||||
if (Compound != wmd.Compound) return false;
|
||||
if (HeatMeter != wmd.HeatMeter) return false;
|
||||
|
||||
#if ORACLE_DB
|
||||
if (WMTypeId != wmd.WMTypeId) return false;
|
||||
if (WMTypeRev != wmd.WMTypeRev) return false;
|
||||
#endif
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Adds an item to the list if it does not occur there
|
||||
/// </summary>
|
||||
/// <param name="list">List of items</param>
|
||||
/// <param name="item">Item to add to the list or find there</param>
|
||||
/// <returns>Item from the list (existing or added)</returns>
|
||||
public static WaterMeterData UpdateList(IList<WaterMeterData> list, WaterMeterData item)
|
||||
{
|
||||
if (item == null) return null; /// Null item is not stored in the list
|
||||
|
||||
WaterMeterData found = list.FirstOrDefault<WaterMeterData>(x => x.Equals(item));
|
||||
|
||||
if (found != null) return found; /// The same item found in the list, The found item returned
|
||||
|
||||
list.Add(item); /// Item not fund in the list, it is added to the list
|
||||
return item;
|
||||
}
|
||||
}
|
||||
}
|
||||
-63
@@ -1,63 +0,0 @@
|
||||
namespace Results.Forms
|
||||
{
|
||||
partial class BatchResultsDlg
|
||||
{
|
||||
/// <summary>
|
||||
/// Required designer variable.
|
||||
/// </summary>
|
||||
private System.ComponentModel.IContainer components = null;
|
||||
|
||||
/// <summary>
|
||||
/// Clean up any resources being used.
|
||||
/// </summary>
|
||||
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
|
||||
protected override void Dispose(bool disposing)
|
||||
{
|
||||
if (disposing && (components != null))
|
||||
{
|
||||
components.Dispose();
|
||||
}
|
||||
base.Dispose(disposing);
|
||||
}
|
||||
|
||||
#region Windows Form Designer generated code
|
||||
|
||||
/// <summary>
|
||||
/// Required method for Designer support - do not modify
|
||||
/// the contents of this method with the code editor.
|
||||
/// </summary>
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.flowLayoutPanel = new System.Windows.Forms.FlowLayoutPanel();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// flowLayoutPanel
|
||||
//
|
||||
this.flowLayoutPanel.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.flowLayoutPanel.Location = new System.Drawing.Point(0, 0);
|
||||
this.flowLayoutPanel.Name = "flowLayoutPanel";
|
||||
this.flowLayoutPanel.Size = new System.Drawing.Size(1058, 721);
|
||||
this.flowLayoutPanel.TabIndex = 0;
|
||||
this.flowLayoutPanel.SizeChanged += new System.EventHandler(this.flowLayoutPanel_SizeChanged);
|
||||
//
|
||||
// BatchResultsDlg
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(1058, 721);
|
||||
this.Controls.Add(this.flowLayoutPanel);
|
||||
this.Name = "BatchResultsDlg";
|
||||
this.Text = "Results";
|
||||
this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.BatchResultsDlg_FormClosing);
|
||||
this.Load += new System.EventHandler(this.BatchResultsDlg_Load);
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private System.Windows.Forms.FlowLayoutPanel flowLayoutPanel;
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
@@ -1,406 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Windows.Forms;
|
||||
using log4net;
|
||||
using Config.Entities;
|
||||
using Results.Resources;
|
||||
|
||||
namespace Results.Forms
|
||||
{
|
||||
public partial class BatchResultsDlg : Form
|
||||
{
|
||||
static readonly ILog log = LogManager.GetLogger(typeof(BatchResultsDlg));
|
||||
|
||||
DateTime lastRedraw;
|
||||
DateTime lastSizeChange;
|
||||
bool loaded;
|
||||
|
||||
///
|
||||
/// Public members
|
||||
///
|
||||
public MetersArrangement MetersArrangement;
|
||||
public TestsArrangement TestsArrangement;
|
||||
public int NrMetersInOneGroup;
|
||||
|
||||
public IList<Results.ItemSpec> RsltItems_Screen_SingleWM;
|
||||
public IList<Results.ItemSpec> RsltItems_Screen_CombinedWM;
|
||||
public int[] RsltsClmnWidths { set { rsltsClmnWidths = value; } }
|
||||
|
||||
public int PopupResultsLeft;
|
||||
public int PopupResultsTop;
|
||||
public int PopupResultsWidth;
|
||||
public int PopupResultsHeight;
|
||||
|
||||
public Results.BatchResults Results { set { Display(value); } }
|
||||
|
||||
///
|
||||
/// Private members
|
||||
///
|
||||
Results.BatchResults results;
|
||||
bool compound;
|
||||
|
||||
ListView firstListView;
|
||||
public int[] rsltsClmnWidths;
|
||||
int rsltsClmnCount { get { return (rsltsClmnWidths != null) ? rsltsClmnWidths.Length : 0; } }
|
||||
|
||||
int lvWidth;
|
||||
int lvHeight;
|
||||
|
||||
|
||||
Timer timer;
|
||||
|
||||
|
||||
public BatchResultsDlg()
|
||||
{
|
||||
InitializeComponent();
|
||||
Text = Strings.Results;
|
||||
|
||||
lastSizeChange = DateTime.Now;
|
||||
|
||||
// Create a timer with a ten second interval.
|
||||
timer = new Timer();
|
||||
timer.Interval = 500; /// ms
|
||||
timer.Tick += new EventHandler(OnTimer);
|
||||
timer.Start();
|
||||
}
|
||||
|
||||
private void BatchResultsDlg_Load(object sender, EventArgs e)
|
||||
{
|
||||
if (PopupResultsLeft != 0) Left = PopupResultsLeft;
|
||||
if (PopupResultsTop != 0) Top = PopupResultsTop;
|
||||
if (PopupResultsWidth != 0) Width = PopupResultsWidth;
|
||||
if (PopupResultsHeight != 0) Height = PopupResultsHeight;
|
||||
|
||||
loaded = true;
|
||||
if (results != null) Redraw();
|
||||
}
|
||||
|
||||
public void Display(Results.BatchResults results)
|
||||
{
|
||||
this.results = results;
|
||||
if (loaded) Redraw();
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Re-draw the results. Apply new settings if they changed.
|
||||
/// </summary>
|
||||
public void Redraw()
|
||||
{
|
||||
lastRedraw = DateTime.Now;
|
||||
|
||||
this.SuspendLayout();
|
||||
|
||||
try
|
||||
{
|
||||
/// Determine how many water meters were enabled for result evaluation and printing
|
||||
int enabledWMsCount = 0;
|
||||
for (int i = 0; i < results.WMPositionsCount; i++)
|
||||
{
|
||||
if (results.WaterMeters[i] != null && !results.WaterMeters[i].Disabled)
|
||||
{
|
||||
enabledWMsCount++;
|
||||
}
|
||||
}
|
||||
|
||||
int metersInOneGroup = Math.Max(1, Math.Min(enabledWMsCount, NrMetersInOneGroup));
|
||||
int nrGroups = Math.Max(1, (enabledWMsCount + NrMetersInOneGroup - 1) / metersInOneGroup);
|
||||
|
||||
if (MetersArrangement == MetersArrangement.Horizontally)
|
||||
{
|
||||
flowLayoutPanel.FlowDirection = FlowDirection.LeftToRight;
|
||||
lvWidth = flowLayoutPanel.Width / metersInOneGroup - 6;
|
||||
lvHeight = flowLayoutPanel.Height / nrGroups - 6;
|
||||
}
|
||||
else
|
||||
{
|
||||
flowLayoutPanel.FlowDirection = FlowDirection.TopDown;
|
||||
lvWidth = flowLayoutPanel.Width / nrGroups - 6;
|
||||
lvHeight = flowLayoutPanel.Height / metersInOneGroup - 6;
|
||||
}
|
||||
flowLayoutPanel.Controls.Clear();
|
||||
flowLayoutPanel.WrapContents = true;
|
||||
flowLayoutPanel.AutoScroll = true;
|
||||
|
||||
bool first = true;
|
||||
for (int i = 0; i < results.WMPositionsCount; i++)
|
||||
{
|
||||
if (results.WaterMeters[i] != null && !results.WaterMeters[i].Disabled)
|
||||
{
|
||||
if (TestsArrangement == TestsArrangement.Rows)
|
||||
{
|
||||
ListView lview = GetResultsTestsAreRows(results.WaterMeters[i], i + 1);
|
||||
if (first) { firstListView = lview; first = false; }
|
||||
if (lview != null) flowLayoutPanel.Controls.Add(lview);
|
||||
}
|
||||
else
|
||||
{
|
||||
ListView lview = GetResultsTestsAreColumns(results.WaterMeters[i], i + 1);
|
||||
if (first) { firstListView = lview; first = false; }
|
||||
if (lview != null) flowLayoutPanel.Controls.Add(lview);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
log.FatalFormat("Redrawing results failed : {0}", e.Message);
|
||||
if (e.InnerException != null)
|
||||
{
|
||||
log.FatalFormat("InnerMessage : {0}", e.InnerException.Message);
|
||||
}
|
||||
log.FatalFormat("StackTrace : {0}{1}", Environment.NewLine, e.StackTrace);
|
||||
}
|
||||
|
||||
this.ResumeLayout(false);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Get an empty ListView control with appropriate parameters.
|
||||
/// </summary>
|
||||
/// <returns>ListView control</returns>
|
||||
ListView GetListView()
|
||||
{
|
||||
ListView lview = new ListView();
|
||||
lview.AllowColumnReorder = false;
|
||||
lview.Dock = System.Windows.Forms.DockStyle.None;
|
||||
lview.FullRowSelect = true;
|
||||
lview.GridLines = true;
|
||||
lview.Location = new System.Drawing.Point(0, 0);
|
||||
lview.Size = new System.Drawing.Size(lvWidth, lvHeight);
|
||||
lview.TabIndex = 0;
|
||||
lview.UseCompatibleStateImageBehavior = false;
|
||||
lview.View = System.Windows.Forms.View.Details;
|
||||
return lview;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Get decorated test names for a specified watermeter
|
||||
/// </summary>
|
||||
/// <param name="wMtr">Watermeter results entity</param>
|
||||
/// <returns>A list of strings</returns>
|
||||
IList<string> GetAllDecoratedTestNames(Results.Entities.WaterMeter wMtr)
|
||||
{
|
||||
IList<string> testNames = new List<string>();
|
||||
|
||||
foreach (var mtr in wMtr.MeterTestRslts)
|
||||
{
|
||||
if ((mtr.CompoundMeterId == (byte)CompoundMeterId.Single || mtr.CompoundMeterId == (byte)CompoundMeterId.Compound)
|
||||
&& mtr.TestDone
|
||||
&& (mtr.Publish() != Config.Entities.Publish.Never)
|
||||
&& (mtr.Publish() != Config.Entities.Publish.Internal))
|
||||
{
|
||||
testNames.Add(mtr.Name());
|
||||
}
|
||||
}
|
||||
|
||||
return testNames;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Get a ListView control filled with results of the meter 'mtr'
|
||||
/// </summary>
|
||||
/// <param name="mtr">Water meter number (1-based): 1 .. Config.Data.WMsCount</param>
|
||||
/// <returns>ListView object</returns>
|
||||
ListView GetResultsTestsAreRows(Results.Entities.WaterMeter wMtr, int printedWMNr)
|
||||
{
|
||||
compound = wMtr.Compound();
|
||||
|
||||
ListView lview = GetListView();
|
||||
|
||||
IList<Results.ItemSpec> items = (compound ? RsltItems_Screen_CombinedWM : RsltItems_Screen_SingleWM);
|
||||
if (items == null || items.Count == 0) return lview;
|
||||
|
||||
// Header
|
||||
lview.Columns.Add(printedWMNr.ToString(), (rsltsClmnCount > 0) ? rsltsClmnWidths[0] : 40);
|
||||
int i = 1;
|
||||
foreach (var item in items)
|
||||
{
|
||||
lview.Columns.Add(item.ClmnHeaderText, (rsltsClmnCount > i) ? rsltsClmnWidths[i] : 70);
|
||||
i++;
|
||||
}
|
||||
|
||||
|
||||
IList<string> testNames = GetAllDecoratedTestNames(wMtr);
|
||||
int ix = 0;
|
||||
foreach (var mtr in wMtr.MeterTestRslts)
|
||||
{
|
||||
if ((mtr.CompoundMeterId == (byte)CompoundMeterId.Single || mtr.CompoundMeterId == (byte)CompoundMeterId.Compound)
|
||||
&& mtr.TestDone
|
||||
&& (mtr.Publish() != Config.Entities.Publish.Never)
|
||||
&& (mtr.Publish() != Config.Entities.Publish.Internal))
|
||||
{
|
||||
ListViewItem lvi = new ListViewItem(testNames[ix++]);
|
||||
|
||||
foreach (var item in items)
|
||||
{
|
||||
string str;
|
||||
if (compound)
|
||||
{
|
||||
var main = wMtr.GetMeterTestRslt(mtr.Name(), CompoundMeterId.CompoundMain);
|
||||
var aux = wMtr.GetMeterTestRslt(mtr.Name(), CompoundMeterId.CompoundAux);
|
||||
str = (item.CanPrintCompoundMeter && main != null && aux != null)
|
||||
? item.PrintCombined(main, aux, mtr)
|
||||
: string.Empty;
|
||||
}
|
||||
else
|
||||
{
|
||||
str = item.CanPrintSingle ? item.Print(mtr) : string.Empty;
|
||||
}
|
||||
|
||||
string[] texts = str.Split(new char[] { '|' });
|
||||
if (texts.Length == 1)
|
||||
{
|
||||
lvi.SubItems.Add(str);
|
||||
}
|
||||
else if (texts.Length == 2)
|
||||
{
|
||||
Color color = texts[1].Equals("Green") ? Color.Green : (texts[1].Equals("Red") ? Color.Red : Color.White);
|
||||
lvi.UseItemStyleForSubItems = false;
|
||||
lvi.SubItems.Add(texts[0]);
|
||||
lvi.SubItems[lvi.SubItems.Count - 1].BackColor = color;
|
||||
}
|
||||
else
|
||||
{
|
||||
lvi.SubItems.Add(string.Empty);
|
||||
}
|
||||
}
|
||||
|
||||
lview.Items.Add(lvi);
|
||||
}
|
||||
}
|
||||
|
||||
return lview;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Get a ListView control filled with results of the meter 'mtr'
|
||||
/// </summary>
|
||||
/// <param name="mtr">Water meter number (1-based): 1 .. Config.Data.WMsCount</param>
|
||||
/// <returns>ListView object</returns>
|
||||
ListView GetResultsTestsAreColumns(Results.Entities.WaterMeter wMtr, int printedWMNr)
|
||||
{
|
||||
compound = wMtr.Compound();
|
||||
|
||||
ListView lview = GetListView();
|
||||
|
||||
IList<Results.ItemSpec> items = (compound ? RsltItems_Screen_CombinedWM : RsltItems_Screen_SingleWM);
|
||||
if (items == null || items.Count == 0) return lview;
|
||||
|
||||
// Header
|
||||
lview.Columns.Add(printedWMNr.ToString(), (rsltsClmnCount > 0) ? rsltsClmnWidths[0] : 40);
|
||||
int i = 1;
|
||||
foreach (var str in GetAllDecoratedTestNames(wMtr))
|
||||
{
|
||||
lview.Columns.Add(str, (rsltsClmnCount > i) ? rsltsClmnWidths[i] : 70);
|
||||
i++;
|
||||
}
|
||||
|
||||
foreach (var item in items)
|
||||
{
|
||||
ListViewItem lvi = new ListViewItem(item.ClmnHeaderText);
|
||||
if (compound)
|
||||
{
|
||||
foreach (var mtr in wMtr.MeterTestRslts)
|
||||
{
|
||||
if (mtr.CompoundMeterId == (byte)CompoundMeterId.Compound && mtr.TestDone
|
||||
&& (mtr.Publish() != Config.Entities.Publish.Never)
|
||||
&& (mtr.Publish() != Config.Entities.Publish.Internal))
|
||||
{
|
||||
var main = wMtr.GetMeterTestRslt(mtr.Name(), CompoundMeterId.CompoundMain);
|
||||
var aux = wMtr.GetMeterTestRslt(mtr.Name(), CompoundMeterId.CompoundAux);
|
||||
|
||||
string str = (item.CanPrintCompoundMeter && main != null && aux != null)
|
||||
? item.PrintCombined(main, aux, mtr)
|
||||
: string.Empty;
|
||||
|
||||
string[] texts = str.Split(new char[] { '|' });
|
||||
if (texts.Length == 1)
|
||||
{
|
||||
lvi.SubItems.Add(str);
|
||||
}
|
||||
else if (texts.Length == 2)
|
||||
{
|
||||
Color color = texts[1].Equals("Green") ? Color.Green : (texts[1].Equals("Red") ? Color.Red : Color.White);
|
||||
lvi.UseItemStyleForSubItems = false;
|
||||
lvi.SubItems.Add(texts[0]);
|
||||
lvi.SubItems[lvi.SubItems.Count - 1].BackColor = color;
|
||||
}
|
||||
else
|
||||
{
|
||||
lvi.SubItems.Add(string.Empty);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
foreach (var mtr in wMtr.MeterTestRslts)
|
||||
{
|
||||
if (mtr.TestDone && (mtr.Publish() != Config.Entities.Publish.Never)
|
||||
&& (mtr.Publish() != Config.Entities.Publish.Internal))
|
||||
{
|
||||
string str = !item.CanPrintSingle ? string.Empty : item.Print(mtr);
|
||||
|
||||
string[] texts = str.Split(new char[] { '|' });
|
||||
if (texts.Length == 1)
|
||||
{
|
||||
lvi.SubItems.Add(str);
|
||||
}
|
||||
else if (texts.Length == 2)
|
||||
{
|
||||
Color color = texts[1].Equals("Green") ? Color.Green : (texts[1].Equals("Red") ? Color.Red : Color.White);
|
||||
lvi.UseItemStyleForSubItems = false;
|
||||
lvi.SubItems.Add(texts[0]);
|
||||
lvi.SubItems[lvi.SubItems.Count - 1].BackColor = color;
|
||||
}
|
||||
else
|
||||
{
|
||||
lvi.SubItems.Add(string.Empty);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
lview.Items.Add(lvi);
|
||||
}
|
||||
|
||||
return lview;
|
||||
}
|
||||
|
||||
private void BatchResultsDlg_FormClosing(object sender, FormClosingEventArgs e)
|
||||
{
|
||||
PopupResultsLeft = Left;
|
||||
PopupResultsTop = Top;
|
||||
PopupResultsWidth = Width;
|
||||
PopupResultsHeight = Height;
|
||||
}
|
||||
|
||||
private void flowLayoutPanel_SizeChanged(object sender, EventArgs e)
|
||||
{
|
||||
lastSizeChange = DateTime.Now;
|
||||
}
|
||||
|
||||
private void OnTimer(object source, EventArgs e)
|
||||
{
|
||||
if (DateTime.Compare(lastSizeChange, lastRedraw) > 0)
|
||||
{
|
||||
/// The last size change was later then the last redraw
|
||||
|
||||
DateTime now = DateTime.Now;
|
||||
if (DateTime.Compare(lastSizeChange + new TimeSpan(0, 0, 1), now) < 0)
|
||||
{
|
||||
/// More then 1s since the last size change
|
||||
Redraw();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,510 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2016 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Windows.Forms;
|
||||
using log4net;
|
||||
using Config.Entities;
|
||||
using Results;
|
||||
using Results.Resources;
|
||||
|
||||
namespace Results.Forms
|
||||
{
|
||||
public partial class ResultsConfigDlg : Form
|
||||
{
|
||||
/// <summary>
|
||||
/// ListViewEx columns
|
||||
/// </summary>
|
||||
enum Column
|
||||
{
|
||||
Item,
|
||||
Caption,
|
||||
Units,
|
||||
Format,
|
||||
Precision,
|
||||
Width,
|
||||
Alignment,
|
||||
TestID,
|
||||
Count,
|
||||
}
|
||||
|
||||
Control[] editors; /// all editors except of units
|
||||
ComboBox unitsCB; /// units combo box
|
||||
|
||||
|
||||
public IList<WMeterRsltItemSpec> AvailableItems;
|
||||
public IList<WMeterRsltItemSpec> SelectedItems;
|
||||
|
||||
public MetersKind MetersKind;
|
||||
|
||||
|
||||
bool supressTestIDColumn;
|
||||
|
||||
|
||||
public ResultsConfigDlg(bool supressTestIDColumn)
|
||||
: this()
|
||||
{
|
||||
this.supressTestIDColumn = supressTestIDColumn;
|
||||
}
|
||||
|
||||
public ResultsConfigDlg()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
|
||||
void Localize()
|
||||
{
|
||||
Text = Strings.Configuration;
|
||||
availableResultsLabel.Text = Strings.Available_results;
|
||||
availableTabControl.TabPages[0].Text = "A...Z";
|
||||
availableTabControl.TabPages[1].Text = Strings.Quantity;
|
||||
availableTabControl.TabPages[2].Text = Strings.Category;
|
||||
|
||||
selectedResultsLabel.Text = Strings.Selected_results;
|
||||
|
||||
addButton.Text = Strings.Add;
|
||||
removeButton.Text = Strings.Remove;
|
||||
removeAllButton.Text = Strings.Remove_all;
|
||||
okButton.Text = Strings.OkBtnText;
|
||||
cancelButton.Text = Strings.CancelBtnText;
|
||||
upButton.Text = Strings.UpBtnText;
|
||||
downButton.Text = Strings.DownBtnText;
|
||||
}
|
||||
|
||||
void ResultsConfig_Load(object sender, EventArgs e)
|
||||
{
|
||||
Localize();
|
||||
|
||||
/// Add columns to ListViewEx
|
||||
selectedResultsListViewEx.Columns.Add(new ColumnHeader { Text = Strings.Item, Width = 120 });
|
||||
selectedResultsListViewEx.Columns.Add(new ColumnHeader { Text = Strings.Caption });
|
||||
selectedResultsListViewEx.Columns.Add(new ColumnHeader { Text = Strings.Units });
|
||||
selectedResultsListViewEx.Columns.Add(new ColumnHeader { Text = Strings.Format });
|
||||
selectedResultsListViewEx.Columns.Add(new ColumnHeader { Text = Strings.Precision });
|
||||
selectedResultsListViewEx.Columns.Add(new ColumnHeader { Text = Strings.Width });
|
||||
selectedResultsListViewEx.Columns.Add(new ColumnHeader { Text = Strings.Alignment });
|
||||
if (!supressTestIDColumn)
|
||||
{
|
||||
selectedResultsListViewEx.Columns.Add(new ColumnHeader { Text = Strings.Test_ID });
|
||||
}
|
||||
|
||||
/// Create controls used by ListViewEx to edit items
|
||||
unitsCB = new ComboBox();
|
||||
|
||||
ComboBox alignmentCB = new ComboBox();
|
||||
for (Config.Entities.Alignment a = 0; a < Config.Entities.Alignment.Count; a++)
|
||||
{
|
||||
alignmentCB.Items.Add(a.ToDescription());
|
||||
}
|
||||
|
||||
editors = new Control[]
|
||||
{
|
||||
null,
|
||||
new TextBox(), /// caption
|
||||
unitsCB,
|
||||
new TextBox(), /// format
|
||||
new TextBox(), /// precision
|
||||
new TextBox(), /// width
|
||||
alignmentCB,
|
||||
new TextBox(), /// testID
|
||||
};
|
||||
foreach (var edi in editors)
|
||||
{
|
||||
if (edi != null)
|
||||
{
|
||||
edi.Visible = false;
|
||||
Controls.Add(edi);
|
||||
}
|
||||
}
|
||||
|
||||
selectedResultsListViewEx.SubItemClicked += new SubItemEventHandler(selectedResultsListViewEx_SubItemClicked);
|
||||
selectedResultsListViewEx.SubItemEndEditing += new SubItemEndEditingEventHandler(selectedResultsListViewEx_SubItemEndEditing);
|
||||
|
||||
//availableAlphabeticTreeView.ShowNodeToolTips = true;
|
||||
//availableByQuantityTreeView.ShowNodeToolTips = true;
|
||||
//availableByCategoryTreeView.ShowNodeToolTips = true;
|
||||
|
||||
RedrawAvailable();
|
||||
RedrawSelected();
|
||||
}
|
||||
|
||||
void selectedResultsListViewEx_SubItemClicked(object sender, SubItemEventArgs e)
|
||||
{
|
||||
if (e.SubItem == (int)Column.Units)
|
||||
{
|
||||
Config.Quantity quantity = (e.Item.Tag as WMeterRsltItemSpec).Quantity;
|
||||
unitsCB.Items.Clear();
|
||||
unitsCB.Items.Add(Config.Unit.None.ToDescription()); /// "---"
|
||||
for (Config.Unit u = (Config.Unit)1; u < Config.Unit.Count; u++)
|
||||
{
|
||||
if (Config.Units.IsQuantity(u, quantity)) unitsCB.Items.Add(u.ToDescription());
|
||||
}
|
||||
selectedResultsListViewEx.StartEditing(unitsCB, e.Item, e.SubItem);
|
||||
}
|
||||
else if ((e.SubItem > 0) && (e.SubItem < (int)(supressTestIDColumn ? Column.TestID : Column.Count)))
|
||||
{
|
||||
selectedResultsListViewEx.StartEditing(editors[e.SubItem], e.Item, e.SubItem);
|
||||
}
|
||||
}
|
||||
|
||||
void selectedResultsListViewEx_SubItemEndEditing(object sender, SubItemEndEditingEventArgs e)
|
||||
{
|
||||
ListViewItem lvi = e.Item;
|
||||
WMeterRsltItemSpec item = lvi.Tag as WMeterRsltItemSpec;
|
||||
|
||||
switch ((Column)e.SubItem)
|
||||
{
|
||||
case Column.Caption: item.Caption = e.DisplayText; return;
|
||||
case Column.Units:
|
||||
for (Config.Unit u = 0; u < Config.Unit.Count; u++)
|
||||
{
|
||||
if (u.ToDescription().Equals(unitsCB.Text))
|
||||
{
|
||||
item.Units = u;
|
||||
return; /// OK
|
||||
}
|
||||
}
|
||||
break; /// Error
|
||||
|
||||
case Column.Format: item.Format = e.DisplayText; return;
|
||||
case Column.Precision: item.Precision = e.DisplayText; return;
|
||||
case Column.Width:
|
||||
{
|
||||
int width;
|
||||
if (Int32.TryParse(editors[e.SubItem].Text, out width) && width >= 0)
|
||||
{
|
||||
item.Width = width;
|
||||
return; /// OK
|
||||
}
|
||||
break; /// Error
|
||||
}
|
||||
|
||||
case Column.Alignment:
|
||||
for (Config.Entities.Alignment a = 0; a < Config.Entities.Alignment.Count; a++)
|
||||
{
|
||||
if (a.ToDescription().Equals(editors[e.SubItem].Text))
|
||||
{
|
||||
item.Alignment = a;
|
||||
return;
|
||||
}
|
||||
}
|
||||
break; /// Error
|
||||
|
||||
case Column.TestID: item.TestID = e.DisplayText; return;
|
||||
|
||||
default:
|
||||
return; /// OK
|
||||
}
|
||||
|
||||
e.DisplayText = e.Item.SubItems[e.SubItem].Text;
|
||||
e.Cancel = true;
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Redraw available items (right hand side)
|
||||
/// </summary>
|
||||
void RedrawAvailable()
|
||||
{
|
||||
RedrawInAlphabeticOrder(availableAlphabeticTreeView);
|
||||
RedrawByQuantity(availableByQuantityTreeView);
|
||||
RedrawByCategory(availableByCategoryTreeView);
|
||||
}
|
||||
|
||||
|
||||
void RedrawInAlphabeticOrder(TreeView treeView)
|
||||
{
|
||||
treeView.Nodes.Clear();
|
||||
|
||||
IList<WMeterRsltItemSpec> alphabeticlList = WMeterRsltItemSpec.AllItems.OrderBy(x => x.Name).ToList();
|
||||
///
|
||||
foreach (var item in alphabeticlList)
|
||||
{
|
||||
TreeNode node = new TreeNode(item.Name);
|
||||
node.Tag = item;
|
||||
node.ToolTipText = item.ToolTipText;
|
||||
availableAlphabeticTreeView.Nodes.Add(node);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void RedrawByQuantity(TreeView treeView)
|
||||
{
|
||||
treeView.Nodes.Clear();
|
||||
|
||||
IList<Config.Quantity> quantities = new List<Config.Quantity>();
|
||||
for (Config.Quantity q = 0; q < Config.Quantity.Count; q++) quantities.Add(q);
|
||||
|
||||
IList<Config.Quantity> sortedQuantities = quantities.OrderBy(x => x.ToDescription()).ToList();
|
||||
|
||||
foreach (var q in sortedQuantities)
|
||||
{
|
||||
int n = 0;
|
||||
foreach (var ri in WMeterRsltItemSpec.AllItems)
|
||||
{
|
||||
if (ri.Quantity == q) n++;
|
||||
}
|
||||
|
||||
if (n > 0)
|
||||
{
|
||||
TreeNode[] array = new TreeNode[n];
|
||||
int i = 0;
|
||||
foreach (var ri in WMeterRsltItemSpec.AllItems)
|
||||
{
|
||||
if (ri.Quantity == q)
|
||||
{
|
||||
TreeNode node = new TreeNode(ri.Name);
|
||||
node.Tag = ri;
|
||||
node.ToolTipText = ri.ToolTipText;
|
||||
array[i++] = node;
|
||||
}
|
||||
}
|
||||
|
||||
treeView.Nodes.Add(new TreeNode(q.ToDescription(), array));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void RedrawByCategory(TreeView treeView)
|
||||
{
|
||||
treeView.Nodes.Clear();
|
||||
|
||||
IList<ItemCategory> categories = new List<ItemCategory>();
|
||||
for (ItemCategory c = 0; c < ItemCategory.Count; c++) categories.Add(c);
|
||||
|
||||
IList<ItemCategory> sortedCategories = categories.OrderBy(x => x.ToDescription()).ToList();
|
||||
|
||||
foreach (var c in sortedCategories)
|
||||
{
|
||||
int n = 0;
|
||||
foreach (var ri in WMeterRsltItemSpec.AllItems)
|
||||
{
|
||||
if (ri.Category == c) n++;
|
||||
}
|
||||
|
||||
if (n > 0)
|
||||
{
|
||||
TreeNode[] array = new TreeNode[n];
|
||||
int i = 0;
|
||||
foreach (var ri in WMeterRsltItemSpec.AllItems)
|
||||
{
|
||||
if (ri.Category == c)
|
||||
{
|
||||
TreeNode node = new TreeNode(ri.Name);
|
||||
node.Tag = ri;
|
||||
node.ToolTipText = ri.ToolTipText;
|
||||
array[i++] = node;
|
||||
}
|
||||
}
|
||||
|
||||
treeView.Nodes.Add(new TreeNode(c.ToDescription(), array));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Redraw selected items (right hand side)
|
||||
/// </summary>
|
||||
void RedrawSelected()
|
||||
{
|
||||
selectedResultsListViewEx.Items.Clear();
|
||||
foreach (var item in SelectedItems)
|
||||
{
|
||||
ListViewItem lvi = new ListViewItem(item.Name); /// Item
|
||||
lvi.Tag = item;
|
||||
lvi.SubItems.Add(item.Caption); /// Header
|
||||
lvi.SubItems.Add(item.Units.ToDescription()); /// Units
|
||||
lvi.SubItems.Add(item.Format); /// Format
|
||||
lvi.SubItems.Add(item.Precision); /// Precision
|
||||
lvi.SubItems.Add(item.Width.ToString()); /// Width
|
||||
lvi.SubItems.Add(item.Alignment.ToDescription()); /// Alignment
|
||||
if (!supressTestIDColumn)
|
||||
{
|
||||
lvi.SubItems.Add(item.TestID); /// TestID
|
||||
}
|
||||
|
||||
selectedResultsListViewEx.Items.Add(lvi);
|
||||
}
|
||||
}
|
||||
|
||||
void UpdateSelectedFromView()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
void addButton_Click(object sender, EventArgs e)
|
||||
{
|
||||
switch (availableTabControl.SelectedIndex)
|
||||
{
|
||||
case 0:
|
||||
availableAlphabeticTreeView_DoubleClick(this, null);
|
||||
break;
|
||||
case 1:
|
||||
availableByQuantityTreeView_DoubleClick(this, null);
|
||||
break;
|
||||
case 2:
|
||||
availableByCategoryTreeView_DoubleClick(this, null);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
private void availableAlphabeticTreeView_DoubleClick(object sender, EventArgs e)
|
||||
{
|
||||
if (availableAlphabeticTreeView.SelectedNode != null &&
|
||||
availableAlphabeticTreeView.SelectedNode.Tag is WMeterRsltItemSpec)
|
||||
{
|
||||
AddItem(availableAlphabeticTreeView.SelectedNode.Tag as WMeterRsltItemSpec);
|
||||
}
|
||||
}
|
||||
|
||||
private void availableByQuantityTreeView_DoubleClick(object sender, EventArgs e)
|
||||
{
|
||||
if (availableByQuantityTreeView.SelectedNode != null &&
|
||||
availableByQuantityTreeView.SelectedNode.Tag is WMeterRsltItemSpec)
|
||||
{
|
||||
AddItem(availableByQuantityTreeView.SelectedNode.Tag as WMeterRsltItemSpec);
|
||||
}
|
||||
}
|
||||
|
||||
private void availableByCategoryTreeView_DoubleClick(object sender, EventArgs e)
|
||||
{
|
||||
if (availableByCategoryTreeView.SelectedNode != null &&
|
||||
availableByCategoryTreeView.SelectedNode.Tag is WMeterRsltItemSpec)
|
||||
{
|
||||
AddItem(availableByCategoryTreeView.SelectedNode.Tag as WMeterRsltItemSpec);
|
||||
}
|
||||
}
|
||||
|
||||
void AddItem(WMeterRsltItemSpec item)
|
||||
{
|
||||
WMeterRsltItemSpec newItem = item.Clone();
|
||||
newItem.Caption = newItem.Name;
|
||||
SelectedItems.Add(newItem);
|
||||
RedrawSelected();
|
||||
|
||||
/// Select the last item
|
||||
selectedResultsListViewEx.Focus();
|
||||
selectedResultsListViewEx.Items[SelectedItems.Count - 1].Selected = true;
|
||||
selectedResultsListViewEx.Items[SelectedItems.Count - 1].EnsureVisible();
|
||||
}
|
||||
|
||||
|
||||
private void selectedResultsListBox_DoubleClick(object sender, EventArgs e)
|
||||
{
|
||||
/// Double click works when just one item is selected
|
||||
|
||||
if (selectedResultsListViewEx.SelectedIndices.Count == 1)
|
||||
{
|
||||
SelectedItems.RemoveAt(selectedResultsListViewEx.SelectedIndices[0]);
|
||||
RedrawAvailable();
|
||||
RedrawSelected();
|
||||
}
|
||||
}
|
||||
|
||||
void removeButton_Click(object sender, EventArgs e)
|
||||
{
|
||||
/// Remove from the list (the last selected item first so that the indexes are not affected)
|
||||
|
||||
for (int i = selectedResultsListViewEx.SelectedIndices.Count - 1; i >= 0; i--)
|
||||
{
|
||||
SelectedItems.RemoveAt(selectedResultsListViewEx.SelectedIndices[i]);
|
||||
}
|
||||
RedrawAvailable();
|
||||
RedrawSelected();
|
||||
}
|
||||
|
||||
void removeAllButton_Click(object sender, EventArgs e)
|
||||
{
|
||||
/// Remove all items from 'Selected' list
|
||||
|
||||
SelectedItems.Clear();
|
||||
RedrawAvailable();
|
||||
RedrawSelected();
|
||||
}
|
||||
|
||||
void okButton_Click(object sender, EventArgs e)
|
||||
{
|
||||
DialogResult = DialogResult.OK;
|
||||
Close();
|
||||
}
|
||||
|
||||
private void ResultsConfigDlg_KeyPress(object sender, KeyPressEventArgs e)
|
||||
{
|
||||
e.Handled = true;
|
||||
}
|
||||
|
||||
private void upButton_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (selectedResultsListViewEx.SelectedIndices.Count != 1) return;
|
||||
|
||||
int selIdx = selectedResultsListViewEx.SelectedIndices[0];
|
||||
if (selIdx == 0)
|
||||
{
|
||||
/// Cannot move up
|
||||
selectedResultsListViewEx.Focus();
|
||||
selectedResultsListViewEx.Items[0].Selected = true;
|
||||
return;
|
||||
}
|
||||
|
||||
WMeterRsltItemSpec tmp = SelectedItems[selIdx - 1];
|
||||
SelectedItems[selIdx - 1] = SelectedItems[selIdx];
|
||||
SelectedItems[selIdx] = tmp;
|
||||
|
||||
RedrawSelected();
|
||||
|
||||
selectedResultsListViewEx.Focus();
|
||||
selectedResultsListViewEx.Items[selIdx - 1].Selected = true;
|
||||
selectedResultsListViewEx.Items[selIdx - 1].EnsureVisible();
|
||||
}
|
||||
|
||||
private void downButton_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (selectedResultsListViewEx.SelectedIndices.Count != 1) return;
|
||||
|
||||
int selIdx = selectedResultsListViewEx.SelectedIndices[0];
|
||||
if (selIdx == SelectedItems.Count - 1)
|
||||
{
|
||||
/// Cannot move down
|
||||
selectedResultsListViewEx.Focus();
|
||||
selectedResultsListViewEx.Items[SelectedItems.Count - 1].Selected = true;
|
||||
return;
|
||||
}
|
||||
|
||||
WMeterRsltItemSpec tmp = SelectedItems[selIdx + 1];
|
||||
SelectedItems[selIdx + 1] = SelectedItems[selIdx];
|
||||
SelectedItems[selIdx] = tmp;
|
||||
|
||||
RedrawSelected();
|
||||
|
||||
selectedResultsListViewEx.Focus();
|
||||
selectedResultsListViewEx.Items[selIdx + 1].Selected = true;
|
||||
selectedResultsListViewEx.Items[selIdx + 1].EnsureVisible();
|
||||
}
|
||||
|
||||
private void cancelButton_Click(object sender, EventArgs e)
|
||||
{
|
||||
DialogResult = DialogResult.Cancel;
|
||||
Close();
|
||||
}
|
||||
|
||||
private void tabPage1_Click(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
private void availableByCategoryTreeView_NodeMouseHover(object sender, TreeNodeMouseHoverEventArgs e)
|
||||
{
|
||||
ToolTip toolTip = new ToolTip();
|
||||
toolTip.SetToolTip(this, e.Node.ToolTipText);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
-289
@@ -1,289 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2016 Sensus Metering Systems
|
||||
///
|
||||
namespace Results.Forms
|
||||
{
|
||||
partial class ResultsConfigDlg
|
||||
{
|
||||
/// <summary>
|
||||
/// Required designer variable.
|
||||
/// </summary>
|
||||
private System.ComponentModel.IContainer components = null;
|
||||
|
||||
/// <summary>
|
||||
/// Clean up any resources being used.
|
||||
/// </summary>
|
||||
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
|
||||
protected override void Dispose(bool disposing)
|
||||
{
|
||||
if (disposing && (components != null))
|
||||
{
|
||||
components.Dispose();
|
||||
}
|
||||
base.Dispose(disposing);
|
||||
}
|
||||
|
||||
#region Windows Form Designer generated code
|
||||
|
||||
/// <summary>
|
||||
/// Required method for Designer support - do not modify
|
||||
/// the contents of this method with the code editor.
|
||||
/// </summary>
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.components = new System.ComponentModel.Container();
|
||||
this.okButton = new System.Windows.Forms.Button();
|
||||
this.cancelButton = new System.Windows.Forms.Button();
|
||||
this.availableResultsLabel = new System.Windows.Forms.Label();
|
||||
this.selectedResultsLabel = new System.Windows.Forms.Label();
|
||||
this.removeAllButton = new System.Windows.Forms.Button();
|
||||
this.removeButton = new System.Windows.Forms.Button();
|
||||
this.addButton = new System.Windows.Forms.Button();
|
||||
this.upButton = new System.Windows.Forms.Button();
|
||||
this.downButton = new System.Windows.Forms.Button();
|
||||
this.availableTabControl = new System.Windows.Forms.TabControl();
|
||||
this.tabPage1 = new System.Windows.Forms.TabPage();
|
||||
this.availableAlphabeticTreeView = new System.Windows.Forms.TreeView();
|
||||
this.tabPage2 = new System.Windows.Forms.TabPage();
|
||||
this.availableByQuantityTreeView = new System.Windows.Forms.TreeView();
|
||||
this.tabPage3 = new System.Windows.Forms.TabPage();
|
||||
this.availableByCategoryTreeView = new System.Windows.Forms.TreeView();
|
||||
this.selectedResultsListViewEx = new Results.Forms.ListViewEx();
|
||||
this.availableTabControl.SuspendLayout();
|
||||
this.tabPage1.SuspendLayout();
|
||||
this.tabPage2.SuspendLayout();
|
||||
this.tabPage3.SuspendLayout();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// okButton
|
||||
//
|
||||
this.okButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.okButton.Location = new System.Drawing.Point(373, 499);
|
||||
this.okButton.Name = "okButton";
|
||||
this.okButton.Size = new System.Drawing.Size(105, 30);
|
||||
this.okButton.TabIndex = 4;
|
||||
this.okButton.Text = "OK";
|
||||
this.okButton.UseVisualStyleBackColor = true;
|
||||
this.okButton.Click += new System.EventHandler(this.okButton_Click);
|
||||
//
|
||||
// cancelButton
|
||||
//
|
||||
this.cancelButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.cancelButton.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
||||
this.cancelButton.Location = new System.Drawing.Point(494, 499);
|
||||
this.cancelButton.Name = "cancelButton";
|
||||
this.cancelButton.Size = new System.Drawing.Size(105, 30);
|
||||
this.cancelButton.TabIndex = 5;
|
||||
this.cancelButton.Text = "Cancel";
|
||||
this.cancelButton.UseVisualStyleBackColor = true;
|
||||
this.cancelButton.Click += new System.EventHandler(this.cancelButton_Click);
|
||||
//
|
||||
// availableResultsLabel
|
||||
//
|
||||
this.availableResultsLabel.AutoSize = true;
|
||||
this.availableResultsLabel.Location = new System.Drawing.Point(12, 9);
|
||||
this.availableResultsLabel.Name = "availableResultsLabel";
|
||||
this.availableResultsLabel.Size = new System.Drawing.Size(86, 13);
|
||||
this.availableResultsLabel.TabIndex = 8;
|
||||
this.availableResultsLabel.Text = "Available results:";
|
||||
//
|
||||
// selectedResultsLabel
|
||||
//
|
||||
this.selectedResultsLabel.AutoSize = true;
|
||||
this.selectedResultsLabel.Location = new System.Drawing.Point(284, 9);
|
||||
this.selectedResultsLabel.Name = "selectedResultsLabel";
|
||||
this.selectedResultsLabel.Size = new System.Drawing.Size(85, 13);
|
||||
this.selectedResultsLabel.TabIndex = 9;
|
||||
this.selectedResultsLabel.Text = "Selected results:";
|
||||
//
|
||||
// removeAllButton
|
||||
//
|
||||
this.removeAllButton.Location = new System.Drawing.Point(218, 221);
|
||||
this.removeAllButton.Name = "removeAllButton";
|
||||
this.removeAllButton.Size = new System.Drawing.Size(94, 30);
|
||||
this.removeAllButton.TabIndex = 46;
|
||||
this.removeAllButton.Text = "<< R&emove all";
|
||||
this.removeAllButton.UseVisualStyleBackColor = true;
|
||||
this.removeAllButton.Click += new System.EventHandler(this.removeAllButton_Click);
|
||||
//
|
||||
// removeButton
|
||||
//
|
||||
this.removeButton.Location = new System.Drawing.Point(218, 186);
|
||||
this.removeButton.Name = "removeButton";
|
||||
this.removeButton.Size = new System.Drawing.Size(93, 30);
|
||||
this.removeButton.TabIndex = 45;
|
||||
this.removeButton.Text = "< &Remove";
|
||||
this.removeButton.UseVisualStyleBackColor = true;
|
||||
this.removeButton.Click += new System.EventHandler(this.removeButton_Click);
|
||||
//
|
||||
// addButton
|
||||
//
|
||||
this.addButton.Location = new System.Drawing.Point(218, 151);
|
||||
this.addButton.Name = "addButton";
|
||||
this.addButton.Size = new System.Drawing.Size(93, 30);
|
||||
this.addButton.TabIndex = 44;
|
||||
this.addButton.Text = "&Add >";
|
||||
this.addButton.UseVisualStyleBackColor = true;
|
||||
this.addButton.Click += new System.EventHandler(this.addButton_Click);
|
||||
//
|
||||
// upButton
|
||||
//
|
||||
this.upButton.Location = new System.Drawing.Point(218, 313);
|
||||
this.upButton.Name = "upButton";
|
||||
this.upButton.Size = new System.Drawing.Size(93, 30);
|
||||
this.upButton.TabIndex = 48;
|
||||
this.upButton.Text = "Up";
|
||||
this.upButton.UseVisualStyleBackColor = true;
|
||||
this.upButton.Click += new System.EventHandler(this.upButton_Click);
|
||||
//
|
||||
// downButton
|
||||
//
|
||||
this.downButton.Location = new System.Drawing.Point(218, 349);
|
||||
this.downButton.Name = "downButton";
|
||||
this.downButton.Size = new System.Drawing.Size(93, 30);
|
||||
this.downButton.TabIndex = 49;
|
||||
this.downButton.Text = "Down";
|
||||
this.downButton.UseVisualStyleBackColor = true;
|
||||
this.downButton.Click += new System.EventHandler(this.downButton_Click);
|
||||
//
|
||||
// availableTabControl
|
||||
//
|
||||
this.availableTabControl.Controls.Add(this.tabPage1);
|
||||
this.availableTabControl.Controls.Add(this.tabPage2);
|
||||
this.availableTabControl.Controls.Add(this.tabPage3);
|
||||
this.availableTabControl.Location = new System.Drawing.Point(6, 31);
|
||||
this.availableTabControl.Name = "availableTabControl";
|
||||
this.availableTabControl.SelectedIndex = 0;
|
||||
this.availableTabControl.Size = new System.Drawing.Size(206, 453);
|
||||
this.availableTabControl.TabIndex = 50;
|
||||
//
|
||||
// tabPage1
|
||||
//
|
||||
this.tabPage1.Controls.Add(this.availableAlphabeticTreeView);
|
||||
this.tabPage1.Location = new System.Drawing.Point(4, 22);
|
||||
this.tabPage1.Name = "tabPage1";
|
||||
this.tabPage1.Padding = new System.Windows.Forms.Padding(3);
|
||||
this.tabPage1.Size = new System.Drawing.Size(198, 427);
|
||||
this.tabPage1.TabIndex = 0;
|
||||
this.tabPage1.Text = "A...Z";
|
||||
this.tabPage1.UseVisualStyleBackColor = true;
|
||||
this.tabPage1.Click += new System.EventHandler(this.tabPage1_Click);
|
||||
//
|
||||
// availableAlphabeticTreeView
|
||||
//
|
||||
this.availableAlphabeticTreeView.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.availableAlphabeticTreeView.Location = new System.Drawing.Point(3, 3);
|
||||
this.availableAlphabeticTreeView.Name = "availableAlphabeticTreeView";
|
||||
this.availableAlphabeticTreeView.Size = new System.Drawing.Size(192, 421);
|
||||
this.availableAlphabeticTreeView.TabIndex = 0;
|
||||
this.availableAlphabeticTreeView.DoubleClick += new System.EventHandler(this.availableAlphabeticTreeView_DoubleClick);
|
||||
//
|
||||
// tabPage2
|
||||
//
|
||||
this.tabPage2.Controls.Add(this.availableByQuantityTreeView);
|
||||
this.tabPage2.Location = new System.Drawing.Point(4, 22);
|
||||
this.tabPage2.Name = "tabPage2";
|
||||
this.tabPage2.Padding = new System.Windows.Forms.Padding(3);
|
||||
this.tabPage2.Size = new System.Drawing.Size(198, 427);
|
||||
this.tabPage2.TabIndex = 1;
|
||||
this.tabPage2.Text = "by quantity";
|
||||
this.tabPage2.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// availableByQuantityTreeView
|
||||
//
|
||||
this.availableByQuantityTreeView.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.availableByQuantityTreeView.Location = new System.Drawing.Point(3, 3);
|
||||
this.availableByQuantityTreeView.Name = "availableByQuantityTreeView";
|
||||
this.availableByQuantityTreeView.Size = new System.Drawing.Size(192, 421);
|
||||
this.availableByQuantityTreeView.TabIndex = 0;
|
||||
this.availableByQuantityTreeView.DoubleClick += new System.EventHandler(this.availableByQuantityTreeView_DoubleClick);
|
||||
//
|
||||
// tabPage3
|
||||
//
|
||||
this.tabPage3.Controls.Add(this.availableByCategoryTreeView);
|
||||
this.tabPage3.Location = new System.Drawing.Point(4, 22);
|
||||
this.tabPage3.Name = "tabPage3";
|
||||
this.tabPage3.Size = new System.Drawing.Size(198, 427);
|
||||
this.tabPage3.TabIndex = 2;
|
||||
this.tabPage3.Text = "by category";
|
||||
this.tabPage3.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// availableByCategoryTreeView
|
||||
//
|
||||
this.availableByCategoryTreeView.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.availableByCategoryTreeView.Location = new System.Drawing.Point(0, 0);
|
||||
this.availableByCategoryTreeView.Name = "availableByCategoryTreeView";
|
||||
this.availableByCategoryTreeView.Size = new System.Drawing.Size(198, 427);
|
||||
this.availableByCategoryTreeView.TabIndex = 0;
|
||||
this.availableByCategoryTreeView.NodeMouseHover += new System.Windows.Forms.TreeNodeMouseHoverEventHandler(this.availableByCategoryTreeView_NodeMouseHover);
|
||||
this.availableByCategoryTreeView.DoubleClick += new System.EventHandler(this.availableByCategoryTreeView_DoubleClick);
|
||||
//
|
||||
// selectedResultsListViewEx
|
||||
//
|
||||
this.selectedResultsListViewEx.AllowColumnReorder = true;
|
||||
this.selectedResultsListViewEx.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||
| System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.selectedResultsListViewEx.DoubleClickActivation = false;
|
||||
this.selectedResultsListViewEx.FullRowSelect = true;
|
||||
this.selectedResultsListViewEx.Location = new System.Drawing.Point(317, 31);
|
||||
this.selectedResultsListViewEx.Name = "selectedResultsListViewEx";
|
||||
this.selectedResultsListViewEx.Size = new System.Drawing.Size(594, 453);
|
||||
this.selectedResultsListViewEx.TabIndex = 47;
|
||||
this.selectedResultsListViewEx.UseCompatibleStateImageBehavior = false;
|
||||
this.selectedResultsListViewEx.View = System.Windows.Forms.View.Details;
|
||||
this.selectedResultsListViewEx.SubItemClicked += new Results.Forms.SubItemEventHandler(this.selectedResultsListViewEx_SubItemClicked);
|
||||
this.selectedResultsListViewEx.SubItemEndEditing += new Results.Forms.SubItemEndEditingEventHandler(this.selectedResultsListViewEx_SubItemEndEditing);
|
||||
//
|
||||
// ResultsConfigDlg
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(923, 543);
|
||||
this.Controls.Add(this.availableTabControl);
|
||||
this.Controls.Add(this.downButton);
|
||||
this.Controls.Add(this.upButton);
|
||||
this.Controls.Add(this.selectedResultsListViewEx);
|
||||
this.Controls.Add(this.removeAllButton);
|
||||
this.Controls.Add(this.removeButton);
|
||||
this.Controls.Add(this.addButton);
|
||||
this.Controls.Add(this.selectedResultsLabel);
|
||||
this.Controls.Add(this.availableResultsLabel);
|
||||
this.Controls.Add(this.cancelButton);
|
||||
this.Controls.Add(this.okButton);
|
||||
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog;
|
||||
this.Name = "ResultsConfigDlg";
|
||||
this.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide;
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
|
||||
this.Text = "ResultsConfig";
|
||||
this.Load += new System.EventHandler(this.ResultsConfig_Load);
|
||||
this.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.ResultsConfigDlg_KeyPress);
|
||||
this.availableTabControl.ResumeLayout(false);
|
||||
this.tabPage1.ResumeLayout(false);
|
||||
this.tabPage2.ResumeLayout(false);
|
||||
this.tabPage3.ResumeLayout(false);
|
||||
this.ResumeLayout(false);
|
||||
this.PerformLayout();
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private System.Windows.Forms.Button okButton;
|
||||
private System.Windows.Forms.Button cancelButton;
|
||||
private System.Windows.Forms.Label availableResultsLabel;
|
||||
private System.Windows.Forms.Label selectedResultsLabel;
|
||||
private System.Windows.Forms.Button removeAllButton;
|
||||
private System.Windows.Forms.Button removeButton;
|
||||
private System.Windows.Forms.Button addButton;
|
||||
private ListViewEx selectedResultsListViewEx;
|
||||
private System.Windows.Forms.Button upButton;
|
||||
private System.Windows.Forms.Button downButton;
|
||||
private System.Windows.Forms.TabControl availableTabControl;
|
||||
private System.Windows.Forms.TabPage tabPage1;
|
||||
private System.Windows.Forms.TabPage tabPage2;
|
||||
private System.Windows.Forms.TreeView availableAlphabeticTreeView;
|
||||
private System.Windows.Forms.TreeView availableByQuantityTreeView;
|
||||
private System.Windows.Forms.TabPage tabPage3;
|
||||
private System.Windows.Forms.TreeView availableByCategoryTreeView;
|
||||
}
|
||||
}
|
||||
@@ -1,123 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<metadata name="toolTip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>17, 17</value>
|
||||
</metadata>
|
||||
</root>
|
||||
@@ -1,117 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2016-2017 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
|
||||
namespace Results
|
||||
{
|
||||
public enum ItemID
|
||||
{
|
||||
String, /// 0
|
||||
Test_name, /// 1
|
||||
Procedure_name, /// 2
|
||||
Batch_number, /// 3
|
||||
Test_method, /// 4
|
||||
Density, /// 5
|
||||
Q_from, /// 6
|
||||
Q_to, /// 7
|
||||
Test_volume, /// 8
|
||||
Error_limit_Lo, /// 9
|
||||
Error_limit_Hi, /// 10
|
||||
Uncertainty, /// 11
|
||||
Test_start_time, /// 12
|
||||
Test_end_time, /// 13
|
||||
Test_time, /// 14
|
||||
Flow, /// 15
|
||||
T_up_mean, /// 16
|
||||
T_down_mean, /// 17
|
||||
T_div, /// 18
|
||||
P_up, /// 19
|
||||
P_up_start, /// 20
|
||||
P_up_end, /// 21
|
||||
P_down, /// 22
|
||||
P_down_start, /// 23
|
||||
P_down_end, /// 24
|
||||
Reference_error, /// 25
|
||||
Ambient_temperature, /// 26
|
||||
Ambient_pressure, /// 27
|
||||
Ambient_humidity, /// 28
|
||||
Volume, /// 29
|
||||
Reference_volume, /// 30
|
||||
Error, /// 31
|
||||
Passed, /// 32
|
||||
Watermeter_type, /// 33
|
||||
Producer, /// 34
|
||||
DN, /// 35
|
||||
L, /// 36
|
||||
Mounting, /// 37
|
||||
Q4, /// 38
|
||||
Q3, /// 39
|
||||
Q2, /// 40
|
||||
Q1, /// 41
|
||||
Metrological_class, /// 42
|
||||
Temperature_class, /// 43
|
||||
Pressure_loss_class, /// 44
|
||||
Max_admissible_pressure, /// 45
|
||||
Flow_profile_sensitivity_class, /// 46
|
||||
Approval_info, /// 47
|
||||
Certificate, /// 48
|
||||
Pulses_per_liter, /// 49
|
||||
Text1, /// 50
|
||||
Text2, /// 51
|
||||
Text3, /// 52
|
||||
Text4, /// 53
|
||||
Text5, /// 54
|
||||
Serial_Nr, /// 55
|
||||
Purchase_order, /// 56
|
||||
Year_of_production, /// 57
|
||||
WM_Position, /// 58
|
||||
End_state, /// 59
|
||||
Pulses, /// 60
|
||||
Pulses__liter, /// 61
|
||||
Reference_pulses, /// 62
|
||||
Reference_energy, /// 63
|
||||
Test_bench_ID, /// 64
|
||||
Program_version, /// 65
|
||||
User_name, /// 66
|
||||
User_nr, /// 67
|
||||
Energy, /// 68
|
||||
Watermeters, /// 69
|
||||
Protocol_title, /// 70
|
||||
Batch_start_time, /// 71
|
||||
Batch_end_time, /// 72
|
||||
Lite_per_pulse_Read, /// 73
|
||||
Result_code, /// 74
|
||||
Remark, /// 75
|
||||
TempHiMean, /// 76
|
||||
TempHiStart, /// 77
|
||||
TempHiEnd, /// 78
|
||||
TempHiAve, /// 79
|
||||
TempLoMean, /// 80
|
||||
TempLoStart, /// 81
|
||||
TempLoEnd, /// 82
|
||||
TempLoAve, /// 83
|
||||
P_delta_mean, /// 84
|
||||
P_delta_start, /// 85
|
||||
P_delta_end, /// 86
|
||||
Meter_type, /// 87 Single, Compound or HeatMeter
|
||||
Volume_main, /// 88
|
||||
Volume_aux, /// 89
|
||||
Start_volume, /// 90
|
||||
Start_volume_main, /// 91
|
||||
Start_volume_aux, /// 92
|
||||
End_volume, /// 93
|
||||
End_volume_main, /// 94
|
||||
End_volume_aux, /// 95
|
||||
Error_main, /// 96
|
||||
Error_aux, /// 97
|
||||
Serial_Nr_main, /// 98
|
||||
Serial_Nr_aux, /// 99
|
||||
End_state_main, /// 100
|
||||
End_state_aux, /// 101
|
||||
Q_rise, /// 102
|
||||
Q_fall, /// 103
|
||||
|
||||
Count,
|
||||
}
|
||||
}
|
||||
@@ -1,244 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2013-2015 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using Results.Entities;
|
||||
using Results.Resources;
|
||||
|
||||
namespace Results
|
||||
{
|
||||
public class ItemSpec
|
||||
{
|
||||
///
|
||||
/// Public fields
|
||||
///
|
||||
public readonly string Name; /// Name-s of all items must be unique
|
||||
public readonly string ClmnHeaderText; /// Text printed in the column header
|
||||
|
||||
|
||||
///
|
||||
/// Function to pick a MeterTestResult field and convert it into a string
|
||||
///
|
||||
public delegate string PrintDlgt(MeterTestRslt meterTestRslt);
|
||||
|
||||
///
|
||||
/// Function to pick a MeterTestResult field and convert it into a string
|
||||
///
|
||||
public delegate string PrintCompoundDlgt(MeterTestRslt mainMtrTestResult,
|
||||
MeterTestRslt auxMtrTestResult,
|
||||
MeterTestRslt compoundMtrTestResult);
|
||||
|
||||
///
|
||||
/// Function to pick a MeterTestResult field and convert it into a string
|
||||
///
|
||||
public delegate string PrintHeatMeterDlgt(MeterTestRslt volumeTestResult,
|
||||
MeterTestRslt energyTestResult);
|
||||
|
||||
private readonly PrintDlgt printDlgt;
|
||||
private readonly PrintCompoundDlgt printCompoundDlgt;
|
||||
private readonly PrintHeatMeterDlgt printHeatMeterDlgt;
|
||||
|
||||
public bool CanPrintSingle { get { return (printDlgt != null); } }
|
||||
public bool CanPrintCompoundMeter { get { return (printCompoundDlgt != null); } }
|
||||
public bool CanPrintHeatMeter { get { return (printHeatMeterDlgt != null); } }
|
||||
|
||||
/// <summary> Safe wrapper which replaces null-s by empty strings </summary>
|
||||
public string Print(MeterTestRslt meterTestRslt)
|
||||
{
|
||||
string str = null;
|
||||
if (printDlgt != null) str = printDlgt(meterTestRslt);
|
||||
return (str == null) ? string.Empty : str;
|
||||
}
|
||||
|
||||
/// <summary> Safe wrapper which replaces null-s by empty strings </summary>
|
||||
public string PrintCombined(MeterTestRslt mainMtrTestResult,
|
||||
MeterTestRslt auxMtrTestResult,
|
||||
MeterTestRslt compoundMtrTestResult)
|
||||
{
|
||||
string str = null;
|
||||
if (printCompoundDlgt != null) str = printCompoundDlgt(mainMtrTestResult, auxMtrTestResult, compoundMtrTestResult);
|
||||
return (str == null) ? string.Empty : str;
|
||||
}
|
||||
|
||||
/// <summary> Safe wrapper which replaces null-s by empty strings </summary>
|
||||
public string PrintHeatMeter(MeterTestRslt volumeTestResult,
|
||||
MeterTestRslt energyTestResult)
|
||||
{
|
||||
string str = null;
|
||||
if (printHeatMeterDlgt != null) str = printHeatMeterDlgt(volumeTestResult, energyTestResult);
|
||||
return (str == null) ? string.Empty : str;
|
||||
}
|
||||
|
||||
|
||||
///
|
||||
/// Public constructor
|
||||
///
|
||||
public ItemSpec(string name, string clmnHeaderText, PrintDlgt printDlgt, PrintCompoundDlgt printCombinedDlgt, PrintHeatMeterDlgt printHeatMeterDlgt)
|
||||
{
|
||||
Name = name;
|
||||
ClmnHeaderText = clmnHeaderText;
|
||||
this.printDlgt = printDlgt;
|
||||
this.printCompoundDlgt = printCombinedDlgt;
|
||||
this.printHeatMeterDlgt = printHeatMeterDlgt;
|
||||
}
|
||||
|
||||
|
||||
/// Static list of all available items
|
||||
public static readonly IList<ItemSpec> AllItems;
|
||||
|
||||
/// Static constructor that initializes the list of all items
|
||||
static ItemSpec()
|
||||
{
|
||||
AllItems = new List<ItemSpec>();
|
||||
|
||||
/// Common
|
||||
|
||||
//AllItems.Add(new ResultItemSpec("Bench ID", "Bench ID", x => x.BenchID, (x, y, z) => x.BenchID));
|
||||
AllItems.Add(new ItemSpec("Test name", Strings.Test, x => x.Name(), (x, y, z) => z.Name(), (x, z) => z.Name()));
|
||||
AllItems.Add(new ItemSpec("Procedure name", Strings.Procedure, x => x.ProcedureName(), (x, y, z) => z.ProcedureName(), (x, z) => z.ProcedureName()));
|
||||
AllItems.Add(new ItemSpec("Batch number", Strings.Batch_nr, x => x.BatchNr().ToString(), (x, y, z) => z.BatchNr().ToString(), (x, z) => z.BatchNr().ToString()));
|
||||
AllItems.Add(new ItemSpec("Test method", Strings.Test_method, x => x.Method(), (x, y, z) => z.Method(), (x, z) => z.Method()));
|
||||
AllItems.Add(new ItemSpec("Density", Strings.Density, x => x.DensityOut().ToString("F1"), (x, y, z) => z.DensityOut().ToString("F1"), (x, z) => z.DensityOut().ToString("F1"))); /// [kg/m3]
|
||||
|
||||
/// Target values
|
||||
AllItems.Add(new ItemSpec("Q from", Strings.Q_from + " [m3/h]", x => x.Qfrom().ToString("F3"), (x, y, z) => z.Qfrom().ToString("F3"), (x, z) => z.Qfrom().ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("Q to", Strings.Q_to + " [m3/h]", x => x.Qto().ToString("F3"), (x, y, z) => z.Qto().ToString("F3"), (x, z) => z.Qto().ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("Test volume", Strings.Test_vol + " [l]", x => x.TargetVolume().ToString("F1"), (x, y, z) => z.TargetVolume().ToString("F1"), (x, z) => z.TargetVolume().ToString("F1")));
|
||||
AllItems.Add(new ItemSpec("Error limit Lo", Strings.ErrLimLo + " [%]", x => x.ErrLimLo().ToString("F1"), (x, y, z) => z.ErrLimLo().ToString("F1"), (x, z) => z.ErrLimLo().ToString("F1")));
|
||||
AllItems.Add(new ItemSpec("Error limit Hi", Strings.ErrLimHi + " [%]", x => x.ErrLimHi().ToString("F1"), (x, y, z) => z.ErrLimHi().ToString("F1"), (x, z) => z.ErrLimHi().ToString("F1")));
|
||||
AllItems.Add(new ItemSpec("Uncertainty", Strings.Uncertainty + " [%]", x => x.Uncertainty().ToString("F2"), (x, y, z) => z.Uncertainty().ToString("F2"), (x, z) => z.Uncertainty().ToString("F2")));
|
||||
|
||||
/// Test results
|
||||
AllItems.Add(new ItemSpec("Test start time", Strings.T_start, x => x.StartTime().ToShortTimeString(), (x, y, z) => z.StartTime().ToShortTimeString(), (x, z) => z.StartTime().ToShortTimeString()));
|
||||
AllItems.Add(new ItemSpec("Test end time", Strings.T_end, x => x.EndTime().ToShortTimeString(), (x, y, z) => z.EndTime().ToShortTimeString(), (x, z) => z.EndTime().ToShortTimeString()));
|
||||
AllItems.Add(new ItemSpec("Test time", Strings.T_s, x => x.TestTime.ToString("F2"), (x, y, z) => z.TestTime.ToString("F2"), (x, z) => z.TestTime.ToString("F2")));
|
||||
AllItems.Add(new ItemSpec("Flow", Strings.Flow + " [m3/h]", x => Utils.DoubleToStr(x.FlowVolume(), 4), (x, y, z) => Utils.DoubleToStr(z.FlowVolume(), 4), (x, z) => Utils.DoubleToStr(x.FlowVolume(), 4)));
|
||||
AllItems.Add(new ItemSpec("T in", Strings.T_in + " [°C]", x => x.TestRslt.TempUpMean.ToString("F2"), (x, y, z) => z.TestRslt.TempUpMean.ToString("F2"), (x, z) => z.TestRslt.TempUpMean.ToString("F2")));
|
||||
AllItems.Add(new ItemSpec("T out", Strings.T_out + " [°C]", x => x.TestRslt.TempDownMean.ToString("F2"), (x, y, z) => z.TestRslt.TempDownMean.ToString("F2"), (x, z) => z.TestRslt.TempDownMean.ToString("F2")));
|
||||
AllItems.Add(new ItemSpec("T div", Strings.T_div + " [°C]", x => x.TestRslt.TempDivMean.ToString("F2"), (x, y, z) => z.TestRslt.TempDivMean.ToString("F2"), (x, z) => z.TestRslt.TempDivMean.ToString("F2")));
|
||||
AllItems.Add(new ItemSpec("P up", Strings.P_up + " [kPa]", x => (100 * x.TestRslt.PressUpMean).ToString("F3"), (x, y, z) => z.TestRslt.PressUpMean.ToString("F3"), (x, z) => z.TestRslt.PressUpMean.ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("P up start", Strings.P_up_start + " [kPa]", x => (100 * x.TestRslt.PressUpStart).ToString("F3"), (x, y, z) => z.TestRslt.PressUpStart.ToString("F3"), (x, z) => z.TestRslt.PressUpStart.ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("P up end", Strings.P_up_end + " [kPa]", x => (100 * x.TestRslt.PressUpEnd).ToString("F3"), (x, y, z) => z.TestRslt.PressUpEnd.ToString("F3"), (x, z) => z.TestRslt.PressUpEnd.ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("P down", Strings.P_dn + " [kPa]", x => (100 * x.TestRslt.PressDownMean).ToString("F3"), (x, y, z) => z.TestRslt.PressDownMean.ToString("F3"), (x, z) => z.TestRslt.PressDownMean.ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("P down start", Strings.P_dn_start + " [kPa]", x => (100 * x.TestRslt.PressDownStart).ToString("F3"), (x, y, z) => z.TestRslt.PressDownStart.ToString("F3"), (x, z) => z.TestRslt.PressDownStart.ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("P down end", Strings.P_dn_end + " [kPa]", x => (100 * x.TestRslt.PressDownEnd).ToString("F3"), (x, y, z) => z.TestRslt.PressDownEnd.ToString("F3"), (x, z) => z.TestRslt.PressDownEnd.ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("P delta", Strings.P_delta + " [kPa]", x => (100 * x.TestRslt.PressDeltaMean).ToString("F3"), (x, y, z) => z.TestRslt.PressDeltaMean.ToString("F3"), (x, z) => z.TestRslt.PressDeltaMean.ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("P delta start", Strings.P_delta_start + " [kPa]", x => (100 * x.TestRslt.PressDeltaStart).ToString("F3"), (x, y, z) => z.TestRslt.PressDeltaStart.ToString("F3"), (x, z) => z.TestRslt.PressDeltaStart.ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("P delta end", Strings.P_delta_end + " [kPa]", x => (100 * x.TestRslt.PressDeltaEnd).ToString("F3"), (x, y, z) => z.TestRslt.PressDeltaEnd.ToString("F3"), (x, z) => z.TestRslt.PressDeltaEnd.ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("Reference error", Strings.ErrRef + " [%]", x => x.TestRslt.ErrorMaster.ToString("F3"), (x, y, z) => z.TestRslt.ErrorMaster.ToString("F3"), (x, z) => z.TestRslt.ErrorMaster.ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("Ambient temperature", Strings.T_amb + " [°C]", x => x.TestRslt.AmbTempMean.ToString("F1"), (x, y, z) => z.TestRslt.AmbTempMean.ToString("F1"), (x, z) => z.TestRslt.AmbTempMean.ToString("F1")));
|
||||
AllItems.Add(new ItemSpec("Ambient pressure", Strings.P_amb + " [mbar]", x => (1000 * x.TestRslt.AmbPressMean).ToString("F0"), (x, y, z) => (1000 * z.TestRslt.AmbPressMean).ToString("F0"), (x, z) => (1000 * z.TestRslt.AmbPressMean).ToString("F0")));
|
||||
AllItems.Add(new ItemSpec("Ambient humidity", Strings.H_amb + " [%]", x => x.TestRslt.AmbHumiMean.ToString("F1"), (x, y, z) => z.TestRslt.AmbHumiMean.ToString("F1"), (x, z) => z.TestRslt.AmbHumiMean.ToString("F1")));
|
||||
|
||||
/// Single and combined meter results
|
||||
AllItems.Add(new ItemSpec("Start volume", Strings.Start_volume + " [l]", x => x.VolumeStart.ToString("F3"), (x, y, z) => z.VolumeStart.ToString("F3"), (x, z) => z.VolumeStart.ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("End volume", Strings.End_volume + " [l]", x => x.VolumeEnd.ToString("F3"), (x, y, z) => z.VolumeEnd.ToString("F3"), (x, z) => z.VolumeEnd.ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("Volume", Strings.Volume + " [l]", x => x.VolumeMeter.ToString("F3"), (x, y, z) => z.VolumeMeter.ToString("F3"), (x, z) => x.VolumeMeter.ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("Reference volume", Strings.VolRef + " [l]", x => x.VolumeRef.ToString("F3"), (x, y, z) => z.VolumeRef.ToString("F3"), (x, z) => x.VolumeRef.ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("Error", Strings.Error + " [%]", x => x.Error.ToString("F2"), (x, y, z) => z.Error.ToString("F2"), null));
|
||||
AllItems.Add(new ItemSpec("Passed", Strings.Result, x => x.PassedColorStr(), (x, y, z) => z.PassedColorStr(), null));
|
||||
AllItems.Add(new ItemSpec("Volume Error", "Volume Error" + " [%]", null, null, (x, z) => x.Error.ToString("F2")));
|
||||
AllItems.Add(new ItemSpec("Volume Passed", "Volume Passed", null, null, (x, z) => x.PassedColorStr()));
|
||||
AllItems.Add(new ItemSpec("Energy Error", "Energy Error" + " [%]", null, null, (x, z) => z.Error.ToString("F2")));
|
||||
AllItems.Add(new ItemSpec("Energy Passed", "Energy Passed", null, null, (x, z) => z.PassedColorStr()));
|
||||
|
||||
/// Water meter info
|
||||
AllItems.Add(new ItemSpec("Watermeter type", Strings.WM_Type, x => x.WaterMeterData().ProductName, (x, y, z) => z.WaterMeterData().ProductName, (x, z) => z.WaterMeterData().ProductName));
|
||||
AllItems.Add(new ItemSpec("Producer", Strings.Producer, x => x.WaterMeterData().Producer, (x, y, z) => z.WaterMeterData().Producer, (x, z) => z.WaterMeterData().Producer));
|
||||
AllItems.Add(new ItemSpec("Metrological class", Strings.MClass, x => x.WaterMeterData().MetrologicalClass, (x, y, z) => z.WaterMeterData().MetrologicalClass, (x, z) => z.WaterMeterData().MetrologicalClass));
|
||||
AllItems.Add(new ItemSpec("Approval info", Strings.Approval, x => x.WaterMeterData().ApprovalInfo, (x, y, z) => z.WaterMeterData().ApprovalInfo, (x, z) => z.WaterMeterData().ApprovalInfo));
|
||||
AllItems.Add(new ItemSpec("Q4", "Q4 [m3/h]", x => x.WaterMeterData().Q4_Qmax.ToString(), (x, y, z) => z.WaterMeterData().Q4_Qmax.ToString(), null));
|
||||
AllItems.Add(new ItemSpec("Q3", "Q3 [m3/h]", x => x.WaterMeterData().Q3_Qn.ToString(), (x, y, z) => z.WaterMeterData().Q3_Qn.ToString(), null));
|
||||
AllItems.Add(new ItemSpec("Q2", "Q2 [m3/h]", x => x.WaterMeterData().Q2_Qt.ToString(), (x, y, z) => z.WaterMeterData().Q2_Qt.ToString(), null));
|
||||
AllItems.Add(new ItemSpec("Q1", "Q1 [m3/h]", x => x.WaterMeterData().Q1_Qmin.ToString(), (x, y, z) => z.WaterMeterData().Q1_Qmin.ToString(), null));
|
||||
AllItems.Add(new ItemSpec("Qmax", "Qmax [m3/h]", x => x.WaterMeterData().Q4_Qmax.ToString(), (x, y, z) => z.WaterMeterData().Q4_Qmax.ToString(), null));
|
||||
AllItems.Add(new ItemSpec("Qn", "Qn [m3/h]", x => x.WaterMeterData().Q3_Qn.ToString(), (x, y, z) => z.WaterMeterData().Q3_Qn.ToString(), null));
|
||||
AllItems.Add(new ItemSpec("Qt", "Qt [m3/h]", x => x.WaterMeterData().Q2_Qt.ToString(), (x, y, z) => z.WaterMeterData().Q2_Qt.ToString(), null));
|
||||
AllItems.Add(new ItemSpec("Qmin", "Qmin [m3/h]", x => x.WaterMeterData().Q1_Qmin.ToString(), (x, y, z) => z.WaterMeterData().Q1_Qmin.ToString(), null));
|
||||
|
||||
/// Water meters results
|
||||
AllItems.Add(new ItemSpec("Serial Nr", Strings.sn, x => x.WaterMeter.SerialNr, (x, y, z) => z.WaterMeter.SerialNr, (x, z) => z.WaterMeter.SerialNr));
|
||||
AllItems.Add(new ItemSpec("Purchase order", Strings.PO, x => x.WaterMeter.PurchaseOrder, (x, y, z) => z.WaterMeter.PurchaseOrder, (x, z) => z.WaterMeter.PurchaseOrder));
|
||||
AllItems.Add(new ItemSpec("Year of production", Strings.Year, x => x.WaterMeter.YearOfProduction.ToString(), (x, y, z) => z.WaterMeter.YearOfProduction.ToString(), (x, z) => z.WaterMeter.YearOfProduction.ToString()));
|
||||
AllItems.Add(new ItemSpec("WM Position", Strings.Pos, x => x.WaterMeter.WMPosition.ToString(), (x, y, z) => z.WaterMeter.WMPosition.ToString(), (x, z) => z.WaterMeter.WMPosition.ToString()));
|
||||
|
||||
/// Water meters results (single)
|
||||
AllItems.Add(new ItemSpec("End state", Strings.End_state, x => x.EndState(), null, null));
|
||||
AllItems.Add(new ItemSpec("Pulses", Strings.Pulses, x => x.PulsesMeter.ToString(), null, null));
|
||||
AllItems.Add(new ItemSpec("Pulses/liter", Strings.PulsesLiter, x => x.PulsesPerLiter.ToString(), null, null));
|
||||
AllItems.Add(new ItemSpec("Reference pulses", Strings.RefPulses, x => x.PulsesMaster.ToString(), null, null));
|
||||
|
||||
/// Water meters results (combined)
|
||||
AllItems.Add(new ItemSpec("Q rise", Strings.Q_rise + " [m3/h]", null, (x, y, z) => (z.QRise() == 0) ? "-" : Utils.DoubleToStr(z.QRise(), 4), null));
|
||||
AllItems.Add(new ItemSpec("Q fall", Strings.Q_fall + " [m3/h]", null, (x, y, z) => (z.QFall() == 0) ? "-" : Utils.DoubleToStr(z.QFall(), 4), null));
|
||||
AllItems.Add(new ItemSpec("Error large WM", Strings.Err_main + " [%]", null, (x, y, z) => x.Error.ToString("F2"), null));
|
||||
AllItems.Add(new ItemSpec("Error small WM", Strings.Err_aux + " [%]", null, (x, y, z) => y.Error.ToString("F2"), null));
|
||||
AllItems.Add(new ItemSpec("Serial Nr large WM", Strings.sn_main, null, (x, y, z) => x.SerialNr(), null));
|
||||
AllItems.Add(new ItemSpec("Serial Nr small WM", Strings.sn_aux, null, (x, y, z) => y.SerialNr(), null));
|
||||
AllItems.Add(new ItemSpec("End state large WM", Strings.EndState_main, null, (x, y, z) => x.EndState(), null));
|
||||
AllItems.Add(new ItemSpec("End state small WM", Strings.EndState_aux, null, (x, y, z) => y.EndState(), null));
|
||||
AllItems.Add(new ItemSpec("Start volume main", Strings.Start_volume_main + " [l]",x => x.VolumeMeter.ToString("F3"), (x, y, z) => x.VolumeStart.ToString("F3"), null));
|
||||
AllItems.Add(new ItemSpec("End volume main", Strings.End_volume_main + " [l]", x => x.VolumeMeter.ToString("F3"), (x, y, z) => x.VolumeEnd.ToString("F3"), null));
|
||||
AllItems.Add(new ItemSpec("Volume main", Strings.Volume_main + " [l]", x => x.VolumeMeter.ToString("F3"), (x, y, z) => x.VolumeMeter.ToString("F3"), null));
|
||||
AllItems.Add(new ItemSpec("Start volume aux", Strings.Start_volume_aux + " [l]", x => x.VolumeMeter.ToString("F3"), (x, y, z) => y.VolumeStart.ToString("F3"), null));
|
||||
AllItems.Add(new ItemSpec("End volume aux", Strings.End_volume_aux + " [l]", x => x.VolumeMeter.ToString("F3"), (x, y, z) => y.VolumeEnd.ToString("F3"), null));
|
||||
AllItems.Add(new ItemSpec("Volume aux", Strings.Volume_aux + " [l]", x => x.VolumeMeter.ToString("F3"), (x, y, z) => y.VolumeMeter.ToString("F3"), null));
|
||||
|
||||
/// Batch info
|
||||
AllItems.Add(new ItemSpec("Batch number", Strings.Batch_nr, x => x.Batch().BatchNr.ToString(), (x, y, z) => x.Batch().BatchNr.ToString(), (x, z) => x.Batch().BatchNr.ToString()));
|
||||
AllItems.Add(new ItemSpec("Test bench ID", Strings.Bench, x => x.Batch().TestBenchId.ToString(), (x, y, z) => x.Batch().TestBenchId.ToString(), (x, z) => x.Batch().TestBenchId.ToString()));
|
||||
AllItems.Add(new ItemSpec("Program version", Strings.Ver, x => x.Batch().ProgramVersion, (x, y, z) => x.Batch().ProgramVersion, (x, z) => x.Batch().ProgramVersion));
|
||||
AllItems.Add(new ItemSpec("User name", Strings.User, x => x.Batch().UserName, (x, y, z) => x.Batch().UserName, (x, z) => x.Batch().UserName));
|
||||
AllItems.Add(new ItemSpec("User nr.", Strings.User_nr, x => x.Batch().UserNumber.ToString(), (x, y, z) => x.Batch().UserNumber.ToString(), (x, z) => x.Batch().UserNumber.ToString()));
|
||||
AllItems.Add(new ItemSpec("Procedure name", Strings.Procedure, x => x.Batch().ProcedureName, (x, y, z) => x.Batch().ProcedureName, (x, z) => x.Batch().ProcedureName));
|
||||
AllItems.Add(new ItemSpec("Watermeters", Strings.WMs, x => x.Batch().WatermetersStr, (x, y, z) => x.Batch().WatermetersStr, (x, z) => x.Batch().WatermetersStr));
|
||||
AllItems.Add(new ItemSpec("Protocol title", Strings.Protocol, x => x.Batch().ProtocolTitle, (x, y, z) => x.Batch().ProtocolTitle, (x, z) => x.Batch().ProtocolTitle));
|
||||
AllItems.Add(new ItemSpec("Batch start time", Strings.Start, x => x.Batch().StartTime.ToShortTimeString(), (x, y, z) => x.Batch().StartTime.ToShortTimeString(), (x, z) => x.Batch().StartTime.ToShortTimeString()));
|
||||
AllItems.Add(new ItemSpec("Batch end time", Strings.End, x => x.Batch().EndTime.ToShortTimeString(), (x, y, z) => x.Batch().EndTime.ToShortTimeString(), (x, z) => x.Batch().EndTime.ToShortTimeString()));
|
||||
|
||||
/// Heat meters results
|
||||
AllItems.Add(new ItemSpec("Energy", Strings.Energy, null, null, (x, z) => z.VolumeMeter.ToString()));
|
||||
AllItems.Add(new ItemSpec("Reference energy", Strings.Energy_ref, null, null, (x, z) => z.VolumeRef.ToString()));
|
||||
AllItems.Add(new ItemSpec("Temp hi me", "T hi me", null, null, (x, z) => z.TestRslt.Custom1.ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("Temp hi st", "T hi st", null, null, (x, z) => z.TestRslt.Custom2.ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("Temp hi en", "T hi en", null, null, (x, z) => z.TestRslt.Custom3.ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("Temp hi av", "T hi av", null, null, (x, z) => ((z.TestRslt.Custom2 + z.TestRslt.Custom3) / 2).ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("Temp lo me", "T lo me", null, null, (x, z) => z.TestRslt.Custom6.ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("Temp lo st", "T lo st", null, null, (x, z) => z.TestRslt.Custom7.ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("Temp lo en", "T lo en", null, null, (x, z) => z.TestRslt.Custom8.ToString("F3")));
|
||||
AllItems.Add(new ItemSpec("Temp lo av", "T lo av", null, null, (x, z) => ((z.TestRslt.Custom7 + z.TestRslt.Custom8) / 2).ToString("F3")));
|
||||
|
||||
AllItems.Add(new ItemSpec("Start mass", Strings.Start_mass + " [kg]", x => x.TestRslt.MassStart.ToString("F4"), (x, y, z) => z.TestRslt.MassStart.ToString("F4"), (x, z) => z.TestRslt.MassStart.ToString("F4")));
|
||||
AllItems.Add(new ItemSpec("End mass", Strings.End_mass + " [kg]", x => x.TestRslt.MassEnd.ToString("F4"), (x, y, z) => z.TestRslt.MassEnd.ToString("F4"), (x, z) => z.TestRslt.MassEnd.ToString("F4")));
|
||||
}
|
||||
|
||||
public static ItemSpec GetItem(string name)
|
||||
{
|
||||
foreach (var item in AllItems) if (item.Name.Equals(name)) return item;
|
||||
return null;
|
||||
}
|
||||
|
||||
public static string[] ToStrArray(IList<ItemSpec> items)
|
||||
{
|
||||
int count = (items != null) ? items.Count : 0;
|
||||
string[] result = new string[count];
|
||||
for (int i = 0; i < count; i++) result[i] = items[i].Name;
|
||||
return result;
|
||||
}
|
||||
|
||||
public static IList<ItemSpec> FromStrArray(string[] strArray)
|
||||
{
|
||||
IList<ItemSpec> result = new List<ItemSpec>();
|
||||
if (strArray != null)
|
||||
{
|
||||
for (int i = 0; i < strArray.Length; i++)
|
||||
{
|
||||
ItemSpec item = GetItem(strArray[i]);
|
||||
if (item != null) result.Add(item);
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,40 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2015 Sensus Metering Systems
|
||||
///
|
||||
using FluentNHibernate.Mapping;
|
||||
using Results.Entities;
|
||||
|
||||
namespace Results.Mappings
|
||||
{
|
||||
class BatchMap : ClassMap<Batch>
|
||||
{
|
||||
public BatchMap()
|
||||
{
|
||||
Id(x => x.Id);
|
||||
Map(x => x.BatchNr);
|
||||
Map(x => x.TestBenchId);
|
||||
Map(x => x.ProgramVersion);
|
||||
Map(x => x.UserName);
|
||||
Map(x => x.UserNumber);
|
||||
Map(x => x.ProcedureName);
|
||||
Map(x => x.ProcedureRevision);
|
||||
Map(x => x.ProtocolTitle);
|
||||
Map(x => x.Remark)
|
||||
.CustomType("StringClob")
|
||||
.CustomSqlType("varchar(2000)");
|
||||
Map(x => x.Custom1);
|
||||
Map(x => x.Custom2);
|
||||
Map(x => x.Custom3);
|
||||
Map(x => x.StartTime);
|
||||
Map(x => x.EndTime);
|
||||
Map(x => x.RsltsSent);
|
||||
Map(x => x.RsltsPrinted);
|
||||
HasMany(x => x.Tests)
|
||||
.Cascade.All();
|
||||
HasMany(x => x.WaterMeters)
|
||||
.Cascade.All();
|
||||
HasMany(x => x.TestRslts)
|
||||
.Cascade.All();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,26 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2016 Sensus Metering Systems
|
||||
///
|
||||
using FluentNHibernate.Mapping;
|
||||
using Results.Entities;
|
||||
|
||||
namespace Results.Mappings
|
||||
{
|
||||
class ComponentsMap : ClassMap<Components>
|
||||
{
|
||||
public ComponentsMap()
|
||||
{
|
||||
Id(x => x.Id);
|
||||
Map(x => x.TestBenchId);
|
||||
Map(x => x.TestBenchName);
|
||||
Map(x => x.Pump);
|
||||
Map(x => x.RegValve);
|
||||
Map(x => x.Flowmeter);
|
||||
Map(x => x.Diverter);
|
||||
Map(x => x.Scale);
|
||||
Map(x => x.Custom1);
|
||||
Map(x => x.Custom2);
|
||||
Map(x => x.Custom3);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,33 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2015 Sensus Metering Systems
|
||||
///
|
||||
using FluentNHibernate.Mapping;
|
||||
using Results.Entities;
|
||||
|
||||
namespace Results.Mappings
|
||||
{
|
||||
class MeterTestRsltMap : ClassMap<MeterTestRslt>
|
||||
{
|
||||
public MeterTestRsltMap()
|
||||
{
|
||||
Id(x => x.Id);
|
||||
Map(x => x.CompoundMeterId);
|
||||
Map(x => x.PulsesMeter);
|
||||
Map(x => x.PulsesMaster);
|
||||
Map(x => x.PulsesPerLiter);
|
||||
Map(x => x.VolumeStart);
|
||||
Map(x => x.VolumeEnd);
|
||||
Map(x => x.VolumeMeter);
|
||||
Map(x => x.VolumeRef);
|
||||
Map(x => x.TimestampStart);
|
||||
Map(x => x.TimestampEnd);
|
||||
Map(x => x.TestTime);
|
||||
Map(x => x.Error);
|
||||
Map(x => x.TestDone);
|
||||
Map(x => x.Passed);
|
||||
|
||||
References(x => x.WaterMeter);
|
||||
References(x => x.TestRslt);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,28 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2015 Sensus Metering Systems
|
||||
///
|
||||
using FluentNHibernate.Mapping;
|
||||
using Results.Entities;
|
||||
|
||||
namespace Results.Mappings
|
||||
{
|
||||
class TestDataMap : ClassMap<TestData>
|
||||
{
|
||||
public TestDataMap()
|
||||
{
|
||||
Id(x => x.Id);
|
||||
Map(x => x.Name);
|
||||
Map(x => x.Qfrom);
|
||||
Map(x => x.Qto);
|
||||
Map(x => x.TargetVolume);
|
||||
Map(x => x.TargetTime);
|
||||
Map(x => x.Repeats);
|
||||
Map(x => x.Method);
|
||||
Map(x => x.ErrLimLo);
|
||||
Map(x => x.ErrLimHi);
|
||||
Map(x => x.Uncertainty);
|
||||
Map(x => x.Publish);
|
||||
Map(x => x.Evaluate);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,102 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2015 Sensus Metering Systems
|
||||
///
|
||||
using FluentNHibernate.Mapping;
|
||||
using Results.Entities;
|
||||
|
||||
namespace Results.Mappings
|
||||
{
|
||||
class TestRsltMap : ClassMap<TestRslt>
|
||||
{
|
||||
public TestRsltMap()
|
||||
{
|
||||
Id(x => x.Id);
|
||||
References<Batch>(x => x.Batch);
|
||||
References<TestData>(x => x.TestData);
|
||||
References<Components>(x => x.Components);
|
||||
Map(x => x.Part);
|
||||
Map(x => x.RepetitionNr);
|
||||
|
||||
Map(x => x.StartTime);
|
||||
Map(x => x.EndTime);
|
||||
Map(x => x.FlowSetTime);
|
||||
Map(x => x.TestTime);
|
||||
Map(x => x.PulsesMaster);
|
||||
Map(x => x.ConstMaster);
|
||||
Map(x => x.MassStartRaw);
|
||||
Map(x => x.MassStart);
|
||||
Map(x => x.MassEndRaw);
|
||||
Map(x => x.MassEnd);
|
||||
Map(x => x.DensityIn);
|
||||
Map(x => x.DensityOut);
|
||||
Map(x => x.DensityDiv);
|
||||
Map(x => x.Buoyancy);
|
||||
Map(x => x.FlowMass);
|
||||
Map(x => x.FlowVolume);
|
||||
Map(x => x.VolumeCTV);
|
||||
Map(x => x.VolumeMaster);
|
||||
Map(x => x.ErrorMaster);
|
||||
#if HEAT_METERS
|
||||
Map(x => x.RefEnergy);
|
||||
#endif
|
||||
Map(x => x.AmbTempMean).Column("AmbientTempAve");
|
||||
Map(x => x.AmbTempStart);
|
||||
Map(x => x.AmbTempEnd);
|
||||
Map(x => x.AmbTempMin);
|
||||
Map(x => x.AmbTempMax);
|
||||
Map(x => x.AmbPressMean).Column("AmbientPressAve");
|
||||
Map(x => x.AmbPressStart);
|
||||
Map(x => x.AmbPressEnd);
|
||||
Map(x => x.AmbPressMin);
|
||||
Map(x => x.AmbPressMax);
|
||||
Map(x => x.AmbHumiMean).Column("AmbientHumiAve");
|
||||
Map(x => x.AmbHumiStart);
|
||||
Map(x => x.AmbHumiEnd);
|
||||
Map(x => x.AmbHumiMin);
|
||||
Map(x => x.AmbHumiMax);
|
||||
Map(x => x.PressUpMean).Column("PressUpAvrg");
|
||||
Map(x => x.PressUpStart);
|
||||
Map(x => x.PressUpEnd);
|
||||
Map(x => x.PressUpMin);
|
||||
Map(x => x.PressUpMax);
|
||||
Map(x => x.PressDownMean).Column("PressDownAvrg");
|
||||
Map(x => x.PressDownStart);
|
||||
Map(x => x.PressDownEnd);
|
||||
Map(x => x.PressDownMin);
|
||||
Map(x => x.PressDownMax);
|
||||
Map(x => x.PressDeltaMean);
|
||||
Map(x => x.PressDeltaStart);
|
||||
Map(x => x.PressDeltaEnd);
|
||||
Map(x => x.PressDeltaMin);
|
||||
Map(x => x.PressDeltaMax);
|
||||
Map(x => x.TempUpMean).Column("TempInAvrg");
|
||||
Map(x => x.TempUpStart).Column("TempInStart");
|
||||
Map(x => x.TempUpEnd).Column("TempInEnd");
|
||||
Map(x => x.TempUpMin).Column("TempInMin");
|
||||
Map(x => x.TempUpMax).Column("TempInMax");
|
||||
Map(x => x.TempDownMean).Column("TempOutAvrg");
|
||||
Map(x => x.TempDownStart).Column("TempOutStart");
|
||||
Map(x => x.TempDownEnd).Column("TempOutEnd");
|
||||
Map(x => x.TempDownMin).Column("TempOutMin");
|
||||
Map(x => x.TempDownMax).Column("TempOutMax");
|
||||
Map(x => x.TempDivMean).Column("TempDivAvrg");
|
||||
Map(x => x.TempDivStart);
|
||||
Map(x => x.TempDivEnd);
|
||||
Map(x => x.TempDivMin);
|
||||
Map(x => x.TempDivMax);
|
||||
Map(x => x.FlowStart);
|
||||
Map(x => x.FlowEnd);
|
||||
Map(x => x.FlowMin);
|
||||
Map(x => x.FlowMax);
|
||||
|
||||
Map(x => x.Custom1);
|
||||
Map(x => x.Custom2);
|
||||
Map(x => x.Custom3);
|
||||
Map(x => x.Custom4);
|
||||
Map(x => x.Custom5);
|
||||
Map(x => x.Custom6);
|
||||
Map(x => x.Custom7);
|
||||
Map(x => x.Custom8);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,58 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2015 Sensus Metering Systems
|
||||
///
|
||||
using FluentNHibernate.Mapping;
|
||||
using Results.Entities;
|
||||
|
||||
namespace Results.Mappings
|
||||
{
|
||||
class WaterMeterDataMap : ClassMap<WaterMeterData>
|
||||
{
|
||||
public WaterMeterDataMap()
|
||||
{
|
||||
Id(x => x.Id);
|
||||
Map(x => x.ProductName);
|
||||
Map(x => x.Producer);
|
||||
|
||||
Map(x => x.DN);
|
||||
Map(x => x.L);
|
||||
Map(x => x.Mounting);
|
||||
|
||||
Map(x => x.Q4_Qmax);
|
||||
Map(x => x.Q3_Qn);
|
||||
Map(x => x.Q2_Qt);
|
||||
Map(x => x.Q1_Qmin);
|
||||
|
||||
Map(x => x.MetrologicalClass);
|
||||
Map(x => x.TemperatureClass);
|
||||
Map(x => x.PressureLossClass);
|
||||
Map(x => x.MaxAdmissiblePressure);
|
||||
Map(x => x.FlowProfileSensitivityClass);
|
||||
|
||||
Map(x => x.ApprovalInfo);
|
||||
Map(x => x.Certificate);
|
||||
|
||||
Map(x => x.PulsesPerLtr);
|
||||
|
||||
Map(x => x.ProducerAux);
|
||||
Map(x => x.Q3_Qn_Aux);
|
||||
Map(x => x.MetrologicalClassAux);
|
||||
Map(x => x.ApprovalInfoAux);
|
||||
|
||||
Map(x => x.Text1);
|
||||
Map(x => x.Text2);
|
||||
Map(x => x.Text3);
|
||||
Map(x => x.Text4);
|
||||
Map(x => x.Text5);
|
||||
|
||||
Map(x => x.Compound);
|
||||
#if HEAT_METER_SUPPORT
|
||||
Map(x => x.HeatMeter);
|
||||
#endif
|
||||
#if ORACLE_DB
|
||||
Map(x => x.WMTypeId);
|
||||
Map(x => x.WMTypeRev);
|
||||
#endif
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,44 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2015 Sensus Metering Systems
|
||||
///
|
||||
using FluentNHibernate.Mapping;
|
||||
using Results.Entities;
|
||||
|
||||
namespace Results.Mappings
|
||||
{
|
||||
class WaterMeterMap : ClassMap<WaterMeter>
|
||||
{
|
||||
public WaterMeterMap()
|
||||
{
|
||||
Id(x => x.Id);
|
||||
Map(x => x.SerialNr);
|
||||
Map(x => x.SerialNrAux);
|
||||
Map(x => x.PurchaseOrder);
|
||||
Map(x => x.YearOfProduction);
|
||||
Map(x => x.WMPosition);
|
||||
Map(x => x.EndState);
|
||||
Map(x => x.EndStateAux);
|
||||
Map(x => x.QRise);
|
||||
Map(x => x.QFall);
|
||||
Map(x => x.Passed);
|
||||
Map(x => x.ResultCode);
|
||||
|
||||
#if IPERL
|
||||
Map(x => x.SerialNrEx);
|
||||
Map(x => x.OrigCalibFactor);
|
||||
Map(x => x.CalibFactor);
|
||||
Map(x => x.Q2ErrWOCorrection);
|
||||
Map(x => x.Q2CorrectionDone);
|
||||
Map(x => x.Q2Correction);
|
||||
Map(x => x.Q2CorrFlowRight);
|
||||
Map(x => x.Diff2Hz8Hz);
|
||||
Map(x => x.Hz2CorrectionDone);
|
||||
Map(x => x.Hz2Correction);
|
||||
#endif
|
||||
References(x => x.WaterMeterData);
|
||||
References(x => x.Batch);
|
||||
HasMany(x => x.MeterTestRslts)
|
||||
.Cascade.All();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,446 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2013-2016 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Drawing;
|
||||
using System.Drawing.Printing;
|
||||
using System.IO;
|
||||
using Config.Entities;
|
||||
using Results.Resources;
|
||||
|
||||
namespace Results.Output.Printers.Cevak
|
||||
{
|
||||
enum DocumentSection
|
||||
{
|
||||
FirstPage,
|
||||
OtherPages,
|
||||
Appendix1,
|
||||
Appendix2,
|
||||
Count,
|
||||
}
|
||||
|
||||
public class PrintDocumentCevak : PrintDocument
|
||||
{
|
||||
const string FontFamilyName = "Arial"; //"Times New Roman";
|
||||
|
||||
const int SpacingOne = 18;
|
||||
const int SpacingOneAndHalf = (3 * SpacingOne) / 2;
|
||||
|
||||
readonly int topMargin;
|
||||
readonly int bottomMargin;
|
||||
readonly int leftMargin;
|
||||
readonly int TitleX;
|
||||
readonly int TitleY; /// Depends on the size of the header
|
||||
readonly int HdrTop; /// = TitleY + 60
|
||||
readonly int BodyTop; /// = HdrTop + 160
|
||||
|
||||
/// Size of the printed area without margins, after taking into account 'pageOrientation'
|
||||
int printHeight;
|
||||
int printWidth;
|
||||
|
||||
/// <summary>
|
||||
/// Property variable for the Font the user wishes to use
|
||||
/// </summary>
|
||||
Font font;
|
||||
Font boldFont;
|
||||
Font titleFont;
|
||||
|
||||
///
|
||||
/// Data to print
|
||||
///
|
||||
Results.Entities.Batch batch;
|
||||
|
||||
string testBenchName;
|
||||
string address1;
|
||||
|
||||
|
||||
///
|
||||
/// Items to print
|
||||
///
|
||||
readonly IList<Results.ItemSpec> rsltItems;
|
||||
|
||||
///
|
||||
/// Layout and status
|
||||
///
|
||||
DocumentSection documentSection;
|
||||
|
||||
int nrWMsOnFirstPage;
|
||||
int nrWMsOnNextPage;
|
||||
int nextWMNr; /// nr. of watermeter to be printed as the first one on the next page
|
||||
int nrPages;
|
||||
int pageNr; /// Page number to be printed at the bottom of the page
|
||||
|
||||
/// <summary>
|
||||
/// Constructor
|
||||
/// </summary>
|
||||
/// <param name="textToPrint">Text to be printed</param>
|
||||
public PrintDocumentCevak(Results.Entities.Batch batch,
|
||||
PageOrientation pageOrientation,
|
||||
int topMargin, int bottomMargin, int leftMargin,
|
||||
string testBenchName, string address1)
|
||||
{
|
||||
this.batch = batch;
|
||||
|
||||
DefaultPageSettings.Landscape = (pageOrientation == PageOrientation.Landscape);
|
||||
|
||||
this.topMargin = topMargin;
|
||||
this.bottomMargin = bottomMargin;
|
||||
this.leftMargin = leftMargin;
|
||||
|
||||
this.testBenchName = testBenchName;
|
||||
this.address1 = address1;
|
||||
|
||||
TitleX = leftMargin;
|
||||
TitleY = topMargin; /// Depends on the size of the header
|
||||
HdrTop = TitleY + 60;
|
||||
BodyTop = HdrTop + 250;
|
||||
|
||||
rsltItems = Results.ItemSpec.FromStrArray(new string[] {
|
||||
"Test name",
|
||||
"Volume",
|
||||
"Reference volume",
|
||||
"Test time",
|
||||
"Flow",
|
||||
"Error",
|
||||
"Passed",
|
||||
//"Reference error", // ?
|
||||
});
|
||||
|
||||
/// Set print area size and margins (in dots using 100 dpi)
|
||||
if (DefaultPageSettings.Landscape)
|
||||
{
|
||||
printHeight = base.DefaultPageSettings.PaperSize.Width - topMargin - bottomMargin;
|
||||
printWidth = base.DefaultPageSettings.PaperSize.Height - leftMargin - leftMargin;
|
||||
}
|
||||
else
|
||||
{
|
||||
printHeight = base.DefaultPageSettings.PaperSize.Height - topMargin - bottomMargin;
|
||||
printWidth = base.DefaultPageSettings.PaperSize.Width - leftMargin - leftMargin;
|
||||
}
|
||||
|
||||
|
||||
int testsCount = 0;
|
||||
foreach (var mtr in batch.WaterMeters[0].MeterTestRslts)
|
||||
{
|
||||
if (mtr.Publish() == Config.Entities.Publish.Always) testsCount++;
|
||||
}
|
||||
|
||||
if (batch.WaterMeters[0].Compound()) testsCount /= 3;
|
||||
|
||||
int wmSectionHeight = (testsCount + 4) * SpacingOne;
|
||||
|
||||
nrWMsOnFirstPage = (printHeight - BodyTop + TitleY - 2 * SpacingOne) / wmSectionHeight;
|
||||
nrWMsOnNextPage = (printHeight - 2 * SpacingOne) / wmSectionHeight;
|
||||
nrWMsOnNextPage = Math.Max(nrWMsOnNextPage, 1); /// Prevent division by zero if there are too many WM tests
|
||||
|
||||
nrPages = 1 + (batch.WaterMeters.Count - nrWMsOnFirstPage + nrWMsOnNextPage - 1) / nrWMsOnNextPage;
|
||||
|
||||
pageNr = 1;
|
||||
nextWMNr = 0;
|
||||
documentSection = DocumentSection.FirstPage;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Override the default onbeginPrint method of the PrintDocument Object
|
||||
/// </summary>
|
||||
/// <param name=e></param>
|
||||
/// <remarks></remarks>
|
||||
protected override void OnBeginPrint(System.Drawing.Printing.PrintEventArgs e)
|
||||
{
|
||||
base.OnBeginPrint(e);
|
||||
|
||||
if (font == null) { font = new Font(FontFamilyName, 10, FontStyle.Regular); }
|
||||
if (boldFont == null) { boldFont = new Font(FontFamilyName, 10, FontStyle.Bold); }
|
||||
if (titleFont == null) { titleFont = new Font(FontFamilyName, 18, FontStyle.Bold); }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Override the default OnPrintPage method of the PrintDocument.
|
||||
/// </summary>
|
||||
/// <param name=e></param>
|
||||
/// <remarks>This provides the print logic for our document</remarks>
|
||||
protected override void OnPrintPage(System.Drawing.Printing.PrintPageEventArgs e)
|
||||
{
|
||||
/// Run base code
|
||||
base.OnPrintPage(e);
|
||||
|
||||
/// Use the StringFormat class for the text layout of our document
|
||||
StringFormat format = new StringFormat(StringFormatFlags.LineLimit);
|
||||
|
||||
|
||||
if (documentSection != DocumentSection.OtherPages)
|
||||
{
|
||||
///----------
|
||||
/// Header
|
||||
///----------
|
||||
if (documentSection == DocumentSection.FirstPage)
|
||||
{
|
||||
RectangleF printArea = new RectangleF(TitleX, TitleY, printWidth, 40);
|
||||
e.Graphics.DrawString(batch.ProtocolTitle, titleFont, Brushes.Black, printArea);
|
||||
}
|
||||
else
|
||||
{
|
||||
PrintAt(e, TitleX, TitleY, batch.ProtocolTitle);
|
||||
}
|
||||
|
||||
string[] leftColumn = new string[]
|
||||
{
|
||||
"Protokol č.: ",
|
||||
"Zákazník: ",
|
||||
"Datum a čas: ",
|
||||
"Procedura: ",
|
||||
"Popis procedury: ",
|
||||
"Typ vodoměru: ",
|
||||
"Zkoušející: ",
|
||||
"Název zkušební stanice: ",
|
||||
"Zkušební SW, č. verze: ",
|
||||
"Metodika: ", /// BenchAdresa 1
|
||||
//"Okolní teplota: ", // Disabled, see email dated 25.11.2016
|
||||
//"Okolní tlak: ",
|
||||
//"Relativní vlhkost: ",
|
||||
};
|
||||
|
||||
string[] rightColumn = new string[]
|
||||
{
|
||||
batch.BatchNr.ToString(),
|
||||
batch.WaterMeters[0].PurchaseOrder,
|
||||
//batch.EndTime.ToShortDateString() + " " + batch.EndTime.ToShortTimeString(),
|
||||
string.Format("{0}.{1}.{2} {3}:{4}", batch.EndTime.Year.ToString("D4"),
|
||||
batch.EndTime.Month.ToString("D2"),
|
||||
batch.EndTime.Day.ToString("D2"),
|
||||
batch.EndTime.Hour.ToString("D2"),
|
||||
batch.EndTime.Minute.ToString("D2")),
|
||||
string.IsNullOrEmpty(batch.ProcedureName) ? "" : batch.ProcedureName,
|
||||
string.IsNullOrEmpty(batch.ProcedureDescription) ? "" : batch.ProcedureDescription,
|
||||
string.IsNullOrEmpty(batch.WatermetersStr) ? "" : batch.WatermetersStr,
|
||||
string.IsNullOrEmpty(batch.UserName) ? "" : batch.UserName,
|
||||
string.IsNullOrEmpty(testBenchName) ? "" : testBenchName,
|
||||
string.Format("Test Bench Framework ver.{0}", batch.ProgramVersion),
|
||||
string.IsNullOrEmpty(address1) ? "" : address1,
|
||||
//batch.AmbientTempAve().ToString("F1") + " °C", // Disabled, see email dated 25.11.2016
|
||||
//Config.Units.ConvertTo(Config.Unit.mbar, batch.AmbientPressAve()).ToString("F0") + " mbar",
|
||||
//batch.AmbientHumiAve().ToString("F0") + " %",
|
||||
};
|
||||
|
||||
/// Determine max. left column width in characters
|
||||
int maxLen = 0;
|
||||
foreach (var s in leftColumn) if (s.Length > maxLen) maxLen = s.Length;
|
||||
|
||||
/// Write aligned columns
|
||||
for (int i = 0; i < Math.Min(leftColumn.Length, rightColumn.Length); i++)
|
||||
{
|
||||
PrintAt(e, leftMargin, HdrTop + SpacingOne * i, leftColumn[i]);
|
||||
PrintAt(e, 300, HdrTop + SpacingOne * i, rightColumn[i]);
|
||||
}
|
||||
}
|
||||
|
||||
if (documentSection == DocumentSection.FirstPage || documentSection == DocumentSection.OtherPages)
|
||||
{
|
||||
///--------
|
||||
/// Body
|
||||
///--------
|
||||
|
||||
/// This variable represents the top coordinate of the area where WM results are printed
|
||||
/// and it is updated (increased by) the value returned by PrintWM() - the section size.
|
||||
int nextWmTop = (pageNr == 1) ? BodyTop : TitleY;
|
||||
|
||||
int nrWMsOnPage = (pageNr == 1) ? nrWMsOnFirstPage : nrWMsOnNextPage;
|
||||
|
||||
for (int wmNr = nextWMNr; wmNr < Math.Min(nextWMNr + nrWMsOnPage, batch.WaterMeters.Count); wmNr++) /// wmNr is 0-based
|
||||
{
|
||||
int wmPosition = true ? batch.WaterMeters[wmNr].WMPosition : (wmNr + 1);
|
||||
nextWmTop += PrintWM(e, batch.WaterMeters[wmNr], wmPosition, nextWmTop);
|
||||
}
|
||||
|
||||
nextWMNr += nrWMsOnPage;
|
||||
e.HasMorePages = true;
|
||||
if (nextWMNr < batch.WaterMeters.Count)
|
||||
{
|
||||
documentSection = DocumentSection.OtherPages;
|
||||
}
|
||||
else
|
||||
{
|
||||
documentSection = DocumentSection.Appendix1;
|
||||
}
|
||||
|
||||
///----------
|
||||
/// Footer
|
||||
///----------
|
||||
string footerText = string.Format("{0} {1}/{2}", Strings.Page, pageNr++, nrPages);
|
||||
int footerWidth = (int)e.Graphics.MeasureString(footerText, font).Width;
|
||||
PrintAt(e, leftMargin + (printWidth - footerWidth) / 2, topMargin + printHeight - SpacingOne, footerText);
|
||||
}
|
||||
else
|
||||
{
|
||||
///-------------------------------
|
||||
/// List of passed water meters
|
||||
///-------------------------------
|
||||
|
||||
int nextWmTop = BodyTop;
|
||||
|
||||
foreach (var wm in batch.WaterMeters)
|
||||
{
|
||||
if (wm.Passed)
|
||||
{
|
||||
PrintAt(e, leftMargin, nextWmTop, string.Format("Vodoměr {0}: s/n {1}", wm.WMPosition, wm.SerialNr));
|
||||
nextWmTop += SpacingOne;
|
||||
}
|
||||
}
|
||||
|
||||
if (documentSection == DocumentSection.Appendix1)
|
||||
{
|
||||
documentSection = DocumentSection.Appendix2;
|
||||
e.HasMorePages = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
e.HasMorePages = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Print one water meter results
|
||||
/// </summary>
|
||||
/// <param name="wm">Water meter</param>
|
||||
/// <param name="printedWMNr">Number of the water meter printed</param>
|
||||
/// <param name="top">Top coordinate of watermeter data</param>
|
||||
/// <returns>The height of the printed section</returns>
|
||||
int PrintWM(System.Drawing.Printing.PrintPageEventArgs e,
|
||||
Results.Entities.WaterMeter wm, int printedWMNr, int top)
|
||||
{
|
||||
/// Determin column widths
|
||||
float[] columnPos = new float[rsltItems.Count + 1];
|
||||
columnPos[0] = (float)leftMargin;
|
||||
|
||||
for (int i = 0; i < rsltItems.Count; i++)
|
||||
{
|
||||
float columnWidth = e.Graphics.MeasureString(rsltItems[i].ClmnHeaderText, font).Width;
|
||||
foreach (var mtr in wm.MeterTestRslts)
|
||||
{
|
||||
string itemText;
|
||||
|
||||
if (!wm.Compound())
|
||||
{
|
||||
itemText = rsltItems[i].Print(mtr);
|
||||
}
|
||||
else if (mtr.CompoundMeterId == (byte)CompoundMeterId.Compound)
|
||||
{
|
||||
Results.Entities.MeterTestRslt mainMtr = wm.GetMeterTestRslt(mtr.Name(), CompoundMeterId.CompoundMain);
|
||||
Results.Entities.MeterTestRslt auxMtr = wm.GetMeterTestRslt(mtr.Name(), CompoundMeterId.CompoundAux);
|
||||
itemText = rsltItems[i].PrintCombined(mainMtr, auxMtr, mtr);
|
||||
}
|
||||
else
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
/// Strip color information
|
||||
string[] texts = itemText.Split(new char[] { '|' });
|
||||
if (texts.Length == 2) { itemText = texts[0]; }
|
||||
|
||||
float width = e.Graphics.MeasureString(itemText, font).Width;
|
||||
if (width > columnWidth) columnWidth = width;
|
||||
}
|
||||
columnPos[i + 1] = columnPos[i] + columnWidth + 20.0f;
|
||||
}
|
||||
int tableLeftX = (int)columnPos[0];
|
||||
int tableRightX = (int)columnPos[rsltItems.Count] - 20;
|
||||
|
||||
string wmText = string.Format("Vodoměr {0}", printedWMNr);
|
||||
PrintAt(e, leftMargin, top, wmText);
|
||||
if (!string.IsNullOrEmpty(wm.SerialNr))
|
||||
{
|
||||
PrintAt(e, leftMargin + (int)e.Graphics.MeasureString(wmText, font).Width, top,
|
||||
string.Format(" s/n = {0}", wm.SerialNr));
|
||||
}
|
||||
|
||||
/// Horizontal line
|
||||
int horY = top + 25;
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, 2), new Point(tableLeftX, horY), new Point(tableRightX, horY));
|
||||
|
||||
for (int i = 0; i < rsltItems.Count; i++)
|
||||
{
|
||||
PrintAt(e, (int)columnPos[i], top + 27, rsltItems[i].ClmnHeaderText);
|
||||
}
|
||||
|
||||
/// Horizontal line
|
||||
horY = top + 27 + SpacingOne;
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, 2), new Point(tableLeftX, horY), new Point(tableRightX, horY));
|
||||
|
||||
int testsCount = 0;
|
||||
foreach (var mtr in wm.MeterTestRslts)
|
||||
{
|
||||
if (mtr.Publish() == Config.Entities.Publish.Always)
|
||||
{
|
||||
testsCount++;
|
||||
for (int i = 0; i < rsltItems.Count; i++)
|
||||
{
|
||||
string itemText;
|
||||
|
||||
if (!wm.Compound())
|
||||
{
|
||||
/// Single water meter
|
||||
itemText = rsltItems[i].Print(mtr);
|
||||
}
|
||||
else if (mtr.CompoundMeterId == (byte)CompoundMeterId.Compound)
|
||||
{
|
||||
Results.Entities.MeterTestRslt mainMtr = wm.GetMeterTestRslt(mtr.Name(), CompoundMeterId.CompoundMain);
|
||||
Results.Entities.MeterTestRslt auxMtr = wm.GetMeterTestRslt(mtr.Name(), CompoundMeterId.CompoundMain);
|
||||
itemText = rsltItems[i].PrintCombined(mainMtr, auxMtr, mtr);
|
||||
}
|
||||
else
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
/// Strip color information
|
||||
string[] texts = itemText.Split(new char[] { '|' });
|
||||
if (texts.Length == 2)
|
||||
{
|
||||
itemText = texts[0];
|
||||
Color color = texts[1].Equals("Green") ? Color.Green : (texts[1].Equals("Red") ? Color.Red : Color.White);
|
||||
/// TODO: How to print colors?
|
||||
}
|
||||
|
||||
PrintAt(e, (int)columnPos[i], top + 30 + SpacingOne * testsCount, itemText);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Horizontal line
|
||||
horY = top + 30 + SpacingOne * (testsCount + 1);
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, 2), new Point(tableLeftX, horY), new Point(tableRightX, horY));
|
||||
|
||||
return (testsCount + 4) * SpacingOne;
|
||||
}
|
||||
|
||||
|
||||
void PrintAt(System.Drawing.Printing.PrintPageEventArgs e, Point p, string text)
|
||||
{
|
||||
PrintAt(e, p.X, p.Y, text);
|
||||
}
|
||||
|
||||
|
||||
void PrintAt(System.Drawing.Printing.PrintPageEventArgs e, int x, int y, string text)
|
||||
{
|
||||
RectangleF printArea = new RectangleF(x, y, 667, SpacingOne);
|
||||
e.Graphics.DrawString(text, this.font, Brushes.Black, printArea);
|
||||
}
|
||||
|
||||
|
||||
void PrintBoldAt(System.Drawing.Printing.PrintPageEventArgs e, Point p, string text)
|
||||
{
|
||||
PrintBoldAt(e, p.X, p.Y, text);
|
||||
}
|
||||
|
||||
|
||||
void PrintBoldAt(System.Drawing.Printing.PrintPageEventArgs e, int x, int y, string text)
|
||||
{
|
||||
RectangleF printArea = new RectangleF(x, y, 667, SpacingOne);
|
||||
e.Graphics.DrawString(text, this.boldFont, Brushes.Black, printArea);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,389 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2016-2017 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Drawing;
|
||||
using System.Drawing.Printing;
|
||||
using Config.Entities;
|
||||
|
||||
namespace Results.Output.Printers.Munich
|
||||
{
|
||||
public class MunichPrintDocument : PrintDocument
|
||||
{
|
||||
const string FontFamilyName = "Arial"; //"Times New Roman";
|
||||
|
||||
const int SpacingOne = 18;
|
||||
const int SpacingOneAndHalf = (3 * SpacingOne) / 2;
|
||||
const int TitleX = 240;
|
||||
const int TitleY = 180; /// Depends on the size of the header
|
||||
const int FirstLineNr = 14; /// Depends on the size of the header
|
||||
const int Tab1 = 80; /// Positions of columns above the table
|
||||
const int Tab2 = 240;
|
||||
const int Tab3 = 430;
|
||||
const int Tab4 = 590;
|
||||
const int BorderW = 1; /// Table border line width
|
||||
const int MarginTop = 7; /// Margins of the text from table lines
|
||||
const int MarginLeft = 4; /// Margins of the text from table lines
|
||||
|
||||
///
|
||||
/// Data to print
|
||||
///
|
||||
readonly string docVersion;
|
||||
readonly Results.Entities.WaterMeter wm;
|
||||
string zaehlertyp;
|
||||
string pruefvorlage;
|
||||
|
||||
readonly IList<Results.Entities.MeterTestRslt> results;
|
||||
readonly int resultsCount;
|
||||
readonly bool compound; /// true when MetersKind is MetersKind.Combined
|
||||
|
||||
readonly int secondTableOffset; /// Calculated in the constructor
|
||||
|
||||
/// Top coordinate of the table
|
||||
int top;
|
||||
|
||||
/// <summary>
|
||||
/// Property variable for the Font the user wishes to use
|
||||
/// </summary>
|
||||
Font font;
|
||||
Font boldFont;
|
||||
Font fontTitle;
|
||||
|
||||
/// <summary>
|
||||
/// Constructor
|
||||
/// </summary>
|
||||
/// <param name="textToPrint">Text to be printed</param>
|
||||
public MunichPrintDocument(string docVersion,
|
||||
Results.Entities.WaterMeter wm,
|
||||
PageOrientation pageOrientation)
|
||||
{
|
||||
this.docVersion = docVersion;
|
||||
this.wm = wm;
|
||||
compound = wm.Compound();
|
||||
|
||||
string[] info = wm.ProductName().Split(new char[] { ';' });
|
||||
if (info.Length >= 2)
|
||||
{
|
||||
pruefvorlage = info[0];
|
||||
zaehlertyp = info[1];
|
||||
}
|
||||
else if (info.Length == 1)
|
||||
{
|
||||
pruefvorlage = info[0];
|
||||
zaehlertyp = compound ? "Verbundzähler" : "Einzelzähler";
|
||||
}
|
||||
else
|
||||
{
|
||||
pruefvorlage = wm.ProcedureName();
|
||||
zaehlertyp = compound ? "Verbundzähler" : "Einzelzähler";
|
||||
}
|
||||
|
||||
results = wm.MeterTestRslts;
|
||||
this.resultsCount = compound ? (results.Count / 3) : results.Count;
|
||||
|
||||
int resultsCount = wm.MeterTestRslts.Count;
|
||||
if (compound) resultsCount /= 3;
|
||||
|
||||
secondTableOffset = (resultsCount + 2) * SpacingOneAndHalf;
|
||||
|
||||
DefaultPageSettings.Landscape = (pageOrientation == PageOrientation.Landscape);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Override the default onbeginPrint method of the PrintDocument Object.
|
||||
/// </summary>
|
||||
/// <param name=e></param>
|
||||
/// <remarks></remarks>
|
||||
protected override void OnBeginPrint(System.Drawing.Printing.PrintEventArgs e)
|
||||
{
|
||||
base.OnBeginPrint(e);
|
||||
|
||||
if (font == null) { font = new Font(FontFamilyName, 10, FontStyle.Regular); }
|
||||
if (boldFont == null) { boldFont = new Font(FontFamilyName, 10, FontStyle.Bold); }
|
||||
if (fontTitle == null) { fontTitle = new Font(FontFamilyName, 24, FontStyle.Bold); }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Override the default OnPrintPage method of the PrintDocument.
|
||||
/// </summary>
|
||||
/// <param name=e></param>
|
||||
/// <remarks>This provides the print logic for our document</remarks>
|
||||
protected override void OnPrintPage(System.Drawing.Printing.PrintPageEventArgs e)
|
||||
{
|
||||
/// Run base code
|
||||
base.OnPrintPage(e);
|
||||
|
||||
/// Draw 2550 x 3507 'headpic' scaled to A4 at 100 DPI
|
||||
e.Graphics.DrawImage(Results.Properties.Resources.Headpic, new Rectangle(0, 0, 827, 1137));
|
||||
|
||||
/// Set print area size and margins (in dots using 80 dpi)
|
||||
int printHeight = base.DefaultPageSettings.PaperSize.Height - base.DefaultPageSettings.Margins.Top - base.DefaultPageSettings.Margins.Bottom;
|
||||
int printWidth = base.DefaultPageSettings.PaperSize.Width - base.DefaultPageSettings.Margins.Left - base.DefaultPageSettings.Margins.Right;
|
||||
int leftMargin = base.DefaultPageSettings.Margins.Left; /// X
|
||||
int topMargin = base.DefaultPageSettings.Margins.Top; /// Y
|
||||
|
||||
/// Check if the user selected to print in Landscape mode
|
||||
/// if they did then we need to swap height/width parameters
|
||||
if (base.DefaultPageSettings.Landscape)
|
||||
{
|
||||
int tmp = printHeight;
|
||||
printHeight = printWidth;
|
||||
printWidth = tmp;
|
||||
}
|
||||
|
||||
int x = leftMargin;
|
||||
int y = topMargin;
|
||||
|
||||
/// Use the StringFormat class for the text layout of our document
|
||||
StringFormat format = new StringFormat(StringFormatFlags.LineLimit);
|
||||
|
||||
RectangleF printArea = new RectangleF(TitleX, TitleY, 667, 50);
|
||||
e.Graphics.DrawString(wm.Batch.ProtocolTitle, this.fontTitle, Brushes.Black, printArea);
|
||||
|
||||
int lineNr = FirstLineNr;
|
||||
PrintAt(e, Tab1, lineNr * SpacingOne, docVersion);
|
||||
lineNr++;
|
||||
PrintBoldAt(e, Tab1, lineNr * SpacingOne, "Prüfstand Nr :");
|
||||
PrintBoldAt(e, Tab2, lineNr * SpacingOne, wm.BenchId().ToString());
|
||||
PrintBoldAt(e, Tab3, lineNr * SpacingOne, "Datum :");
|
||||
PrintBoldAt(e, Tab4, lineNr * SpacingOne, wm.Batch.EndTime.Date.ToString("d"));
|
||||
lineNr++;
|
||||
PrintAt(e, Tab1, lineNr * SpacingOne, "Zählertyp :");
|
||||
PrintAt(e, Tab2, lineNr * SpacingOne, zaehlertyp);
|
||||
PrintAt(e, Tab3, lineNr * SpacingOne, "Eichjahr :");
|
||||
PrintAt(e, Tab4, lineNr * SpacingOne, wm.YearOfProduction.ToString());
|
||||
lineNr++;
|
||||
PrintAt(e, Tab1, lineNr * SpacingOne, "Prüfvorlage :");
|
||||
PrintAt(e, Tab2, lineNr * SpacingOne, pruefvorlage);
|
||||
lineNr += 2;
|
||||
|
||||
if (compound)
|
||||
{
|
||||
PrintBoldAt(e, Tab1, lineNr * SpacingOne, "Hauptzahler");
|
||||
PrintBoldAt(e, Tab3, lineNr * SpacingOne, "Nebenzahler");
|
||||
lineNr++;
|
||||
}
|
||||
|
||||
PrintAt(e, Tab1, lineNr * SpacingOne, "Hersteller :");
|
||||
PrintAt(e, Tab2, lineNr * SpacingOne, wm.Producer());
|
||||
if (compound)
|
||||
{
|
||||
PrintAt(e, Tab3, lineNr * SpacingOne, "Hersteller :");
|
||||
PrintAt(e, Tab4, lineNr * SpacingOne, wm.ProducerAux());
|
||||
}
|
||||
lineNr++;
|
||||
|
||||
PrintAt(e, Tab1, lineNr * SpacingOne, "Seriennummer :");
|
||||
PrintAt(e, Tab2, lineNr * SpacingOne, wm.SerialNr);
|
||||
if (compound)
|
||||
{
|
||||
PrintAt(e, Tab3, lineNr * SpacingOne, "Seriennummer :");
|
||||
PrintAt(e, Tab4, lineNr * SpacingOne, wm.SerialNrAux);
|
||||
}
|
||||
lineNr++;
|
||||
|
||||
PrintAt(e, Tab1, lineNr * SpacingOne, "Qn :");
|
||||
PrintAt(e, Tab2, lineNr * SpacingOne, wm.Q3_Qn().ToString());
|
||||
if (compound)
|
||||
{
|
||||
PrintAt(e, Tab3, lineNr * SpacingOne, "Qn :");
|
||||
PrintAt(e, Tab4, lineNr * SpacingOne, wm.Q3_Qn_Aux().ToString());
|
||||
}
|
||||
lineNr++;
|
||||
|
||||
PrintAt(e, Tab1, lineNr * SpacingOne, "Zulassungszeichen :");
|
||||
PrintAt(e, Tab2, lineNr * SpacingOne, wm.ApprovalInfo());
|
||||
if (compound)
|
||||
{
|
||||
PrintAt(e, Tab3, lineNr * SpacingOne, "Zulassungszeichen :");
|
||||
PrintAt(e, Tab4, lineNr * SpacingOne, wm.ApprovalInfoAux());
|
||||
}
|
||||
lineNr++;
|
||||
|
||||
PrintAt(e, Tab1, lineNr * SpacingOne, "Metr. klasse :");
|
||||
PrintAt(e, Tab2, lineNr * SpacingOne, wm.MetrologicalClass());
|
||||
if (compound)
|
||||
{
|
||||
PrintAt(e, Tab3, lineNr * SpacingOne, "Metr. klasse :");
|
||||
PrintAt(e, Tab4, lineNr * SpacingOne, wm.MetrologicalClassAux());
|
||||
}
|
||||
lineNr++;
|
||||
|
||||
PrintAt(e, Tab1, lineNr * SpacingOne, "Stand :");
|
||||
PrintAt(e, Tab2, lineNr * SpacingOne, wm.EndState);
|
||||
if (compound)
|
||||
{
|
||||
PrintAt(e, Tab3, lineNr * SpacingOne, "Stand :");
|
||||
PrintAt(e, Tab4, lineNr * SpacingOne, wm.EndStateAux);
|
||||
|
||||
lineNr += 2;
|
||||
PrintAt(e, Tab1, lineNr * SpacingOne, "Umschaltpunkte :");
|
||||
lineNr++;
|
||||
PrintAt(e, Tab1, lineNr * SpacingOne, "Qsteig");
|
||||
PrintAt(e, Tab2, lineNr * SpacingOne, (1000.0 * wm.QRise).ToString("F1") + " l/h");
|
||||
lineNr++;
|
||||
PrintAt(e, Tab1, lineNr * SpacingOne, "Qfall");
|
||||
PrintAt(e, Tab2, lineNr * SpacingOne, (1000.0 * wm.QFall).ToString("F1") + " l/h");
|
||||
}
|
||||
|
||||
lineNr += 2;
|
||||
top = SpacingOne * lineNr;
|
||||
|
||||
PrintTable(e);
|
||||
DrawTable(e);
|
||||
|
||||
lineNr += (secondTableOffset * 2) / SpacingOne;
|
||||
PrintAt(e, Tab1, lineNr * SpacingOne, "Temperatur");
|
||||
PrintAt(e, Tab2, lineNr * SpacingOne, wm.Batch.AmbientTempAve().ToString("F1") + " \x00b0C");
|
||||
lineNr++;
|
||||
PrintAt(e, Tab1, lineNr * SpacingOne, "Feuchtigkeit");
|
||||
PrintAt(e, Tab2, lineNr * SpacingOne, wm.Batch.AmbientHumiAve().ToString("F0") + " %");
|
||||
lineNr++;
|
||||
PrintAt(e, Tab1, lineNr * SpacingOne, "Luftdruck");
|
||||
PrintAt(e, Tab2, lineNr * SpacingOne, Config.Units.ConvertTo(Config.Unit.mbar, wm.Batch.AmbientPressAve()).ToString("F0") + " mbar");
|
||||
|
||||
lineNr++;
|
||||
PrintAt(e, Tab3, lineNr * SpacingOne, wm.Batch.EndTime.Date.ToString("d"));
|
||||
lineNr ++;
|
||||
PrintAt(e, Tab3, lineNr * SpacingOne, "Datum");
|
||||
PrintAt(e, Tab4, lineNr * SpacingOne, "Unterschrift");
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Print table texts.
|
||||
/// </summary>
|
||||
void PrintTable(System.Drawing.Printing.PrintPageEventArgs e)
|
||||
{
|
||||
PrintAt(e, FromTest(-1, -1), "Prüflauf");
|
||||
PrintAt(e, FromTest(-1, 0), "Q [l/h]");
|
||||
PrintAt(e, FromTest(-1, 1), "Prüf-Vol.[l]");
|
||||
PrintAt(e, FromTest(-1, 2), compound ? "HZ-Vol.[l]" : "Z-Vol.[l]");
|
||||
PrintAt(e, FromTest(-1, 3), compound ? "NZ-Vol.[l]" : "-");
|
||||
PrintAt(e, FromTest(-1, 4), "Fehler [%]");
|
||||
PrintAt(e, FromTest(-1, 5), "Ergebnis");
|
||||
|
||||
PrintAt(e, FromTest(-1, 6), "Q [l/h]");
|
||||
PrintAt(e, FromTest(-1, 7), "Temperatur");
|
||||
PrintAt(e, FromTest(-1, 8), "Dichte");
|
||||
PrintAt(e, FromTest(-1, 9), "Prüfzeit");
|
||||
PrintAt(e, FromTest(-1, 10), "Druck Eing.");
|
||||
PrintAt(e, FromTest(-1, 11), "Druck Ausg.");
|
||||
|
||||
int rowCnt = 0;
|
||||
foreach (var mtr in wm.MeterTestRslts)
|
||||
{
|
||||
if (!compound || mtr.CompoundMeterId == (byte)CompoundMeterId.Compound)
|
||||
{
|
||||
Point p = FromTest(rowCnt, -1);
|
||||
PrintAt(e, p.X, p.Y, mtr.Name());
|
||||
PrintAt(e, p.X, p.Y + (resultsCount + 2) * SpacingOneAndHalf, mtr.Name());
|
||||
|
||||
PrintAt(e, FromTest(rowCnt, 0), mtr.TestRslt.FlowMass.ToString("F1"));
|
||||
PrintAt(e, FromTest(rowCnt, 1), mtr.TestRslt.VolumeCTV.ToString("F2"));
|
||||
if (compound)
|
||||
{
|
||||
Results.Entities.MeterTestRslt mainMtr = wm.GetMeterTestRslt(mtr.Name(), CompoundMeterId.CompoundMain);
|
||||
Results.Entities.MeterTestRslt auxMtr = wm.GetMeterTestRslt(mtr.Name(), CompoundMeterId.CompoundAux);
|
||||
|
||||
PrintAt(e, FromTest(rowCnt, 2), mainMtr.VolumeMeter.ToString("F2"));
|
||||
PrintAt(e, FromTest(rowCnt, 3), auxMtr.VolumeMeter.ToString("F2"));
|
||||
PrintAt(e, FromTest(rowCnt, 4), mtr.Error.ToString("F2"));
|
||||
PrintAt(e, FromTest(rowCnt, 5), mtr.Passed ? "iO" : "NiO");
|
||||
}
|
||||
else
|
||||
{
|
||||
PrintAt(e, FromTest(rowCnt, 2), mtr.VolumeMeter.ToString("F2"));
|
||||
PrintAt(e, FromTest(rowCnt, 3), "-");
|
||||
PrintAt(e, FromTest(rowCnt, 4), mtr.Error.ToString("F2"));
|
||||
PrintAt(e, FromTest(rowCnt, 5), mtr.Passed ? "iO" : "NiO");
|
||||
}
|
||||
PrintAt(e, FromTest(rowCnt, 6), mtr.TestRslt.FlowMass.ToString("F1"));
|
||||
PrintAt(e, FromTest(rowCnt, 7), mtr.TestRslt.TempDownMean.ToString("F2"));
|
||||
PrintAt(e, FromTest(rowCnt, 8), mtr.TestRslt.DensityDiv.ToString("F2"));
|
||||
PrintAt(e, FromTest(rowCnt, 9), mtr.TestTime.ToString("F1"));
|
||||
PrintAt(e, FromTest(rowCnt, 10), Config.Units.ConvertTo(Config.Unit.bar, mtr.TestRslt.PressUpMean).ToString("F3"));
|
||||
PrintAt(e, FromTest(rowCnt, 11), Config.Units.ConvertTo(Config.Unit.bar, mtr.TestRslt.PressDownMean).ToString("F3"));
|
||||
|
||||
rowCnt++;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Draw table lines.
|
||||
/// </summary>
|
||||
void DrawTable(System.Drawing.Printing.PrintPageEventArgs e)
|
||||
{
|
||||
int mid = top + SpacingOneAndHalf;
|
||||
int bot = top + (resultsCount + 1) * SpacingOneAndHalf;
|
||||
|
||||
int top2 = top + secondTableOffset;
|
||||
int mid2 = mid + secondTableOffset;
|
||||
int bot2 = bot + secondTableOffset;
|
||||
|
||||
// Horizontal lines
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point(80, top), new Point(747, top));
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point(80, mid), new Point(747, mid));
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point(80, bot), new Point(747, bot));
|
||||
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point(80, top2), new Point(747, top2));
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point(80, mid2), new Point(747, mid2));
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point(80, bot2), new Point(747, bot2));
|
||||
|
||||
// Vertical lines
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point( 80, top), new Point( 80, bot));
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point(267, top), new Point(267, bot));
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point(347, top), new Point(347, bot));
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point(427, top), new Point(427, bot));
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point(507, top), new Point(507, bot));
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point(587, top), new Point(587, bot));
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point(667, top), new Point(667, bot));
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point(747, top), new Point(747, bot));
|
||||
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point( 80, top2), new Point( 80, bot2));
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point(267, top2), new Point(267, bot2));
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point(347, top2), new Point(347, bot2));
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point(427, top2), new Point(427, bot2));
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point(507, top2), new Point(507, bot2));
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point(587, top2), new Point(587, bot2));
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point(667, top2), new Point(667, bot2));
|
||||
e.Graphics.DrawLine(new Pen(Color.Black, BorderW), new Point(747, top2), new Point(747, bot2));
|
||||
}
|
||||
|
||||
void PrintAt(System.Drawing.Printing.PrintPageEventArgs e, Point p, string text)
|
||||
{
|
||||
PrintAt(e, p.X, p.Y, text);
|
||||
}
|
||||
|
||||
void PrintAt(System.Drawing.Printing.PrintPageEventArgs e, int x, int y, string text)
|
||||
{
|
||||
RectangleF printArea = new RectangleF(x, y, 667, SpacingOne);
|
||||
e.Graphics.DrawString(text, this.font, Brushes.Black, printArea);
|
||||
}
|
||||
|
||||
void PrintBoldAt(System.Drawing.Printing.PrintPageEventArgs e, Point p, string text)
|
||||
{
|
||||
PrintBoldAt(e, p.X, p.Y, text);
|
||||
}
|
||||
|
||||
void PrintBoldAt(System.Drawing.Printing.PrintPageEventArgs e, int x, int y, string text)
|
||||
{
|
||||
RectangleF printArea = new RectangleF(x, y, 667, SpacingOne);
|
||||
e.Graphics.DrawString(text, this.boldFont, Brushes.Black, printArea);
|
||||
}
|
||||
|
||||
Point FromTest(int testNr, int parNr)
|
||||
{
|
||||
const int NrParamsInOneTableRow = 6;
|
||||
|
||||
int x = 267 + (parNr % NrParamsInOneTableRow) * 80 + MarginLeft;
|
||||
int y = top + SpacingOneAndHalf + MarginTop + testNr * SpacingOneAndHalf
|
||||
+ ((parNr >= NrParamsInOneTableRow) ? secondTableOffset : 0);
|
||||
|
||||
if (parNr < 0) x = 80 + MarginLeft; /// When parNr == -1 return the left column x coordinate
|
||||
|
||||
return new Point(x, y);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,36 +0,0 @@
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
// General Information about an assembly is controlled through the following
|
||||
// set of attributes. Change these attribute values to modify the information
|
||||
// associated with an assembly.
|
||||
[assembly: AssemblyTitle("Results")]
|
||||
[assembly: AssemblyDescription("")]
|
||||
[assembly: AssemblyConfiguration("")]
|
||||
[assembly: AssemblyCompany("Sensus")]
|
||||
[assembly: AssemblyProduct("Results")]
|
||||
[assembly: AssemblyCopyright("Copyright © 2016")]
|
||||
[assembly: AssemblyTrademark("")]
|
||||
[assembly: AssemblyCulture("")]
|
||||
|
||||
// Setting ComVisible to false makes the types in this assembly not visible
|
||||
// to COM components. If you need to access a type in this assembly from
|
||||
// COM, set the ComVisible attribute to true on that type.
|
||||
[assembly: ComVisible(false)]
|
||||
|
||||
// The following GUID is for the ID of the typelib if this project is exposed to COM
|
||||
[assembly: Guid("5da980c4-8924-4762-9b72-91e011e08f6c")]
|
||||
|
||||
// Version information for an assembly consists of the following four values:
|
||||
//
|
||||
// Major Version
|
||||
// Minor Version
|
||||
// Build Number
|
||||
// Revision
|
||||
//
|
||||
// You can specify all the values or you can default the Build and Revision Numbers
|
||||
// by using the '*' as shown below:
|
||||
// [assembly: AssemblyVersion("1.0.*")]
|
||||
[assembly: AssemblyVersion("2.12.486.0")]
|
||||
[assembly: AssemblyFileVersion("2.12.486.0")]
|
||||
Generated
-73
@@ -1,73 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
// Runtime Version:4.0.30319.42000
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Results.Properties {
|
||||
using System;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// A strongly-typed resource class, for looking up localized strings, etc.
|
||||
/// </summary>
|
||||
// This class was auto-generated by the StronglyTypedResourceBuilder
|
||||
// class via a tool like ResGen or Visual Studio.
|
||||
// To add or remove a member, edit your .ResX file then rerun ResGen
|
||||
// with the /str option, or rebuild your VS project.
|
||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
|
||||
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||
internal class Resources {
|
||||
|
||||
private static global::System.Resources.ResourceManager resourceMan;
|
||||
|
||||
private static global::System.Globalization.CultureInfo resourceCulture;
|
||||
|
||||
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
|
||||
internal Resources() {
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Returns the cached ResourceManager instance used by this class.
|
||||
/// </summary>
|
||||
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||
internal static global::System.Resources.ResourceManager ResourceManager {
|
||||
get {
|
||||
if (object.ReferenceEquals(resourceMan, null)) {
|
||||
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("Results.Properties.Resources", typeof(Resources).Assembly);
|
||||
resourceMan = temp;
|
||||
}
|
||||
return resourceMan;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Overrides the current thread's CurrentUICulture property for all
|
||||
/// resource lookups using this strongly typed resource class.
|
||||
/// </summary>
|
||||
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||
internal static global::System.Globalization.CultureInfo Culture {
|
||||
get {
|
||||
return resourceCulture;
|
||||
}
|
||||
set {
|
||||
resourceCulture = value;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized resource of type System.Drawing.Bitmap.
|
||||
/// </summary>
|
||||
internal static System.Drawing.Bitmap Headpic {
|
||||
get {
|
||||
object obj = ResourceManager.GetObject("Headpic", resourceCulture);
|
||||
return ((System.Drawing.Bitmap)(obj));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,124 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
|
||||
<data name="Headpic" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||
<value>..\Resources\Headpic.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||
</data>
|
||||
</root>
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 71 KiB |
Generated
-1008
File diff suppressed because it is too large
Load Diff
@@ -1,198 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<data name="Add" xml:space="preserve">
|
||||
<value>Přidat ></value>
|
||||
</data>
|
||||
<data name="Alignment" xml:space="preserve">
|
||||
<value>Zarovnání</value>
|
||||
</data>
|
||||
<data name="Available_results" xml:space="preserve">
|
||||
<value>Dostupné výsledky</value>
|
||||
</data>
|
||||
<data name="CancelBtnText" xml:space="preserve">
|
||||
<value>Zrušit</value>
|
||||
</data>
|
||||
<data name="Caption" xml:space="preserve">
|
||||
<value>Nadpis</value>
|
||||
</data>
|
||||
<data name="Configuration" xml:space="preserve">
|
||||
<value>Konfigurace</value>
|
||||
</data>
|
||||
<data name="DownBtnText" xml:space="preserve">
|
||||
<value>Dolů</value>
|
||||
</data>
|
||||
<data name="Format" xml:space="preserve">
|
||||
<value>Formát</value>
|
||||
</data>
|
||||
<data name="Item" xml:space="preserve">
|
||||
<value>Položka</value>
|
||||
</data>
|
||||
<data name="OkBtnText" xml:space="preserve">
|
||||
<value>OK</value>
|
||||
</data>
|
||||
<data name="Precision" xml:space="preserve">
|
||||
<value>Přesnost</value>
|
||||
</data>
|
||||
<data name="Remark" xml:space="preserve">
|
||||
<value>Poznámka</value>
|
||||
</data>
|
||||
<data name="Remove" xml:space="preserve">
|
||||
<value>< Odebrat</value>
|
||||
</data>
|
||||
<data name="Remove_all" xml:space="preserve">
|
||||
<value>Odebrat vše</value>
|
||||
</data>
|
||||
<data name="Result" xml:space="preserve">
|
||||
<value>Výsledek</value>
|
||||
</data>
|
||||
<data name="Results" xml:space="preserve">
|
||||
<value>Výsledky</value>
|
||||
</data>
|
||||
<data name="Result_code" xml:space="preserve">
|
||||
<value>Kód výsledku</value>
|
||||
</data>
|
||||
<data name="Selected_results" xml:space="preserve">
|
||||
<value>Vybrané výsledky</value>
|
||||
</data>
|
||||
<data name="Test_ID" xml:space="preserve">
|
||||
<value>Test</value>
|
||||
</data>
|
||||
<data name="Units" xml:space="preserve">
|
||||
<value>Jednotky</value>
|
||||
</data>
|
||||
<data name="UpBtnText" xml:space="preserve">
|
||||
<value>Nahoru</value>
|
||||
</data>
|
||||
<data name="Width" xml:space="preserve">
|
||||
<value>Šířka</value>
|
||||
</data>
|
||||
<data name="Mounting" xml:space="preserve">
|
||||
<value>Montáž</value>
|
||||
</data>
|
||||
<data name="Page" xml:space="preserve">
|
||||
<value>str.</value>
|
||||
</data>
|
||||
<data name="Category" xml:space="preserve">
|
||||
<value>Kategorie</value>
|
||||
</data>
|
||||
<data name="Quantity" xml:space="preserve">
|
||||
<value>Veličina</value>
|
||||
</data>
|
||||
</root>
|
||||
@@ -1,384 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<data name="Add" xml:space="preserve">
|
||||
<value>Hinzufügen ></value>
|
||||
</data>
|
||||
<data name="Alignment" xml:space="preserve">
|
||||
<value>Ausrichtung</value>
|
||||
</data>
|
||||
<data name="Approval" xml:space="preserve">
|
||||
<value>Zulassung</value>
|
||||
</data>
|
||||
<data name="Available_results" xml:space="preserve">
|
||||
<value>Ergebnisse</value>
|
||||
</data>
|
||||
<data name="Batch_nr" xml:space="preserve">
|
||||
<value>Stapel Nr.</value>
|
||||
</data>
|
||||
<data name="Bench" xml:space="preserve">
|
||||
<value>Prüfstand</value>
|
||||
</data>
|
||||
<data name="CancelBtnText" xml:space="preserve">
|
||||
<value>Abbrechen</value>
|
||||
</data>
|
||||
<data name="Caption" xml:space="preserve">
|
||||
<value>Überschrift</value>
|
||||
</data>
|
||||
<data name="Configuration" xml:space="preserve">
|
||||
<value>Konfiguration</value>
|
||||
</data>
|
||||
<data name="Density" xml:space="preserve">
|
||||
<value>Dichte</value>
|
||||
</data>
|
||||
<data name="DownBtnText" xml:space="preserve">
|
||||
<value>Abwärts</value>
|
||||
</data>
|
||||
<data name="End" xml:space="preserve">
|
||||
<value>Endzeit</value>
|
||||
</data>
|
||||
<data name="EndState_aux" xml:space="preserve">
|
||||
<value>Eindstand Nebenz.</value>
|
||||
</data>
|
||||
<data name="EndState_main" xml:space="preserve">
|
||||
<value>Eindstand Hauptz.</value>
|
||||
</data>
|
||||
<data name="End_state" xml:space="preserve">
|
||||
<value>Eindstand</value>
|
||||
</data>
|
||||
<data name="ErrLimHi" xml:space="preserve">
|
||||
<value>Fehlergrenze hoch</value>
|
||||
</data>
|
||||
<data name="ErrLimLo" xml:space="preserve">
|
||||
<value>Fehlergrenze niedrig</value>
|
||||
</data>
|
||||
<data name="Error" xml:space="preserve">
|
||||
<value>Fehler</value>
|
||||
</data>
|
||||
<data name="ErrRef" xml:space="preserve">
|
||||
<value>Referenzfehler</value>
|
||||
</data>
|
||||
<data name="Err_aux" xml:space="preserve">
|
||||
<value>Fehler Nebenz.</value>
|
||||
</data>
|
||||
<data name="Err_main" xml:space="preserve">
|
||||
<value>Fehler Hauptz.</value>
|
||||
</data>
|
||||
<data name="Flow" xml:space="preserve">
|
||||
<value>Durchfluss</value>
|
||||
</data>
|
||||
<data name="Format" xml:space="preserve">
|
||||
<value>Format</value>
|
||||
</data>
|
||||
<data name="H_amb" xml:space="preserve">
|
||||
<value>H umgebung</value>
|
||||
</data>
|
||||
<data name="Item" xml:space="preserve">
|
||||
<value>Posten</value>
|
||||
</data>
|
||||
<data name="MClass" xml:space="preserve">
|
||||
<value>Metr. Klasse</value>
|
||||
</data>
|
||||
<data name="OkBtnText" xml:space="preserve">
|
||||
<value>OK</value>
|
||||
</data>
|
||||
<data name="PO" xml:space="preserve">
|
||||
<value>Bestellung</value>
|
||||
</data>
|
||||
<data name="Pos" xml:space="preserve">
|
||||
<value>Pos.</value>
|
||||
</data>
|
||||
<data name="Precision" xml:space="preserve">
|
||||
<value>Präzision</value>
|
||||
</data>
|
||||
<data name="Procedure" xml:space="preserve">
|
||||
<value>Prüfvorlage</value>
|
||||
</data>
|
||||
<data name="Protocol" xml:space="preserve">
|
||||
<value>Protokoll</value>
|
||||
</data>
|
||||
<data name="Pulses" xml:space="preserve">
|
||||
<value>Impulse</value>
|
||||
</data>
|
||||
<data name="PulsesLiter" xml:space="preserve">
|
||||
<value>Impulse/l</value>
|
||||
</data>
|
||||
<data name="P_amb" xml:space="preserve">
|
||||
<value>Dr umgebung</value>
|
||||
</data>
|
||||
<data name="P_dn_end" xml:space="preserve">
|
||||
<value>Dr aus ende</value>
|
||||
</data>
|
||||
<data name="P_dn" xml:space="preserve">
|
||||
<value>Dr aus</value>
|
||||
</data>
|
||||
<data name="P_dn_start" xml:space="preserve">
|
||||
<value>Dr aus start</value>
|
||||
</data>
|
||||
<data name="P_up_end" xml:space="preserve">
|
||||
<value>Dr ein ende</value>
|
||||
</data>
|
||||
<data name="P_up" xml:space="preserve">
|
||||
<value>Dr ein</value>
|
||||
</data>
|
||||
<data name="P_up_start" xml:space="preserve">
|
||||
<value>Dr ein start</value>
|
||||
</data>
|
||||
<data name="Q_fall" xml:space="preserve">
|
||||
<value>Q fall</value>
|
||||
</data>
|
||||
<data name="Q_from" xml:space="preserve">
|
||||
<value>Q von</value>
|
||||
</data>
|
||||
<data name="Q_rise" xml:space="preserve">
|
||||
<value>Q steig</value>
|
||||
</data>
|
||||
<data name="Q_to" xml:space="preserve">
|
||||
<value>Q bis</value>
|
||||
</data>
|
||||
<data name="RefPulses" xml:space="preserve">
|
||||
<value>Ref. Impulse</value>
|
||||
</data>
|
||||
<data name="Remove" xml:space="preserve">
|
||||
<value>< Entfernen</value>
|
||||
</data>
|
||||
<data name="Remove_all" xml:space="preserve">
|
||||
<value>Alles entfernen</value>
|
||||
</data>
|
||||
<data name="Result" xml:space="preserve">
|
||||
<value>Ergebnis</value>
|
||||
</data>
|
||||
<data name="Selected_results" xml:space="preserve">
|
||||
<value>Ergebnisse ausgewählt</value>
|
||||
</data>
|
||||
<data name="sn" xml:space="preserve">
|
||||
<value>Seriennr.</value>
|
||||
</data>
|
||||
<data name="sn_aux" xml:space="preserve">
|
||||
<value>Seriennr. Nebenz.</value>
|
||||
</data>
|
||||
<data name="sn_main" xml:space="preserve">
|
||||
<value>Seriennr. Hauptz.</value>
|
||||
</data>
|
||||
<data name="Start" xml:space="preserve">
|
||||
<value>Startzeit</value>
|
||||
</data>
|
||||
<data name="Test" xml:space="preserve">
|
||||
<value>Prüfpunkt</value>
|
||||
</data>
|
||||
<data name="Test_ID" xml:space="preserve">
|
||||
<value>Prüfpunkt</value>
|
||||
</data>
|
||||
<data name="Test_method" xml:space="preserve">
|
||||
<value>Prüfart</value>
|
||||
</data>
|
||||
<data name="Test_vol" xml:space="preserve">
|
||||
<value>Prüfvolumen</value>
|
||||
</data>
|
||||
<data name="T_amb" xml:space="preserve">
|
||||
<value>T umgebung</value>
|
||||
</data>
|
||||
<data name="T_div" xml:space="preserve">
|
||||
<value>T div</value>
|
||||
</data>
|
||||
<data name="T_end" xml:space="preserve">
|
||||
<value>Endzeit</value>
|
||||
</data>
|
||||
<data name="T_in" xml:space="preserve">
|
||||
<value>T ein</value>
|
||||
</data>
|
||||
<data name="T_out" xml:space="preserve">
|
||||
<value>T aus</value>
|
||||
</data>
|
||||
<data name="T_s" xml:space="preserve">
|
||||
<value>Dauer [s]</value>
|
||||
</data>
|
||||
<data name="T_start" xml:space="preserve">
|
||||
<value>Startzeit</value>
|
||||
</data>
|
||||
<data name="Uncertainty" xml:space="preserve">
|
||||
<value>Unsicherheit</value>
|
||||
</data>
|
||||
<data name="Units" xml:space="preserve">
|
||||
<value>Einheit</value>
|
||||
</data>
|
||||
<data name="UpBtnText" xml:space="preserve">
|
||||
<value>Aufwärts</value>
|
||||
</data>
|
||||
<data name="User" xml:space="preserve">
|
||||
<value>Benutzer</value>
|
||||
</data>
|
||||
<data name="User_nr" xml:space="preserve">
|
||||
<value>Benutzer Nr.</value>
|
||||
</data>
|
||||
<data name="Ver" xml:space="preserve">
|
||||
<value>Ver.</value>
|
||||
</data>
|
||||
<data name="VolRef" xml:space="preserve">
|
||||
<value>Ref. Volumen</value>
|
||||
</data>
|
||||
<data name="Volume" xml:space="preserve">
|
||||
<value>Volumen</value>
|
||||
</data>
|
||||
<data name="Width" xml:space="preserve">
|
||||
<value>Breite</value>
|
||||
</data>
|
||||
<data name="WMs" xml:space="preserve">
|
||||
<value>WZ</value>
|
||||
</data>
|
||||
<data name="WM_Type" xml:space="preserve">
|
||||
<value>WZ Typ</value>
|
||||
</data>
|
||||
<data name="Year" xml:space="preserve">
|
||||
<value>Eichjahr</value>
|
||||
</data>
|
||||
<data name="Results" xml:space="preserve">
|
||||
<value>Ergebnisse</value>
|
||||
</data>
|
||||
<data name="Remark" xml:space="preserve">
|
||||
<value>Bemerkung</value>
|
||||
</data>
|
||||
<data name="Result_code" xml:space="preserve">
|
||||
<value>Ergebniscode</value>
|
||||
</data>
|
||||
<data name="Mounting" xml:space="preserve">
|
||||
<value>Montage</value>
|
||||
</data>
|
||||
<data name="Producer" xml:space="preserve">
|
||||
<value>Hersteller</value>
|
||||
</data>
|
||||
<data name="Meter_type" xml:space="preserve">
|
||||
<value>Typ</value>
|
||||
</data>
|
||||
<data name="Compound" xml:space="preserve">
|
||||
<value>Verbund</value>
|
||||
</data>
|
||||
<data name="Heat_meter" xml:space="preserve">
|
||||
<value />
|
||||
</data>
|
||||
<data name="Single" xml:space="preserve">
|
||||
<value>Einzel</value>
|
||||
</data>
|
||||
<data name="Category" xml:space="preserve">
|
||||
<value>Kategorie</value>
|
||||
</data>
|
||||
<data name="Quantity" xml:space="preserve">
|
||||
<value>Größe</value>
|
||||
</data>
|
||||
</root>
|
||||
@@ -1,423 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<data name="Add" xml:space="preserve">
|
||||
<value>Dodać ></value>
|
||||
</data>
|
||||
<data name="Alignment" xml:space="preserve">
|
||||
<value>Wyrównywanie</value>
|
||||
</data>
|
||||
<data name="Approval" xml:space="preserve">
|
||||
<value>Zatwierdzenie</value>
|
||||
</data>
|
||||
<data name="Available_results" xml:space="preserve">
|
||||
<value>Dostępne wyniki:</value>
|
||||
</data>
|
||||
<data name="Batch_nr" xml:space="preserve">
|
||||
<value>Nr pakietu</value>
|
||||
</data>
|
||||
<data name="Bench" xml:space="preserve">
|
||||
<value>Stanowisko</value>
|
||||
</data>
|
||||
<data name="CancelBtnText" xml:space="preserve">
|
||||
<value>Anuluj</value>
|
||||
</data>
|
||||
<data name="Caption" xml:space="preserve">
|
||||
<value>Podpis</value>
|
||||
</data>
|
||||
<data name="Configuration" xml:space="preserve">
|
||||
<value>Konfiguracja</value>
|
||||
</data>
|
||||
<data name="Density" xml:space="preserve">
|
||||
<value>Gęstość</value>
|
||||
</data>
|
||||
<data name="DownBtnText" xml:space="preserve">
|
||||
<value>W dół</value>
|
||||
</data>
|
||||
<data name="End" xml:space="preserve">
|
||||
<value>Koniec</value>
|
||||
</data>
|
||||
<data name="EndState_aux" xml:space="preserve">
|
||||
<value>Stan końcowy dodatkowy</value>
|
||||
</data>
|
||||
<data name="EndState_main" xml:space="preserve">
|
||||
<value>Stan końcowy podstawowy</value>
|
||||
</data>
|
||||
<data name="End_state" xml:space="preserve">
|
||||
<value>Stan końcowy</value>
|
||||
</data>
|
||||
<data name="ErrLimHi" xml:space="preserve">
|
||||
<value>Max. Dopuszczalny błąd</value>
|
||||
</data>
|
||||
<data name="ErrLimLo" xml:space="preserve">
|
||||
<value>Min. Dopuszczalny błąd</value>
|
||||
</data>
|
||||
<data name="Error" xml:space="preserve">
|
||||
<value>Błąd</value>
|
||||
</data>
|
||||
<data name="ErrRef" xml:space="preserve">
|
||||
<value>Zakres błędów</value>
|
||||
</data>
|
||||
<data name="Err_aux" xml:space="preserve">
|
||||
<value>Błąd dopuszczalny</value>
|
||||
</data>
|
||||
<data name="Err_main" xml:space="preserve">
|
||||
<value>Błąd podstawowy</value>
|
||||
</data>
|
||||
<data name="Flow" xml:space="preserve">
|
||||
<value>Przepływ</value>
|
||||
</data>
|
||||
<data name="Format" xml:space="preserve">
|
||||
<value>Format</value>
|
||||
</data>
|
||||
<data name="H_amb" xml:space="preserve">
|
||||
<value>H otoczenia</value>
|
||||
</data>
|
||||
<data name="Item" xml:space="preserve">
|
||||
<value>Pozycja</value>
|
||||
</data>
|
||||
<data name="MClass" xml:space="preserve">
|
||||
<value>Klasa licznika</value>
|
||||
</data>
|
||||
<data name="OkBtnText" xml:space="preserve">
|
||||
<value>OK</value>
|
||||
</data>
|
||||
<data name="PO" xml:space="preserve">
|
||||
<value>Zamówienie</value>
|
||||
</data>
|
||||
<data name="Pos" xml:space="preserve">
|
||||
<value>Pozycja</value>
|
||||
</data>
|
||||
<data name="Precision" xml:space="preserve">
|
||||
<value>Dokładność</value>
|
||||
</data>
|
||||
<data name="Procedure" xml:space="preserve">
|
||||
<value>Procedura</value>
|
||||
</data>
|
||||
<data name="Producer" xml:space="preserve">
|
||||
<value>Producent</value>
|
||||
</data>
|
||||
<data name="Protocol" xml:space="preserve">
|
||||
<value>Zapiska</value>
|
||||
</data>
|
||||
<data name="Pulses" xml:space="preserve">
|
||||
<value>Impulsy</value>
|
||||
</data>
|
||||
<data name="PulsesLiter" xml:space="preserve">
|
||||
<value>imp./litr</value>
|
||||
</data>
|
||||
<data name="P_amb" xml:space="preserve">
|
||||
<value>P otoczenia</value>
|
||||
</data>
|
||||
<data name="P_dn_end" xml:space="preserve">
|
||||
<value>P w dół koniec</value>
|
||||
</data>
|
||||
<data name="P_dn" xml:space="preserve">
|
||||
<value>P w dół</value>
|
||||
</data>
|
||||
<data name="P_dn_start" xml:space="preserve">
|
||||
<value>P w dół start</value>
|
||||
</data>
|
||||
<data name="P_up_end" xml:space="preserve">
|
||||
<value>P do góry koniec</value>
|
||||
</data>
|
||||
<data name="P_up" xml:space="preserve">
|
||||
<value>P do góry </value>
|
||||
</data>
|
||||
<data name="P_up_start" xml:space="preserve">
|
||||
<value>P do góry strat</value>
|
||||
</data>
|
||||
<data name="Q_fall" xml:space="preserve">
|
||||
<value>Q obniżanie</value>
|
||||
</data>
|
||||
<data name="Q_from" xml:space="preserve">
|
||||
<value>Q od</value>
|
||||
</data>
|
||||
<data name="Q_rise" xml:space="preserve">
|
||||
<value>Q zwiększanie</value>
|
||||
</data>
|
||||
<data name="Q_to" xml:space="preserve">
|
||||
<value>Q do</value>
|
||||
</data>
|
||||
<data name="RefPulses" xml:space="preserve">
|
||||
<value>Wzorcowe impulsy</value>
|
||||
</data>
|
||||
<data name="Remove" xml:space="preserve">
|
||||
<value>< usuń</value>
|
||||
</data>
|
||||
<data name="Remove_all" xml:space="preserve">
|
||||
<value>Usunąć wszystko</value>
|
||||
</data>
|
||||
<data name="Result" xml:space="preserve">
|
||||
<value>Wyniki</value>
|
||||
</data>
|
||||
<data name="Selected_results" xml:space="preserve">
|
||||
<value>Wybierz wyniki</value>
|
||||
</data>
|
||||
<data name="sn" xml:space="preserve">
|
||||
<value>Nr seryjny</value>
|
||||
</data>
|
||||
<data name="sn_aux" xml:space="preserve">
|
||||
<value>Nr seryjny dodatkowy</value>
|
||||
</data>
|
||||
<data name="sn_main" xml:space="preserve">
|
||||
<value>Nr seryjny główny</value>
|
||||
</data>
|
||||
<data name="Start" xml:space="preserve">
|
||||
<value>Początek</value>
|
||||
</data>
|
||||
<data name="Test" xml:space="preserve">
|
||||
<value>Test</value>
|
||||
</data>
|
||||
<data name="Test_ID" xml:space="preserve">
|
||||
<value>ID testu</value>
|
||||
</data>
|
||||
<data name="Test_method" xml:space="preserve">
|
||||
<value>Metoda badania</value>
|
||||
</data>
|
||||
<data name="Test_vol" xml:space="preserve">
|
||||
<value>Objętość testu</value>
|
||||
</data>
|
||||
<data name="T_amb" xml:space="preserve">
|
||||
<value>T otoczenia</value>
|
||||
</data>
|
||||
<data name="T_div" xml:space="preserve">
|
||||
<value>T różnica</value>
|
||||
</data>
|
||||
<data name="T_end" xml:space="preserve">
|
||||
<value>T końcowa</value>
|
||||
</data>
|
||||
<data name="T_in" xml:space="preserve">
|
||||
<value>T wejściowa</value>
|
||||
</data>
|
||||
<data name="T_out" xml:space="preserve">
|
||||
<value>T wyjściowa</value>
|
||||
</data>
|
||||
<data name="T_s" xml:space="preserve">
|
||||
<value>T [s]</value>
|
||||
</data>
|
||||
<data name="T_start" xml:space="preserve">
|
||||
<value>T początkowa</value>
|
||||
</data>
|
||||
<data name="Uncertainty" xml:space="preserve">
|
||||
<value>Niepewność [%]</value>
|
||||
</data>
|
||||
<data name="Units" xml:space="preserve">
|
||||
<value>Jednostki</value>
|
||||
</data>
|
||||
<data name="UpBtnText" xml:space="preserve">
|
||||
<value>Do góry</value>
|
||||
</data>
|
||||
<data name="User" xml:space="preserve">
|
||||
<value>Użytkownik</value>
|
||||
</data>
|
||||
<data name="User_nr" xml:space="preserve">
|
||||
<value>Nr Użytkownika</value>
|
||||
</data>
|
||||
<data name="Ver" xml:space="preserve">
|
||||
<value>Wersja</value>
|
||||
</data>
|
||||
<data name="VolRef" xml:space="preserve">
|
||||
<value>Wzorzec objętości </value>
|
||||
</data>
|
||||
<data name="Volume" xml:space="preserve">
|
||||
<value>Objętość</value>
|
||||
</data>
|
||||
<data name="Width" xml:space="preserve">
|
||||
<value>Szerokość</value>
|
||||
</data>
|
||||
<data name="WMs" xml:space="preserve">
|
||||
<value>Liczniki</value>
|
||||
</data>
|
||||
<data name="WM_Type" xml:space="preserve">
|
||||
<value>Typ licznika</value>
|
||||
</data>
|
||||
<data name="Year" xml:space="preserve">
|
||||
<value>Rok</value>
|
||||
</data>
|
||||
<data name="Results" xml:space="preserve">
|
||||
<value>Wyniki</value>
|
||||
</data>
|
||||
<data name="Remark" xml:space="preserve">
|
||||
<value>Uwagi</value>
|
||||
</data>
|
||||
<data name="Result_code" xml:space="preserve">
|
||||
<value>Kod wyniku</value>
|
||||
</data>
|
||||
<data name="Mounting" xml:space="preserve">
|
||||
<value>Montaż</value>
|
||||
</data>
|
||||
<data name="Energy" xml:space="preserve">
|
||||
<value>Energia</value>
|
||||
</data>
|
||||
<data name="Energy_ref" xml:space="preserve">
|
||||
<value>Wzorzec energii</value>
|
||||
</data>
|
||||
<data name="P_delta" xml:space="preserve">
|
||||
<value>P delta</value>
|
||||
</data>
|
||||
<data name="P_delta_end" xml:space="preserve">
|
||||
<value>P delta końcowe</value>
|
||||
</data>
|
||||
<data name="P_delta_mean" xml:space="preserve">
|
||||
<value>P delta główne</value>
|
||||
</data>
|
||||
<data name="P_delta_start" xml:space="preserve">
|
||||
<value>P delta początkowe</value>
|
||||
</data>
|
||||
<data name="Meter_type" xml:space="preserve">
|
||||
<value>Typ licznika</value>
|
||||
</data>
|
||||
<data name="Compound" xml:space="preserve">
|
||||
<value>Sprzężony</value>
|
||||
</data>
|
||||
<data name="Heat_meter" xml:space="preserve">
|
||||
<value>Licznik ciepła</value>
|
||||
</data>
|
||||
<data name="Single" xml:space="preserve">
|
||||
<value>Pojedynczy</value>
|
||||
</data>
|
||||
<data name="Page" xml:space="preserve">
|
||||
<value>Strona</value>
|
||||
</data>
|
||||
<data name="End_volume" xml:space="preserve">
|
||||
<value>Objętość końcowa</value>
|
||||
</data>
|
||||
<data name="Start_volume" xml:space="preserve">
|
||||
<value>Objętość początkowa</value>
|
||||
</data>
|
||||
<data name="End_volume_aux" xml:space="preserve">
|
||||
<value>Dodatkowa objętość końcowa</value>
|
||||
</data>
|
||||
<data name="End_volume_main" xml:space="preserve">
|
||||
<value>Główna objętość końćowa</value>
|
||||
</data>
|
||||
<data name="Start_volume_aux" xml:space="preserve">
|
||||
<value>Dodatkowa objętość początkowa</value>
|
||||
</data>
|
||||
<data name="Start_volume_main" xml:space="preserve">
|
||||
<value>Główna objętość początkowa</value>
|
||||
</data>
|
||||
<data name="Volume_aux" xml:space="preserve">
|
||||
<value>Objętość dodatkowa</value>
|
||||
</data>
|
||||
<data name="Volume_main" xml:space="preserve">
|
||||
<value>Objętość główna</value>
|
||||
</data>
|
||||
</root>
|
||||
@@ -1,435 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<data name="Add" xml:space="preserve">
|
||||
<value>Add ></value>
|
||||
</data>
|
||||
<data name="Alignment" xml:space="preserve">
|
||||
<value>Alignment</value>
|
||||
</data>
|
||||
<data name="Approval" xml:space="preserve">
|
||||
<value>Approval</value>
|
||||
</data>
|
||||
<data name="Available_results" xml:space="preserve">
|
||||
<value>Available results</value>
|
||||
</data>
|
||||
<data name="Batch_nr" xml:space="preserve">
|
||||
<value>Batch nr.</value>
|
||||
</data>
|
||||
<data name="Bench" xml:space="preserve">
|
||||
<value>Bench</value>
|
||||
</data>
|
||||
<data name="CancelBtnText" xml:space="preserve">
|
||||
<value>Cancel</value>
|
||||
</data>
|
||||
<data name="Caption" xml:space="preserve">
|
||||
<value>Caption</value>
|
||||
</data>
|
||||
<data name="Configuration" xml:space="preserve">
|
||||
<value>Configuration</value>
|
||||
</data>
|
||||
<data name="Density" xml:space="preserve">
|
||||
<value>Density</value>
|
||||
</data>
|
||||
<data name="DownBtnText" xml:space="preserve">
|
||||
<value>Down</value>
|
||||
</data>
|
||||
<data name="End" xml:space="preserve">
|
||||
<value>End</value>
|
||||
</data>
|
||||
<data name="EndState_aux" xml:space="preserve">
|
||||
<value>End state aux.</value>
|
||||
</data>
|
||||
<data name="EndState_main" xml:space="preserve">
|
||||
<value>End state main</value>
|
||||
</data>
|
||||
<data name="End_state" xml:space="preserve">
|
||||
<value>End state</value>
|
||||
</data>
|
||||
<data name="ErrLimHi" xml:space="preserve">
|
||||
<value>Err.Lim.Hi</value>
|
||||
</data>
|
||||
<data name="ErrLimLo" xml:space="preserve">
|
||||
<value>Err.Lim.Lo</value>
|
||||
</data>
|
||||
<data name="Error" xml:space="preserve">
|
||||
<value>Error</value>
|
||||
</data>
|
||||
<data name="ErrRef" xml:space="preserve">
|
||||
<value>Err.ref.</value>
|
||||
</data>
|
||||
<data name="Err_aux" xml:space="preserve">
|
||||
<value>Err. aux.</value>
|
||||
</data>
|
||||
<data name="Err_main" xml:space="preserve">
|
||||
<value>Err. main</value>
|
||||
</data>
|
||||
<data name="Flow" xml:space="preserve">
|
||||
<value>Flow</value>
|
||||
</data>
|
||||
<data name="Format" xml:space="preserve">
|
||||
<value>Format</value>
|
||||
</data>
|
||||
<data name="H_amb" xml:space="preserve">
|
||||
<value>H amb</value>
|
||||
</data>
|
||||
<data name="Item" xml:space="preserve">
|
||||
<value>Item</value>
|
||||
</data>
|
||||
<data name="MClass" xml:space="preserve">
|
||||
<value>M.Class</value>
|
||||
</data>
|
||||
<data name="OkBtnText" xml:space="preserve">
|
||||
<value>OK</value>
|
||||
</data>
|
||||
<data name="PO" xml:space="preserve">
|
||||
<value>PO</value>
|
||||
</data>
|
||||
<data name="Pos" xml:space="preserve">
|
||||
<value>Pos.</value>
|
||||
</data>
|
||||
<data name="Precision" xml:space="preserve">
|
||||
<value>Precision</value>
|
||||
</data>
|
||||
<data name="Procedure" xml:space="preserve">
|
||||
<value>Procedure</value>
|
||||
</data>
|
||||
<data name="Producer" xml:space="preserve">
|
||||
<value>Producer</value>
|
||||
</data>
|
||||
<data name="Protocol" xml:space="preserve">
|
||||
<value>Protocol</value>
|
||||
</data>
|
||||
<data name="Pulses" xml:space="preserve">
|
||||
<value>Pulses</value>
|
||||
</data>
|
||||
<data name="PulsesLiter" xml:space="preserve">
|
||||
<value>Pulses/l</value>
|
||||
</data>
|
||||
<data name="P_amb" xml:space="preserve">
|
||||
<value>P amb</value>
|
||||
</data>
|
||||
<data name="P_dn_end" xml:space="preserve">
|
||||
<value>P down end</value>
|
||||
</data>
|
||||
<data name="P_dn" xml:space="preserve">
|
||||
<value>P down</value>
|
||||
</data>
|
||||
<data name="P_dn_start" xml:space="preserve">
|
||||
<value>P down start</value>
|
||||
</data>
|
||||
<data name="P_up_end" xml:space="preserve">
|
||||
<value>P up end</value>
|
||||
</data>
|
||||
<data name="P_up" xml:space="preserve">
|
||||
<value>P up</value>
|
||||
</data>
|
||||
<data name="P_up_start" xml:space="preserve">
|
||||
<value>P up start</value>
|
||||
</data>
|
||||
<data name="Q_fall" xml:space="preserve">
|
||||
<value>Q fall</value>
|
||||
</data>
|
||||
<data name="Q_from" xml:space="preserve">
|
||||
<value>Q from</value>
|
||||
</data>
|
||||
<data name="Q_rise" xml:space="preserve">
|
||||
<value>Q rise</value>
|
||||
</data>
|
||||
<data name="Q_to" xml:space="preserve">
|
||||
<value>Q to</value>
|
||||
</data>
|
||||
<data name="RefPulses" xml:space="preserve">
|
||||
<value>Ref.pulses</value>
|
||||
</data>
|
||||
<data name="Remove" xml:space="preserve">
|
||||
<value>< Remove</value>
|
||||
</data>
|
||||
<data name="Remove_all" xml:space="preserve">
|
||||
<value>Remove all</value>
|
||||
</data>
|
||||
<data name="Result" xml:space="preserve">
|
||||
<value>Result</value>
|
||||
</data>
|
||||
<data name="Selected_results" xml:space="preserve">
|
||||
<value>Selected results</value>
|
||||
</data>
|
||||
<data name="sn" xml:space="preserve">
|
||||
<value>s/n</value>
|
||||
</data>
|
||||
<data name="sn_aux" xml:space="preserve">
|
||||
<value>s/n aux.</value>
|
||||
</data>
|
||||
<data name="sn_main" xml:space="preserve">
|
||||
<value>s/n main</value>
|
||||
</data>
|
||||
<data name="Start" xml:space="preserve">
|
||||
<value>Start</value>
|
||||
</data>
|
||||
<data name="Test" xml:space="preserve">
|
||||
<value>Test</value>
|
||||
</data>
|
||||
<data name="Test_ID" xml:space="preserve">
|
||||
<value>Test ID</value>
|
||||
</data>
|
||||
<data name="Test_method" xml:space="preserve">
|
||||
<value>Test method</value>
|
||||
</data>
|
||||
<data name="Test_vol" xml:space="preserve">
|
||||
<value>Test vol.</value>
|
||||
</data>
|
||||
<data name="T_amb" xml:space="preserve">
|
||||
<value>T amb</value>
|
||||
</data>
|
||||
<data name="T_div" xml:space="preserve">
|
||||
<value>T div</value>
|
||||
</data>
|
||||
<data name="T_end" xml:space="preserve">
|
||||
<value>T end</value>
|
||||
</data>
|
||||
<data name="T_in" xml:space="preserve">
|
||||
<value>T in</value>
|
||||
</data>
|
||||
<data name="T_out" xml:space="preserve">
|
||||
<value>T out</value>
|
||||
</data>
|
||||
<data name="T_s" xml:space="preserve">
|
||||
<value>T [s]</value>
|
||||
</data>
|
||||
<data name="T_start" xml:space="preserve">
|
||||
<value>T start</value>
|
||||
</data>
|
||||
<data name="Uncertainty" xml:space="preserve">
|
||||
<value>Uncertainty</value>
|
||||
</data>
|
||||
<data name="Units" xml:space="preserve">
|
||||
<value>Units</value>
|
||||
</data>
|
||||
<data name="UpBtnText" xml:space="preserve">
|
||||
<value>Up</value>
|
||||
</data>
|
||||
<data name="User" xml:space="preserve">
|
||||
<value>User</value>
|
||||
</data>
|
||||
<data name="User_nr" xml:space="preserve">
|
||||
<value>User nr.</value>
|
||||
</data>
|
||||
<data name="Ver" xml:space="preserve">
|
||||
<value>Ver.</value>
|
||||
</data>
|
||||
<data name="VolRef" xml:space="preserve">
|
||||
<value>Vol.ref.</value>
|
||||
</data>
|
||||
<data name="Volume" xml:space="preserve">
|
||||
<value>Volume</value>
|
||||
</data>
|
||||
<data name="Width" xml:space="preserve">
|
||||
<value>Width</value>
|
||||
</data>
|
||||
<data name="WMs" xml:space="preserve">
|
||||
<value>WMs</value>
|
||||
</data>
|
||||
<data name="WM_Type" xml:space="preserve">
|
||||
<value>WM Type</value>
|
||||
</data>
|
||||
<data name="Year" xml:space="preserve">
|
||||
<value>Year</value>
|
||||
</data>
|
||||
<data name="Results" xml:space="preserve">
|
||||
<value>Results</value>
|
||||
</data>
|
||||
<data name="Remark" xml:space="preserve">
|
||||
<value>Remark</value>
|
||||
</data>
|
||||
<data name="Result_code" xml:space="preserve">
|
||||
<value>Result code</value>
|
||||
</data>
|
||||
<data name="Mounting" xml:space="preserve">
|
||||
<value>Mounting</value>
|
||||
</data>
|
||||
<data name="Energy" xml:space="preserve">
|
||||
<value>Energy</value>
|
||||
</data>
|
||||
<data name="Energy_ref" xml:space="preserve">
|
||||
<value>Energy ref.</value>
|
||||
</data>
|
||||
<data name="P_delta" xml:space="preserve">
|
||||
<value>P delta</value>
|
||||
</data>
|
||||
<data name="P_delta_end" xml:space="preserve">
|
||||
<value>P delta end</value>
|
||||
</data>
|
||||
<data name="P_delta_mean" xml:space="preserve">
|
||||
<value>P delta mean</value>
|
||||
</data>
|
||||
<data name="P_delta_start" xml:space="preserve">
|
||||
<value>P delta start</value>
|
||||
</data>
|
||||
<data name="Meter_type" xml:space="preserve">
|
||||
<value>Meter type</value>
|
||||
</data>
|
||||
<data name="Compound" xml:space="preserve">
|
||||
<value>Compound</value>
|
||||
</data>
|
||||
<data name="Heat_meter" xml:space="preserve">
|
||||
<value>Heat meter</value>
|
||||
</data>
|
||||
<data name="Single" xml:space="preserve">
|
||||
<value>Single</value>
|
||||
</data>
|
||||
<data name="Page" xml:space="preserve">
|
||||
<value>Page</value>
|
||||
</data>
|
||||
<data name="End_volume" xml:space="preserve">
|
||||
<value>End volume</value>
|
||||
</data>
|
||||
<data name="Start_volume" xml:space="preserve">
|
||||
<value>Start volume</value>
|
||||
</data>
|
||||
<data name="End_volume_aux" xml:space="preserve">
|
||||
<value>End volume aux</value>
|
||||
</data>
|
||||
<data name="End_volume_main" xml:space="preserve">
|
||||
<value>End volume main</value>
|
||||
</data>
|
||||
<data name="Start_volume_aux" xml:space="preserve">
|
||||
<value>Start volume aux</value>
|
||||
</data>
|
||||
<data name="Start_volume_main" xml:space="preserve">
|
||||
<value>Start volume main</value>
|
||||
</data>
|
||||
<data name="Volume_aux" xml:space="preserve">
|
||||
<value>Volume aux</value>
|
||||
</data>
|
||||
<data name="Volume_main" xml:space="preserve">
|
||||
<value>Volume main</value>
|
||||
</data>
|
||||
<data name="End_mass" xml:space="preserve">
|
||||
<value>End mass</value>
|
||||
</data>
|
||||
<data name="Start_mass" xml:space="preserve">
|
||||
<value>Start mass</value>
|
||||
</data>
|
||||
<data name="Category" xml:space="preserve">
|
||||
<value>Category</value>
|
||||
</data>
|
||||
<data name="Quantity" xml:space="preserve">
|
||||
<value>Quantity</value>
|
||||
</data>
|
||||
</root>
|
||||
@@ -1,423 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<data name="Add" xml:space="preserve">
|
||||
<value>Добавить ></value>
|
||||
</data>
|
||||
<data name="Alignment" xml:space="preserve">
|
||||
<value>Выравнивание</value>
|
||||
</data>
|
||||
<data name="Approval" xml:space="preserve">
|
||||
<value>Утверждение</value>
|
||||
</data>
|
||||
<data name="Available_results" xml:space="preserve">
|
||||
<value>Доступные результаты</value>
|
||||
</data>
|
||||
<data name="Batch_nr" xml:space="preserve">
|
||||
<value>№ пакета</value>
|
||||
</data>
|
||||
<data name="Bench" xml:space="preserve">
|
||||
<value>Установка</value>
|
||||
</data>
|
||||
<data name="CancelBtnText" xml:space="preserve">
|
||||
<value>Отмена</value>
|
||||
</data>
|
||||
<data name="Caption" xml:space="preserve">
|
||||
<value>Подпись</value>
|
||||
</data>
|
||||
<data name="Configuration" xml:space="preserve">
|
||||
<value>Конфигурация</value>
|
||||
</data>
|
||||
<data name="Density" xml:space="preserve">
|
||||
<value>Плотность</value>
|
||||
</data>
|
||||
<data name="DownBtnText" xml:space="preserve">
|
||||
<value>Вниз</value>
|
||||
</data>
|
||||
<data name="End" xml:space="preserve">
|
||||
<value>Конец</value>
|
||||
</data>
|
||||
<data name="EndState_aux" xml:space="preserve">
|
||||
<value>Конечн. сост. доп.</value>
|
||||
</data>
|
||||
<data name="EndState_main" xml:space="preserve">
|
||||
<value>Конечн. сост. главн.</value>
|
||||
</data>
|
||||
<data name="End_state" xml:space="preserve">
|
||||
<value>Итог</value>
|
||||
</data>
|
||||
<data name="ErrLimHi" xml:space="preserve">
|
||||
<value>Макс.допуст.погр.</value>
|
||||
</data>
|
||||
<data name="ErrLimLo" xml:space="preserve">
|
||||
<value>Мин.доп.погр</value>
|
||||
</data>
|
||||
<data name="Error" xml:space="preserve">
|
||||
<value>Ошибка</value>
|
||||
</data>
|
||||
<data name="ErrRef" xml:space="preserve">
|
||||
<value>Err.ref.</value>
|
||||
</data>
|
||||
<data name="Err_aux" xml:space="preserve">
|
||||
<value>Погр.доп.</value>
|
||||
</data>
|
||||
<data name="Err_main" xml:space="preserve">
|
||||
<value>Погр.глав.</value>
|
||||
</data>
|
||||
<data name="Flow" xml:space="preserve">
|
||||
<value>Расход</value>
|
||||
</data>
|
||||
<data name="Format" xml:space="preserve">
|
||||
<value>Формат</value>
|
||||
</data>
|
||||
<data name="H_amb" xml:space="preserve">
|
||||
<value>H amb</value>
|
||||
</data>
|
||||
<data name="Item" xml:space="preserve">
|
||||
<value>Item</value>
|
||||
</data>
|
||||
<data name="MClass" xml:space="preserve">
|
||||
<value>M.Class</value>
|
||||
</data>
|
||||
<data name="OkBtnText" xml:space="preserve">
|
||||
<value>OK</value>
|
||||
</data>
|
||||
<data name="PO" xml:space="preserve">
|
||||
<value>PO</value>
|
||||
</data>
|
||||
<data name="Pos" xml:space="preserve">
|
||||
<value>Pos.</value>
|
||||
</data>
|
||||
<data name="Precision" xml:space="preserve">
|
||||
<value>Точность</value>
|
||||
</data>
|
||||
<data name="Procedure" xml:space="preserve">
|
||||
<value>Процедура</value>
|
||||
</data>
|
||||
<data name="Producer" xml:space="preserve">
|
||||
<value>Производитель</value>
|
||||
</data>
|
||||
<data name="Protocol" xml:space="preserve">
|
||||
<value>Протокол</value>
|
||||
</data>
|
||||
<data name="Pulses" xml:space="preserve">
|
||||
<value>Импульсы</value>
|
||||
</data>
|
||||
<data name="PulsesLiter" xml:space="preserve">
|
||||
<value>Импульсы/л</value>
|
||||
</data>
|
||||
<data name="P_amb" xml:space="preserve">
|
||||
<value>P amb</value>
|
||||
</data>
|
||||
<data name="P_dn_end" xml:space="preserve">
|
||||
<value>P вниз конец</value>
|
||||
</data>
|
||||
<data name="P_dn" xml:space="preserve">
|
||||
<value>P вниз</value>
|
||||
</data>
|
||||
<data name="P_dn_start" xml:space="preserve">
|
||||
<value>P вниз начало</value>
|
||||
</data>
|
||||
<data name="P_up_end" xml:space="preserve">
|
||||
<value>P вверз конец</value>
|
||||
</data>
|
||||
<data name="P_up" xml:space="preserve">
|
||||
<value>P вверх</value>
|
||||
</data>
|
||||
<data name="P_up_start" xml:space="preserve">
|
||||
<value>P вверх начало</value>
|
||||
</data>
|
||||
<data name="Q_fall" xml:space="preserve">
|
||||
<value>Q пониж</value>
|
||||
</data>
|
||||
<data name="Q_from" xml:space="preserve">
|
||||
<value>Q от</value>
|
||||
</data>
|
||||
<data name="Q_rise" xml:space="preserve">
|
||||
<value>Q повыш</value>
|
||||
</data>
|
||||
<data name="Q_to" xml:space="preserve">
|
||||
<value>Q до</value>
|
||||
</data>
|
||||
<data name="RefPulses" xml:space="preserve">
|
||||
<value>Эт.импульсы</value>
|
||||
</data>
|
||||
<data name="Remove" xml:space="preserve">
|
||||
<value>< Удалить</value>
|
||||
</data>
|
||||
<data name="Remove_all" xml:space="preserve">
|
||||
<value>Удалить все</value>
|
||||
</data>
|
||||
<data name="Result" xml:space="preserve">
|
||||
<value>Результат</value>
|
||||
</data>
|
||||
<data name="Selected_results" xml:space="preserve">
|
||||
<value>Выбанные результаты</value>
|
||||
</data>
|
||||
<data name="sn" xml:space="preserve">
|
||||
<value>С/Н:</value>
|
||||
</data>
|
||||
<data name="sn_aux" xml:space="preserve">
|
||||
<value>С/Н доп</value>
|
||||
</data>
|
||||
<data name="sn_main" xml:space="preserve">
|
||||
<value>С/Н главн</value>
|
||||
</data>
|
||||
<data name="Start" xml:space="preserve">
|
||||
<value>Начало</value>
|
||||
</data>
|
||||
<data name="Test" xml:space="preserve">
|
||||
<value>Тест</value>
|
||||
</data>
|
||||
<data name="Test_ID" xml:space="preserve">
|
||||
<value>ID теста</value>
|
||||
</data>
|
||||
<data name="Test_method" xml:space="preserve">
|
||||
<value>Метод испытания</value>
|
||||
</data>
|
||||
<data name="Test_vol" xml:space="preserve">
|
||||
<value>Тест.объем</value>
|
||||
</data>
|
||||
<data name="T_amb" xml:space="preserve">
|
||||
<value>T amb</value>
|
||||
</data>
|
||||
<data name="T_div" xml:space="preserve">
|
||||
<value>T div</value>
|
||||
</data>
|
||||
<data name="T_end" xml:space="preserve">
|
||||
<value>T оконч.</value>
|
||||
</data>
|
||||
<data name="T_in" xml:space="preserve">
|
||||
<value>T вх</value>
|
||||
</data>
|
||||
<data name="T_out" xml:space="preserve">
|
||||
<value>T вых</value>
|
||||
</data>
|
||||
<data name="T_s" xml:space="preserve">
|
||||
<value>T [с]</value>
|
||||
</data>
|
||||
<data name="T_start" xml:space="preserve">
|
||||
<value>T начала</value>
|
||||
</data>
|
||||
<data name="Uncertainty" xml:space="preserve">
|
||||
<value>Неопределенность</value>
|
||||
</data>
|
||||
<data name="Units" xml:space="preserve">
|
||||
<value>Единицы</value>
|
||||
</data>
|
||||
<data name="UpBtnText" xml:space="preserve">
|
||||
<value>Вверх</value>
|
||||
</data>
|
||||
<data name="User" xml:space="preserve">
|
||||
<value>Пользователь</value>
|
||||
</data>
|
||||
<data name="User_nr" xml:space="preserve">
|
||||
<value>№ пользователя</value>
|
||||
</data>
|
||||
<data name="Ver" xml:space="preserve">
|
||||
<value>Эт.</value>
|
||||
</data>
|
||||
<data name="VolRef" xml:space="preserve">
|
||||
<value>Об.эт.</value>
|
||||
</data>
|
||||
<data name="Volume" xml:space="preserve">
|
||||
<value>Объем</value>
|
||||
</data>
|
||||
<data name="Width" xml:space="preserve">
|
||||
<value>Ширина</value>
|
||||
</data>
|
||||
<data name="WMs" xml:space="preserve">
|
||||
<value>Счетчики</value>
|
||||
</data>
|
||||
<data name="WM_Type" xml:space="preserve">
|
||||
<value>Тип счетчика</value>
|
||||
</data>
|
||||
<data name="Year" xml:space="preserve">
|
||||
<value>Год</value>
|
||||
</data>
|
||||
<data name="Results" xml:space="preserve">
|
||||
<value>Результаты</value>
|
||||
</data>
|
||||
<data name="Remark" xml:space="preserve">
|
||||
<value>Примечание</value>
|
||||
</data>
|
||||
<data name="Result_code" xml:space="preserve">
|
||||
<value>Код результата</value>
|
||||
</data>
|
||||
<data name="Mounting" xml:space="preserve">
|
||||
<value>Монтаж</value>
|
||||
</data>
|
||||
<data name="Energy" xml:space="preserve">
|
||||
<value>Энергия</value>
|
||||
</data>
|
||||
<data name="Energy_ref" xml:space="preserve">
|
||||
<value>Эт. энергия</value>
|
||||
</data>
|
||||
<data name="P_delta" xml:space="preserve">
|
||||
<value>P дельта</value>
|
||||
</data>
|
||||
<data name="P_delta_end" xml:space="preserve">
|
||||
<value>P дельта кон</value>
|
||||
</data>
|
||||
<data name="P_delta_mean" xml:space="preserve">
|
||||
<value>P дельта ср</value>
|
||||
</data>
|
||||
<data name="P_delta_start" xml:space="preserve">
|
||||
<value>P дельта нач</value>
|
||||
</data>
|
||||
<data name="Meter_type" xml:space="preserve">
|
||||
<value>Тип счетчика</value>
|
||||
</data>
|
||||
<data name="Compound" xml:space="preserve">
|
||||
<value>Комбинированный</value>
|
||||
</data>
|
||||
<data name="Heat_meter" xml:space="preserve">
|
||||
<value>Теплосчетчик</value>
|
||||
</data>
|
||||
<data name="Single" xml:space="preserve">
|
||||
<value>Единый</value>
|
||||
</data>
|
||||
<data name="Page" xml:space="preserve">
|
||||
<value>Страница</value>
|
||||
</data>
|
||||
<data name="End_volume" xml:space="preserve">
|
||||
<value>Кон. объем</value>
|
||||
</data>
|
||||
<data name="Start_volume" xml:space="preserve">
|
||||
<value>Нач. объем</value>
|
||||
</data>
|
||||
<data name="End_volume_aux" xml:space="preserve">
|
||||
<value>Кон. объем доп.</value>
|
||||
</data>
|
||||
<data name="End_volume_main" xml:space="preserve">
|
||||
<value>Кон. объем главн.</value>
|
||||
</data>
|
||||
<data name="Start_volume_aux" xml:space="preserve">
|
||||
<value>Нач. объем доп.</value>
|
||||
</data>
|
||||
<data name="Start_volume_main" xml:space="preserve">
|
||||
<value>Нач. объем главн.</value>
|
||||
</data>
|
||||
<data name="Volume_aux" xml:space="preserve">
|
||||
<value>Объем доп.</value>
|
||||
</data>
|
||||
<data name="Volume_main" xml:space="preserve">
|
||||
<value>Объем главн.</value>
|
||||
</data>
|
||||
</root>
|
||||
@@ -1,165 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProductVersion>8.0.30703</ProductVersion>
|
||||
<SchemaVersion>2.0</SchemaVersion>
|
||||
<ProjectGuid>{9D0DCC88-DC81-47EB-9FDD-4C3907871BFB}</ProjectGuid>
|
||||
<OutputType>Library</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>Results</RootNamespace>
|
||||
<AssemblyName>Results</AssemblyName>
|
||||
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<DefineConstants>TRACE;DEBUG;MUNICH</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<PlatformTarget>x86</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>TRACE;MUNICH</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="FluentNHibernate">
|
||||
<HintPath>..\packages\FluentNHibernate.2.0.3.0\lib\net40\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.0.4000\lib\net40\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="log4net">
|
||||
<HintPath>..\packages\log4net.2.0.2\lib\net40-full\log4net.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="MySql.Data">
|
||||
<HintPath>..\packages\MySql.Data.6.6.5\lib\net40\MySql.Data.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="NHibernate">
|
||||
<HintPath>..\packages\NHibernate.4.0.4.4000\lib\net40\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Drawing" />
|
||||
<Reference Include="System.Windows.Forms" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
<Reference Include="System.Data" />
|
||||
<Reference Include="System.Xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="BatchResults.cs" />
|
||||
<Compile Include="Entities\Batch.cs" />
|
||||
<Compile Include="Entities\Components.cs" />
|
||||
<Compile Include="Entities\MeterTestRslt.cs" />
|
||||
<Compile Include="Entities\TestData.cs" />
|
||||
<Compile Include="Entities\TestRslt.cs" />
|
||||
<Compile Include="Entities\WaterMeterData.cs" />
|
||||
<Compile Include="Entities\WaterMeter.cs" />
|
||||
<Compile Include="DB.cs" />
|
||||
<Compile Include="Forms\BatchResultsDlg.cs">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Forms\BatchResultsDlg.Designer.cs">
|
||||
<DependentUpon>BatchResultsDlg.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Forms\ListViewEx.cs">
|
||||
<SubType>Component</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Forms\ResultsConfigDlg.cs">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Forms\ResultsConfigDlg.designer.cs">
|
||||
<DependentUpon>ResultsConfigDlg.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="ItemID.cs" />
|
||||
<Compile Include="Mappings\BatchMap.cs" />
|
||||
<Compile Include="Mappings\ComponentsMap.cs" />
|
||||
<Compile Include="Mappings\MeterTestRsltMap.cs" />
|
||||
<Compile Include="Mappings\TestDataMap.cs" />
|
||||
<Compile Include="Mappings\TestRsltMap.cs" />
|
||||
<Compile Include="Mappings\WaterMeterDataMap.cs" />
|
||||
<Compile Include="Mappings\WaterMeterMap.cs" />
|
||||
<Compile Include="Output\Printers\Cevak\PrintDocumentCevak.cs">
|
||||
<SubType>Component</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Output\Printers\Munich\MunichPrintDocument.cs">
|
||||
<SubType>Component</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<Compile Include="ItemSpec.cs" />
|
||||
<Compile Include="Properties\Resources.Designer.cs">
|
||||
<AutoGen>True</AutoGen>
|
||||
<DesignTime>True</DesignTime>
|
||||
<DependentUpon>Resources.resx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Resources\Strings.Designer.cs">
|
||||
<AutoGen>True</AutoGen>
|
||||
<DesignTime>True</DesignTime>
|
||||
<DependentUpon>Strings.resx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Utils.cs" />
|
||||
<Compile Include="WMeterRsltItemSpec.cs" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\Config\Config.csproj">
|
||||
<Project>{743DF7DB-C7B6-42EB-986D-0F485E5588E4}</Project>
|
||||
<Name>Config</Name>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\Users\Users.csproj">
|
||||
<Project>{6E5CB0E9-E1B6-4E5D-AC6E-B1049E180F2B}</Project>
|
||||
<Name>Users</Name>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Folder Include="FileWriters\" />
|
||||
<Folder Include="Output\FileWriters\Basic\" />
|
||||
<Folder Include="Output\FileWriters\Enhanced\" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<EmbeddedResource Include="Forms\BatchResultsDlg.resx">
|
||||
<DependentUpon>BatchResultsDlg.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Forms\ListViewEx.resx">
|
||||
<DependentUpon>ListViewEx.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Forms\ResultsConfigDlg.resx">
|
||||
<DependentUpon>ResultsConfigDlg.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Properties\Resources.resx">
|
||||
<Generator>ResXFileCodeGenerator</Generator>
|
||||
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Resources\Strings.cs.resx" />
|
||||
<EmbeddedResource Include="Resources\Strings.de.resx">
|
||||
<SubType>Designer</SubType>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Resources\Strings.pl.resx" />
|
||||
<EmbeddedResource Include="Resources\Strings.resx">
|
||||
<Generator>ResXFileCodeGenerator</Generator>
|
||||
<LastGenOutput>Strings.Designer.cs</LastGenOutput>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Resources\Strings.ru.resx" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Resources\Headpic.png" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||
Other similar extension points exist, see Microsoft.Common.targets.
|
||||
<Target Name="BeforeBuild">
|
||||
</Target>
|
||||
<Target Name="AfterBuild">
|
||||
</Target>
|
||||
-->
|
||||
</Project>
|
||||
@@ -1,79 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2016 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System.Text;
|
||||
using Config.Entities;
|
||||
|
||||
namespace Results
|
||||
{
|
||||
public static class Utils
|
||||
{
|
||||
public static string GetTestName(string name, int repeats, int repetitionNr)
|
||||
{
|
||||
if (repeats == 1) return name;
|
||||
return string.Format("{0} ({1}/{2})", name, repetitionNr, repeats);
|
||||
}
|
||||
|
||||
|
||||
public static int BenchIdOracle2Asc(int benchIdOracle)
|
||||
{
|
||||
switch (benchIdOracle)
|
||||
{
|
||||
case 4: return 35; /// WR9
|
||||
case 5: return 33; /// WR10
|
||||
case 6: return 34; /// WR11
|
||||
case 7: return 29; /// PT7, special
|
||||
case 8: return 36; /// WR13
|
||||
case 9: return 37; /// WR15
|
||||
case 10: return 38; /// WR16
|
||||
default: return 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Converts float number to a string with the specified number of significant digits
|
||||
/// </summary>
|
||||
/// <param name="value">Float value to be converted to a string</param>
|
||||
/// <param name="validDigits">Number of significant digits: 4, 3, or 2 (otherwise a full precision number is printed)</param>
|
||||
/// <returns>String representation of the float number</returns>
|
||||
public static string DoubleToStr(double value, int validDigits)
|
||||
{
|
||||
if (-float.Epsilon <= value && value <= float.Epsilon)
|
||||
{
|
||||
return "0";
|
||||
}
|
||||
else if (validDigits == 4)
|
||||
{
|
||||
if (value >= 999.5 || value < -999.5) return value.ToString("F0");
|
||||
else if (value >= 99.95 || value < -99.95) return value.ToString("F1");
|
||||
else if (value >= 9.995 || value < -9.995) return value.ToString("F2");
|
||||
else if (value >= 0.9995 || value < -0.9995) return value.ToString("F3");
|
||||
else if (value >= 0.09995 || value < -0.09995) return value.ToString("F4");
|
||||
else if (value >= 0.009995 || value < -0.009995) return value.ToString("F5");
|
||||
else return value.ToString("F6");
|
||||
}
|
||||
else if (validDigits == 3)
|
||||
{
|
||||
if (value >= 99.5 || value < -99.5) return value.ToString("F0");
|
||||
else if (value >= 9.95 || value < -9.95) return value.ToString("F1");
|
||||
else if (value >= 0.995 || value < -0.995) return value.ToString("F2");
|
||||
else if (value >= 0.0995 || value < -0.0995) return value.ToString("F3");
|
||||
else if (value >= 0.00995 || value < -0.00995) return value.ToString("F4");
|
||||
else if (value >= 0.000995 || value < -0.000995) return value.ToString("F5");
|
||||
else return value.ToString("F6");
|
||||
}
|
||||
else if (validDigits == 2)
|
||||
{
|
||||
if (value >= 9.5 || value < -9.5) return value.ToString("F0");
|
||||
else if (value >= 0.95 || value < -0.95) return value.ToString("F1");
|
||||
else if (value >= 0.095 || value < -0.095) return value.ToString("F2");
|
||||
else if (value >= 0.0095 || value < -0.0095) return value.ToString("F3");
|
||||
else if (value >= 0.00095 || value < -0.00095) return value.ToString("F4");
|
||||
else return value.ToString("F5");
|
||||
}
|
||||
else return value.ToString();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,398 +0,0 @@
|
||||
///
|
||||
/// Copyright (c) 2013-2017 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using Config;
|
||||
using Config.Entities;
|
||||
using Results.Entities;
|
||||
using Results.Resources;
|
||||
|
||||
namespace Results
|
||||
{
|
||||
public class WMeterRsltItemSpec
|
||||
{
|
||||
///
|
||||
/// Public fields
|
||||
///
|
||||
public readonly int Uid;
|
||||
public readonly string OldUid;
|
||||
public readonly string Name; /// Name-s of all items must be unique
|
||||
public readonly string ToolTipText; /// Tool-Tip Text
|
||||
public readonly Quantity Quantity; /// Quantity
|
||||
public readonly ItemCategory Category; ///
|
||||
public string Caption; /// Specifies item description to be printed as a caption (in the header, etc.)
|
||||
public string TestID; /// Specifies the test
|
||||
public Config.Unit Units; /// Specifies units for the output
|
||||
public string Format; /// Specifies format for the output
|
||||
public string Precision; /// Specifies precision for the output
|
||||
public int Width; /// Specifies the number of characters of the output, 0 = automatic
|
||||
public Config.Entities.Alignment Alignment; /// Specifies alignment for the output
|
||||
|
||||
public WMeterRsltItemSpec Clone()
|
||||
{
|
||||
WMeterRsltItemSpec item2 = new WMeterRsltItemSpec((ItemID)Uid, Name, ToolTipText, Quantity, Category, printDlgt);
|
||||
item2.Caption = Caption;
|
||||
item2.TestID = TestID;
|
||||
item2.Units = Units;
|
||||
item2.Format = Format;
|
||||
item2.Precision = Precision;
|
||||
item2.Width = Width;
|
||||
item2.Alignment = Alignment;
|
||||
return item2;
|
||||
}
|
||||
|
||||
///
|
||||
/// Function to pick a MeterTestResult field and convert it into a string
|
||||
///
|
||||
public delegate string PrintDlgt(WaterMeter waterMeterResult, string testID, Config.Unit units, string format, string precision);
|
||||
|
||||
private readonly PrintDlgt printDlgt;
|
||||
|
||||
/// <summary> Safe wrapper which replaces null-s by empty strings </summary>
|
||||
public string Print(WaterMeter waterMeterResult)
|
||||
{
|
||||
return Print(waterMeterResult, TestID);
|
||||
}
|
||||
public string Print(WaterMeter waterMeterResult, string testId)
|
||||
{
|
||||
string str = printDlgt(waterMeterResult, testId, Units, Format, Precision);
|
||||
if (str == null) str = string.Empty;
|
||||
|
||||
if (!string.IsNullOrEmpty(Format))
|
||||
{
|
||||
str = string.Format(Format, str);
|
||||
}
|
||||
|
||||
int len = str.Length;
|
||||
if (Width == 0 || len >= Width)
|
||||
{
|
||||
return str;
|
||||
}
|
||||
else if (Alignment == Config.Entities.Alignment.Left)
|
||||
{
|
||||
return str + new string(' ', Width - len);
|
||||
}
|
||||
else if (Alignment == Config.Entities.Alignment.Right)
|
||||
{
|
||||
return new string(' ', Width - len) + str;
|
||||
}
|
||||
else // Alignment.Center or Alignment.Justified
|
||||
{
|
||||
int nrSpaces = Width - len;
|
||||
return new string(' ', nrSpaces / 2) + str + new string(' ', nrSpaces - (nrSpaces / 2));
|
||||
}
|
||||
}
|
||||
|
||||
///
|
||||
/// Public constructor
|
||||
///
|
||||
public WMeterRsltItemSpec(ItemID itemId, string name, string toolTipText, Quantity quantity, ItemCategory category, PrintDlgt printDlgt)
|
||||
{
|
||||
Uid = (int)itemId;
|
||||
OldUid = itemId.ToString().Replace("__", "/").Replace('_', ' ');
|
||||
Name = name;
|
||||
ToolTipText = toolTipText;
|
||||
Quantity = quantity;
|
||||
Category = category;
|
||||
this.printDlgt = printDlgt;
|
||||
}
|
||||
|
||||
///
|
||||
/// Constructorwithot ToolTip text
|
||||
///
|
||||
public WMeterRsltItemSpec(ItemID itemId, string name, Quantity quantity, ItemCategory category, PrintDlgt printDlgt)
|
||||
{
|
||||
Uid = (int)itemId;
|
||||
OldUid = itemId.ToString().Replace("__", "/").Replace('_', ' ');
|
||||
Name = name;
|
||||
ToolTipText = string.Format("{0} bla, bla, bla", Name);
|
||||
Quantity = quantity;
|
||||
Category = category;
|
||||
this.printDlgt = printDlgt;
|
||||
}
|
||||
|
||||
|
||||
/// Static list of all available items
|
||||
public static readonly IList<WMeterRsltItemSpec> AllItems;
|
||||
|
||||
/// Static constructor that initializes the list of all items
|
||||
static WMeterRsltItemSpec()
|
||||
{
|
||||
AllItems = new List<WMeterRsltItemSpec>();
|
||||
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.String, "String", "", Quantity.String, ItemCategory.Other, (w, t, u, f, p) => f));
|
||||
|
||||
/// Common
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Test_name, Strings.Test, Quantity.String, ItemCategory.TestData, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : w.GetTestRslt(t).Name()));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Procedure_name, Strings.Procedure, Quantity.String, ItemCategory.Other, (w, t, u, f, p) => w.ProcedureName()));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Batch_number, Strings.Batch_nr, Quantity.Number, ItemCategory.Other, (w, t, u, f, p) => w.BatchNr().ToString()));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Test_method, Strings.Test_method + " *", Quantity.String, ItemCategory.TestData, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : w.GetTestRslt(t).Method()));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Density, Strings.Density + " *", Quantity.Density, ItemCategory.Other, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : w.GetTestRslt(t).DensityOut.ToString(string.IsNullOrEmpty(p) ? "F1" : p))); /// [kg/m3]
|
||||
|
||||
/// Target values
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Q_from, Strings.Q_from + "()", Quantity.Flow, ItemCategory.TestData, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : w.GetTestRslt(t).Qfrom().ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Q_to, Strings.Q_to + "()", Quantity.Flow, ItemCategory.TestData, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : w.GetTestRslt(t).Qto().ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Test_volume, Strings.Test_vol + "()", Quantity.Volume, ItemCategory.TestData, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).TargetVolume()).ToString(string.IsNullOrEmpty(p) ? "F1" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Error_limit_Lo, Strings.ErrLimLo + "()", Quantity.Error, ItemCategory.TestData, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).ErrLimLo()).ToString(string.IsNullOrEmpty(p) ? "F1" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Error_limit_Hi, Strings.ErrLimHi + "()", Quantity.Error, ItemCategory.TestData, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).ErrLimHi()).ToString(string.IsNullOrEmpty(p) ? "F1" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Uncertainty, Strings.Uncertainty + "()", Quantity.Error, ItemCategory.TestData, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : w.GetTestRslt(t).Uncertainty().ToString(string.IsNullOrEmpty(p) ? "F2" : p)));
|
||||
|
||||
/// Test results
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Test_start_time, Strings.T_start + "()", Quantity.DateTime, ItemCategory.TestResult, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : (string.IsNullOrEmpty(f) ? w.GetTestRslt(t).StartTime.ToString() : string.Format(f, w.GetTestRslt(t).StartTime))));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Test_end_time, Strings.T_end + "()", Quantity.DateTime, ItemCategory.TestResult, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : (string.IsNullOrEmpty(f) ? w.GetTestRslt(t).EndTime.ToString() : string.Format(f, w.GetTestRslt(t).EndTime))));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Test_time, Strings.T_s + "()", Quantity.Time, ItemCategory.TestResult, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : w.GetTestRslt(t).TestTime.ToString(string.IsNullOrEmpty(p) ? "F2" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Flow, Strings.Flow + "()", Quantity.Flow, ItemCategory.TestResult, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Utils.DoubleToStr(Config.Units.ConvertTo(u, w.GetTestRslt(t).FlowVolume), 4)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.T_up_mean, Strings.T_in + "()", Quantity.Temperature, ItemCategory.TestResult, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).TempUpMean).ToString(string.IsNullOrEmpty(p) ? "F2" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.T_down_mean, Strings.T_out + "()", Quantity.Temperature, ItemCategory.TestResult, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).TempDownMean).ToString(string.IsNullOrEmpty(p) ? "F2" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.T_div, Strings.T_div + "()", Quantity.Temperature, ItemCategory.TestResult, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).TempDivMean).ToString(string.IsNullOrEmpty(p) ? "F2" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.P_up, Strings.P_up + "()", Quantity.Pressure, ItemCategory.TestResult, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).PressUpMean).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.P_up_start, Strings.P_up_start + "()", Quantity.Pressure, ItemCategory.TestResult, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).PressUpStart).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.P_up_end, Strings.P_up_end + "()", Quantity.Pressure, ItemCategory.TestResult, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).PressUpEnd).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.P_down, Strings.P_dn + "()", Quantity.Pressure, ItemCategory.TestResult, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).PressDownMean).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.P_down_start, Strings.P_dn_start + "()", Quantity.Pressure, ItemCategory.TestResult, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).PressDownStart).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.P_down_end, Strings.P_dn_end + "()", Quantity.Pressure, ItemCategory.TestResult, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).PressDownEnd).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.P_delta_mean, Strings.P_delta + "()", Quantity.Pressure, ItemCategory.TestResult, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).PressDeltaMean).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.P_delta_start, Strings.P_delta_start + "()", Quantity.Pressure, ItemCategory.TestResult, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).PressDeltaStart).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.P_delta_end, Strings.P_delta_end + "()", Quantity.Pressure, ItemCategory.TestResult, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).PressDeltaEnd).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Reference_error, Strings.ErrRef + "()", Quantity.Error, ItemCategory.TestResult, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).ErrorMaster).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Ambient_temperature, Strings.T_amb + "()", Quantity.Temperature, ItemCategory.TestResult, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? Config.Units.ConvertTo(u, w.Batch.AmbientTempAve()).ToString(string.IsNullOrEmpty(p) ? "F1" : p) : Config.Units.ConvertTo(u, w.GetTestRslt(t).AmbTempMean).ToString(string.IsNullOrEmpty(p) ? "F1" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Ambient_pressure, Strings.P_amb + "()", Quantity.Pressure, ItemCategory.TestResult, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? Config.Units.ConvertTo(u, w.Batch.AmbientPressAve()).ToString(string.IsNullOrEmpty(p) ? "F0" : p) : Config.Units.ConvertTo(u, w.GetTestRslt(t).AmbPressMean).ToString(string.IsNullOrEmpty(p) ? "F0" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Ambient_humidity, Strings.H_amb + "()", Quantity.Humidity, ItemCategory.TestResult, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? Config.Units.ConvertTo(u, w.Batch.AmbientHumiAve()).ToString(string.IsNullOrEmpty(p) ? "F1" : p) : Config.Units.ConvertTo(u, w.GetTestRslt(t).AmbHumiMean).ToString(string.IsNullOrEmpty(p) ? "F1" : p)));
|
||||
|
||||
/// Single and combined meter results
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Volume, Strings.Volume + "()", Quantity.Volume, ItemCategory.MeterResult, (w, t, u, f, p) => (w.GetMeterTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetMeterTestRslt(t).VolumeMeter).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Reference_volume, Strings.VolRef + "()", Quantity.Volume, ItemCategory.MeterResult, (w, t, u, f, p) => (w.GetMeterTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetMeterTestRslt(t).VolumeRef).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
#if TURA_IPERL || TURA_SPECIAL
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Error, Strings.Error + "()", Quantity.Error, ItemCategory.MeterResult, (w, t, u, f, p) => (w.GetMeterTestRslt(t) == null) ? "0" : Config.Units.ConvertTo(u, w.GetMeterTestRslt(t).Error).ToString(string.IsNullOrEmpty(p) ? "F2" : p)));
|
||||
#else
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Error, Strings.Error + "()", Quantity.Error, ItemCategory.MeterResult, (w, t, u, f, p) => (w.GetMeterTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetMeterTestRslt(t).Error).ToString(string.IsNullOrEmpty(p) ? "F2" : p)));
|
||||
#endif
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Passed, Strings.Result + "()", Quantity.Boolean, ItemCategory.MeterResult, (w, t, u, f, p) => (w.GetMeterTestRslt(t) == null) ? "" : w.GetMeterTestRslt(t).PassedColorStr()));
|
||||
|
||||
/// Water meter info
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Watermeter_type, Strings.WM_Type, Quantity.String, ItemCategory.MeterData, (w, t, u, f, p) => w.WaterMeterData.ProductName));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Producer, Strings.Producer, Quantity.String, ItemCategory.MeterData, (w, t, u, f, p) => w.WaterMeterData.Producer));
|
||||
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.DN, "DN", Quantity.Length, ItemCategory.MeterData, (w, t, u, f, p) => string.IsNullOrEmpty(p) ? Config.Units.ConvertTo(u, w.WaterMeterData.DN).ToString()
|
||||
: Config.Units.ConvertTo(u, w.WaterMeterData.DN).ToString(p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.L, "L", Quantity.Length, ItemCategory.MeterData, (w, t, u, f, p) => string.IsNullOrEmpty(p) ? Config.Units.ConvertTo(u, w.WaterMeterData.L).ToString()
|
||||
: Config.Units.ConvertTo(u, w.WaterMeterData.L).ToString(p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Mounting, Strings.Mounting, Quantity.String, ItemCategory.MeterData, (w, t, u, f, p) => w.WaterMeterData.Mounting.ToDescription()));
|
||||
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Q4, "Q4_Qmax", Quantity.Flow, ItemCategory.MeterData, (w, t, u, f, p) => string.IsNullOrEmpty(p) ? Config.Units.ConvertTo(u, w.WaterMeterData.Q4_Qmax).ToString()
|
||||
: Config.Units.ConvertTo(u, w.WaterMeterData.Q4_Qmax).ToString(p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Q3, "Q3_Qn", Quantity.Flow, ItemCategory.MeterData, (w, t, u, f, p) => string.IsNullOrEmpty(p) ? Config.Units.ConvertTo(u, w.WaterMeterData.Q3_Qn).ToString()
|
||||
: Config.Units.ConvertTo(u, w.WaterMeterData.Q3_Qn).ToString(p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Q2, "Q2_Qt", Quantity.Flow, ItemCategory.MeterData, (w, t, u, f, p) => string.IsNullOrEmpty(p) ? Config.Units.ConvertTo(u, w.WaterMeterData.Q2_Qt).ToString()
|
||||
: Config.Units.ConvertTo(u, w.WaterMeterData.Q2_Qt).ToString(p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Q1, "Q1_Qmin", Quantity.Flow, ItemCategory.MeterData, (w, t, u, f, p) => string.IsNullOrEmpty(p) ? Config.Units.ConvertTo(u, w.WaterMeterData.Q1_Qmin).ToString()
|
||||
: Config.Units.ConvertTo(u, w.WaterMeterData.Q1_Qmin).ToString(p)));
|
||||
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Metrological_class, Strings.MClass, Quantity.String, ItemCategory.MeterData, (w, t, u, f, p) => w.WaterMeterData.MetrologicalClass));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Temperature_class, "Temperature class", Quantity.String, ItemCategory.MeterData, (w, t, u, f, p) => w.WaterMeterData.TemperatureClass.ToDescription()));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Pressure_loss_class, "Pressure loss class", Quantity.String, ItemCategory.MeterData, (w, t, u, f, p) => w.WaterMeterData.PressureLossClass.ToDescription()));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Max_admissible_pressure, "Max. admissible pressure", Quantity.String, ItemCategory.MeterData, (w, t, u, f, p) => w.WaterMeterData.MaxAdmissiblePressure.ToDescription()));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Flow_profile_sensitivity_class, "Flow profile sensitivity class", Quantity.String, ItemCategory.MeterData, (w, t, u, f, p) => w.WaterMeterData.FlowProfileSensitivityClass.ToDescription()));
|
||||
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Approval_info, Strings.Approval, Quantity.String, ItemCategory.MeterData, (w, t, u, f, p) => w.WaterMeterData.ApprovalInfo));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Certificate, "Certificate", Quantity.String, ItemCategory.MeterData, (w, t, u, f, p) => w.WaterMeterData.Certificate));
|
||||
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Pulses_per_liter, Strings.PulsesLiter, Quantity.PulsePerLtr, ItemCategory.MeterData, (w, t, u, f, p) => string.IsNullOrEmpty(p) ? w.WaterMeterData.PulsesPerLtr.ToString()
|
||||
: w.WaterMeterData.PulsesPerLtr.ToString(p)));
|
||||
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Text1, "Text1", Quantity.String, ItemCategory.Other, (w, t, u, f, p) => w.WaterMeterData.Text1));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Text2, "Text2", Quantity.String, ItemCategory.Other, (w, t, u, f, p) => w.WaterMeterData.Text2));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Text3, "Text3", Quantity.String, ItemCategory.Other, (w, t, u, f, p) => w.WaterMeterData.Text3));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Text4, "Text4", Quantity.String, ItemCategory.Other, (w, t, u, f, p) => w.WaterMeterData.Text4));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Text5, "Text5", Quantity.String, ItemCategory.Other, (w, t, u, f, p) => w.WaterMeterData.Text5));
|
||||
|
||||
/// Water meters results
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Serial_Nr, Strings.sn, Quantity.String, ItemCategory.MeterResult, (w, t, u, f, p) => w.SerialNr));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Purchase_order, Strings.PO, Quantity.String, ItemCategory.Other, (w, t, u, f, p) => w.PurchaseOrder));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Year_of_production, Strings.Year, Quantity.Number, ItemCategory.Other, (w, t, u, f, p) => w.YearOfProduction.ToString()));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.WM_Position, Strings.Pos, Quantity.Number, ItemCategory.Other, (w, t, u, f, p) => w.WMPosition.ToString()));
|
||||
|
||||
/// Water meters results (single)
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.End_state, Strings.End_state, Quantity.String, ItemCategory.MeterResult, (w, t, u, f, p) => w.EndState));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Pulses, Strings.Pulses + "()", Quantity.Number, ItemCategory.MeterResult, (w, t, u, f, p) => (w.GetMeterTestRslt(t) == null) ? "" : w.GetMeterTestRslt(t).PulsesMeter.ToString()));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Pulses__liter, Strings.PulsesLiter + "()", Quantity.PulsePerLtr, ItemCategory.Other, (w, t, u, f, p) => (w.GetMeterTestRslt(t) == null) ? "" : (string.IsNullOrEmpty(p) ? w.GetMeterTestRslt(t).PulsesPerLiter.ToString()
|
||||
: w.GetMeterTestRslt(t).PulsesPerLiter.ToString(p))));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Reference_pulses, Strings.RefPulses + "()", Quantity.Number, ItemCategory.Other, (w, t, u, f, p) => (w.GetMeterTestRslt(t) == null) ? "" : w.GetMeterTestRslt(t).PulsesMaster.ToString()));
|
||||
|
||||
/// Water meters results (combined)
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Q_rise, Strings.Q_rise, Quantity.Flow, ItemCategory.MeterResult, (w, t, u, f, p) => (w.QRise == 0) ? "-" : Utils.DoubleToStr(w.QRise, 4)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Q_fall, Strings.Q_fall, Quantity.Flow, ItemCategory.MeterResult, (w, t, u, f, p) => (w.QFall == 0) ? "-" : Utils.DoubleToStr(w.QFall, 4)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Error_main, Strings.Err_main + "()", Quantity.Error, ItemCategory.MeterResult, (w, t, u, f, p) => (w.GetMeterTestRslt(t, CompoundMeterId.CompoundMain) == null) ? "" : (string.IsNullOrEmpty(p) ? w.GetMeterTestRslt(t, CompoundMeterId.CompoundMain).Error.ToString()
|
||||
: w.GetMeterTestRslt(t, CompoundMeterId.CompoundMain).Error.ToString(p))));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Error_aux, Strings.Err_aux + "()", Quantity.Error, ItemCategory.MeterResult, (w, t, u, f, p) => (w.GetMeterTestRslt(t, CompoundMeterId.CompoundAux) == null) ? "" : (string.IsNullOrEmpty(p) ? w.GetMeterTestRslt(t, CompoundMeterId.CompoundAux).Error.ToString()
|
||||
: w.GetMeterTestRslt(t, CompoundMeterId.CompoundAux).Error.ToString(p))));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Serial_Nr_main, Strings.sn_main, Quantity.String, ItemCategory.MeterResult, (w, t, u, f, p) => w.SerialNr));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Serial_Nr_aux, Strings.sn_aux, Quantity.String, ItemCategory.MeterResult, (w, t, u, f, p) => w.SerialNrAux));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.End_state_main, Strings.EndState_main, Quantity.String, ItemCategory.MeterResult, (w, t, u, f, p) => w.EndState));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.End_state_aux, Strings.EndState_aux, Quantity.String, ItemCategory.MeterResult, (w, t, u, f, p) => w.EndStateAux));
|
||||
|
||||
/// Batch info
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Test_bench_ID, Strings.Bench, Quantity.String, ItemCategory.Other, (w, t, u, f, p) => w.Batch.TestBenchId.ToString()));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Program_version, Strings.Ver, Quantity.String, ItemCategory.Other, (w, t, u, f, p) => w.Batch.ProgramVersion));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.User_name, Strings.User, Quantity.String, ItemCategory.Other, (w, t, u, f, p) => w.Batch.UserName));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.User_nr, Strings.User_nr, Quantity.Number, ItemCategory.Other, (w, t, u, f, p) => w.Batch.UserNumber.ToString()));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Watermeters, Strings.WMs, Quantity.String, ItemCategory.Other, (w, t, u, f, p) => w.Batch.WatermetersStr));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Protocol_title, Strings.Protocol, Quantity.String, ItemCategory.Other, (w, t, u, f, p) => w.Batch.ProtocolTitle));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Batch_start_time, Strings.Start, Quantity.DateTime, ItemCategory.Other, (w, t, u, f, p) => string.IsNullOrEmpty(f) ? w.Batch.StartTime.ToString() : string.Format(f, w.Batch.StartTime)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Batch_end_time, Strings.End, Quantity.DateTime, ItemCategory.Other, (w, t, u, f, p) => string.IsNullOrEmpty(f) ? w.Batch.EndTime.ToString() : string.Format(f, w.Batch.EndTime)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Lite_per_pulse_Read, "1 / PlsPerLtr_Read", Quantity.PulsePerLtr, ItemCategory.Other, (w, t, u, f, p) => string.IsNullOrEmpty(p) ? ((w.WaterMeterData.PulsesPerLtr != 0) ? 1 / w.WaterMeterData.PulsesPerLtr : 0).ToString()
|
||||
: ((w.WaterMeterData.PulsesPerLtr != 0) ? 1 / w.WaterMeterData.PulsesPerLtr : 0).ToString(p)));
|
||||
/// Extra water meter data
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Result_code, Strings.Result_code, Quantity.Number, ItemCategory.MeterResult, (w, t, u, f, p) => string.IsNullOrEmpty(f) ? w.ResultCode.ToString() : string.Format(f, w.ResultCode)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Remark, Strings.Remark, Quantity.String, ItemCategory.TestResult, (w, t, u, f, p) => w.Batch.Remark));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Meter_type, Strings.Meter_type, Quantity.String, ItemCategory.Other, (w, t, u, f, p) => w.WaterMeterData.Compound ? Strings.Compound : (w.WaterMeterData.HeatMeter ? Strings.Heat_meter : Strings.Single)));
|
||||
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Volume_main, Strings.Volume_main + "()", Quantity.Volume, ItemCategory.MeterResult, (w, t, u, f, p) => (w.GetMeterTestRslt(t, CompoundMeterId.CompoundMain) == null) ? "" : Config.Units.ConvertTo(u, w.GetMeterTestRslt(t).VolumeMeter).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Volume_aux, Strings.Volume_aux + "()", Quantity.Volume, ItemCategory.MeterResult, (w, t, u, f, p) => (w.GetMeterTestRslt(t, CompoundMeterId.CompoundAux) == null) ? "" : Config.Units.ConvertTo(u, w.GetMeterTestRslt(t).VolumeMeter).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Start_volume, Strings.Start_volume + "()", Quantity.Volume, ItemCategory.MeterResult, (w, t, u, f, p) => (w.GetMeterTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetMeterTestRslt(t).VolumeStart).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Start_volume_main, Strings.Start_volume_main + "()", Quantity.Volume, ItemCategory.MeterResult, (w, t, u, f, p) => (w.GetMeterTestRslt(t, CompoundMeterId.CompoundMain) == null) ? "" : Config.Units.ConvertTo(u, w.GetMeterTestRslt(t).VolumeStart).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Start_volume_aux, Strings.Start_volume_aux + "()", Quantity.Volume, ItemCategory.MeterResult, (w, t, u, f, p) => (w.GetMeterTestRslt(t, CompoundMeterId.CompoundAux) == null) ? "" : Config.Units.ConvertTo(u, w.GetMeterTestRslt(t).VolumeStart).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.End_volume, Strings.End_volume + "()", Quantity.Volume, ItemCategory.MeterResult, (w, t, u, f, p) => (w.GetMeterTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetMeterTestRslt(t).VolumeEnd).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.End_volume_main, Strings.End_volume_main + "()", Quantity.Volume, ItemCategory.MeterResult, (w, t, u, f, p) => (w.GetMeterTestRslt(t, CompoundMeterId.CompoundMain) == null) ? "" : Config.Units.ConvertTo(u, w.GetMeterTestRslt(t).VolumeEnd).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.End_volume_aux, Strings.End_volume_aux + "()", Quantity.Volume, ItemCategory.MeterResult, (w, t, u, f, p) => (w.GetMeterTestRslt(t, CompoundMeterId.CompoundAux) == null) ? "" : Config.Units.ConvertTo(u, w.GetMeterTestRslt(t).VolumeEnd).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
|
||||
#if HEAT_METERS
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Energy, Strings.Energy + "()", Quantity.Energy, ItemCategory.Other, (w, t, u, f, p) => (w.GetMeterTestRslt(t, Config.Entities.CompoundMeterId.HeatMeterEnergy) == null) ? "" : Config.Units.ConvertTo(u, w.GetMeterTestRslt(t, Config.Entities.CompoundMeterId.HeatMeterEnergy).VolumeMeter).ToString(string.IsNullOrEmpty(p) ? "F1" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.Reference_energy, Strings.Energy_ref + "()", Quantity.Energy, ItemCategory.Other, (w, t, u, f, p) => (w.GetMeterTestRslt(t, Config.Entities.CompoundMeterId.HeatMeterEnergy) == null) ? "" : Config.Units.ConvertTo(u, w.GetMeterTestRslt(t, Config.Entities.CompoundMeterId.HeatMeterEnergy).VolumeRef).ToString(string.IsNullOrEmpty(p) ? "F1" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.TempHiMean, "T hi me", Quantity.Temperature, ItemCategory.Other, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).Custom1).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.TempHiStart, "T hi st", Quantity.Temperature, ItemCategory.Other, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).Custom2).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.TempHiEnd, "T hi en", Quantity.Temperature, ItemCategory.Other, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).Custom3).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.TempHiAve, "T hi av", Quantity.Temperature, ItemCategory.Other, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, (w.GetTestRslt(t).Custom2 + w.GetTestRslt(t).Custom3) / 2).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.TempLoMean, "T lo me", Quantity.Temperature, ItemCategory.Other, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).Custom6).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.TempLoStart, "T lo st", Quantity.Temperature, ItemCategory.Other, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).Custom7).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.TempLoEnd, "T lo en", Quantity.Temperature, ItemCategory.Other, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, w.GetTestRslt(t).Custom8).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
AllItems.Add(new WMeterRsltItemSpec(ItemID.TempLoAve, "T lo av", Quantity.Temperature, ItemCategory.Other, (w, t, u, f, p) => (w.GetTestRslt(t) == null) ? "" : Config.Units.ConvertTo(u, (w.GetTestRslt(t).Custom7 + w.GetTestRslt(t).Custom8) / 2).ToString(string.IsNullOrEmpty(p) ? "F3" : p)));
|
||||
#endif
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Converts a list of 'Output item specifications' to a string array
|
||||
/// </summary>
|
||||
/// <param name="items"></param>
|
||||
/// <returns></returns>
|
||||
public static string[] ToStrArray(IList<WMeterRsltItemSpec> items)
|
||||
{
|
||||
int count = (items != null) ? items.Count : 0;
|
||||
string[] result = new string[count];
|
||||
for (int i = 0; i < count; i++)
|
||||
{
|
||||
result[i] = string.Format("{0}~{1}~{2}~{3}~{4}~{5}~{6}~{7}",
|
||||
items[i].Uid,
|
||||
items[i].Caption,
|
||||
items[i].TestID,
|
||||
items[i].Units,
|
||||
items[i].Format,
|
||||
items[i].Precision,
|
||||
items[i].Width,
|
||||
items[i].Alignment);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Converts a string array to a list of 'Output item specifications'
|
||||
/// </summary>
|
||||
/// <param name="strArray"></param>
|
||||
/// <returns></returns>
|
||||
public static IList<WMeterRsltItemSpec> FromStrArray(string[] strArray)
|
||||
{
|
||||
IList<WMeterRsltItemSpec> result = new List<WMeterRsltItemSpec>();
|
||||
|
||||
if (strArray != null)
|
||||
{
|
||||
for (int i = 0; i < strArray.Length; i++)
|
||||
{
|
||||
try
|
||||
{
|
||||
if (strArray[i].Contains("~"))
|
||||
{
|
||||
///
|
||||
/// Load the new style results item specification
|
||||
///
|
||||
string[] field = strArray[i].Split(new char[] { '~' });
|
||||
WMeterRsltItemSpec item = GetItem(int.Parse(field[0]));
|
||||
|
||||
item.Caption = field[1];
|
||||
item.TestID = field[2];
|
||||
item.Units = 0;
|
||||
for (Config.Unit u = 0; u < Config.Unit.Count; u++)
|
||||
{
|
||||
if (u.ToString().Equals(field[3])) { item.Units = u; break; }
|
||||
}
|
||||
item.Format = field[4];
|
||||
item.Precision = field[5];
|
||||
item.Width = int.Parse(field[6]);
|
||||
item.Alignment = 0;
|
||||
for (Config.Entities.Alignment a = 0; a < Config.Entities.Alignment.Count; a++)
|
||||
{
|
||||
if (a.ToString().Equals(field[7])) { item.Alignment = a; break; }
|
||||
}
|
||||
|
||||
result.Add(item);
|
||||
}
|
||||
else
|
||||
{
|
||||
///
|
||||
/// Try to load the old style results item specification
|
||||
///
|
||||
bool added = false;
|
||||
foreach (var it in AllItems)
|
||||
{
|
||||
if (strArray[i].Equals(it.OldUid))
|
||||
{
|
||||
WMeterRsltItemSpec item = it.Clone();
|
||||
item.Caption = item.Name.Replace("()", "").Replace(" *", "");
|
||||
item.Units = 0; /// use default units
|
||||
item.Format = null; /// the same like format string "{0}"
|
||||
item.Precision = null;
|
||||
item.Width = 0; /// do not ad any extra spaces
|
||||
item.Alignment = Alignment.Left;
|
||||
result.Add(item);
|
||||
added = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (!added)
|
||||
{
|
||||
WMeterRsltItemSpec item = GetItem(0);
|
||||
item.Caption = "Prs.Err.";
|
||||
item.Format = string.Format("Parse error: {0}", strArray[i]);
|
||||
result.Add(item);
|
||||
}
|
||||
}
|
||||
}
|
||||
catch
|
||||
{
|
||||
WMeterRsltItemSpec item = GetItem(0);
|
||||
item.Caption = "Prs.Err.";
|
||||
item.Format = string.Format("Parse error: {0}", strArray[i]);
|
||||
result.Add(item);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
public static WMeterRsltItemSpec GetItem(int uid)
|
||||
{
|
||||
foreach (var item in AllItems)
|
||||
{
|
||||
if (item.Uid == uid) return item.Clone();
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
public static WMeterRsltItemSpec GetItem(ItemID itemId)
|
||||
{
|
||||
return GetItem((int)itemId);
|
||||
}
|
||||
}
|
||||
}
|
||||
Generated
+137
@@ -0,0 +1,137 @@
|
||||
namespace ResultsBrowser
|
||||
{
|
||||
partial class BenchesDlg
|
||||
{
|
||||
/// <summary>
|
||||
/// Required designer variable.
|
||||
/// </summary>
|
||||
private System.ComponentModel.IContainer components = null;
|
||||
|
||||
/// <summary>
|
||||
/// Clean up any resources being used.
|
||||
/// </summary>
|
||||
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
|
||||
protected override void Dispose(bool disposing)
|
||||
{
|
||||
if (disposing && (components != null))
|
||||
{
|
||||
components.Dispose();
|
||||
}
|
||||
base.Dispose(disposing);
|
||||
}
|
||||
|
||||
#region Windows Form Designer generated code
|
||||
|
||||
/// <summary>
|
||||
/// Required method for Designer support - do not modify
|
||||
/// the contents of this method with the code editor.
|
||||
/// </summary>
|
||||
private void InitializeComponent()
|
||||
{
|
||||
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(BenchesDlg));
|
||||
this.okButton = new System.Windows.Forms.Button();
|
||||
this.cancelButton = new System.Windows.Forms.Button();
|
||||
this.testBenchesListBox = new System.Windows.Forms.ListBox();
|
||||
this.label1 = new System.Windows.Forms.Label();
|
||||
this.editButton = new System.Windows.Forms.Button();
|
||||
this.addButton = new System.Windows.Forms.Button();
|
||||
this.removeButton = new System.Windows.Forms.Button();
|
||||
this.copyButton = new System.Windows.Forms.Button();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// okButton
|
||||
//
|
||||
resources.ApplyResources(this.okButton, "okButton");
|
||||
this.okButton.DialogResult = System.Windows.Forms.DialogResult.OK;
|
||||
this.okButton.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
this.okButton.Name = "okButton";
|
||||
this.okButton.UseVisualStyleBackColor = true;
|
||||
this.okButton.Click += new System.EventHandler(this.okButton_Click);
|
||||
//
|
||||
// cancelButton
|
||||
//
|
||||
resources.ApplyResources(this.cancelButton, "cancelButton");
|
||||
this.cancelButton.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
||||
this.cancelButton.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
this.cancelButton.Name = "cancelButton";
|
||||
this.cancelButton.UseVisualStyleBackColor = true;
|
||||
this.cancelButton.Click += new System.EventHandler(this.cancelButton_Click);
|
||||
//
|
||||
// testBenchesListBox
|
||||
//
|
||||
resources.ApplyResources(this.testBenchesListBox, "testBenchesListBox");
|
||||
this.testBenchesListBox.FormattingEnabled = true;
|
||||
this.testBenchesListBox.Name = "testBenchesListBox";
|
||||
this.testBenchesListBox.DoubleClick += new System.EventHandler(this.testBenchesListBox_DoubleClick);
|
||||
//
|
||||
// label1
|
||||
//
|
||||
resources.ApplyResources(this.label1, "label1");
|
||||
this.label1.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
this.label1.Name = "label1";
|
||||
//
|
||||
// editButton
|
||||
//
|
||||
resources.ApplyResources(this.editButton, "editButton");
|
||||
this.editButton.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
this.editButton.Name = "editButton";
|
||||
this.editButton.UseVisualStyleBackColor = true;
|
||||
this.editButton.Click += new System.EventHandler(this.editButton_Click);
|
||||
//
|
||||
// addButton
|
||||
//
|
||||
resources.ApplyResources(this.addButton, "addButton");
|
||||
this.addButton.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
this.addButton.Name = "addButton";
|
||||
this.addButton.UseVisualStyleBackColor = true;
|
||||
this.addButton.Click += new System.EventHandler(this.addButton_Click);
|
||||
//
|
||||
// removeButton
|
||||
//
|
||||
resources.ApplyResources(this.removeButton, "removeButton");
|
||||
this.removeButton.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
this.removeButton.Name = "removeButton";
|
||||
this.removeButton.UseVisualStyleBackColor = true;
|
||||
this.removeButton.Click += new System.EventHandler(this.removeButton_Click);
|
||||
//
|
||||
// copyButton
|
||||
//
|
||||
resources.ApplyResources(this.copyButton, "copyButton");
|
||||
this.copyButton.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
this.copyButton.Name = "copyButton";
|
||||
this.copyButton.UseVisualStyleBackColor = true;
|
||||
this.copyButton.Click += new System.EventHandler(this.copyButton_Click);
|
||||
//
|
||||
// BenchesDlg
|
||||
//
|
||||
resources.ApplyResources(this, "$this");
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.Controls.Add(this.copyButton);
|
||||
this.Controls.Add(this.removeButton);
|
||||
this.Controls.Add(this.addButton);
|
||||
this.Controls.Add(this.editButton);
|
||||
this.Controls.Add(this.label1);
|
||||
this.Controls.Add(this.testBenchesListBox);
|
||||
this.Controls.Add(this.okButton);
|
||||
this.Controls.Add(this.cancelButton);
|
||||
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
|
||||
this.MaximizeBox = false;
|
||||
this.Name = "BenchesDlg";
|
||||
this.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide;
|
||||
this.ResumeLayout(false);
|
||||
this.PerformLayout();
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private System.Windows.Forms.Button okButton;
|
||||
private System.Windows.Forms.Button cancelButton;
|
||||
private System.Windows.Forms.ListBox testBenchesListBox;
|
||||
private System.Windows.Forms.Label label1;
|
||||
private System.Windows.Forms.Button editButton;
|
||||
private System.Windows.Forms.Button addButton;
|
||||
private System.Windows.Forms.Button removeButton;
|
||||
private System.Windows.Forms.Button copyButton;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,199 @@
|
||||
using System;
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace ResultsBrowser
|
||||
{
|
||||
/// <summary>
|
||||
/// Dialog to edit local settings that specify database parameters (S1.2)
|
||||
/// </summary>
|
||||
public partial class BenchesDlg : Form
|
||||
{
|
||||
// Local copy of 'local settings' initialized to Program.localSettings.
|
||||
// Dialog modifies this copy and updates Program.localSettings just
|
||||
// when 'OK' is pressed.
|
||||
LocalSettings localSettings;
|
||||
|
||||
/// <summary>
|
||||
/// Constructor, initializes the dialog
|
||||
/// </summary>
|
||||
public BenchesDlg()
|
||||
{
|
||||
localSettings = new LocalSettings();
|
||||
localSettings.Assign(Program.LocalSettings);
|
||||
|
||||
InitializeComponent();
|
||||
RedrawTestBenchesListBox();
|
||||
}
|
||||
|
||||
void RedrawTestBenchesListBox()
|
||||
{
|
||||
testBenchesListBox.Items.Clear();
|
||||
if (localSettings.testBenches != null)
|
||||
{
|
||||
int nrBenches = localSettings.testBenches.GetLength(0);
|
||||
for (int i = 0; i < nrBenches; i++)
|
||||
{
|
||||
testBenchesListBox.Items.Add(localSettings.testBenches[i].BenchName);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Create a new test bench DB specification and append it to the list
|
||||
/// </summary>
|
||||
/// <param name="sender">Not used</param>
|
||||
/// <param name="e">Not used</param>
|
||||
private void addButton_Click(object sender, EventArgs e)
|
||||
{
|
||||
DatabaseSettings bench = new DatabaseSettings();
|
||||
DatabaseSettingsDlg dlg = new DatabaseSettingsDlg(bench);
|
||||
DialogResult dr = dlg.ShowDialog();
|
||||
if (dr == DialogResult.OK)
|
||||
{
|
||||
int nrBenches =
|
||||
(localSettings.testBenches == null) ? 0 : localSettings.testBenches.GetLength(0);
|
||||
|
||||
if (nrBenches == 0)
|
||||
{
|
||||
localSettings.testBenches = new DatabaseSettings[1];
|
||||
localSettings.testBenches[0] = bench;
|
||||
}
|
||||
else
|
||||
{
|
||||
DatabaseSettings[] newTestBenches = new DatabaseSettings[nrBenches + 1];
|
||||
for (int i = 0; i < nrBenches; i++)
|
||||
{
|
||||
newTestBenches[i] = localSettings.testBenches[i];
|
||||
}
|
||||
newTestBenches[nrBenches] = bench;
|
||||
localSettings.testBenches = newTestBenches;
|
||||
}
|
||||
|
||||
testBenchesListBox.Items.Add(bench.BenchName);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Create a new test bench DB specification,which is a copy of the
|
||||
/// selected bench, and append it to the list
|
||||
/// </summary>
|
||||
/// <param name="sender">Not used</param>
|
||||
/// <param name="e">Not used</param>
|
||||
private void copyButton_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (testBenchesListBox.SelectedIndex >= 0)
|
||||
{
|
||||
DatabaseSettings ori = localSettings.testBenches[testBenchesListBox.SelectedIndex];
|
||||
DatabaseSettings bench = (DatabaseSettings)ori.Clone();
|
||||
|
||||
DatabaseSettingsDlg dlg = new DatabaseSettingsDlg(bench);
|
||||
DialogResult dr = dlg.ShowDialog();
|
||||
if (dr == DialogResult.OK)
|
||||
{
|
||||
int nrBenches =
|
||||
(localSettings.testBenches == null) ? 0 : localSettings.testBenches.GetLength(0);
|
||||
|
||||
DatabaseSettings[] newTestBenches = new DatabaseSettings[nrBenches + 1];
|
||||
for (int i = 0; i < nrBenches; i++)
|
||||
{
|
||||
newTestBenches[i] = localSettings.testBenches[i];
|
||||
}
|
||||
newTestBenches[nrBenches] = bench;
|
||||
localSettings.testBenches = newTestBenches;
|
||||
|
||||
testBenchesListBox.Items.Add(bench.BenchName);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Edit selected test bench DB specification
|
||||
/// </summary>
|
||||
/// <param name="sender">Not used</param>
|
||||
/// <param name="e">Not used</param>
|
||||
private void editButton_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (testBenchesListBox.SelectedIndex >= 0)
|
||||
{
|
||||
DatabaseSettingsDlg dlg = new DatabaseSettingsDlg(localSettings.testBenches[testBenchesListBox.SelectedIndex]);
|
||||
DialogResult dr = dlg.ShowDialog();
|
||||
if (dr == DialogResult.OK)
|
||||
{
|
||||
// Update the item name
|
||||
testBenchesListBox.Items[testBenchesListBox.SelectedIndex] =
|
||||
localSettings.testBenches[testBenchesListBox.SelectedIndex].BenchName;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Remove selected test bench DB specification from the list
|
||||
/// </summary>
|
||||
/// <param name="sender">Not used</param>
|
||||
/// <param name="e">Not used</param>
|
||||
private void removeButton_Click(object sender, EventArgs e)
|
||||
{
|
||||
int selectedIx = testBenchesListBox.SelectedIndex;
|
||||
if (selectedIx >= 0)
|
||||
{
|
||||
int nrBenches =
|
||||
(localSettings.testBenches == null) ? 0 : localSettings.testBenches.GetLength(0);
|
||||
|
||||
if (nrBenches == 1)
|
||||
{
|
||||
localSettings.testBenches = null;
|
||||
}
|
||||
else
|
||||
{
|
||||
DatabaseSettings[] newTestBenches = new DatabaseSettings[nrBenches - 1];
|
||||
for (int i = 0; i < selectedIx; i++)
|
||||
{
|
||||
newTestBenches[i] = localSettings.testBenches[i];
|
||||
}
|
||||
for (int i = selectedIx + 1; i < nrBenches; i++)
|
||||
{
|
||||
newTestBenches[i - 1] = localSettings.testBenches[i];
|
||||
}
|
||||
localSettings.testBenches = newTestBenches;
|
||||
}
|
||||
|
||||
RedrawTestBenchesListBox();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Update setting, return 'OK'
|
||||
/// </summary>
|
||||
/// <param name="sender">Not used</param>
|
||||
/// <param name="e">Not used</param>
|
||||
private void okButton_Click(object sender, EventArgs e)
|
||||
{
|
||||
Program.LocalSettings.Assign(localSettings); // Update Program.localSettings
|
||||
DialogResult = DialogResult.OK;
|
||||
Close();
|
||||
return;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Throw away changes, return 'Cancel'
|
||||
/// </summary>
|
||||
/// <param name="sender">Not used</param>
|
||||
/// <param name="e">Not used</param>
|
||||
private void cancelButton_Click(object sender, EventArgs e)
|
||||
{
|
||||
DialogResult = DialogResult.Cancel;
|
||||
Close();
|
||||
return;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Double click on an item = edit item
|
||||
/// </summary>
|
||||
/// <param name="sender">Not used</param>
|
||||
/// <param name="e">Not used</param>
|
||||
private void testBenchesListBox_DoubleClick(object sender, EventArgs e)
|
||||
{
|
||||
editButton_Click(sender, e);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
@@ -118,27 +118,31 @@
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<data name="okButton.Text" xml:space="preserve">
|
||||
<value>OK</value>
|
||||
<value>&OK</value>
|
||||
</data>
|
||||
<data name="cancelButton.Text" xml:space="preserve">
|
||||
<value>Отмена</value>
|
||||
<value>&Abbrechen</value>
|
||||
</data>
|
||||
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
|
||||
<data name="label1.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>58, 13</value>
|
||||
</data>
|
||||
<data name="label1.Text" xml:space="preserve">
|
||||
<value>Испытательные стенды :</value>
|
||||
<value>Prüfstände</value>
|
||||
</data>
|
||||
<data name="editButton.Text" xml:space="preserve">
|
||||
<value>&Редактировать</value>
|
||||
<value>&Bearbeiten...</value>
|
||||
</data>
|
||||
<data name="addButton.Text" xml:space="preserve">
|
||||
<value>&Добавить</value>
|
||||
<value>&Neu...</value>
|
||||
</data>
|
||||
<data name="removeButton.Text" xml:space="preserve">
|
||||
<value>&Удалить</value>
|
||||
<value>&Löschen</value>
|
||||
</data>
|
||||
<data name="copyButton.Text" xml:space="preserve">
|
||||
<value>&Копировать</value>
|
||||
<value>&Kopieren</value>
|
||||
</data>
|
||||
<data name="$this.Text" xml:space="preserve">
|
||||
<value>Настройки Базы данных</value>
|
||||
<value>Datenbank Einstellungen</value>
|
||||
</data>
|
||||
</root>
|
||||
@@ -0,0 +1,339 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<assembly alias="mscorlib" name="mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
|
||||
<data name="testBenchesListBox.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>13</value>
|
||||
</data>
|
||||
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
|
||||
<data name="editButton.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>192, 105</value>
|
||||
</data>
|
||||
<data name=">>copyButton.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name="cancelButton.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>105, 28</value>
|
||||
</data>
|
||||
<data name="addButton.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>192, 37</value>
|
||||
</data>
|
||||
<data name="testBenchesListBox.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>164, 134</value>
|
||||
</data>
|
||||
<data name="addButton.Text" xml:space="preserve">
|
||||
<value>&Add</value>
|
||||
</data>
|
||||
<data name=">>removeButton.ZOrder" xml:space="preserve">
|
||||
<value>1</value>
|
||||
</data>
|
||||
<data name="editButton.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>15</value>
|
||||
</data>
|
||||
<data name=">>editButton.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>cancelButton.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>$this.Name" xml:space="preserve">
|
||||
<value>BenchesDlg</value>
|
||||
</data>
|
||||
<data name=">>testBenchesListBox.ZOrder" xml:space="preserve">
|
||||
<value>5</value>
|
||||
</data>
|
||||
<data name=">>label1.Name" xml:space="preserve">
|
||||
<value>label1</value>
|
||||
</data>
|
||||
<data name="removeButton.Text" xml:space="preserve">
|
||||
<value>&Remove</value>
|
||||
</data>
|
||||
<data name="cancelButton.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>344, 71</value>
|
||||
</data>
|
||||
<data name=">>cancelButton.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name="cancelButton.Text" xml:space="preserve">
|
||||
<value>Cancel</value>
|
||||
</data>
|
||||
<data name=">>testBenchesListBox.Name" xml:space="preserve">
|
||||
<value>testBenchesListBox</value>
|
||||
</data>
|
||||
<data name="copyButton.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>192, 71</value>
|
||||
</data>
|
||||
<data name=">>okButton.Name" xml:space="preserve">
|
||||
<value>okButton</value>
|
||||
</data>
|
||||
<data name=">>label1.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>testBenchesListBox.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.ListBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name="editButton.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>105, 28</value>
|
||||
</data>
|
||||
<data name="copyButton.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>0</value>
|
||||
</data>
|
||||
<data name="label1.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>14</value>
|
||||
</data>
|
||||
<data name=">>editButton.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name="label1.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>79, 13</value>
|
||||
</data>
|
||||
<data name="addButton.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>105, 28</value>
|
||||
</data>
|
||||
<data name=">>removeButton.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name="$this.ClientSize" type="System.Drawing.Size, System.Drawing">
|
||||
<value>459, 185</value>
|
||||
</data>
|
||||
<data name="cancelButton.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>11</value>
|
||||
</data>
|
||||
<data name="$this.AutoScaleDimensions" type="System.Drawing.SizeF, System.Drawing">
|
||||
<value>6, 13</value>
|
||||
</data>
|
||||
<data name="okButton.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>105, 28</value>
|
||||
</data>
|
||||
<data name="editButton.Text" xml:space="preserve">
|
||||
<value>&Edit</value>
|
||||
</data>
|
||||
<data name=">>addButton.Name" xml:space="preserve">
|
||||
<value>addButton</value>
|
||||
</data>
|
||||
<assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
|
||||
<data name="$this.StartPosition" type="System.Windows.Forms.FormStartPosition, System.Windows.Forms">
|
||||
<value>CenterParent</value>
|
||||
</data>
|
||||
<data name=">>okButton.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name="removeButton.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>192, 139</value>
|
||||
</data>
|
||||
<data name=">>cancelButton.ZOrder" xml:space="preserve">
|
||||
<value>7</value>
|
||||
</data>
|
||||
<data name="okButton.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>344, 37</value>
|
||||
</data>
|
||||
<data name="copyButton.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>105, 28</value>
|
||||
</data>
|
||||
<data name="removeButton.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>17</value>
|
||||
</data>
|
||||
<data name=">>removeButton.Name" xml:space="preserve">
|
||||
<value>removeButton</value>
|
||||
</data>
|
||||
<data name="copyButton.Text" xml:space="preserve">
|
||||
<value>&Copy</value>
|
||||
</data>
|
||||
<data name="testBenchesListBox.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>12, 37</value>
|
||||
</data>
|
||||
<data name=">>label1.ZOrder" xml:space="preserve">
|
||||
<value>4</value>
|
||||
</data>
|
||||
<data name=">>addButton.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>okButton.ZOrder" xml:space="preserve">
|
||||
<value>6</value>
|
||||
</data>
|
||||
<data name=">>addButton.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>copyButton.Name" xml:space="preserve">
|
||||
<value>copyButton</value>
|
||||
</data>
|
||||
<data name="removeButton.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>105, 28</value>
|
||||
</data>
|
||||
<data name="label1.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
</data>
|
||||
<data name=">>editButton.ZOrder" xml:space="preserve">
|
||||
<value>3</value>
|
||||
</data>
|
||||
<data name=">>editButton.Name" xml:space="preserve">
|
||||
<value>editButton</value>
|
||||
</data>
|
||||
<data name=">>cancelButton.Name" xml:space="preserve">
|
||||
<value>cancelButton</value>
|
||||
</data>
|
||||
<data name="label1.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>12, 15</value>
|
||||
</data>
|
||||
<data name=">>removeButton.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>copyButton.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>testBenchesListBox.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>addButton.ZOrder" xml:space="preserve">
|
||||
<value>2</value>
|
||||
</data>
|
||||
<data name="okButton.Text" xml:space="preserve">
|
||||
<value>OK</value>
|
||||
</data>
|
||||
<data name="$this.Text" xml:space="preserve">
|
||||
<value>Database Settings</value>
|
||||
</data>
|
||||
<data name=">>okButton.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>$this.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Form, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>label1.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>copyButton.ZOrder" xml:space="preserve">
|
||||
<value>0</value>
|
||||
</data>
|
||||
<data name="okButton.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>12</value>
|
||||
</data>
|
||||
<data name="addButton.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>16</value>
|
||||
</data>
|
||||
<data name="label1.Text" xml:space="preserve">
|
||||
<value>Test Benches :</value>
|
||||
</data>
|
||||
<metadata name="$this.Localizable" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="$this.Language" type="System.Globalization.CultureInfo, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>de</value>
|
||||
</metadata>
|
||||
</root>
|
||||
@@ -0,0 +1,28 @@
|
||||
using System;
|
||||
|
||||
namespace ResultsBrowser
|
||||
{
|
||||
/// <summary>
|
||||
/// Database settings required to make a connection
|
||||
/// </summary>
|
||||
public class DBSettings : ICloneable
|
||||
{
|
||||
public DBType DbType;
|
||||
public string ConnectionString;
|
||||
|
||||
public DBSettings()
|
||||
{
|
||||
}
|
||||
|
||||
public DBSettings(DBType dbType, string connectionString)
|
||||
{
|
||||
this.DbType = dbType;
|
||||
this.ConnectionString = connectionString;
|
||||
}
|
||||
|
||||
public object Clone()
|
||||
{
|
||||
return new DBSettings(DbType, ConnectionString);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,48 @@
|
||||
using System;
|
||||
using System.Text;
|
||||
using System.Xml.Serialization;
|
||||
|
||||
namespace ResultsBrowser
|
||||
{
|
||||
/// <summary>
|
||||
/// Test bench database settings, contains bench name and settings od several databases
|
||||
/// </summary>
|
||||
public class DatabaseSettings : ICloneable
|
||||
{
|
||||
// Public fields
|
||||
public string BenchName;
|
||||
public bool IsRealBench;
|
||||
public DBSettings UsersDBSettings;
|
||||
public DBSettings BenchDBSettings;
|
||||
public DBSettings ProceduresDBSettings;
|
||||
public DBSettings WMTypesDBSettings;
|
||||
public DBSettings WaterMetersDBSettings;
|
||||
|
||||
// Constructor
|
||||
public DatabaseSettings()
|
||||
{
|
||||
BenchName = String.Empty; /// Empty string to avoid null
|
||||
IsRealBench = false;
|
||||
UsersDBSettings = new DBSettings(DBType.MySql, "SERVER=localhost; DATABASE=tbf_users; UID=root; PASSWORD=;");
|
||||
BenchDBSettings = new DBSettings(DBType.MySql, "SERVER=localhost; DATABASE=tbf_bench; UID=root; PASSWORD=;");
|
||||
ProceduresDBSettings = new DBSettings(DBType.MySql, "SERVER=localhost; DATABASE=tbf_procedures; UID=root; PASSWORD=;");
|
||||
WMTypesDBSettings = new DBSettings(DBType.MySql, "SERVER=localhost; DATABASE=tbf_wmtypes; UID=root; PASSWORD=;");
|
||||
WaterMetersDBSettings = new DBSettings(DBType.MySql, "SERVER=localhost; DATABASE=tbf_watermeters; UID=root; PASSWORD=;");
|
||||
}
|
||||
|
||||
public object Clone()
|
||||
{
|
||||
DatabaseSettings result = new DatabaseSettings();
|
||||
|
||||
result.BenchName = BenchName;
|
||||
result.IsRealBench = IsRealBench;
|
||||
result.UsersDBSettings = (DBSettings)UsersDBSettings.Clone();
|
||||
result.BenchDBSettings = (DBSettings)BenchDBSettings.Clone();
|
||||
result.ProceduresDBSettings = (DBSettings)ProceduresDBSettings.Clone();
|
||||
result.WMTypesDBSettings = (DBSettings)WMTypesDBSettings.Clone();
|
||||
result.WaterMetersDBSettings = (DBSettings)WaterMetersDBSettings.Clone();
|
||||
|
||||
return result;
|
||||
}
|
||||
}
|
||||
}
|
||||
+370
@@ -0,0 +1,370 @@
|
||||
namespace ResultsBrowser
|
||||
{
|
||||
partial class DatabaseSettingsDlg
|
||||
{
|
||||
/// <summary>
|
||||
/// Required designer variable.
|
||||
/// </summary>
|
||||
private System.ComponentModel.IContainer components = null;
|
||||
|
||||
/// <summary>
|
||||
/// Clean up any resources being used.
|
||||
/// </summary>
|
||||
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
|
||||
protected override void Dispose(bool disposing)
|
||||
{
|
||||
if (disposing && (components != null))
|
||||
{
|
||||
components.Dispose();
|
||||
}
|
||||
base.Dispose(disposing);
|
||||
}
|
||||
|
||||
#region Windows Form Designer generated code
|
||||
|
||||
/// <summary>
|
||||
/// Required method for Designer support - do not modify
|
||||
/// the contents of this method with the code editor.
|
||||
/// </summary>
|
||||
private void InitializeComponent()
|
||||
{
|
||||
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(DatabaseSettingsDlg));
|
||||
this.okButton = new System.Windows.Forms.Button();
|
||||
this.cancelButton = new System.Windows.Forms.Button();
|
||||
this.label1 = new System.Windows.Forms.Label();
|
||||
this.benchNameTextBox = new System.Windows.Forms.TextBox();
|
||||
this.usersConnectionStringTextBox = new System.Windows.Forms.TextBox();
|
||||
this.connectionStringLabel = new System.Windows.Forms.Label();
|
||||
this.benchConnectionStringTextBox = new System.Windows.Forms.TextBox();
|
||||
this.proceduresConnectionStringTextBox = new System.Windows.Forms.TextBox();
|
||||
this.wmTypesConnectionStringTextBox = new System.Windows.Forms.TextBox();
|
||||
this.watermetersConnectionStringTextBox = new System.Windows.Forms.TextBox();
|
||||
this.label2 = new System.Windows.Forms.Label();
|
||||
this.label3 = new System.Windows.Forms.Label();
|
||||
this.label4 = new System.Windows.Forms.Label();
|
||||
this.label5 = new System.Windows.Forms.Label();
|
||||
this.label6 = new System.Windows.Forms.Label();
|
||||
this.testConnUsersBtn = new System.Windows.Forms.Button();
|
||||
this.createUsersDbBtn = new System.Windows.Forms.Button();
|
||||
this.realBenchCheckBox = new System.Windows.Forms.CheckBox();
|
||||
this.dbTypeLabel = new System.Windows.Forms.Label();
|
||||
this.usersDbTypeComboBox = new System.Windows.Forms.ComboBox();
|
||||
this.benchDbTypeComboBox = new System.Windows.Forms.ComboBox();
|
||||
this.proceduresDbTypeComboBox = new System.Windows.Forms.ComboBox();
|
||||
this.wmTypesDbTypeComboBox = new System.Windows.Forms.ComboBox();
|
||||
this.watermetersDbTypeComboBox = new System.Windows.Forms.ComboBox();
|
||||
this.testConnBenchBtn = new System.Windows.Forms.Button();
|
||||
this.testConnProceduresBtn = new System.Windows.Forms.Button();
|
||||
this.testConnWMTypesBtn = new System.Windows.Forms.Button();
|
||||
this.testConnWaterMetersBtn = new System.Windows.Forms.Button();
|
||||
this.createBenchDbBtn = new System.Windows.Forms.Button();
|
||||
this.createProceduresDbBtn = new System.Windows.Forms.Button();
|
||||
this.createWMTypesDbBtn = new System.Windows.Forms.Button();
|
||||
this.createWaterMetersDbBtn = new System.Windows.Forms.Button();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// okButton
|
||||
//
|
||||
this.okButton.DialogResult = System.Windows.Forms.DialogResult.OK;
|
||||
this.okButton.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
resources.ApplyResources(this.okButton, "okButton");
|
||||
this.okButton.Name = "okButton";
|
||||
this.okButton.UseVisualStyleBackColor = true;
|
||||
this.okButton.Click += new System.EventHandler(this.okButton_Click);
|
||||
//
|
||||
// cancelButton
|
||||
//
|
||||
this.cancelButton.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
||||
this.cancelButton.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
resources.ApplyResources(this.cancelButton, "cancelButton");
|
||||
this.cancelButton.Name = "cancelButton";
|
||||
this.cancelButton.UseVisualStyleBackColor = true;
|
||||
this.cancelButton.Click += new System.EventHandler(this.cancelButton_Click);
|
||||
//
|
||||
// label1
|
||||
//
|
||||
resources.ApplyResources(this.label1, "label1");
|
||||
this.label1.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
this.label1.Name = "label1";
|
||||
//
|
||||
// benchNameTextBox
|
||||
//
|
||||
resources.ApplyResources(this.benchNameTextBox, "benchNameTextBox");
|
||||
this.benchNameTextBox.Name = "benchNameTextBox";
|
||||
//
|
||||
// usersConnectionStringTextBox
|
||||
//
|
||||
resources.ApplyResources(this.usersConnectionStringTextBox, "usersConnectionStringTextBox");
|
||||
this.usersConnectionStringTextBox.Name = "usersConnectionStringTextBox";
|
||||
//
|
||||
// connectionStringLabel
|
||||
//
|
||||
resources.ApplyResources(this.connectionStringLabel, "connectionStringLabel");
|
||||
this.connectionStringLabel.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
this.connectionStringLabel.Name = "connectionStringLabel";
|
||||
//
|
||||
// benchConnectionStringTextBox
|
||||
//
|
||||
resources.ApplyResources(this.benchConnectionStringTextBox, "benchConnectionStringTextBox");
|
||||
this.benchConnectionStringTextBox.Name = "benchConnectionStringTextBox";
|
||||
//
|
||||
// proceduresConnectionStringTextBox
|
||||
//
|
||||
resources.ApplyResources(this.proceduresConnectionStringTextBox, "proceduresConnectionStringTextBox");
|
||||
this.proceduresConnectionStringTextBox.Name = "proceduresConnectionStringTextBox";
|
||||
//
|
||||
// wmTypesConnectionStringTextBox
|
||||
//
|
||||
resources.ApplyResources(this.wmTypesConnectionStringTextBox, "wmTypesConnectionStringTextBox");
|
||||
this.wmTypesConnectionStringTextBox.Name = "wmTypesConnectionStringTextBox";
|
||||
//
|
||||
// watermetersConnectionStringTextBox
|
||||
//
|
||||
resources.ApplyResources(this.watermetersConnectionStringTextBox, "watermetersConnectionStringTextBox");
|
||||
this.watermetersConnectionStringTextBox.Name = "watermetersConnectionStringTextBox";
|
||||
//
|
||||
// label2
|
||||
//
|
||||
resources.ApplyResources(this.label2, "label2");
|
||||
this.label2.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
this.label2.Name = "label2";
|
||||
//
|
||||
// label3
|
||||
//
|
||||
resources.ApplyResources(this.label3, "label3");
|
||||
this.label3.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
this.label3.Name = "label3";
|
||||
//
|
||||
// label4
|
||||
//
|
||||
resources.ApplyResources(this.label4, "label4");
|
||||
this.label4.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
this.label4.Name = "label4";
|
||||
//
|
||||
// label5
|
||||
//
|
||||
resources.ApplyResources(this.label5, "label5");
|
||||
this.label5.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
this.label5.Name = "label5";
|
||||
//
|
||||
// label6
|
||||
//
|
||||
resources.ApplyResources(this.label6, "label6");
|
||||
this.label6.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
this.label6.Name = "label6";
|
||||
//
|
||||
// testConnUsersBtn
|
||||
//
|
||||
this.testConnUsersBtn.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
||||
this.testConnUsersBtn.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
resources.ApplyResources(this.testConnUsersBtn, "testConnUsersBtn");
|
||||
this.testConnUsersBtn.Name = "testConnUsersBtn";
|
||||
this.testConnUsersBtn.UseVisualStyleBackColor = true;
|
||||
this.testConnUsersBtn.Click += new System.EventHandler(this.testConnUsersBtn_Click);
|
||||
//
|
||||
// createUsersDbBtn
|
||||
//
|
||||
this.createUsersDbBtn.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
||||
this.createUsersDbBtn.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
resources.ApplyResources(this.createUsersDbBtn, "createUsersDbBtn");
|
||||
this.createUsersDbBtn.Name = "createUsersDbBtn";
|
||||
this.createUsersDbBtn.UseVisualStyleBackColor = true;
|
||||
this.createUsersDbBtn.Click += new System.EventHandler(this.createDatabasesButton_Click);
|
||||
//
|
||||
// realBenchCheckBox
|
||||
//
|
||||
resources.ApplyResources(this.realBenchCheckBox, "realBenchCheckBox");
|
||||
this.realBenchCheckBox.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
this.realBenchCheckBox.Name = "realBenchCheckBox";
|
||||
this.realBenchCheckBox.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// dbTypeLabel
|
||||
//
|
||||
resources.ApplyResources(this.dbTypeLabel, "dbTypeLabel");
|
||||
this.dbTypeLabel.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
this.dbTypeLabel.Name = "dbTypeLabel";
|
||||
//
|
||||
// usersDbTypeComboBox
|
||||
//
|
||||
this.usersDbTypeComboBox.FormattingEnabled = true;
|
||||
resources.ApplyResources(this.usersDbTypeComboBox, "usersDbTypeComboBox");
|
||||
this.usersDbTypeComboBox.Name = "usersDbTypeComboBox";
|
||||
//
|
||||
// benchDbTypeComboBox
|
||||
//
|
||||
this.benchDbTypeComboBox.FormattingEnabled = true;
|
||||
resources.ApplyResources(this.benchDbTypeComboBox, "benchDbTypeComboBox");
|
||||
this.benchDbTypeComboBox.Name = "benchDbTypeComboBox";
|
||||
//
|
||||
// proceduresDbTypeComboBox
|
||||
//
|
||||
this.proceduresDbTypeComboBox.FormattingEnabled = true;
|
||||
resources.ApplyResources(this.proceduresDbTypeComboBox, "proceduresDbTypeComboBox");
|
||||
this.proceduresDbTypeComboBox.Name = "proceduresDbTypeComboBox";
|
||||
//
|
||||
// wmTypesDbTypeComboBox
|
||||
//
|
||||
this.wmTypesDbTypeComboBox.FormattingEnabled = true;
|
||||
resources.ApplyResources(this.wmTypesDbTypeComboBox, "wmTypesDbTypeComboBox");
|
||||
this.wmTypesDbTypeComboBox.Name = "wmTypesDbTypeComboBox";
|
||||
//
|
||||
// watermetersDbTypeComboBox
|
||||
//
|
||||
this.watermetersDbTypeComboBox.FormattingEnabled = true;
|
||||
resources.ApplyResources(this.watermetersDbTypeComboBox, "watermetersDbTypeComboBox");
|
||||
this.watermetersDbTypeComboBox.Name = "watermetersDbTypeComboBox";
|
||||
//
|
||||
// testConnBenchBtn
|
||||
//
|
||||
this.testConnBenchBtn.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
||||
this.testConnBenchBtn.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
resources.ApplyResources(this.testConnBenchBtn, "testConnBenchBtn");
|
||||
this.testConnBenchBtn.Name = "testConnBenchBtn";
|
||||
this.testConnBenchBtn.UseVisualStyleBackColor = true;
|
||||
this.testConnBenchBtn.Click += new System.EventHandler(this.testConnBenchBtn_Click);
|
||||
//
|
||||
// testConnProceduresBtn
|
||||
//
|
||||
this.testConnProceduresBtn.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
||||
this.testConnProceduresBtn.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
resources.ApplyResources(this.testConnProceduresBtn, "testConnProceduresBtn");
|
||||
this.testConnProceduresBtn.Name = "testConnProceduresBtn";
|
||||
this.testConnProceduresBtn.UseVisualStyleBackColor = true;
|
||||
this.testConnProceduresBtn.Click += new System.EventHandler(this.testConnProceduresBtn_Click);
|
||||
//
|
||||
// testConnWMTypesBtn
|
||||
//
|
||||
this.testConnWMTypesBtn.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
||||
this.testConnWMTypesBtn.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
resources.ApplyResources(this.testConnWMTypesBtn, "testConnWMTypesBtn");
|
||||
this.testConnWMTypesBtn.Name = "testConnWMTypesBtn";
|
||||
this.testConnWMTypesBtn.UseVisualStyleBackColor = true;
|
||||
this.testConnWMTypesBtn.Click += new System.EventHandler(this.testConnWMTypesBtn_Click);
|
||||
//
|
||||
// testConnWaterMetersBtn
|
||||
//
|
||||
this.testConnWaterMetersBtn.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
||||
this.testConnWaterMetersBtn.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
resources.ApplyResources(this.testConnWaterMetersBtn, "testConnWaterMetersBtn");
|
||||
this.testConnWaterMetersBtn.Name = "testConnWaterMetersBtn";
|
||||
this.testConnWaterMetersBtn.UseVisualStyleBackColor = true;
|
||||
this.testConnWaterMetersBtn.Click += new System.EventHandler(this.testConnWaterMetersBtn_Click);
|
||||
//
|
||||
// createBenchDbBtn
|
||||
//
|
||||
this.createBenchDbBtn.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
||||
this.createBenchDbBtn.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
resources.ApplyResources(this.createBenchDbBtn, "createBenchDbBtn");
|
||||
this.createBenchDbBtn.Name = "createBenchDbBtn";
|
||||
this.createBenchDbBtn.UseVisualStyleBackColor = true;
|
||||
this.createBenchDbBtn.Click += new System.EventHandler(this.createbenchDbBtn_Click);
|
||||
//
|
||||
// createProceduresDbBtn
|
||||
//
|
||||
this.createProceduresDbBtn.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
||||
this.createProceduresDbBtn.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
resources.ApplyResources(this.createProceduresDbBtn, "createProceduresDbBtn");
|
||||
this.createProceduresDbBtn.Name = "createProceduresDbBtn";
|
||||
this.createProceduresDbBtn.UseVisualStyleBackColor = true;
|
||||
this.createProceduresDbBtn.Click += new System.EventHandler(this.createProecduresDbBtn_Click);
|
||||
//
|
||||
// createWMTypesDbBtn
|
||||
//
|
||||
this.createWMTypesDbBtn.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
||||
this.createWMTypesDbBtn.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
resources.ApplyResources(this.createWMTypesDbBtn, "createWMTypesDbBtn");
|
||||
this.createWMTypesDbBtn.Name = "createWMTypesDbBtn";
|
||||
this.createWMTypesDbBtn.UseVisualStyleBackColor = true;
|
||||
this.createWMTypesDbBtn.Click += new System.EventHandler(this.createWMTypesDbBtn_Click);
|
||||
//
|
||||
// createWaterMetersDbBtn
|
||||
//
|
||||
this.createWaterMetersDbBtn.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
||||
this.createWaterMetersDbBtn.ImageKey = global::TBF.Resources.Strings.String1;
|
||||
resources.ApplyResources(this.createWaterMetersDbBtn, "createWaterMetersDbBtn");
|
||||
this.createWaterMetersDbBtn.Name = "createWaterMetersDbBtn";
|
||||
this.createWaterMetersDbBtn.UseVisualStyleBackColor = true;
|
||||
this.createWaterMetersDbBtn.Click += new System.EventHandler(this.createWaterMetersDbBtn_Click);
|
||||
//
|
||||
// DatabaseSettingsDlg
|
||||
//
|
||||
resources.ApplyResources(this, "$this");
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.Controls.Add(this.createWaterMetersDbBtn);
|
||||
this.Controls.Add(this.createWMTypesDbBtn);
|
||||
this.Controls.Add(this.createProceduresDbBtn);
|
||||
this.Controls.Add(this.createBenchDbBtn);
|
||||
this.Controls.Add(this.testConnWaterMetersBtn);
|
||||
this.Controls.Add(this.testConnWMTypesBtn);
|
||||
this.Controls.Add(this.testConnProceduresBtn);
|
||||
this.Controls.Add(this.testConnBenchBtn);
|
||||
this.Controls.Add(this.watermetersDbTypeComboBox);
|
||||
this.Controls.Add(this.wmTypesDbTypeComboBox);
|
||||
this.Controls.Add(this.proceduresDbTypeComboBox);
|
||||
this.Controls.Add(this.benchDbTypeComboBox);
|
||||
this.Controls.Add(this.usersDbTypeComboBox);
|
||||
this.Controls.Add(this.dbTypeLabel);
|
||||
this.Controls.Add(this.realBenchCheckBox);
|
||||
this.Controls.Add(this.createUsersDbBtn);
|
||||
this.Controls.Add(this.testConnUsersBtn);
|
||||
this.Controls.Add(this.label6);
|
||||
this.Controls.Add(this.label5);
|
||||
this.Controls.Add(this.label4);
|
||||
this.Controls.Add(this.label3);
|
||||
this.Controls.Add(this.label2);
|
||||
this.Controls.Add(this.watermetersConnectionStringTextBox);
|
||||
this.Controls.Add(this.wmTypesConnectionStringTextBox);
|
||||
this.Controls.Add(this.proceduresConnectionStringTextBox);
|
||||
this.Controls.Add(this.benchConnectionStringTextBox);
|
||||
this.Controls.Add(this.connectionStringLabel);
|
||||
this.Controls.Add(this.usersConnectionStringTextBox);
|
||||
this.Controls.Add(this.benchNameTextBox);
|
||||
this.Controls.Add(this.label1);
|
||||
this.Controls.Add(this.okButton);
|
||||
this.Controls.Add(this.cancelButton);
|
||||
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
|
||||
this.MinimizeBox = false;
|
||||
this.Name = "DatabaseSettingsDlg";
|
||||
this.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide;
|
||||
this.Load += new System.EventHandler(this.BenchSettingsDlg_Load);
|
||||
this.ResumeLayout(false);
|
||||
this.PerformLayout();
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private System.Windows.Forms.Button okButton;
|
||||
private System.Windows.Forms.Button cancelButton;
|
||||
private System.Windows.Forms.Label label1;
|
||||
private System.Windows.Forms.TextBox benchNameTextBox;
|
||||
private System.Windows.Forms.TextBox usersConnectionStringTextBox;
|
||||
private System.Windows.Forms.Label connectionStringLabel;
|
||||
private System.Windows.Forms.TextBox benchConnectionStringTextBox;
|
||||
private System.Windows.Forms.TextBox proceduresConnectionStringTextBox;
|
||||
private System.Windows.Forms.TextBox wmTypesConnectionStringTextBox;
|
||||
private System.Windows.Forms.TextBox watermetersConnectionStringTextBox;
|
||||
private System.Windows.Forms.Label label2;
|
||||
private System.Windows.Forms.Label label3;
|
||||
private System.Windows.Forms.Label label4;
|
||||
private System.Windows.Forms.Label label5;
|
||||
private System.Windows.Forms.Label label6;
|
||||
private System.Windows.Forms.Button testConnUsersBtn;
|
||||
private System.Windows.Forms.Button createUsersDbBtn;
|
||||
private System.Windows.Forms.CheckBox realBenchCheckBox;
|
||||
private System.Windows.Forms.Label dbTypeLabel;
|
||||
private System.Windows.Forms.ComboBox usersDbTypeComboBox;
|
||||
private System.Windows.Forms.ComboBox benchDbTypeComboBox;
|
||||
private System.Windows.Forms.ComboBox proceduresDbTypeComboBox;
|
||||
private System.Windows.Forms.ComboBox wmTypesDbTypeComboBox;
|
||||
private System.Windows.Forms.ComboBox watermetersDbTypeComboBox;
|
||||
private System.Windows.Forms.Button testConnBenchBtn;
|
||||
private System.Windows.Forms.Button testConnProceduresBtn;
|
||||
private System.Windows.Forms.Button testConnWMTypesBtn;
|
||||
private System.Windows.Forms.Button testConnWaterMetersBtn;
|
||||
private System.Windows.Forms.Button createBenchDbBtn;
|
||||
private System.Windows.Forms.Button createProceduresDbBtn;
|
||||
private System.Windows.Forms.Button createWMTypesDbBtn;
|
||||
private System.Windows.Forms.Button createWaterMetersDbBtn;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,261 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Text;
|
||||
using System.Windows.Forms;
|
||||
using TBF.Resources;
|
||||
|
||||
namespace TBF
|
||||
{
|
||||
/// <summary>
|
||||
/// Dialog to process test bench name and database settings (BenchSettings)
|
||||
/// </summary>
|
||||
public partial class DatabaseSettingsDlg : Form
|
||||
{
|
||||
// Reference to bench DB settins (not a local copy)
|
||||
DatabaseSettings bench;
|
||||
|
||||
/// <summary>
|
||||
/// Constructor
|
||||
/// </summary>
|
||||
/// <param name="bench">Test bench database settings</param>
|
||||
public DatabaseSettingsDlg(DatabaseSettings bench)
|
||||
{
|
||||
this.bench = bench;
|
||||
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
void Localize()
|
||||
{
|
||||
Text = Strings.Test_Bench_Databases_Specification;
|
||||
label1.Text = Strings.Test_bench_name;
|
||||
realBenchCheckBox.Text = Strings.Test_bench_is_controlled_by_this_computer;
|
||||
dbTypeLabel.Text = Strings.Database_type;
|
||||
connectionStringLabel.Text = Strings.Connection_string;
|
||||
label2.Text = Strings.Users_and_groups;
|
||||
label3.Text = Strings.Bench_parameters;
|
||||
label4.Text = Strings.Procedures;
|
||||
label5.Text = Strings.Water_meter_types;
|
||||
label6.Text = Strings.Water_meter_data;
|
||||
okButton.Text = Strings.OkBtnText;
|
||||
cancelButton.Text = Strings.CancelBtnText;
|
||||
|
||||
testConnBenchBtn.Text = Strings.Test_connection;
|
||||
testConnProceduresBtn.Text = Strings.Test_connection;
|
||||
testConnUsersBtn.Text = Strings.Test_connection;
|
||||
testConnWaterMetersBtn.Text = Strings.Test_connection;
|
||||
testConnWMTypesBtn.Text = Strings.Test_connection;
|
||||
|
||||
createBenchDbBtn.Text = Strings.Create_DB;
|
||||
createProceduresDbBtn.Text = Strings.Create_DB;
|
||||
createUsersDbBtn.Text = Strings.Create_DB;
|
||||
createWaterMetersDbBtn.Text = Strings.Create_DB;
|
||||
createWMTypesDbBtn.Text = Strings.Create_DB;
|
||||
}
|
||||
|
||||
private void BenchSettingsDlg_Load(object sender, EventArgs e)
|
||||
{
|
||||
Localize();
|
||||
|
||||
benchNameTextBox.Text = bench.BenchName;
|
||||
realBenchCheckBox.Checked = bench.IsRealBench;
|
||||
|
||||
/// Initialize 'Database type' combo-boxes
|
||||
for (int i = 0; i < (int)DBType.DbTypesCount; i++)
|
||||
{
|
||||
DBType dbType = (DBType)i;
|
||||
usersDbTypeComboBox.Items.Add(dbType);
|
||||
benchDbTypeComboBox.Items.Add(dbType);
|
||||
proceduresDbTypeComboBox.Items.Add(dbType);
|
||||
wmTypesDbTypeComboBox.Items.Add(dbType);
|
||||
watermetersDbTypeComboBox.Items.Add(dbType);
|
||||
}
|
||||
usersDbTypeComboBox.SelectedIndex = (int)bench.UsersDBSettings.DbType;
|
||||
benchDbTypeComboBox.SelectedIndex = (int)bench.BenchDBSettings.DbType;
|
||||
proceduresDbTypeComboBox.SelectedIndex = (int)bench.ProceduresDBSettings.DbType;
|
||||
wmTypesDbTypeComboBox.SelectedIndex = (int)bench.WMTypesDBSettings.DbType;
|
||||
watermetersDbTypeComboBox.SelectedIndex = (int)bench.WaterMetersDBSettings.DbType;
|
||||
|
||||
/// Initialize connection strings
|
||||
usersConnectionStringTextBox.Text = bench.UsersDBSettings.ConnectionString;
|
||||
benchConnectionStringTextBox.Text = bench.BenchDBSettings.ConnectionString;
|
||||
proceduresConnectionStringTextBox.Text = bench.ProceduresDBSettings.ConnectionString;
|
||||
wmTypesConnectionStringTextBox.Text = bench.WMTypesDBSettings.ConnectionString;
|
||||
watermetersConnectionStringTextBox.Text = bench.WaterMetersDBSettings.ConnectionString;
|
||||
}
|
||||
|
||||
bool UpdateBenchFromUIControls()
|
||||
{
|
||||
for (int i = 0; i < Program.LocalSettings.BenchesCount; i++)
|
||||
{
|
||||
if (bench != Program.LocalSettings.TestBenches[i] &&
|
||||
benchNameTextBox.Text == Program.LocalSettings.TestBenches[i].BenchName)
|
||||
{
|
||||
MessageBox.Show(Strings.Bench_name_conflict_Use_another_name_pls, Strings.Error, MessageBoxButtons.OK);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
bench.BenchName = benchNameTextBox.Text;
|
||||
bench.IsRealBench = realBenchCheckBox.Checked;
|
||||
|
||||
bench.UsersDBSettings.ConnectionString = usersConnectionStringTextBox.Text;
|
||||
bench.BenchDBSettings.ConnectionString = benchConnectionStringTextBox.Text;
|
||||
bench.ProceduresDBSettings.ConnectionString = proceduresConnectionStringTextBox.Text;
|
||||
bench.WMTypesDBSettings.ConnectionString = wmTypesConnectionStringTextBox.Text;
|
||||
bench.WaterMetersDBSettings.ConnectionString = watermetersConnectionStringTextBox.Text;
|
||||
|
||||
bench.UsersDBSettings.DbType = (DBType)usersDbTypeComboBox.SelectedIndex;
|
||||
bench.BenchDBSettings.DbType = (DBType)benchDbTypeComboBox.SelectedIndex;
|
||||
bench.ProceduresDBSettings.DbType = (DBType)proceduresDbTypeComboBox.SelectedIndex;
|
||||
bench.WMTypesDBSettings.DbType = (DBType)wmTypesDbTypeComboBox.SelectedIndex;
|
||||
bench.WaterMetersDBSettings.DbType = (DBType)watermetersDbTypeComboBox.SelectedIndex;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Update bench DB setting, return 'OK'
|
||||
/// </summary>
|
||||
/// <param name="sender">Not used</param>
|
||||
/// <param name="e">Not used</param>
|
||||
private void okButton_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (UpdateBenchFromUIControls())
|
||||
{
|
||||
DialogResult = DialogResult.OK;
|
||||
Close();
|
||||
return;
|
||||
}
|
||||
|
||||
DialogResult = DialogResult.None;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Throw away changes, return 'Cancel'
|
||||
/// </summary>
|
||||
/// <param name="sender">Not used</param>
|
||||
/// <param name="e">Not used</param>
|
||||
private void cancelButton_Click(object sender, EventArgs e)
|
||||
{
|
||||
DialogResult = DialogResult.Cancel;
|
||||
Close();
|
||||
}
|
||||
|
||||
private void createDatabasesButton_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (!UpdateBenchFromUIControls()) return;
|
||||
|
||||
if (DialogResult.OK == MessageBox.Show(Strings.DB_will_be_overwritten + Environment.NewLine +
|
||||
Strings.Do_you_want_to_proceed, Strings.Warning,
|
||||
MessageBoxButtons.OKCancel, MessageBoxIcon.Exclamation))
|
||||
try
|
||||
{
|
||||
Cursor.Current = Cursors.WaitCursor;
|
||||
FluentCommon.CreateEmptyUsersDB(bench.UsersDBSettings);
|
||||
MessageBox.Show(Strings.DB_was_successfully_created, Strings.Notification);
|
||||
Cursor.Current = Cursors.Default;
|
||||
DialogResult = DialogResult.None;
|
||||
}
|
||||
catch (Exception exception)
|
||||
{
|
||||
Cursor.Current = Cursors.Default;
|
||||
MessageBox.Show(Strings.Error_while_creating_DB_Reason + exception.Message, Strings.Error);
|
||||
}
|
||||
}
|
||||
|
||||
private void createbenchDbBtn_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (!UpdateBenchFromUIControls()) return;
|
||||
|
||||
if (DialogResult.OK == MessageBox.Show(Strings.DB_will_be_overwritten + Environment.NewLine +
|
||||
Strings.Do_you_want_to_proceed, Strings.Warning,
|
||||
MessageBoxButtons.OKCancel, MessageBoxIcon.Exclamation))
|
||||
try
|
||||
{
|
||||
Cursor.Current = Cursors.WaitCursor;
|
||||
FluentCommon.CreateEmptyBenchDB(bench.BenchDBSettings);
|
||||
MessageBox.Show(Strings.DB_was_successfully_created, Strings.Notification);
|
||||
Cursor.Current = Cursors.Default;
|
||||
DialogResult = DialogResult.None;
|
||||
}
|
||||
catch (Exception exception)
|
||||
{
|
||||
Cursor.Current = Cursors.Default;
|
||||
MessageBox.Show(Strings.Error_while_creating_DB_Reason + exception.Message, Strings.Error);
|
||||
}
|
||||
}
|
||||
|
||||
private void createProecduresDbBtn_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (!UpdateBenchFromUIControls()) return;
|
||||
|
||||
if (DialogResult.OK == MessageBox.Show(Strings.DB_will_be_overwritten + Environment.NewLine +
|
||||
Strings.Do_you_want_to_proceed, Strings.Warning,
|
||||
MessageBoxButtons.OKCancel, MessageBoxIcon.Exclamation))
|
||||
try
|
||||
{
|
||||
Cursor.Current = Cursors.WaitCursor;
|
||||
FluentCommon.CreateEmptyProceduresDB(bench.ProceduresDBSettings);
|
||||
MessageBox.Show(Strings.DB_was_successfully_created, Strings.Notification);
|
||||
Cursor.Current = Cursors.Default;
|
||||
DialogResult = DialogResult.None;
|
||||
}
|
||||
catch (Exception exception)
|
||||
{
|
||||
Cursor.Current = Cursors.Default;
|
||||
MessageBox.Show(Strings.Error_while_creating_DB_Reason + exception.Message, Strings.Error);
|
||||
}
|
||||
}
|
||||
|
||||
private void createWMTypesDbBtn_Click(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
private void createWaterMetersDbBtn_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (!UpdateBenchFromUIControls()) return;
|
||||
|
||||
if (DialogResult.OK == MessageBox.Show(Strings.DB_will_be_overwritten + Environment.NewLine +
|
||||
Strings.Do_you_want_to_proceed, Strings.Warning,
|
||||
MessageBoxButtons.OKCancel, MessageBoxIcon.Exclamation))
|
||||
try
|
||||
{
|
||||
Cursor.Current = Cursors.WaitCursor;
|
||||
FluentCommon.CreateEmptyWaterMetersDB(bench.WaterMetersDBSettings);
|
||||
MessageBox.Show(Strings.DB_was_successfully_created, Strings.Notification);
|
||||
Cursor.Current = Cursors.Default;
|
||||
DialogResult = DialogResult.None;
|
||||
}
|
||||
catch (Exception exception)
|
||||
{
|
||||
Cursor.Current = Cursors.Default;
|
||||
MessageBox.Show(Strings.Error_while_creating_DB_Reason + exception.Message, Strings.Error);
|
||||
}
|
||||
}
|
||||
|
||||
private void testConnUsersBtn_Click(object sender, EventArgs e)
|
||||
{
|
||||
}
|
||||
|
||||
private void testConnBenchBtn_Click(object sender, EventArgs e)
|
||||
{
|
||||
}
|
||||
|
||||
private void testConnProceduresBtn_Click(object sender, EventArgs e)
|
||||
{
|
||||
}
|
||||
|
||||
private void testConnWMTypesBtn_Click(object sender, EventArgs e)
|
||||
{
|
||||
}
|
||||
|
||||
private void testConnWaterMetersBtn_Click(object sender, EventArgs e)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
+535
-298
@@ -122,7 +122,7 @@
|
||||
<value>614, 15</value>
|
||||
</data>
|
||||
<data name="okButton.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>225, 28</value>
|
||||
<value>217, 28</value>
|
||||
</data>
|
||||
<assembly alias="mscorlib" name="mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
|
||||
<data name="okButton.TabIndex" type="System.Int32, mscorlib">
|
||||
@@ -141,13 +141,13 @@
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>okButton.ZOrder" xml:space="preserve">
|
||||
<value>20</value>
|
||||
<value>30</value>
|
||||
</data>
|
||||
<data name="cancelButton.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>614, 49</value>
|
||||
</data>
|
||||
<data name="cancelButton.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>225, 28</value>
|
||||
<value>217, 28</value>
|
||||
</data>
|
||||
<data name="cancelButton.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>13</value>
|
||||
@@ -165,7 +165,7 @@
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>cancelButton.ZOrder" xml:space="preserve">
|
||||
<value>21</value>
|
||||
<value>31</value>
|
||||
</data>
|
||||
<data name="label1.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
@@ -192,7 +192,7 @@
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>label1.ZOrder" xml:space="preserve">
|
||||
<value>19</value>
|
||||
<value>29</value>
|
||||
</data>
|
||||
<data name="benchNameTextBox.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>116, 15</value>
|
||||
@@ -213,7 +213,28 @@
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>benchNameTextBox.ZOrder" xml:space="preserve">
|
||||
<value>18</value>
|
||||
<value>28</value>
|
||||
</data>
|
||||
<data name="usersConnectionStringTextBox.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>202, 101</value>
|
||||
</data>
|
||||
<data name="usersConnectionStringTextBox.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>406, 20</value>
|
||||
</data>
|
||||
<data name="usersConnectionStringTextBox.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>17</value>
|
||||
</data>
|
||||
<data name=">>usersConnectionStringTextBox.Name" xml:space="preserve">
|
||||
<value>usersConnectionStringTextBox</value>
|
||||
</data>
|
||||
<data name=">>usersConnectionStringTextBox.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>usersConnectionStringTextBox.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>usersConnectionStringTextBox.ZOrder" xml:space="preserve">
|
||||
<value>27</value>
|
||||
</data>
|
||||
<data name="connectionStringLabel.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
@@ -240,103 +261,274 @@
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>connectionStringLabel.ZOrder" xml:space="preserve">
|
||||
<value>17</value>
|
||||
<value>26</value>
|
||||
</data>
|
||||
<data name="configDbConnectionStringTextBox.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>202, 107</value>
|
||||
<data name="benchConnectionStringTextBox.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>202, 127</value>
|
||||
</data>
|
||||
<data name="configDbConnectionStringTextBox.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<data name="benchConnectionStringTextBox.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>406, 20</value>
|
||||
</data>
|
||||
<data name="configDbConnectionStringTextBox.TabIndex" type="System.Int32, mscorlib">
|
||||
<data name="benchConnectionStringTextBox.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>19</value>
|
||||
</data>
|
||||
<data name=">>benchConnectionStringTextBox.Name" xml:space="preserve">
|
||||
<value>benchConnectionStringTextBox</value>
|
||||
</data>
|
||||
<data name=">>benchConnectionStringTextBox.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>benchConnectionStringTextBox.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>benchConnectionStringTextBox.ZOrder" xml:space="preserve">
|
||||
<value>25</value>
|
||||
</data>
|
||||
<data name="proceduresConnectionStringTextBox.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>202, 153</value>
|
||||
</data>
|
||||
<data name="proceduresConnectionStringTextBox.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>406, 20</value>
|
||||
</data>
|
||||
<data name="proceduresConnectionStringTextBox.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>20</value>
|
||||
</data>
|
||||
<data name=">>configDbConnectionStringTextBox.Name" xml:space="preserve">
|
||||
<value>configDbConnectionStringTextBox</value>
|
||||
<data name=">>proceduresConnectionStringTextBox.Name" xml:space="preserve">
|
||||
<value>proceduresConnectionStringTextBox</value>
|
||||
</data>
|
||||
<data name=">>configDbConnectionStringTextBox.Type" xml:space="preserve">
|
||||
<data name=">>proceduresConnectionStringTextBox.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>configDbConnectionStringTextBox.Parent" xml:space="preserve">
|
||||
<data name=">>proceduresConnectionStringTextBox.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>configDbConnectionStringTextBox.ZOrder" xml:space="preserve">
|
||||
<value>16</value>
|
||||
<data name=">>proceduresConnectionStringTextBox.ZOrder" xml:space="preserve">
|
||||
<value>24</value>
|
||||
</data>
|
||||
<data name="resultsDbConnectionStringTextBox.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>202, 137</value>
|
||||
<data name="wmTypesConnectionStringTextBox.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>202, 179</value>
|
||||
</data>
|
||||
<data name="resultsDbConnectionStringTextBox.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<data name="wmTypesConnectionStringTextBox.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>406, 20</value>
|
||||
</data>
|
||||
<data name="resultsDbConnectionStringTextBox.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>22</value>
|
||||
<data name="wmTypesConnectionStringTextBox.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>21</value>
|
||||
</data>
|
||||
<data name=">>resultsDbConnectionStringTextBox.Name" xml:space="preserve">
|
||||
<value>resultsDbConnectionStringTextBox</value>
|
||||
<data name=">>wmTypesConnectionStringTextBox.Name" xml:space="preserve">
|
||||
<value>wmTypesConnectionStringTextBox</value>
|
||||
</data>
|
||||
<data name=">>resultsDbConnectionStringTextBox.Type" xml:space="preserve">
|
||||
<data name=">>wmTypesConnectionStringTextBox.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>resultsDbConnectionStringTextBox.Parent" xml:space="preserve">
|
||||
<data name=">>wmTypesConnectionStringTextBox.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>resultsDbConnectionStringTextBox.ZOrder" xml:space="preserve">
|
||||
<value>15</value>
|
||||
<data name=">>wmTypesConnectionStringTextBox.ZOrder" xml:space="preserve">
|
||||
<value>23</value>
|
||||
</data>
|
||||
<data name="configLabel.AutoSize" type="System.Boolean, mscorlib">
|
||||
<data name="watermetersConnectionStringTextBox.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>202, 205</value>
|
||||
</data>
|
||||
<data name="watermetersConnectionStringTextBox.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>406, 20</value>
|
||||
</data>
|
||||
<data name="watermetersConnectionStringTextBox.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>22</value>
|
||||
</data>
|
||||
<data name=">>watermetersConnectionStringTextBox.Name" xml:space="preserve">
|
||||
<value>watermetersConnectionStringTextBox</value>
|
||||
</data>
|
||||
<data name=">>watermetersConnectionStringTextBox.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>watermetersConnectionStringTextBox.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>watermetersConnectionStringTextBox.ZOrder" xml:space="preserve">
|
||||
<value>22</value>
|
||||
</data>
|
||||
<data name="label2.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
</data>
|
||||
<data name="configLabel.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>12, 110</value>
|
||||
<data name="label2.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>12, 104</value>
|
||||
</data>
|
||||
<data name="configLabel.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>69, 13</value>
|
||||
<data name="label2.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>90, 13</value>
|
||||
</data>
|
||||
<data name="configLabel.TabIndex" type="System.Int32, mscorlib">
|
||||
<data name="label2.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>47</value>
|
||||
</data>
|
||||
<data name="label2.Text" xml:space="preserve">
|
||||
<value>Users and groups</value>
|
||||
</data>
|
||||
<data name=">>label2.Name" xml:space="preserve">
|
||||
<value>label2</value>
|
||||
</data>
|
||||
<data name=">>label2.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>label2.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>label2.ZOrder" xml:space="preserve">
|
||||
<value>21</value>
|
||||
</data>
|
||||
<data name="label3.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
</data>
|
||||
<data name="label3.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>12, 130</value>
|
||||
</data>
|
||||
<data name="label3.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>93, 13</value>
|
||||
</data>
|
||||
<data name="label3.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>48</value>
|
||||
</data>
|
||||
<data name="label3.Text" xml:space="preserve">
|
||||
<value>Bench parameters</value>
|
||||
</data>
|
||||
<data name=">>label3.Name" xml:space="preserve">
|
||||
<value>label3</value>
|
||||
</data>
|
||||
<data name=">>label3.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>label3.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>label3.ZOrder" xml:space="preserve">
|
||||
<value>20</value>
|
||||
</data>
|
||||
<data name="label4.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
</data>
|
||||
<data name="label4.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>12, 156</value>
|
||||
</data>
|
||||
<data name="label4.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>61, 13</value>
|
||||
</data>
|
||||
<data name="label4.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>49</value>
|
||||
</data>
|
||||
<data name="configLabel.Text" xml:space="preserve">
|
||||
<value>Configuration</value>
|
||||
<data name="label4.Text" xml:space="preserve">
|
||||
<value>Procedures</value>
|
||||
</data>
|
||||
<data name=">>configLabel.Name" xml:space="preserve">
|
||||
<value>configLabel</value>
|
||||
<data name=">>label4.Name" xml:space="preserve">
|
||||
<value>label4</value>
|
||||
</data>
|
||||
<data name=">>configLabel.Type" xml:space="preserve">
|
||||
<data name=">>label4.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>configLabel.Parent" xml:space="preserve">
|
||||
<data name=">>label4.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>configLabel.ZOrder" xml:space="preserve">
|
||||
<value>14</value>
|
||||
<data name=">>label4.ZOrder" xml:space="preserve">
|
||||
<value>19</value>
|
||||
</data>
|
||||
<data name="resultsLabel.AutoSize" type="System.Boolean, mscorlib">
|
||||
<data name="label5.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
</data>
|
||||
<data name="resultsLabel.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>12, 140</value>
|
||||
<data name="label5.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>12, 182</value>
|
||||
</data>
|
||||
<data name="resultsLabel.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>42, 13</value>
|
||||
<data name="label5.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>90, 13</value>
|
||||
</data>
|
||||
<data name="resultsLabel.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>51</value>
|
||||
<data name="label5.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>50</value>
|
||||
</data>
|
||||
<data name="resultsLabel.Text" xml:space="preserve">
|
||||
<value>Results</value>
|
||||
<data name="label5.Text" xml:space="preserve">
|
||||
<value>Watermeter types</value>
|
||||
</data>
|
||||
<data name=">>resultsLabel.Name" xml:space="preserve">
|
||||
<value>resultsLabel</value>
|
||||
<data name=">>label5.Name" xml:space="preserve">
|
||||
<value>label5</value>
|
||||
</data>
|
||||
<data name=">>resultsLabel.Type" xml:space="preserve">
|
||||
<data name=">>label5.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>resultsLabel.Parent" xml:space="preserve">
|
||||
<data name=">>label5.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>resultsLabel.ZOrder" xml:space="preserve">
|
||||
<value>13</value>
|
||||
<data name=">>label5.ZOrder" xml:space="preserve">
|
||||
<value>18</value>
|
||||
</data>
|
||||
<data name="label6.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
</data>
|
||||
<data name="label6.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>12, 208</value>
|
||||
</data>
|
||||
<data name="label6.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>67, 13</value>
|
||||
</data>
|
||||
<data name="label6.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>51</value>
|
||||
</data>
|
||||
<data name="label6.Text" xml:space="preserve">
|
||||
<value>Watermeters</value>
|
||||
</data>
|
||||
<data name=">>label6.Name" xml:space="preserve">
|
||||
<value>label6</value>
|
||||
</data>
|
||||
<data name=">>label6.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>label6.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>label6.ZOrder" xml:space="preserve">
|
||||
<value>17</value>
|
||||
</data>
|
||||
<data name="testConnUsersBtn.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>614, 99</value>
|
||||
</data>
|
||||
<data name="testConnUsersBtn.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>95, 23</value>
|
||||
</data>
|
||||
<data name="testConnUsersBtn.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>52</value>
|
||||
</data>
|
||||
<data name="testConnUsersBtn.Text" xml:space="preserve">
|
||||
<value>Test Connection</value>
|
||||
</data>
|
||||
<data name=">>testConnUsersBtn.Name" xml:space="preserve">
|
||||
<value>testConnUsersBtn</value>
|
||||
</data>
|
||||
<data name=">>testConnUsersBtn.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>testConnUsersBtn.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>testConnUsersBtn.ZOrder" xml:space="preserve">
|
||||
<value>16</value>
|
||||
</data>
|
||||
<data name="createUsersDbBtn.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>711, 99</value>
|
||||
</data>
|
||||
<data name="createUsersDbBtn.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>120, 23</value>
|
||||
</data>
|
||||
<data name="createUsersDbBtn.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>53</value>
|
||||
</data>
|
||||
<data name="createUsersDbBtn.Text" xml:space="preserve">
|
||||
<value>Create DB</value>
|
||||
</data>
|
||||
<data name=">>createUsersDbBtn.Name" xml:space="preserve">
|
||||
<value>createUsersDbBtn</value>
|
||||
</data>
|
||||
<data name=">>createUsersDbBtn.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>createUsersDbBtn.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>createUsersDbBtn.ZOrder" xml:space="preserve">
|
||||
<value>15</value>
|
||||
</data>
|
||||
<data name="realBenchCheckBox.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
@@ -363,7 +555,7 @@
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>realBenchCheckBox.ZOrder" xml:space="preserve">
|
||||
<value>12</value>
|
||||
<value>14</value>
|
||||
</data>
|
||||
<data name="dbTypeLabel.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
@@ -390,221 +582,16 @@
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>dbTypeLabel.ZOrder" xml:space="preserve">
|
||||
<value>11</value>
|
||||
</data>
|
||||
<data name="configDbTypeComboBox.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>116, 107</value>
|
||||
</data>
|
||||
<data name="configDbTypeComboBox.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>80, 21</value>
|
||||
</data>
|
||||
<data name="configDbTypeComboBox.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>58</value>
|
||||
</data>
|
||||
<data name=">>configDbTypeComboBox.Name" xml:space="preserve">
|
||||
<value>configDbTypeComboBox</value>
|
||||
</data>
|
||||
<data name=">>configDbTypeComboBox.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>configDbTypeComboBox.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>configDbTypeComboBox.ZOrder" xml:space="preserve">
|
||||
<value>10</value>
|
||||
</data>
|
||||
<data name="resultsDbTypeComboBox.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>116, 137</value>
|
||||
</data>
|
||||
<data name="resultsDbTypeComboBox.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>80, 21</value>
|
||||
</data>
|
||||
<data name="resultsDbTypeComboBox.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>60</value>
|
||||
</data>
|
||||
<data name=">>resultsDbTypeComboBox.Name" xml:space="preserve">
|
||||
<value>resultsDbTypeComboBox</value>
|
||||
</data>
|
||||
<data name=">>resultsDbTypeComboBox.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>resultsDbTypeComboBox.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>resultsDbTypeComboBox.ZOrder" xml:space="preserve">
|
||||
<value>9</value>
|
||||
</data>
|
||||
<assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
|
||||
<data name="testConnConfigDbBtn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="testConnConfigDbBtn.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>614, 105</value>
|
||||
</data>
|
||||
<data name="testConnConfigDbBtn.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>95, 23</value>
|
||||
</data>
|
||||
<data name="testConnConfigDbBtn.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>62</value>
|
||||
</data>
|
||||
<data name="testConnConfigDbBtn.Text" xml:space="preserve">
|
||||
<value>Test Connection</value>
|
||||
</data>
|
||||
<data name=">>testConnConfigDbBtn.Name" xml:space="preserve">
|
||||
<value>testConnConfigDbBtn</value>
|
||||
</data>
|
||||
<data name=">>testConnConfigDbBtn.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>testConnConfigDbBtn.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>testConnConfigDbBtn.ZOrder" xml:space="preserve">
|
||||
<value>8</value>
|
||||
</data>
|
||||
<data name="testConnResultsDbBtn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="testConnResultsDbBtn.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>614, 135</value>
|
||||
</data>
|
||||
<data name="testConnResultsDbBtn.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>95, 23</value>
|
||||
</data>
|
||||
<data name="testConnResultsDbBtn.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>64</value>
|
||||
</data>
|
||||
<data name="testConnResultsDbBtn.Text" xml:space="preserve">
|
||||
<value>Test Connection</value>
|
||||
</data>
|
||||
<data name=">>testConnResultsDbBtn.Name" xml:space="preserve">
|
||||
<value>testConnResultsDbBtn</value>
|
||||
</data>
|
||||
<data name=">>testConnResultsDbBtn.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>testConnResultsDbBtn.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>testConnResultsDbBtn.ZOrder" xml:space="preserve">
|
||||
<value>7</value>
|
||||
</data>
|
||||
<data name="createConfigDbBtn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="createConfigDbBtn.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>715, 104</value>
|
||||
</data>
|
||||
<data name="createConfigDbBtn.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>124, 23</value>
|
||||
</data>
|
||||
<data name="createConfigDbBtn.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>66</value>
|
||||
</data>
|
||||
<data name="createConfigDbBtn.Text" xml:space="preserve">
|
||||
<value>Create DB</value>
|
||||
</data>
|
||||
<data name=">>createConfigDbBtn.Name" xml:space="preserve">
|
||||
<value>createConfigDbBtn</value>
|
||||
</data>
|
||||
<data name=">>createConfigDbBtn.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>createConfigDbBtn.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>createConfigDbBtn.ZOrder" xml:space="preserve">
|
||||
<value>6</value>
|
||||
</data>
|
||||
<data name="createResultsDbBtn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="createResultsDbBtn.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>715, 134</value>
|
||||
</data>
|
||||
<data name="createResultsDbBtn.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>124, 23</value>
|
||||
</data>
|
||||
<data name="createResultsDbBtn.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>68</value>
|
||||
</data>
|
||||
<data name="createResultsDbBtn.Text" xml:space="preserve">
|
||||
<value>Create DB</value>
|
||||
</data>
|
||||
<data name=">>createResultsDbBtn.Name" xml:space="preserve">
|
||||
<value>createResultsDbBtn</value>
|
||||
</data>
|
||||
<data name=">>createResultsDbBtn.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>createResultsDbBtn.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>createResultsDbBtn.ZOrder" xml:space="preserve">
|
||||
<value>5</value>
|
||||
</data>
|
||||
<data name="createUsersDbBtn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="createUsersDbBtn.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>715, 164</value>
|
||||
</data>
|
||||
<data name="createUsersDbBtn.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>124, 23</value>
|
||||
</data>
|
||||
<data name="createUsersDbBtn.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>73</value>
|
||||
</data>
|
||||
<data name="createUsersDbBtn.Text" xml:space="preserve">
|
||||
<value>Create DB</value>
|
||||
</data>
|
||||
<data name=">>createUsersDbBtn.Name" xml:space="preserve">
|
||||
<value>createUsersDbBtn</value>
|
||||
</data>
|
||||
<data name=">>createUsersDbBtn.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>createUsersDbBtn.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>createUsersDbBtn.ZOrder" xml:space="preserve">
|
||||
<value>0</value>
|
||||
</data>
|
||||
<data name="testConnUsersDbBtn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="testConnUsersDbBtn.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>614, 165</value>
|
||||
</data>
|
||||
<data name="testConnUsersDbBtn.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>95, 23</value>
|
||||
</data>
|
||||
<data name="testConnUsersDbBtn.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>72</value>
|
||||
</data>
|
||||
<data name="testConnUsersDbBtn.Text" xml:space="preserve">
|
||||
<value>Test Connection</value>
|
||||
</data>
|
||||
<data name=">>testConnUsersDbBtn.Name" xml:space="preserve">
|
||||
<value>testConnUsersDbBtn</value>
|
||||
</data>
|
||||
<data name=">>testConnUsersDbBtn.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>testConnUsersDbBtn.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>testConnUsersDbBtn.ZOrder" xml:space="preserve">
|
||||
<value>1</value>
|
||||
<value>13</value>
|
||||
</data>
|
||||
<data name="usersDbTypeComboBox.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>116, 167</value>
|
||||
<value>116, 101</value>
|
||||
</data>
|
||||
<data name="usersDbTypeComboBox.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>80, 21</value>
|
||||
</data>
|
||||
<data name="usersDbTypeComboBox.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>71</value>
|
||||
<value>56</value>
|
||||
</data>
|
||||
<data name=">>usersDbTypeComboBox.Name" xml:space="preserve">
|
||||
<value>usersDbTypeComboBox</value>
|
||||
@@ -616,58 +603,308 @@
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>usersDbTypeComboBox.ZOrder" xml:space="preserve">
|
||||
<value>2</value>
|
||||
<value>12</value>
|
||||
</data>
|
||||
<data name="usersLabel.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
<data name="benchDbTypeComboBox.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>116, 127</value>
|
||||
</data>
|
||||
<data name="usersLabel.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
|
||||
<data name="benchDbTypeComboBox.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>80, 21</value>
|
||||
</data>
|
||||
<data name="benchDbTypeComboBox.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>57</value>
|
||||
</data>
|
||||
<data name=">>benchDbTypeComboBox.Name" xml:space="preserve">
|
||||
<value>benchDbTypeComboBox</value>
|
||||
</data>
|
||||
<data name=">>benchDbTypeComboBox.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>benchDbTypeComboBox.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>benchDbTypeComboBox.ZOrder" xml:space="preserve">
|
||||
<value>11</value>
|
||||
</data>
|
||||
<data name="proceduresDbTypeComboBox.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>116, 153</value>
|
||||
</data>
|
||||
<data name="proceduresDbTypeComboBox.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>80, 21</value>
|
||||
</data>
|
||||
<data name="proceduresDbTypeComboBox.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>58</value>
|
||||
</data>
|
||||
<data name=">>proceduresDbTypeComboBox.Name" xml:space="preserve">
|
||||
<value>proceduresDbTypeComboBox</value>
|
||||
</data>
|
||||
<data name=">>proceduresDbTypeComboBox.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>proceduresDbTypeComboBox.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>proceduresDbTypeComboBox.ZOrder" xml:space="preserve">
|
||||
<value>10</value>
|
||||
</data>
|
||||
<data name="wmTypesDbTypeComboBox.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>116, 179</value>
|
||||
</data>
|
||||
<data name="wmTypesDbTypeComboBox.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>80, 21</value>
|
||||
</data>
|
||||
<data name="wmTypesDbTypeComboBox.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>59</value>
|
||||
</data>
|
||||
<data name=">>wmTypesDbTypeComboBox.Name" xml:space="preserve">
|
||||
<value>wmTypesDbTypeComboBox</value>
|
||||
</data>
|
||||
<data name=">>wmTypesDbTypeComboBox.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>wmTypesDbTypeComboBox.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>wmTypesDbTypeComboBox.ZOrder" xml:space="preserve">
|
||||
<value>9</value>
|
||||
</data>
|
||||
<data name="watermetersDbTypeComboBox.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>116, 205</value>
|
||||
</data>
|
||||
<data name="watermetersDbTypeComboBox.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>80, 21</value>
|
||||
</data>
|
||||
<data name="watermetersDbTypeComboBox.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>60</value>
|
||||
</data>
|
||||
<data name=">>watermetersDbTypeComboBox.Name" xml:space="preserve">
|
||||
<value>watermetersDbTypeComboBox</value>
|
||||
</data>
|
||||
<data name=">>watermetersDbTypeComboBox.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>watermetersDbTypeComboBox.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>watermetersDbTypeComboBox.ZOrder" xml:space="preserve">
|
||||
<value>8</value>
|
||||
</data>
|
||||
<assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
|
||||
<data name="testConnBenchBtn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="usersLabel.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>12, 170</value>
|
||||
<data name="testConnBenchBtn.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>614, 125</value>
|
||||
</data>
|
||||
<data name="usersLabel.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>34, 13</value>
|
||||
<data name="testConnBenchBtn.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>95, 23</value>
|
||||
</data>
|
||||
<data name="usersLabel.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>70</value>
|
||||
<data name="testConnBenchBtn.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>61</value>
|
||||
</data>
|
||||
<data name="usersLabel.Text" xml:space="preserve">
|
||||
<value>Users</value>
|
||||
<data name="testConnBenchBtn.Text" xml:space="preserve">
|
||||
<value>Test Connection</value>
|
||||
</data>
|
||||
<data name=">>usersLabel.Name" xml:space="preserve">
|
||||
<value>usersLabel</value>
|
||||
<data name=">>testConnBenchBtn.Name" xml:space="preserve">
|
||||
<value>testConnBenchBtn</value>
|
||||
</data>
|
||||
<data name=">>usersLabel.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
<data name=">>testConnBenchBtn.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>usersLabel.Parent" xml:space="preserve">
|
||||
<data name=">>testConnBenchBtn.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>usersLabel.ZOrder" xml:space="preserve">
|
||||
<data name=">>testConnBenchBtn.ZOrder" xml:space="preserve">
|
||||
<value>7</value>
|
||||
</data>
|
||||
<data name="testConnProceduresBtn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="testConnProceduresBtn.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>614, 151</value>
|
||||
</data>
|
||||
<data name="testConnProceduresBtn.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>95, 23</value>
|
||||
</data>
|
||||
<data name="testConnProceduresBtn.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>62</value>
|
||||
</data>
|
||||
<data name="testConnProceduresBtn.Text" xml:space="preserve">
|
||||
<value>Test Connection</value>
|
||||
</data>
|
||||
<data name=">>testConnProceduresBtn.Name" xml:space="preserve">
|
||||
<value>testConnProceduresBtn</value>
|
||||
</data>
|
||||
<data name=">>testConnProceduresBtn.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>testConnProceduresBtn.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>testConnProceduresBtn.ZOrder" xml:space="preserve">
|
||||
<value>6</value>
|
||||
</data>
|
||||
<data name="testConnWMTypesBtn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="testConnWMTypesBtn.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>614, 177</value>
|
||||
</data>
|
||||
<data name="testConnWMTypesBtn.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>95, 23</value>
|
||||
</data>
|
||||
<data name="testConnWMTypesBtn.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>63</value>
|
||||
</data>
|
||||
<data name="testConnWMTypesBtn.Text" xml:space="preserve">
|
||||
<value>Test Connection</value>
|
||||
</data>
|
||||
<data name=">>testConnWMTypesBtn.Name" xml:space="preserve">
|
||||
<value>testConnWMTypesBtn</value>
|
||||
</data>
|
||||
<data name=">>testConnWMTypesBtn.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>testConnWMTypesBtn.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>testConnWMTypesBtn.ZOrder" xml:space="preserve">
|
||||
<value>5</value>
|
||||
</data>
|
||||
<data name="testConnWaterMetersBtn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="testConnWaterMetersBtn.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>614, 203</value>
|
||||
</data>
|
||||
<data name="testConnWaterMetersBtn.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>95, 23</value>
|
||||
</data>
|
||||
<data name="testConnWaterMetersBtn.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>64</value>
|
||||
</data>
|
||||
<data name="testConnWaterMetersBtn.Text" xml:space="preserve">
|
||||
<value>Test Connection</value>
|
||||
</data>
|
||||
<data name=">>testConnWaterMetersBtn.Name" xml:space="preserve">
|
||||
<value>testConnWaterMetersBtn</value>
|
||||
</data>
|
||||
<data name=">>testConnWaterMetersBtn.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>testConnWaterMetersBtn.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>testConnWaterMetersBtn.ZOrder" xml:space="preserve">
|
||||
<value>4</value>
|
||||
</data>
|
||||
<data name="createBenchDbBtn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="createBenchDbBtn.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>711, 124</value>
|
||||
</data>
|
||||
<data name="createBenchDbBtn.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>120, 23</value>
|
||||
</data>
|
||||
<data name="createBenchDbBtn.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>65</value>
|
||||
</data>
|
||||
<data name="createBenchDbBtn.Text" xml:space="preserve">
|
||||
<value>Create DB</value>
|
||||
</data>
|
||||
<data name=">>createBenchDbBtn.Name" xml:space="preserve">
|
||||
<value>createBenchDbBtn</value>
|
||||
</data>
|
||||
<data name=">>createBenchDbBtn.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>createBenchDbBtn.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>createBenchDbBtn.ZOrder" xml:space="preserve">
|
||||
<value>3</value>
|
||||
</data>
|
||||
<data name="usersDbConnectionStringTextBox.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>202, 167</value>
|
||||
<data name="createProceduresDbBtn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="usersDbConnectionStringTextBox.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>406, 20</value>
|
||||
<data name="createProceduresDbBtn.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>711, 150</value>
|
||||
</data>
|
||||
<data name="usersDbConnectionStringTextBox.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>69</value>
|
||||
<data name="createProceduresDbBtn.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>120, 23</value>
|
||||
</data>
|
||||
<data name=">>usersDbConnectionStringTextBox.Name" xml:space="preserve">
|
||||
<value>usersDbConnectionStringTextBox</value>
|
||||
<data name="createProceduresDbBtn.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>66</value>
|
||||
</data>
|
||||
<data name=">>usersDbConnectionStringTextBox.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
<data name="createProceduresDbBtn.Text" xml:space="preserve">
|
||||
<value>Create DB</value>
|
||||
</data>
|
||||
<data name=">>usersDbConnectionStringTextBox.Parent" xml:space="preserve">
|
||||
<data name=">>createProceduresDbBtn.Name" xml:space="preserve">
|
||||
<value>createProceduresDbBtn</value>
|
||||
</data>
|
||||
<data name=">>createProceduresDbBtn.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>createProceduresDbBtn.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>usersDbConnectionStringTextBox.ZOrder" xml:space="preserve">
|
||||
<value>4</value>
|
||||
<data name=">>createProceduresDbBtn.ZOrder" xml:space="preserve">
|
||||
<value>2</value>
|
||||
</data>
|
||||
<data name="createWMTypesDbBtn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="createWMTypesDbBtn.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>711, 176</value>
|
||||
</data>
|
||||
<data name="createWMTypesDbBtn.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>120, 23</value>
|
||||
</data>
|
||||
<data name="createWMTypesDbBtn.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>67</value>
|
||||
</data>
|
||||
<data name="createWMTypesDbBtn.Text" xml:space="preserve">
|
||||
<value>Create DB</value>
|
||||
</data>
|
||||
<data name=">>createWMTypesDbBtn.Name" xml:space="preserve">
|
||||
<value>createWMTypesDbBtn</value>
|
||||
</data>
|
||||
<data name=">>createWMTypesDbBtn.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>createWMTypesDbBtn.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>createWMTypesDbBtn.ZOrder" xml:space="preserve">
|
||||
<value>1</value>
|
||||
</data>
|
||||
<data name="createWaterMetersDbBtn.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="createWaterMetersDbBtn.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>711, 202</value>
|
||||
</data>
|
||||
<data name="createWaterMetersDbBtn.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>120, 23</value>
|
||||
</data>
|
||||
<data name="createWaterMetersDbBtn.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>68</value>
|
||||
</data>
|
||||
<data name="createWaterMetersDbBtn.Text" xml:space="preserve">
|
||||
<value>Create DB</value>
|
||||
</data>
|
||||
<data name=">>createWaterMetersDbBtn.Name" xml:space="preserve">
|
||||
<value>createWaterMetersDbBtn</value>
|
||||
</data>
|
||||
<data name=">>createWaterMetersDbBtn.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>createWaterMetersDbBtn.Parent" xml:space="preserve">
|
||||
<value>$this</value>
|
||||
</data>
|
||||
<data name=">>createWaterMetersDbBtn.ZOrder" xml:space="preserve">
|
||||
<value>0</value>
|
||||
</data>
|
||||
<metadata name="$this.Localizable" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
@@ -676,7 +913,7 @@
|
||||
<value>6, 13</value>
|
||||
</data>
|
||||
<data name="$this.ClientSize" type="System.Drawing.Size, System.Drawing">
|
||||
<value>853, 202</value>
|
||||
<value>836, 241</value>
|
||||
</data>
|
||||
<data name="$this.StartPosition" type="System.Windows.Forms.FormStartPosition, System.Windows.Forms">
|
||||
<value>CenterParent</value>
|
||||
@@ -0,0 +1,78 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace ResultsBrowser.Entities
|
||||
{
|
||||
public class BenchPath : IHasItemNr, IHasValves
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
public virtual int ItemNr { get; set; }
|
||||
public virtual string Name { get; set; }
|
||||
public virtual float Qfrom { get; set; } /// Water flow in [m3/h]
|
||||
public virtual float Qto { get; set; } /// Water flow in [m3/h]
|
||||
public virtual string TempIn { get; set; }
|
||||
public virtual string TempOut { get; set; }
|
||||
public virtual string PressIn { get; set; }
|
||||
public virtual string PressOut { get; set; }
|
||||
|
||||
/// Valves
|
||||
public virtual string ValvesOpen { get; set; }
|
||||
public virtual string ValvesClose { get; set; }
|
||||
|
||||
/// ------------- Additional stuff not mapped into the database -------------
|
||||
|
||||
public BenchPath()
|
||||
{
|
||||
}
|
||||
|
||||
public BenchPath(string name, int itemNr)
|
||||
: this()
|
||||
{
|
||||
Name = name;
|
||||
ItemNr = itemNr;
|
||||
}
|
||||
|
||||
public BenchPath(BenchControl.BenchPath path)
|
||||
: this(path.Name, path.ItemNr)
|
||||
{
|
||||
Qfrom = path.Qfrom;
|
||||
Qto = path.Qto;
|
||||
TempIn = (path.TempIn != null) ? path.TempIn.Cfg.Name : null;
|
||||
TempOut = (path.TempOut != null) ? path.TempOut.Cfg.Name : null;
|
||||
PressIn = (path.PressIn != null) ? path.PressIn.Cfg.Name : null;
|
||||
PressOut = (path.PressOut != null) ? path.PressOut.Cfg.Name : null;
|
||||
|
||||
string vOpen = string.Empty;
|
||||
foreach (var valve in path.ValvesOpen)
|
||||
{
|
||||
if (vOpen != string.Empty) vOpen += ";";
|
||||
vOpen += valve.Cfg.Name;
|
||||
}
|
||||
ValvesOpen = vOpen;
|
||||
|
||||
string vClose = string.Empty;
|
||||
foreach (var valve in path.ValvesClose)
|
||||
{
|
||||
if (vClose != string.Empty) vClose += ";";
|
||||
vClose += valve.Cfg.Name;
|
||||
}
|
||||
ValvesClose = vClose;
|
||||
}
|
||||
|
||||
public virtual BenchPath Clone(string name, int itemNr)
|
||||
{
|
||||
BenchPath result = new BenchPath(name, itemNr);
|
||||
|
||||
result.Qfrom = Qfrom;
|
||||
result.Qto = Qto;
|
||||
result.TempIn = TempIn;
|
||||
result.TempOut = TempOut;
|
||||
result.PressIn = PressIn;
|
||||
result.PressOut = PressOut;
|
||||
result.ValvesOpen = ValvesOpen;
|
||||
result.ValvesClose = ValvesClose;
|
||||
|
||||
return result;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,71 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace ResultsBrowser.Entities
|
||||
{
|
||||
public class Component : IHasItemNr
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
public virtual int ItemNr { get; set; }
|
||||
public virtual string Name { get; set; }
|
||||
public virtual string ClassName { get; set; }
|
||||
public virtual string ParentName { get; set; }
|
||||
public virtual DebugMode Mode { get; set; }
|
||||
public virtual LogLevel Logging { get; set; }
|
||||
public virtual string Parameters { get; set; }
|
||||
public virtual IList<MeasurementCorrection> Corrections { get; set; }
|
||||
|
||||
/// ------------- Additional stuff not mapped into the database -------------
|
||||
|
||||
public Component()
|
||||
{
|
||||
Corrections = new List<MeasurementCorrection>();
|
||||
}
|
||||
|
||||
public static Component CreateFromCfg(string name, string className, string parentName, int itemNr,
|
||||
DebugMode debugLevel, LogLevel logLevel, string parameters)
|
||||
{
|
||||
Component result = new Component();
|
||||
result.ItemNr = itemNr;
|
||||
result.Name = name;
|
||||
result.ClassName = className;
|
||||
result.ParentName = parentName;
|
||||
result.Mode = debugLevel;
|
||||
result.Logging = logLevel;
|
||||
result.Parameters = parameters;
|
||||
return result;
|
||||
}
|
||||
|
||||
// Makes a new copy of this object (not just a reference)
|
||||
public virtual Component Clone()
|
||||
{
|
||||
Component result = new Component();
|
||||
result.ItemNr = ItemNr;
|
||||
result.Name = Name;
|
||||
result.ClassName = ClassName;
|
||||
result.ParentName = ParentName;
|
||||
result.Mode = Mode;
|
||||
result.Logging = Logging;
|
||||
result.Parameters = Parameters;
|
||||
return result;
|
||||
}
|
||||
|
||||
public virtual string ToString(string indent)
|
||||
{
|
||||
string result = string.Empty;
|
||||
|
||||
result += indent + "ItemNr = " + (ItemNr + 1).ToString() + Environment.NewLine;
|
||||
result += indent + "Name = " + Name + Environment.NewLine;
|
||||
result += indent + "ClassName = " + ClassName + Environment.NewLine;
|
||||
if (ParentName != null)
|
||||
{
|
||||
result += indent + "ParentName = " + ParentName + Environment.NewLine;
|
||||
}
|
||||
result += indent + "DebugLevel = " + Mode.ToString() + Environment.NewLine;
|
||||
result += indent + "LogLevel = " + Logging.ToString() + Environment.NewLine;
|
||||
result += indent + "Parameters = " + Parameters + Environment.NewLine;
|
||||
|
||||
return result;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
|
||||
namespace ResultsBrowser.Entities
|
||||
{
|
||||
public class ComponentProcedure
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
public virtual string CmpntName { get; set; } /// Component name
|
||||
public virtual string Parameters { get; set; }
|
||||
public virtual Procedure Procedure { get; set; }
|
||||
|
||||
public virtual ComponentProcedure Clone()
|
||||
{
|
||||
ComponentProcedure result = new ComponentProcedure();
|
||||
result.CmpntName = CmpntName;
|
||||
result.Parameters = Parameters;
|
||||
result.Procedure = Procedure;
|
||||
return result;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
|
||||
namespace ResultsBrowser.Entities
|
||||
{
|
||||
public class ComponentTest
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
public virtual string CmpntName { get; set; } /// Component name
|
||||
public virtual string Parameters { get; set; }
|
||||
public virtual Test Test { get; set; }
|
||||
|
||||
public virtual ComponentTest Clone()
|
||||
{
|
||||
ComponentTest result = new ComponentTest();
|
||||
result.CmpntName = CmpntName;
|
||||
result.Parameters = Parameters;
|
||||
result.Test = Test;
|
||||
return result;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,85 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace ResultsBrowser.Entities
|
||||
{
|
||||
/// <summary>
|
||||
/// Kind of meters for the procedure / test
|
||||
/// </summary>
|
||||
public enum MetersKind
|
||||
{
|
||||
Single,
|
||||
Combined,
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Flow set method Std/ComposedMeter
|
||||
/// </summary>
|
||||
public enum QSetMethod
|
||||
{
|
||||
Std,
|
||||
ComposedMeter,
|
||||
Count,
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Procedure method FSS/SSS
|
||||
/// </summary>
|
||||
public enum TestMethod2
|
||||
{
|
||||
FSS,
|
||||
SSS,
|
||||
Count,
|
||||
}
|
||||
|
||||
public enum TestRedType
|
||||
{
|
||||
Fix,
|
||||
/// etc.
|
||||
Count,
|
||||
}
|
||||
|
||||
public enum FQC1
|
||||
{
|
||||
FQC1,
|
||||
FQP1,
|
||||
Count,
|
||||
}
|
||||
|
||||
public enum Device
|
||||
{
|
||||
Screen,
|
||||
Printer,
|
||||
Disk,
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Possible modes of operation of components and devices.
|
||||
/// </summary>
|
||||
public enum DebugMode
|
||||
{
|
||||
DetectedOff = -2,
|
||||
DetectedOn = -1,
|
||||
Normal = 0, /// Normal operation
|
||||
AutoDetect, /// The component (device) will be auto-detected
|
||||
Off, /// The component is off
|
||||
Record,
|
||||
Reply,
|
||||
Simulate, /// Test bench simulation, this mode does not require any hardware
|
||||
Inherit,
|
||||
Count,
|
||||
}
|
||||
|
||||
public enum LogLevel
|
||||
{
|
||||
Off,
|
||||
Fatal,
|
||||
Error,
|
||||
Warn,
|
||||
Info,
|
||||
Debug,
|
||||
All,
|
||||
Count,
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,69 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace ResultsBrowser.Entities
|
||||
{
|
||||
public class FeedingPath : IHasItemNr, IHasValves
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
public virtual int ItemNr { get; set; }
|
||||
public virtual string Name { get; set; }
|
||||
public virtual float Qfrom { get; set; } /// Water flow in [m3/h]
|
||||
public virtual float Qto { get; set; } /// Water flow in [m3/h]
|
||||
public virtual string Pump { get; set; }
|
||||
|
||||
/// Valves
|
||||
public virtual string ValvesOpen { get; set; }
|
||||
public virtual string ValvesClose { get; set; }
|
||||
|
||||
/// ------------- Additional stuff not mapped into the database -------------
|
||||
|
||||
public FeedingPath()
|
||||
{
|
||||
}
|
||||
|
||||
public FeedingPath(string name, int itemNr)
|
||||
: this()
|
||||
{
|
||||
Name = name;
|
||||
ItemNr = itemNr;
|
||||
}
|
||||
|
||||
public FeedingPath(BenchControl.FeedingPath path)
|
||||
: this(path.Name, path.ItemNr)
|
||||
{
|
||||
Qfrom = path.Qfrom;
|
||||
Qto = path.Qto;
|
||||
Pump = (path.Pump != null) ? path.Pump.Cfg.Name : null;
|
||||
|
||||
string vOpen = string.Empty;
|
||||
foreach (var valve in path.ValvesOpen)
|
||||
{
|
||||
if (vOpen != string.Empty) vOpen += ";";
|
||||
vOpen += valve.Cfg.Name;
|
||||
}
|
||||
ValvesOpen = vOpen;
|
||||
|
||||
string vClose = string.Empty;
|
||||
foreach (var valve in path.ValvesClose)
|
||||
{
|
||||
if (vClose != string.Empty) vClose += ";";
|
||||
vClose += valve.Cfg.Name;
|
||||
}
|
||||
ValvesClose = vClose;
|
||||
}
|
||||
|
||||
public virtual FeedingPath Clone(string name, int itemNr)
|
||||
{
|
||||
FeedingPath result = new FeedingPath(name, itemNr);
|
||||
|
||||
result.Qfrom = Qfrom;
|
||||
result.Qto = Qto;
|
||||
result.Pump = Pump;
|
||||
result.ValvesOpen = ValvesOpen;
|
||||
result.ValvesClose = ValvesClose;
|
||||
|
||||
return result;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,25 +1,12 @@
|
||||
///
|
||||
/// Copyright (c) 2016-2017 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace Users.Entities
|
||||
namespace ResultsBrowser.Entities
|
||||
{
|
||||
public class Group
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
public virtual int Gid { get; set; }
|
||||
public virtual string Name { get; set; }
|
||||
|
||||
public Group()
|
||||
{
|
||||
}
|
||||
|
||||
public Group(int gid, string name)
|
||||
{
|
||||
Gid = gid;
|
||||
Name = name;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
|
||||
namespace ResultsBrowser.Entities
|
||||
{
|
||||
interface IHasItemNr
|
||||
{
|
||||
int Id { get; }
|
||||
int ItemNr { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
|
||||
namespace ResultsBrowser.Entities
|
||||
{
|
||||
public interface IHasValves
|
||||
{
|
||||
string ValvesOpen { get; set; } /// List of valves to be opened
|
||||
string ValvesClose { get; set; } /// List of valves to be closed
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
using System;
|
||||
|
||||
namespace ResultsBrowser.Entities
|
||||
{
|
||||
public class MeasurementCorrection
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
public virtual float Measurement { get; set; }
|
||||
public virtual float Correction { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,51 @@
|
||||
using System;
|
||||
|
||||
namespace ResultsBrowser.Entities
|
||||
{
|
||||
public class MeterTestResult
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
public virtual TestResult TestResult { get; set; } /// reference to the TestResult entity
|
||||
|
||||
public virtual string SerialNr { get; set; }
|
||||
public virtual string EndState { get; set; }
|
||||
public virtual float VolumeStart { get; set; } /// liter
|
||||
public virtual float VolumeEnd { get; set; } /// liter
|
||||
public virtual float VolumeMeter { get; set; } /// liter
|
||||
public virtual float VolumeRef { get; set; } /// liter
|
||||
public virtual float VolumeErrorPct { get; set; } /// %
|
||||
public virtual float PulsesMeter { get; set; } /// Not applicable for a combined meter
|
||||
public virtual float PulsesMaster { get; set; }
|
||||
public virtual float Time { get; set; } /// sec.
|
||||
public virtual bool Passed { get; set; } /// true = test passed
|
||||
|
||||
public MeterTestResult()
|
||||
{
|
||||
}
|
||||
|
||||
public MeterTestResult(TestResult testResult)
|
||||
: this()
|
||||
{
|
||||
TestResult = testResult;
|
||||
}
|
||||
|
||||
public virtual MeterTestResult Clone(TestResult testResult)
|
||||
{
|
||||
MeterTestResult result = new MeterTestResult(testResult);
|
||||
|
||||
result.SerialNr = SerialNr;
|
||||
result.EndState = EndState;
|
||||
result.VolumeStart = VolumeStart;
|
||||
result.VolumeEnd = VolumeEnd;
|
||||
result.VolumeMeter = VolumeMeter;
|
||||
result.VolumeRef = VolumeRef;
|
||||
result.VolumeErrorPct = VolumeErrorPct;
|
||||
result.PulsesMeter = PulsesMeter;
|
||||
result.PulsesMaster = PulsesMaster;
|
||||
result.Time = Time;
|
||||
result.Passed = Passed;
|
||||
|
||||
return result;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,157 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace ResultsBrowser.Entities
|
||||
{
|
||||
public class MetersPath : IHasItemNr
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
public virtual int ItemNr { get; set; }
|
||||
public virtual string Name { get; set; }
|
||||
public virtual float Qfrom { get; set; } /// Water flow in [m3/h]
|
||||
public virtual float Qto { get; set; } /// Water flow in [m3/h]
|
||||
|
||||
/// Sensors
|
||||
public virtual string Sensor1 { get; set; }
|
||||
public virtual string Sensor2 { get; set; }
|
||||
public virtual string Sensor3 { get; set; }
|
||||
public virtual string Sensor4 { get; set; }
|
||||
public virtual string Sensor5 { get; set; }
|
||||
public virtual string Sensor6 { get; set; }
|
||||
public virtual string Sensor7 { get; set; }
|
||||
public virtual string Sensor8 { get; set; }
|
||||
public virtual string Sensor9 { get; set; }
|
||||
public virtual string Sensor10 { get; set; }
|
||||
public virtual string Sensor11 { get; set; }
|
||||
public virtual string Sensor12 { get; set; }
|
||||
public virtual string Sensor13 { get; set; }
|
||||
public virtual string Sensor14 { get; set; }
|
||||
public virtual string Sensor15 { get; set; }
|
||||
public virtual string Sensor16 { get; set; }
|
||||
public virtual string Sensor17 { get; set; }
|
||||
public virtual string Sensor18 { get; set; }
|
||||
public virtual string Sensor19 { get; set; }
|
||||
public virtual string Sensor20 { get; set; }
|
||||
|
||||
/// ------------- Additional stuff not mapped into the database -------------
|
||||
|
||||
public MetersPath()
|
||||
{
|
||||
}
|
||||
|
||||
public MetersPath(string name, int itemNr)
|
||||
: this()
|
||||
{
|
||||
Name = name;
|
||||
ItemNr = itemNr;
|
||||
}
|
||||
|
||||
public MetersPath(BenchControl.MetersPath path)
|
||||
: this(path.Name, path.ItemNr)
|
||||
{
|
||||
Qfrom = path.Qfrom;
|
||||
Qto = path.Qto;
|
||||
Sensor1 = (path.RegisterReaders[0] != null) ? path.RegisterReaders[0].Cfg.Name : null;
|
||||
#pragma warning disable
|
||||
if (Program.WMsCount >= 2) Sensor2 = (path.RegisterReaders[1] != null) ? path.RegisterReaders[1].Cfg.Name : null;
|
||||
if (Program.WMsCount >= 3) Sensor3 = (path.RegisterReaders[2] != null) ? path.RegisterReaders[2].Cfg.Name : null;
|
||||
if (Program.WMsCount >= 4) Sensor4 = (path.RegisterReaders[3] != null) ? path.RegisterReaders[3].Cfg.Name : null;
|
||||
if (Program.WMsCount >= 5) Sensor5 = (path.RegisterReaders[4] != null) ? path.RegisterReaders[4].Cfg.Name : null;
|
||||
if (Program.WMsCount >= 6) Sensor6 = (path.RegisterReaders[5] != null) ? path.RegisterReaders[5].Cfg.Name : null;
|
||||
if (Program.WMsCount >= 7) Sensor7 = (path.RegisterReaders[6] != null) ? path.RegisterReaders[6].Cfg.Name : null;
|
||||
if (Program.WMsCount >= 8) Sensor8 = (path.RegisterReaders[7] != null) ? path.RegisterReaders[7].Cfg.Name : null;
|
||||
if (Program.WMsCount >= 9) Sensor9 = (path.RegisterReaders[8] != null) ? path.RegisterReaders[8].Cfg.Name : null;
|
||||
if (Program.WMsCount >= 10) Sensor10 = (path.RegisterReaders[9] != null) ? path.RegisterReaders[9].Cfg.Name : null;
|
||||
if (Program.WMsCount >= 11) Sensor11 = (path.RegisterReaders[10] != null) ? path.RegisterReaders[10].Cfg.Name : null;
|
||||
if (Program.WMsCount >= 12) Sensor12 = (path.RegisterReaders[11] != null) ? path.RegisterReaders[11].Cfg.Name : null;
|
||||
if (Program.WMsCount >= 13) Sensor13 = (path.RegisterReaders[12] != null) ? path.RegisterReaders[12].Cfg.Name : null;
|
||||
if (Program.WMsCount >= 14) Sensor14 = (path.RegisterReaders[13] != null) ? path.RegisterReaders[13].Cfg.Name : null;
|
||||
if (Program.WMsCount >= 15) Sensor15 = (path.RegisterReaders[14] != null) ? path.RegisterReaders[14].Cfg.Name : null;
|
||||
if (Program.WMsCount >= 16) Sensor16 = (path.RegisterReaders[15] != null) ? path.RegisterReaders[15].Cfg.Name : null;
|
||||
if (Program.WMsCount >= 17) Sensor17 = (path.RegisterReaders[16] != null) ? path.RegisterReaders[16].Cfg.Name : null;
|
||||
if (Program.WMsCount >= 18) Sensor18 = (path.RegisterReaders[17] != null) ? path.RegisterReaders[17].Cfg.Name : null;
|
||||
if (Program.WMsCount >= 19) Sensor19 = (path.RegisterReaders[18] != null) ? path.RegisterReaders[18].Cfg.Name : null;
|
||||
if (Program.WMsCount >= 20) Sensor20 = (path.RegisterReaders[19] != null) ? path.RegisterReaders[19].Cfg.Name : null;
|
||||
#pragma warning restore
|
||||
}
|
||||
|
||||
public virtual MetersPath Clone(string name, int itemNr)
|
||||
{
|
||||
MetersPath result = new MetersPath(name, itemNr);
|
||||
result.Qfrom = Qfrom;
|
||||
result.Qto = Qto;
|
||||
result.Sensor1 = Sensor1;
|
||||
result.Sensor2 = Sensor2;
|
||||
result.Sensor3 = Sensor3;
|
||||
result.Sensor4 = Sensor4;
|
||||
result.Sensor5 = Sensor5;
|
||||
result.Sensor6 = Sensor6;
|
||||
result.Sensor7 = Sensor7;
|
||||
result.Sensor8 = Sensor8;
|
||||
result.Sensor9 = Sensor9;
|
||||
result.Sensor10 = Sensor10;
|
||||
result.Sensor11 = Sensor11;
|
||||
result.Sensor12 = Sensor12;
|
||||
result.Sensor13 = Sensor13;
|
||||
result.Sensor14 = Sensor14;
|
||||
result.Sensor15 = Sensor15;
|
||||
result.Sensor16 = Sensor16;
|
||||
result.Sensor17 = Sensor17;
|
||||
result.Sensor18 = Sensor18;
|
||||
result.Sensor19 = Sensor19;
|
||||
result.Sensor20 = Sensor20;
|
||||
return result;
|
||||
}
|
||||
|
||||
/// Returns the component name
|
||||
public virtual string GetSensor(int i)
|
||||
{
|
||||
if (i == 0) return Sensor1;
|
||||
else if (i == 1) return Sensor2;
|
||||
else if (i == 2) return Sensor3;
|
||||
else if (i == 3) return Sensor4;
|
||||
else if (i == 4) return Sensor5;
|
||||
else if (i == 5) return Sensor6;
|
||||
else if (i == 6) return Sensor7;
|
||||
else if (i == 7) return Sensor8;
|
||||
else if (i == 8) return Sensor9;
|
||||
else if (i == 9) return Sensor10;
|
||||
else if (i == 10) return Sensor11;
|
||||
else if (i == 11) return Sensor12;
|
||||
else if (i == 12) return Sensor13;
|
||||
else if (i == 13) return Sensor14;
|
||||
else if (i == 14) return Sensor15;
|
||||
else if (i == 15) return Sensor16;
|
||||
else if (i == 16) return Sensor17;
|
||||
else if (i == 17) return Sensor18;
|
||||
else if (i == 18) return Sensor19;
|
||||
else if (i == 19) return Sensor20;
|
||||
else return null;
|
||||
}
|
||||
|
||||
/// Sets the component name
|
||||
public virtual void SetSensor(int i, string cmpntName)
|
||||
{
|
||||
if (i == 0) Sensor1 = cmpntName;
|
||||
else if (i == 1) Sensor2 = cmpntName;
|
||||
else if (i == 2) Sensor3 = cmpntName;
|
||||
else if (i == 3) Sensor4 = cmpntName;
|
||||
else if (i == 4) Sensor5 = cmpntName;
|
||||
else if (i == 5) Sensor6 = cmpntName;
|
||||
else if (i == 6) Sensor7 = cmpntName;
|
||||
else if (i == 7) Sensor8 = cmpntName;
|
||||
else if (i == 8) Sensor9 = cmpntName;
|
||||
else if (i == 9) Sensor10 = cmpntName;
|
||||
else if (i == 10) Sensor11 = cmpntName;
|
||||
else if (i == 11) Sensor12 = cmpntName;
|
||||
else if (i == 12) Sensor13 = cmpntName;
|
||||
else if (i == 13) Sensor14 = cmpntName;
|
||||
else if (i == 14) Sensor15 = cmpntName;
|
||||
else if (i == 15) Sensor16 = cmpntName;
|
||||
else if (i == 16) Sensor17 = cmpntName;
|
||||
else if (i == 17) Sensor18 = cmpntName;
|
||||
else if (i == 18) Sensor19 = cmpntName;
|
||||
else if (i == 19) Sensor20 = cmpntName;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,91 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace ResultsBrowser.Entities
|
||||
{
|
||||
public class OutputPath : IHasItemNr, IHasValves
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
public virtual int ItemNr { get; set; }
|
||||
public virtual string Name { get; set; }
|
||||
public virtual float Qfrom { get; set; } /// Water flow in [m3/h]
|
||||
public virtual float Qto { get; set; } /// Water flow in [m3/h]
|
||||
public virtual string RegulValve { get; set; }
|
||||
public virtual string FlowMeter { get; set; }
|
||||
public virtual float PidCoef { get; set; } /// PID coefficient for the regulation path
|
||||
public virtual string StartValve { get; set; }
|
||||
public virtual string Diverter { get; set; }
|
||||
public virtual string TempDiv { get; set; }
|
||||
public virtual string Balance { get; set; }
|
||||
public virtual string EmptyTankValve { get; set; }
|
||||
|
||||
/// Valves
|
||||
public virtual string ValvesOpen { get; set; }
|
||||
public virtual string ValvesClose { get; set; }
|
||||
|
||||
/// ------------- Additional stuff not mapped into the database -------------
|
||||
|
||||
public OutputPath()
|
||||
{
|
||||
}
|
||||
|
||||
public OutputPath(string name, int itemNr)
|
||||
: this()
|
||||
{
|
||||
Name = name;
|
||||
ItemNr = itemNr;
|
||||
}
|
||||
|
||||
public OutputPath(BenchControl.OutputPath path)
|
||||
: this(path.Name, path.ItemNr)
|
||||
{
|
||||
Qfrom = path.Qfrom;
|
||||
Qto = path.Qto;
|
||||
RegulValve = (path.RegulValve != null) ? path.RegulValve.Cfg.Name : null;
|
||||
FlowMeter = (path.FlowMeter != null) ? path.FlowMeter.Cfg.Name : null;
|
||||
PidCoef = path.PidCoef;
|
||||
StartValve = (path.StartValve != null) ? path.StartValve.Cfg.Name : null;
|
||||
Diverter = (path.Diverter != null) ? path.Diverter.Cfg.Name : null;
|
||||
TempDiv = (path.TempDiv != null) ? path.TempDiv.Cfg.Name : null;
|
||||
Balance = (path.Balance != null) ? path.Balance.Cfg.Name : null;
|
||||
EmptyTankValve = (path.EmptyTankValve != null) ? path.EmptyTankValve.Cfg.Name : null;
|
||||
|
||||
string vOpen = string.Empty;
|
||||
foreach (var valve in path.ValvesOpen)
|
||||
{
|
||||
if (vOpen != string.Empty) vOpen += ";";
|
||||
vOpen += valve.Cfg.Name;
|
||||
}
|
||||
ValvesOpen = vOpen;
|
||||
|
||||
string vClose = string.Empty;
|
||||
foreach (var valve in path.ValvesClose)
|
||||
{
|
||||
if (vClose != string.Empty) vClose += ";";
|
||||
vClose += valve.Cfg.Name;
|
||||
}
|
||||
ValvesClose = vClose;
|
||||
}
|
||||
|
||||
public virtual OutputPath Clone(string name, int itemNr)
|
||||
{
|
||||
OutputPath result = new OutputPath(name, itemNr);
|
||||
|
||||
result.Name = Name;
|
||||
result.Qfrom = Qfrom;
|
||||
result.Qto = Qto;
|
||||
result.RegulValve = RegulValve;
|
||||
result.FlowMeter = FlowMeter;
|
||||
result.PidCoef = PidCoef;
|
||||
result.StartValve = StartValve;
|
||||
result.Diverter = Diverter;
|
||||
result.TempDiv = TempDiv;
|
||||
result.Balance = Balance;
|
||||
result.EmptyTankValve = EmptyTankValve;
|
||||
result.ValvesOpen = ValvesOpen;
|
||||
result.ValvesClose = ValvesClose;
|
||||
|
||||
return result;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,90 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using TBF.Resources;
|
||||
|
||||
namespace ResultsBrowser.Entities
|
||||
{
|
||||
/// <summary>
|
||||
/// Stores one test procedure, supports revisions and history log
|
||||
/// </summary>
|
||||
public class Procedure : IHasItemNr
|
||||
{
|
||||
public virtual int Id { get; protected set; }
|
||||
public virtual int ItemNr { get; set; }
|
||||
public virtual string Name { get; set; }
|
||||
public virtual MetersKind MetersKind { get; set; }
|
||||
public virtual string Description { get; set; } /// Short description
|
||||
public virtual string CreationUser { get; set; } /// Name of the user who has created or changed this procedure
|
||||
public virtual DateTime CreationTime { get; set; } /// Date and time of the creation or change
|
||||
public virtual string LastChgUser { get; set; } /// Name of the user who has created or changed this procedure
|
||||
public virtual DateTime LastChgTime { get; set; } /// Date and time of the creation or change
|
||||
public virtual string LongDescription { get; set; } /// Long description (notes)
|
||||
public virtual string Watermeters { get; set; } /// Water meter name or Id
|
||||
public virtual string ProtocolTitle { get; set; } /// Title of the printed and saved protocol
|
||||
|
||||
public virtual string DataEntry { get; set; } /// Component to use for data entry
|
||||
public virtual string ResultsPrinter { get; set; } /// Component to use for printing the results
|
||||
public virtual string ResultsWriter { get; set; } /// Component to use for saving the results into the file
|
||||
public virtual string TransitionStart { get; set; }
|
||||
public virtual string TransitionEnd { get; set; }
|
||||
|
||||
public virtual IList<ComponentProcedure> MoreParams { get; set; }
|
||||
public virtual IList<Test> Tests { get; set; }
|
||||
|
||||
////public virtual string MetrologicalClass { get; set; }
|
||||
////public virtual IList<WMType> WMTypes { get; set; }
|
||||
|
||||
/// ------------- Additional stuff not mapped into the database -------------
|
||||
|
||||
public Procedure()
|
||||
{
|
||||
MoreParams = new List<ComponentProcedure>();
|
||||
Tests = new List<Test>();
|
||||
|
||||
///
|
||||
/// Default values
|
||||
///
|
||||
CreationUser = (User.CurrentUser != null) ? User.CurrentUser.Name : null;
|
||||
CreationTime = DateTime.Now;
|
||||
LastChgUser = CreationUser;
|
||||
LastChgTime = CreationTime;
|
||||
MetersKind = Entities.MetersKind.Single;
|
||||
ProtocolTitle = "Watermeter test protocol";
|
||||
}
|
||||
|
||||
public Procedure(string name, int itemNr)
|
||||
: this()
|
||||
{
|
||||
Name = name;
|
||||
ItemNr = itemNr;
|
||||
}
|
||||
|
||||
public virtual Procedure Clone()
|
||||
{
|
||||
Procedure result = new Procedure();
|
||||
|
||||
result.Name = Name;
|
||||
result.MetersKind = MetersKind;
|
||||
result.Description = Description;
|
||||
result.CreationUser = CreationUser;
|
||||
result.CreationTime = CreationTime;
|
||||
result.LastChgUser = LastChgUser;
|
||||
result.LastChgTime = LastChgTime;
|
||||
result.LongDescription = LongDescription;
|
||||
result.Watermeters = Watermeters;
|
||||
result.DataEntry = DataEntry;
|
||||
result.ResultsPrinter = ResultsPrinter;
|
||||
result.ResultsWriter = ResultsWriter;
|
||||
result.TransitionStart = TransitionStart;
|
||||
result.TransitionEnd = TransitionEnd;
|
||||
|
||||
foreach (var prms in MoreParams) { result.MoreParams.Add(prms.Clone()); }
|
||||
foreach (var test in Tests) { result.Tests.Add(test.Clone()); }
|
||||
|
||||
//result.MetrologicalClass = MetrologicalClass;
|
||||
//result.WMType = WMType.Clone();
|
||||
|
||||
return result;
|
||||
}
|
||||
}
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user