Compare commits
119
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2984ea2958 | ||
|
|
9043df05b7 | ||
|
|
9e025f2f06 | ||
|
|
b9835a31a0 | ||
|
|
c77fd822a6 | ||
|
|
60f30d65fd | ||
|
|
704232d231 | ||
|
|
79c5c022ea | ||
|
|
5bea046c01 | ||
|
|
6226a2812b | ||
|
|
4bff6f33de | ||
|
|
e0d10bed71 | ||
|
|
a1df68b888 | ||
|
|
a625e2dfdb | ||
|
|
0181294872 | ||
|
|
401828d4c6 | ||
|
|
2c6e5d3367 | ||
|
|
38983990c2 | ||
|
|
e02411d180 | ||
|
|
69f729b713 | ||
|
|
f773e26fa3 | ||
|
|
9fed5148b6 | ||
|
|
ab3a16bdc5 | ||
|
|
6e3f0dad0e | ||
|
|
ed066a005f | ||
|
|
d3126bd9ea | ||
|
|
1c638b3f87 | ||
|
|
f0afcd57a2 | ||
|
|
769cb230e3 | ||
|
|
3c52e54e02 | ||
|
|
068b7fb3a2 | ||
|
|
2ba6586a0e | ||
|
|
fa403a322a | ||
|
|
30627abc6a | ||
|
|
78772df3a0 | ||
|
|
426bb0cce9 | ||
|
|
3da6fcfe73 | ||
|
|
8f27d1a448 | ||
|
|
c5752f21a9 | ||
|
|
8c30cb21e2 | ||
|
|
5181f75217 | ||
|
|
7ee41afba2 | ||
|
|
5bb99bbf86 | ||
|
|
6fd67cdf08 | ||
|
|
e1bfa71310 | ||
|
|
2476ed7681 | ||
|
|
e413b55c6a | ||
|
|
7d2da63071 | ||
|
|
9aad4a60ab | ||
|
|
6ffbda6e96 | ||
|
|
72a8f1dac6 | ||
|
|
d2631c8c88 | ||
|
|
66b463c468 | ||
|
|
af38dbe81b | ||
|
|
42010a6c26 | ||
|
|
21d3f5e835 | ||
|
|
e93aa6a21e | ||
|
|
812ac96284 | ||
|
|
363f42e75b | ||
|
|
2232c31451 | ||
|
|
1c6e3c17fa | ||
|
|
4d0c34b544 | ||
|
|
93c2338d6c | ||
|
|
a455d62e9e | ||
|
|
aed42818b5 | ||
|
|
281aa93b4b | ||
|
|
3fee487c5d | ||
|
|
e50c636a34 | ||
|
|
1cbab1acd7 | ||
|
|
3bc8b55429 | ||
|
|
e6fc3c25d6 | ||
|
|
b965541b1c | ||
|
|
02fae9b11e | ||
|
|
1eda22a391 | ||
|
|
15c916ae66 | ||
|
|
03fb87e6ed | ||
|
|
bf67b4a4ec | ||
|
|
78d05fb1b9 | ||
|
|
0d47578441 | ||
|
|
07d75b7d00 | ||
|
|
cc88308513 | ||
|
|
bdf3d155f4 | ||
|
|
fe4531ad4c | ||
|
|
23f9331460 | ||
|
|
0d6875065c | ||
|
|
b56f712c71 | ||
|
|
7cc20771fe | ||
|
|
3efb042d18 | ||
|
|
fba8c52dfb | ||
|
|
aa10ea5c04 | ||
|
|
f457278342 | ||
|
|
a0c45d2b39 | ||
|
|
799e5be919 | ||
|
|
08c4541914 | ||
|
|
7b95f5f436 | ||
|
|
f0e57554f2 | ||
|
|
c8a5640ddc | ||
|
|
1a7a5661c4 | ||
|
|
94e83ad63a | ||
|
|
5d2008a6dd | ||
|
|
c315c8a42b | ||
|
|
aaa78d60db | ||
|
|
4b42b5ba7a | ||
|
|
6e04933eeb | ||
|
|
f47e7670a3 | ||
|
|
78575e4f6f | ||
|
|
b38ee92fe4 | ||
|
|
4ac72c6bbf | ||
|
|
c0e7eab3b2 | ||
|
|
5081969fdc | ||
|
|
df386a14f8 | ||
|
|
2b0ee55901 | ||
|
|
5b893d69b4 | ||
|
|
a50c867b7e | ||
|
|
ebcbd47f91 | ||
|
|
310ed6158a | ||
|
|
c64e8e773f | ||
|
|
56275063f7 | ||
|
|
d7401cfec4 |
+22
@@ -54,6 +54,28 @@ Users/bin/
|
||||
Users/obj/
|
||||
UserManagement/bin/
|
||||
UserManagement/obj/
|
||||
DataMatrix4Net/bin/
|
||||
DataMatrix4Net/obj/
|
||||
GenericTest/bin/
|
||||
GenericTest/obj/
|
||||
LabelPrinting/bin/
|
||||
LabelPrinting/obj/
|
||||
OrderManagement/bin/
|
||||
OrderManagement/obj/
|
||||
ProductionTracing/bin/
|
||||
ProductionTracing/obj/
|
||||
RecordProcessing/bin/
|
||||
RecordProcessing/obj/
|
||||
S640TestApp/bin/
|
||||
S640TestApp/obj/
|
||||
SchematicDrawing/bin/
|
||||
SchematicDrawing/obj/
|
||||
SharedDatabase/bin/
|
||||
SharedDatabase/obj/
|
||||
WorkflowConfigurator/bin/
|
||||
WorkflowConfigurator/obj/
|
||||
Workplace/bin/
|
||||
Workplace/obj/
|
||||
.vs/
|
||||
*.suo
|
||||
*.bak
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?><configuration>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
+34
-1
@@ -20,6 +20,7 @@
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<DebugType>pdbonly</DebugType>
|
||||
@@ -28,11 +29,39 @@
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Drawing" />
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Windows.Forms" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
@@ -42,6 +71,7 @@
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="BackgroundBeep.cs" />
|
||||
<Compile Include="Const.cs" />
|
||||
<Compile Include="DatabaseSettings.cs" />
|
||||
<Compile Include="DBSettings.cs" />
|
||||
<Compile Include="Enums.cs" />
|
||||
@@ -92,7 +122,10 @@
|
||||
<DependentUpon>ModelessForm.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
</ItemGroup>
|
||||
<ItemGroup />
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
<None Include="packages.config" />
|
||||
</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.
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
///
|
||||
/// Copyright (c) 2023 Sensus Slovensko a.s.
|
||||
///
|
||||
using System;
|
||||
|
||||
namespace Common
|
||||
{
|
||||
public static class Const
|
||||
{
|
||||
public const string MySqlConnectTimeoutSec = "120";
|
||||
}
|
||||
}
|
||||
@@ -12,6 +12,7 @@ namespace Common
|
||||
{
|
||||
public DBType DbType;
|
||||
public string ConnectionString;
|
||||
public bool IsValid { get { return (DbType != DBType.None) && !string.IsNullOrEmpty(ConnectionString); } }
|
||||
|
||||
public DBSettings()
|
||||
{
|
||||
|
||||
@@ -15,10 +15,10 @@ namespace Common
|
||||
// Public fields
|
||||
public string BenchName;
|
||||
public bool IsRealBench;
|
||||
public DBSettings ProceduresDBSettings; /// Configuration database settings
|
||||
public DBSettings ProceduresDBSettings; /// Configuration database settings
|
||||
public DBSettings WaterMetersDBSettings; /// Results database settings
|
||||
public DBSettings EventsDBSettings; /// Events database settings
|
||||
public DBSettings UsersDBSettings; /// Shared configuration database settings
|
||||
public DBSettings EventsDBSettings; /// Events database settings
|
||||
public DBSettings UsersDBSettings; /// Shared configuration database settings
|
||||
|
||||
// Constructor
|
||||
public DatabaseSettings()
|
||||
|
||||
+9
-10
@@ -1,5 +1,5 @@
|
||||
///
|
||||
/// Copyright (c) 2013-2022 Sensus Slovensko a.s.
|
||||
/// Copyright (c) 2013-2023 Sensus Slovensko a.s.
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
@@ -49,15 +49,6 @@ namespace Common
|
||||
Count
|
||||
}
|
||||
|
||||
/// <summary> Identifies the database based on the content </summary>
|
||||
public enum DBKind
|
||||
{
|
||||
Config,
|
||||
Results,
|
||||
RemoteConfig,
|
||||
Count
|
||||
}
|
||||
|
||||
public enum ProcedureSelection
|
||||
{
|
||||
#if LANG_CS
|
||||
@@ -223,6 +214,14 @@ namespace Common
|
||||
Count,
|
||||
}
|
||||
|
||||
public enum FlowNames
|
||||
{
|
||||
QnQtQmin = 0,
|
||||
Q3Q2Q1 = 1,
|
||||
QpQi = 2,
|
||||
Count,
|
||||
}
|
||||
|
||||
public enum ProfileType
|
||||
{
|
||||
Q3R,
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
using System;
|
||||
///
|
||||
/// Copyright (c) 2021-2023 Sensus Slovensko a.s.
|
||||
///
|
||||
using System;
|
||||
using System.Drawing;
|
||||
using System.Windows.Forms;
|
||||
|
||||
@@ -53,20 +56,20 @@ namespace Common.Forms
|
||||
public event EventHandler<MessageEventArgs> UpdateMessageHandler;
|
||||
void OnUpdateMessage(object sender, MessageEventArgs args)
|
||||
{
|
||||
if (args.Message != null) label1.Text = args.Message;
|
||||
if (args != null && args.Message != null) label1.Text = args.Message;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Called from the state machine when an operation forces a modeless dialog close.
|
||||
/// </summary>
|
||||
public static void CloseForm()
|
||||
public void CloseForm()
|
||||
{
|
||||
if (CloseFormHandler == null) return;
|
||||
try { CloseFormHandler(null, null); }
|
||||
catch (Exception) { }
|
||||
}
|
||||
static public event EventHandler<EventArgs> CloseFormHandler;
|
||||
public event EventHandler<EventArgs> CloseFormHandler;
|
||||
void OnCloseForm(object sender, EventArgs args)
|
||||
{
|
||||
DialogResult = DialogResult.Cancel;
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
/// Copyright (c) 2021-2022 Sensus Slovensko a.s.
|
||||
///
|
||||
using System;
|
||||
using System.IO.Ports;
|
||||
|
||||
namespace Common
|
||||
{
|
||||
@@ -20,6 +21,18 @@ namespace Common
|
||||
return (format == "F0") ? value.ToString("F0") : value.ToString(format).TrimEnd(new char[] { '0' });
|
||||
}
|
||||
|
||||
public static FlowNames ProfileType2FlowNames(ProfileType pt)
|
||||
{
|
||||
switch (pt)
|
||||
{
|
||||
case ProfileType.Q3R: return FlowNames.Q3Q2Q1;
|
||||
case ProfileType.QnClassColdWater: return FlowNames.QnQtQmin;
|
||||
case ProfileType.QnClassHotWater: return FlowNames.QnQtQmin;
|
||||
case ProfileType.QpQi: return FlowNames.QpQi;
|
||||
default: return FlowNames.Q3Q2Q1;
|
||||
}
|
||||
}
|
||||
|
||||
public static string SignificantDigitsToFmt(double value, int sigDigits)
|
||||
{
|
||||
if (sigDigits == 6)
|
||||
@@ -92,5 +105,33 @@ namespace Common
|
||||
else return "F5";
|
||||
}
|
||||
}
|
||||
|
||||
public static Parity GetParity(string str, Parity defaultParity = Parity.None)
|
||||
{
|
||||
if (str.Equals(Parity.None.ToString())) return Parity.None;
|
||||
if (str.Equals(Parity.Even.ToString())) return Parity.Even;
|
||||
if (str.Equals(Parity.Odd.ToString())) return Parity.Odd;
|
||||
if (str.Equals(Parity.Mark.ToString())) return Parity.Mark;
|
||||
if (str.Equals(Parity.Space.ToString())) return Parity.Space;
|
||||
return defaultParity;
|
||||
}
|
||||
|
||||
public static StopBits GetStopBits(string str, StopBits defaultStopBits = StopBits.One)
|
||||
{
|
||||
if (str.Equals(StopBits.None.ToString())) return StopBits.None;
|
||||
if (str.Equals(StopBits.One.ToString())) return StopBits.One;
|
||||
if (str.Equals(StopBits.OnePointFive.ToString())) return StopBits.OnePointFive;
|
||||
if (str.Equals(StopBits.Two.ToString())) return StopBits.Two;
|
||||
return defaultStopBits;
|
||||
}
|
||||
|
||||
public static Handshake GetHandshake(string str, Handshake defaultHandshake = Handshake.None)
|
||||
{
|
||||
if (str.Equals(Handshake.None.ToString())) return Handshake.None;
|
||||
if (str.Equals(Handshake.RequestToSend.ToString())) return Handshake.RequestToSend;
|
||||
if (str.Equals(Handshake.XOnXOff.ToString())) return Handshake.XOnXOff;
|
||||
if (str.Equals(Handshake.RequestToSendXOnXOff.ToString())) return Handshake.RequestToSendXOnXOff;
|
||||
return defaultHandshake;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="FluentNHibernate" version="3.4.0" targetFramework="net472" />
|
||||
<package id="Iesi.Collections" version="4.0.4" targetFramework="net472" />
|
||||
<package id="NHibernate" version="5.5.2" targetFramework="net472" />
|
||||
<package id="Antlr3.Runtime" version="3.5.1" targetFramework="net472" />
|
||||
<package id="Remotion.Linq" version="2.2.0" targetFramework="net472" />
|
||||
<package id="Remotion.Linq.EagerFetching" version="2.2.0" targetFramework="net472" />
|
||||
<package id="VisualBasic.PowerPacks.Vs" version="1.0.0" targetFramework="net472" />
|
||||
</packages>
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?><configuration>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
@@ -122,7 +122,7 @@ namespace Config.CalendarEvent
|
||||
}
|
||||
|
||||
|
||||
public static bool IsCalendarEventTrigerred(ICalendarEvent evnt, DateTime currentDate)
|
||||
public static bool IsCalendarEventTrigerred(ICalendarEvent evnt, DateTime dateTimeNow)
|
||||
{
|
||||
DateTime evntDT = evnt.AllDay
|
||||
? new DateTime(evnt.Date.Year, evnt.Date.Month, evnt.Date.Day, 0, 0, 0)
|
||||
@@ -133,17 +133,17 @@ namespace Config.CalendarEvent
|
||||
DateTime dt1 = evntDT;
|
||||
DateTime dt2 = evntDT + new TimeSpan(8, 0, 0);
|
||||
DateTime dt3 = evntDT + new TimeSpan(16, 0, 0);
|
||||
return (currentDate >= dt1) || (currentDate >= dt1) || (currentDate >= dt3);
|
||||
return (dateTimeNow >= dt1) || (dateTimeNow >= dt1) || (dateTimeNow >= dt3);
|
||||
}
|
||||
else if (!evnt.TriggerOnExactDayOnly)
|
||||
{
|
||||
/// Trigger after event expires
|
||||
return (currentDate >= evntDT);
|
||||
return (dateTimeNow >= evntDT);
|
||||
}
|
||||
else
|
||||
{
|
||||
/// Trigger event on exact date only
|
||||
return (currentDate >= evntDT) && DayMatchesExactly(evnt, currentDate);
|
||||
return (dateTimeNow >= evntDT) && DayMatchesExactly(evnt, dateTimeNow);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+31
-8
@@ -19,7 +19,7 @@
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<DefineConstants>TRACE;DEBUG;MUNICH</DefineConstants>
|
||||
<DefineConstants>TRACE;DEBUG;MILWAUKEE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<AllowUnsafeBlocks>false</AllowUnsafeBlocks>
|
||||
@@ -30,28 +30,45 @@
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>TRACE;MUNICH</DefineConstants>
|
||||
<DefineConstants>TRACE;MILWAUKEE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<Prefer32Bit>false</Prefer32Bit>
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="FluentNHibernate">
|
||||
<HintPath>..\packages\FluentNHibernate.2.0.3.0\lib\net40\FluentNHibernate.dll</HintPath>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.0.4000\lib\net40\Iesi.Collections.dll</HintPath>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="log4net">
|
||||
<HintPath>..\packages\log4net.2.0.2\lib\net40-full\log4net.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.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 Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Configuration" />
|
||||
<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>
|
||||
@@ -59,6 +76,8 @@
|
||||
<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.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Windows.Forms" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
@@ -146,6 +165,10 @@
|
||||
<Name>Users</Name>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
<None Include="packages.config" />
|
||||
</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.
|
||||
|
||||
+7
-1
@@ -38,12 +38,18 @@ namespace Config
|
||||
public const int CompoundWMsCount = 3;
|
||||
public const int HeatMetersCount = 0;
|
||||
public const int MaxPartNr = 3;
|
||||
#elif RUM_MOB || TURA_SPECIAL
|
||||
#elif RUM_MOB
|
||||
public const int WMsCount = 8;
|
||||
public const int LineSize = 8;
|
||||
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 DEWA_300 || FUZHOU_100 || ROMA_200 || LUXEMBURG_40
|
||||
public const int WMsCount = 10;
|
||||
public const int LineSize = 10;
|
||||
|
||||
@@ -46,8 +46,8 @@ namespace Config.Entities
|
||||
Rank = 2;
|
||||
Hidden = false;
|
||||
ReadOnly = false;
|
||||
BackColor = unchecked((int)0xFFFF5050);
|
||||
TextColor = unchecked((int)0xFFFFFFFF);
|
||||
BackColor = unchecked((int)0xFFFF5050); /// (MSB)AARRGGBB(LSB) ... pink
|
||||
TextColor = unchecked((int)0xFFFFFFFF); /// (MSB)AARRGGBB(LSB) ... white
|
||||
TooltipEnabled = true;
|
||||
CustomRecurringFunction = null;
|
||||
}
|
||||
|
||||
@@ -47,7 +47,7 @@ namespace Config.Entities
|
||||
public virtual int AltProcPeriod { get; set; } /// Period of alternative procedures (0 = no alt. procedure)
|
||||
|
||||
public virtual float DN { get; set; } /// Not mapped to DB, valid in ProceduresCtrl for procedure filtering only
|
||||
public virtual float Qn { get; set; } /// - ' ' -
|
||||
public virtual double Qn { get; set; } /// - ' ' -
|
||||
public virtual string MClass { get; set; } /// - ' ' -
|
||||
public virtual string Producer { get; set; } /// - ' ' -
|
||||
|
||||
|
||||
+11
-11
@@ -1,5 +1,5 @@
|
||||
///
|
||||
/// Copyright (c) 2013-2022 Sensus Slovensko a.s.
|
||||
/// Copyright (c) 2013-2023 Sensus Slovensko a.s.
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
@@ -22,11 +22,11 @@ namespace Config.Entities
|
||||
public virtual TestProfile Profile { get; set; } /// UserDefined, Protected, UserDefinedHeatMeter, ProtectedHeatMeter
|
||||
public virtual sbyte Publish { get; set; } /// 0=no, 1=in all protocols, 2=on screen, 3=internal
|
||||
public virtual bool DoEvaluate { get; set; }
|
||||
public virtual float Qtg { get; set; } /// Target water flow [m3/h]
|
||||
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 TestTime { get; set; } /// Test time (estimate) in [s]
|
||||
public virtual double Qtg { get; set; } /// Target water flow [m3/h]
|
||||
public virtual double Qfrom { get; set; } /// Water flow low limit in [m3/h]
|
||||
public virtual double Qto { get; set; } /// Water flow high limit in [m3/h]
|
||||
public virtual double Volume { get; set; } /// Test volume (target) in [l]
|
||||
public virtual double TestTime { get; set; } /// Test time (estimate) in [s]
|
||||
public virtual string Method { get; set; }
|
||||
public virtual float ErrLimLo { get; set; } /// in [%] usually < 0, in case of heat meters: 1=class1, 2=class2, 3=class3
|
||||
public virtual float ErrLimHi { get; set; } /// in [%] usually > 0, in case of heat meters: -Qn in m3/h
|
||||
@@ -292,11 +292,11 @@ namespace Config.Entities
|
||||
tst.Part = int.Parse(input.ReadLine(), ci);
|
||||
tst.Publish = sbyte.Parse(input.ReadLine(), ci);
|
||||
tst.DoEvaluate = bool.Parse(input.ReadLine());
|
||||
tst.Qtg = float.Parse(input.ReadLine(), ci);
|
||||
tst.Qfrom = float.Parse(input.ReadLine(), ci);
|
||||
tst.Qto = float.Parse(input.ReadLine(), ci);
|
||||
tst.Volume = float.Parse(input.ReadLine(), ci);
|
||||
tst.TestTime = float.Parse(input.ReadLine(), ci);
|
||||
tst.Qtg = double.Parse(input.ReadLine(), ci);
|
||||
tst.Qfrom = double.Parse(input.ReadLine(), ci);
|
||||
tst.Qto = double.Parse(input.ReadLine(), ci);
|
||||
tst.Volume = double.Parse(input.ReadLine(), ci);
|
||||
tst.TestTime = double.Parse(input.ReadLine(), ci);
|
||||
tst.Method = input.ReadLine();
|
||||
tst.ErrLimLo = float.Parse(input.ReadLine(), ci);
|
||||
tst.ErrLimHi = float.Parse(input.ReadLine(), ci);
|
||||
|
||||
@@ -1,148 +1,10 @@
|
||||
///
|
||||
/// Copyright (c) 2013-2018 Sensus Slovensko a.s.
|
||||
///
|
||||
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>
|
||||
/// NHibernate session factory (to create the database session 'SessionFactory')
|
||||
/// </summary>
|
||||
/// <returns>A database session</returns>
|
||||
public static ISessionFactory CreateSessionFactory(Common.DBKind database, Common.DBType dbType, string connectionString, bool createDB)
|
||||
{
|
||||
try
|
||||
{
|
||||
FluentConfiguration cfg = Fluently.Configure();
|
||||
|
||||
switch (dbType)
|
||||
{
|
||||
default:
|
||||
case Common.DBType.MySql:
|
||||
cfg = cfg.Database(MySQLConfiguration.Standard.ConnectionString(connectionString));
|
||||
break;
|
||||
case Common.DBType.SQLite:
|
||||
cfg = cfg.Database(SQLiteConfiguration.Standard.UsingFile(connectionString));
|
||||
break;
|
||||
}
|
||||
|
||||
switch (database)
|
||||
{
|
||||
default:
|
||||
case Common.DBKind.Config:
|
||||
case Common.DBKind.RemoteConfig:
|
||||
cfg = cfg.Mappings(m => m.FluentMappings.AddFromAssemblyOf<Data>());
|
||||
break;
|
||||
case Common.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);
|
||||
}
|
||||
|
||||
/// <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(Common.DBType dbType, string connectionString)
|
||||
{
|
||||
ISessionFactory sessionFactory = CreateSessionFactory(Common.DBKind.Config, dbType, connectionString, true);
|
||||
if (sessionFactory == null) return false;
|
||||
|
||||
/// Populate the database
|
||||
using (var session = sessionFactory.OpenSession())
|
||||
{
|
||||
using (var transaction = session.BeginTransaction())
|
||||
{
|
||||
///
|
||||
/// Create user 'admin'
|
||||
///
|
||||
var admin = new Config.Entities.User
|
||||
{
|
||||
UserName = Data.AdminUsername,
|
||||
FullName = Strings.Administrator,
|
||||
LastPwChange = DateTime.Now
|
||||
};
|
||||
admin.SetPassword(Data.AdminPassword);
|
||||
|
||||
///
|
||||
/// Prepare all groups, add some of them to admin
|
||||
///
|
||||
for (Common.GID gid = 0; gid < Common.GID.NrOfGroups; gid++)
|
||||
{
|
||||
Config.Entities.Group group = new Config.Entities.Group(gid);
|
||||
switch (gid)
|
||||
{
|
||||
case Common.GID.Testers:
|
||||
case Common.GID.TestingSpecialists:
|
||||
case Common.GID.HeadOfLab:
|
||||
case Common.GID.MaintenanceSpecialists:
|
||||
case Common.GID.Metrologists:
|
||||
case Common.GID.CalibrationSpecialists:
|
||||
case Common.GID.Administrators:
|
||||
#if TURA_IPERL || TURA_IPERL_NEW || TURA_SPECIAL
|
||||
case Common.GID.TraceabilityManagement:
|
||||
#elif KEMPNO_50 || KRAKOW_50 || TORUN_50 || WARSAW_50 || WARSAW_END
|
||||
case Common.GID.MetrologicalAuthority:
|
||||
case Common.GID.WaterMeterAuthority:
|
||||
#endif
|
||||
admin.AddGroup(group);
|
||||
session.SaveOrUpdate(group); /// Save this group
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
session.SaveOrUpdate(admin); /// Save user 'admin'
|
||||
transaction.Commit();
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+2
-2
@@ -214,9 +214,9 @@ namespace Config
|
||||
/// </summary>
|
||||
public static double ErrorFromVolumes(double measuredVolume, double trueVolume)
|
||||
{
|
||||
if (trueVolume <= float.Epsilon)
|
||||
if (-float.Epsilon <= trueVolume && trueVolume <= float.Epsilon)
|
||||
{
|
||||
if (measuredVolume <= float.Epsilon)
|
||||
if (-float.Epsilon <= measuredVolume && measuredVolume <= float.Epsilon)
|
||||
{
|
||||
log.WarnFormat("ErrorFromVolumes({0},{1}) returns {2}", measuredVolume, trueVolume, -100.0);
|
||||
return -100.0;
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="FluentNHibernate" version="3.4.0" targetFramework="net472" />
|
||||
<package id="Iesi.Collections" version="4.0.4" targetFramework="net472" />
|
||||
<package id="NHibernate" version="5.5.2" targetFramework="net472" />
|
||||
<package id="Antlr3.Runtime" version="3.5.1" targetFramework="net472" />
|
||||
<package id="Remotion.Linq" version="2.2.0" targetFramework="net472" />
|
||||
<package id="Remotion.Linq.EagerFetching" version="2.2.0" targetFramework="net472" />
|
||||
<package id="VisualBasic.PowerPacks.Vs" version="1.0.0" targetFramework="net472" />
|
||||
</packages>
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?><configuration>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
@@ -22,6 +22,7 @@
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<Prefer32Bit>false</Prefer32Bit>
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<DebugType>pdbonly</DebugType>
|
||||
@@ -31,11 +32,39 @@
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<Prefer32Bit>false</Prefer32Bit>
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.ComponentModel.Composition" />
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
@@ -53,6 +82,10 @@
|
||||
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
||||
</Content>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
<None Include="packages.config" />
|
||||
</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.
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="FluentNHibernate" version="3.4.0" targetFramework="net472" />
|
||||
<package id="Iesi.Collections" version="4.0.4" targetFramework="net472" />
|
||||
<package id="NHibernate" version="5.5.2" targetFramework="net472" />
|
||||
<package id="Antlr3.Runtime" version="3.5.1" targetFramework="net472" />
|
||||
<package id="Remotion.Linq" version="2.2.0" targetFramework="net472" />
|
||||
<package id="Remotion.Linq.EagerFetching" version="2.2.0" targetFramework="net472" />
|
||||
<package id="VisualBasic.PowerPacks.Vs" version="1.0.0" targetFramework="net472" />
|
||||
</packages>
|
||||
@@ -1,6 +1,14 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<configuration>
|
||||
<startup>
|
||||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" />
|
||||
</startup>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
@@ -32,9 +32,36 @@
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.ComponentModel.Composition" />
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
@@ -104,6 +131,7 @@
|
||||
<AutoGen>True</AutoGen>
|
||||
<DependentUpon>Resources.resx</DependentUpon>
|
||||
</Compile>
|
||||
<None Include="packages.config" />
|
||||
<None Include="Properties\Settings.settings">
|
||||
<Generator>SettingsSingleFileGenerator</Generator>
|
||||
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="FluentNHibernate" version="3.4.0" targetFramework="net472" />
|
||||
<package id="Iesi.Collections" version="4.0.4" targetFramework="net472" />
|
||||
<package id="NHibernate" version="5.5.2" targetFramework="net472" />
|
||||
<package id="Antlr3.Runtime" version="3.5.1" targetFramework="net472" />
|
||||
<package id="Remotion.Linq" version="2.2.0" targetFramework="net472" />
|
||||
<package id="Remotion.Linq.EagerFetching" version="2.2.0" targetFramework="net472" />
|
||||
<package id="VisualBasic.PowerPacks.Vs" version="1.0.0" targetFramework="net472" />
|
||||
</packages>
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?><configuration>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
@@ -20,6 +20,7 @@
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<PlatformTarget>x64</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<DebugType>pdbonly</DebugType>
|
||||
@@ -28,12 +29,40 @@
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<PlatformTarget>x64</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.ComponentModel.Composition" />
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Drawing" />
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Windows.Forms" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
@@ -74,6 +103,10 @@
|
||||
<SubType>Designer</SubType>
|
||||
</EmbeddedResource>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
<None Include="packages.config" />
|
||||
</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.
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="FluentNHibernate" version="3.4.0" targetFramework="net472" />
|
||||
<package id="Iesi.Collections" version="4.0.4" targetFramework="net472" />
|
||||
<package id="NHibernate" version="5.5.2" targetFramework="net472" />
|
||||
<package id="Antlr3.Runtime" version="3.5.1" targetFramework="net472" />
|
||||
<package id="Remotion.Linq" version="2.2.0" targetFramework="net472" />
|
||||
<package id="Remotion.Linq.EagerFetching" version="2.2.0" targetFramework="net472" />
|
||||
<package id="VisualBasic.PowerPacks.Vs" version="1.0.0" targetFramework="net472" />
|
||||
</packages>
|
||||
@@ -40,8 +40,35 @@
|
||||
<StartupObject>Decrypt.Program</StartupObject>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
@@ -54,6 +81,7 @@
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="app.config" />
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||
|
||||
+11
-2
@@ -1,3 +1,12 @@
|
||||
<?xml version="1.0"?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<configuration>
|
||||
<startup><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2"/></startup></configuration>
|
||||
<startup><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" /></startup>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="FluentNHibernate" version="3.4.0" targetFramework="net472" />
|
||||
<package id="Iesi.Collections" version="4.0.4" targetFramework="net472" />
|
||||
<package id="NHibernate" version="5.5.2" targetFramework="net472" />
|
||||
<package id="Antlr3.Runtime" version="3.5.1" targetFramework="net472" />
|
||||
<package id="Remotion.Linq" version="2.2.0" targetFramework="net472" />
|
||||
<package id="Remotion.Linq.EagerFetching" version="2.2.0" targetFramework="net472" />
|
||||
<package id="VisualBasic.PowerPacks.Vs" version="1.0.0" targetFramework="net472" />
|
||||
</packages>
|
||||
@@ -40,12 +40,39 @@
|
||||
<StartupObject>DeviceTest.Program</StartupObject>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<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="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
@@ -79,6 +106,7 @@
|
||||
<DesignTime>True</DesignTime>
|
||||
</Compile>
|
||||
<None Include="app.config" />
|
||||
<None Include="packages.config" />
|
||||
<None Include="Properties\Settings.settings">
|
||||
<Generator>SettingsSingleFileGenerator</Generator>
|
||||
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
|
||||
|
||||
+11
-2
@@ -1,3 +1,12 @@
|
||||
<?xml version="1.0"?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<configuration>
|
||||
<startup><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2"/></startup></configuration>
|
||||
<startup><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" /></startup>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="FluentNHibernate" version="3.4.0" targetFramework="net472" />
|
||||
<package id="Iesi.Collections" version="4.0.4" targetFramework="net472" />
|
||||
<package id="NHibernate" version="5.5.2" targetFramework="net472" />
|
||||
<package id="Antlr3.Runtime" version="3.5.1" targetFramework="net472" />
|
||||
<package id="Remotion.Linq" version="2.2.0" targetFramework="net472" />
|
||||
<package id="Remotion.Linq.EagerFetching" version="2.2.0" targetFramework="net472" />
|
||||
<package id="VisualBasic.PowerPacks.Vs" version="1.0.0" targetFramework="net472" />
|
||||
</packages>
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?><configuration>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
@@ -24,6 +24,7 @@
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<Prefer32Bit>false</Prefer32Bit>
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<DebugType>pdbonly</DebugType>
|
||||
@@ -33,16 +34,49 @@
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<Prefer32Bit>false</Prefer32Bit>
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
<Reference Include="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Numerics" />
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Int128.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<Compile Include="UInt128.cs" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
<None Include="packages.config" />
|
||||
</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.
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="FluentNHibernate" version="3.4.0" targetFramework="net472" />
|
||||
<package id="Iesi.Collections" version="4.0.4" targetFramework="net472" />
|
||||
<package id="NHibernate" version="5.5.2" targetFramework="net472" />
|
||||
<package id="Antlr3.Runtime" version="3.5.1" targetFramework="net472" />
|
||||
<package id="Remotion.Linq" version="2.2.0" targetFramework="net472" />
|
||||
<package id="Remotion.Linq.EagerFetching" version="2.2.0" targetFramework="net472" />
|
||||
<package id="VisualBasic.PowerPacks.Vs" version="1.0.0" targetFramework="net472" />
|
||||
</packages>
|
||||
@@ -40,8 +40,35 @@
|
||||
<StartupObject>Encrypt.Program</StartupObject>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
@@ -54,6 +81,7 @@
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="app.config" />
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||
|
||||
+11
-2
@@ -1,3 +1,12 @@
|
||||
<?xml version="1.0"?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<configuration>
|
||||
<startup><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2"/></startup></configuration>
|
||||
<startup><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" /></startup>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="FluentNHibernate" version="3.4.0" targetFramework="net472" />
|
||||
<package id="Iesi.Collections" version="4.0.4" targetFramework="net472" />
|
||||
<package id="NHibernate" version="5.5.2" targetFramework="net472" />
|
||||
<package id="Antlr3.Runtime" version="3.5.1" targetFramework="net472" />
|
||||
<package id="Remotion.Linq" version="2.2.0" targetFramework="net472" />
|
||||
<package id="Remotion.Linq.EagerFetching" version="2.2.0" targetFramework="net472" />
|
||||
<package id="VisualBasic.PowerPacks.Vs" version="1.0.0" targetFramework="net472" />
|
||||
</packages>
|
||||
@@ -1,6 +1,14 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<configuration>
|
||||
<startup>
|
||||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" />
|
||||
</startup>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
@@ -0,0 +1,143 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using FluentNHibernate.Cfg;
|
||||
using FluentNHibernate.Cfg.Db;
|
||||
using NHibernate;
|
||||
using NHibernate.Cfg;
|
||||
using NHibernate.Tool.hbm2ddl;
|
||||
using Common;
|
||||
using Events;
|
||||
|
||||
namespace EventViewer
|
||||
{
|
||||
public static class EViewerDB
|
||||
{
|
||||
/// <summary> Session factory for all regular sessions, not for CreateEmptyResultsDB(). </summary>
|
||||
public static ISessionFactory SessionFactory;
|
||||
|
||||
/// <summary> Connection string for all sessions </summary>
|
||||
static string connectionString;
|
||||
///
|
||||
public static string ConnectionString
|
||||
{
|
||||
get { return connectionString; }
|
||||
set
|
||||
{
|
||||
if (value != connectionString)
|
||||
{
|
||||
connectionString = value;
|
||||
SessionFactory = null; /// Clear SessionFactory on connection string change
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary> Database type (MySQL or SQLite) for all sessions </summary>
|
||||
private static DBType dbType;
|
||||
///
|
||||
public static 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 DBType.MySql:
|
||||
cfg = cfg.Database(MySQLConfiguration.Standard.ConnectionString(connectionString));
|
||||
break;
|
||||
case DBType.SQLite:
|
||||
cfg = cfg.Database(SQLiteConfiguration.Standard.UsingFile(connectionString));
|
||||
break;
|
||||
}
|
||||
|
||||
cfg = cfg.Mappings(m => m.FluentMappings.AddFromAssemblyOf<global::Events.Entities.Event>());
|
||||
|
||||
if (createDB)
|
||||
{
|
||||
return cfg.ExposeConfiguration(BuildSchemaCreate)
|
||||
.BuildConfiguration()
|
||||
.SetProperty("hibernate.connection.connect_timeout", Const.MySqlConnectTimeoutSec)
|
||||
.BuildSessionFactory();
|
||||
}
|
||||
else
|
||||
{
|
||||
return cfg.ExposeConfiguration(BuildSchema)
|
||||
.BuildConfiguration()
|
||||
.SetProperty("hibernate.connection.connect_timeout", Const.MySqlConnectTimeoutSec)
|
||||
.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();
|
||||
}
|
||||
|
||||
|
||||
/// <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;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -32,24 +32,39 @@
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="FluentNHibernate, Version=2.0.3.0, Culture=neutral, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>..\packages\FluentNHibernate.2.0.3.0\lib\net40\FluentNHibernate.dll</HintPath>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.0.4000\lib\net40\Iesi.Collections.dll</HintPath>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="MySql.Data">
|
||||
<HintPath>..\packages\MySql.Data.6.6.5\lib\net40\MySql.Data.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="NHibernate, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>..\packages\NHibernate.4.0.4.4000\lib\net40\NHibernate.dll</HintPath>
|
||||
<Reference Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Security" />
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
@@ -66,6 +81,7 @@
|
||||
<Compile Include="EventViewerWnd.Designer.cs">
|
||||
<DependentUpon>EventViewerWnd.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="EViewerDB.cs" />
|
||||
<Compile Include="Forms\EventDetailsDlg.cs">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
@@ -109,6 +125,7 @@
|
||||
<LastGenOutput>Strings.Designer.cs</LastGenOutput>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Resources\Strings.sk.resx" />
|
||||
<None Include="packages.config" />
|
||||
<None Include="Properties\Settings.settings">
|
||||
<Generator>SettingsSingleFileGenerator</Generator>
|
||||
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
|
||||
|
||||
@@ -102,9 +102,9 @@ namespace EventViewer
|
||||
{
|
||||
try
|
||||
{
|
||||
DB.DbType = DBType.MySql;
|
||||
DB.ConnectionString = Program.LocalSettings.ConnectionString;
|
||||
session = DB.CreateSession();
|
||||
EViewerDB.DbType = DBType.MySql;
|
||||
EViewerDB.ConnectionString = Program.LocalSettings.ConnectionString;
|
||||
session = EViewerDB.CreateSession();
|
||||
subscribers = session.QueryOver<Subscriber>().List();
|
||||
unreadEventsRadioButton.Checked = true;
|
||||
}
|
||||
@@ -277,7 +277,7 @@ namespace EventViewer
|
||||
private void settingsButton_Click(object sender, EventArgs e)
|
||||
{
|
||||
//Common.GID[] groupsWithAccess = new Common.GID[] { Common.GID.Administrators };
|
||||
Users.Forms.LoginDlg dlg = new Users.Forms.LoginDlg(true);
|
||||
Users.Forms.LoginDlg dlg = new Users.Forms.LoginDlg();
|
||||
if (dlg.ShowDialog() == DialogResult.OK)
|
||||
{
|
||||
if ((new Forms.SettingsDlg()).ShowDialog() == DialogResult.OK)
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="FluentNHibernate" version="3.4.0" targetFramework="net472" />
|
||||
<package id="Iesi.Collections" version="4.0.4" targetFramework="net472" />
|
||||
<package id="NHibernate" version="5.5.2" targetFramework="net472" />
|
||||
<package id="Antlr3.Runtime" version="3.5.1" targetFramework="net472" />
|
||||
<package id="Remotion.Linq" version="2.2.0" targetFramework="net472" />
|
||||
<package id="Remotion.Linq.EagerFetching" version="2.2.0" targetFramework="net472" />
|
||||
<package id="VisualBasic.PowerPacks.Vs" version="1.0.0" targetFramework="net472" />
|
||||
</packages>
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?><configuration>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
+7
-155
@@ -1,5 +1,5 @@
|
||||
///
|
||||
/// Copyright (c) 2020 Sensus Slovensko a.s.
|
||||
/// Copyright (c) 2020-2023 Sensus Slovensko a.s.
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
@@ -15,156 +15,6 @@ namespace Events
|
||||
{
|
||||
public static class DB
|
||||
{
|
||||
/// <summary> Session factory for all regular sessions, not for CreateEmptyResultsDB(). </summary>
|
||||
public static ISessionFactory SessionFactory;
|
||||
|
||||
/// <summary> Connection string for all sessions </summary>
|
||||
static string connectionString;
|
||||
///
|
||||
public static string ConnectionString
|
||||
{
|
||||
get { return connectionString; }
|
||||
set
|
||||
{
|
||||
if (value != connectionString)
|
||||
{
|
||||
connectionString = value;
|
||||
SessionFactory = null; /// Clear SessionFactory on connection string change
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary> Database type (MySQL or SQLite) for all sessions </summary>
|
||||
private static DBType dbType;
|
||||
///
|
||||
public static 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 DBType.MySql:
|
||||
cfg = cfg.Database(MySQLConfiguration.Standard.ConnectionString(connectionString));
|
||||
break;
|
||||
case DBType.SQLite:
|
||||
cfg = cfg.Database(SQLiteConfiguration.Standard.UsingFile(connectionString));
|
||||
break;
|
||||
}
|
||||
|
||||
cfg = cfg.Mappings(m => m.FluentMappings.AddFromAssemblyOf<Entities.Event>());
|
||||
|
||||
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 (initially empty)
|
||||
/// </summary>
|
||||
@@ -180,7 +30,7 @@ namespace Events
|
||||
DB.BenchName = benchName;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// <summary>
|
||||
/// Loads shared data from the database
|
||||
/// </summary>
|
||||
public static void LoadSubscribers(ISession session)
|
||||
@@ -193,6 +43,7 @@ namespace Events
|
||||
/// </summary>
|
||||
public static void LoadRecentEvents(ISession session, string benchName, int days)
|
||||
{
|
||||
BenchName = benchName;
|
||||
RecentEvents = session.QueryOver<Event>()
|
||||
.Where(e => (e.Bench == benchName))
|
||||
.And(e => (e.TimeStamp >= DateTime.Now - new TimeSpan(days, 0, 0, 0)))
|
||||
@@ -201,7 +52,8 @@ namespace Events
|
||||
|
||||
public static void SaveEvent(ISession session, Event evnt, SubscriberGroup groups)
|
||||
{
|
||||
if (allSubscribers == null) return;
|
||||
if (allSubscribers == null) LoadSubscribers(session);
|
||||
|
||||
IList<Subscriber> thisEventSubscribers = new List<Subscriber>();
|
||||
foreach (var s in allSubscribers)
|
||||
{
|
||||
@@ -211,10 +63,10 @@ namespace Events
|
||||
thisEventSubscribers.Add(s);
|
||||
}
|
||||
}
|
||||
evnt.Bench = BenchName;
|
||||
evnt.Subscribers = thisEventSubscribers;
|
||||
|
||||
evnt.Bench = BenchName;
|
||||
session.SaveOrUpdate(evnt);
|
||||
session.Flush();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+30
-6
@@ -22,6 +22,7 @@
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<Prefer32Bit>false</Prefer32Bit>
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<DebugType>pdbonly</DebugType>
|
||||
@@ -31,23 +32,42 @@
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<Prefer32Bit>false</Prefer32Bit>
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="FluentNHibernate">
|
||||
<HintPath>..\packages\FluentNHibernate.2.0.3.0\lib\net40\FluentNHibernate.dll</HintPath>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.0.4000\lib\net40\Iesi.Collections.dll</HintPath>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.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 Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Drawing" />
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
@@ -72,6 +92,10 @@
|
||||
<Name>Common</Name>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
<None Include="packages.config" />
|
||||
</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.
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="FluentNHibernate" version="3.4.0" targetFramework="net472" />
|
||||
<package id="Iesi.Collections" version="4.0.4" targetFramework="net472" />
|
||||
<package id="NHibernate" version="5.5.2" targetFramework="net472" />
|
||||
<package id="Antlr3.Runtime" version="3.5.1" targetFramework="net472" />
|
||||
<package id="Remotion.Linq" version="2.2.0" targetFramework="net472" />
|
||||
<package id="Remotion.Linq.EagerFetching" version="2.2.0" targetFramework="net472" />
|
||||
<package id="VisualBasic.PowerPacks.Vs" version="1.0.0" targetFramework="net472" />
|
||||
</packages>
|
||||
@@ -1,6 +1,14 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<configuration>
|
||||
<startup>
|
||||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" />
|
||||
</startup>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
@@ -35,8 +35,35 @@
|
||||
<StartupObject>FeatureVectorCalculator.Program</StartupObject>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Windows.Forms.DataVisualization" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
@@ -70,6 +97,7 @@
|
||||
<DependentUpon>Resources.resx</DependentUpon>
|
||||
<DesignTime>True</DesignTime>
|
||||
</Compile>
|
||||
<None Include="packages.config" />
|
||||
<None Include="Properties\Settings.settings">
|
||||
<Generator>SettingsSingleFileGenerator</Generator>
|
||||
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="FluentNHibernate" version="3.4.0" targetFramework="net472" />
|
||||
<package id="Iesi.Collections" version="4.0.4" targetFramework="net472" />
|
||||
<package id="NHibernate" version="5.5.2" targetFramework="net472" />
|
||||
<package id="Antlr3.Runtime" version="3.5.1" targetFramework="net472" />
|
||||
<package id="Remotion.Linq" version="2.2.0" targetFramework="net472" />
|
||||
<package id="Remotion.Linq.EagerFetching" version="2.2.0" targetFramework="net472" />
|
||||
<package id="VisualBasic.PowerPacks.Vs" version="1.0.0" targetFramework="net472" />
|
||||
</packages>
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?><configuration>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
@@ -116,12 +116,40 @@
|
||||
<Prefer32Bit>false</Prefer32Bit>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
<Reference Include="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System">
|
||||
<Name>System</Name>
|
||||
</Reference>
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Data">
|
||||
<Name>System.Data</Name>
|
||||
</Reference>
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Xml">
|
||||
<Name>System.XML</Name>
|
||||
</Reference>
|
||||
@@ -173,6 +201,10 @@
|
||||
<Install>true</Install>
|
||||
</BootstrapperPackage>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
|
||||
<PropertyGroup>
|
||||
<PreBuildEvent>
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="FluentNHibernate" version="3.4.0" targetFramework="net472" />
|
||||
<package id="Iesi.Collections" version="4.0.4" targetFramework="net472" />
|
||||
<package id="NHibernate" version="5.5.2" targetFramework="net472" />
|
||||
<package id="Antlr3.Runtime" version="3.5.1" targetFramework="net472" />
|
||||
<package id="Remotion.Linq" version="2.2.0" targetFramework="net472" />
|
||||
<package id="Remotion.Linq.EagerFetching" version="2.2.0" targetFramework="net472" />
|
||||
<package id="VisualBasic.PowerPacks.Vs" version="1.0.0" targetFramework="net472" />
|
||||
</packages>
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?><configuration>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
@@ -76,7 +76,7 @@
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<DebugType>full</DebugType>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<Prefer32Bit>false</Prefer32Bit>
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
@@ -100,18 +100,46 @@
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<DebugType>none</DebugType>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<Prefer32Bit>false</Prefer32Bit>
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
<Reference Include="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System">
|
||||
<Name>System</Name>
|
||||
</Reference>
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Data">
|
||||
<Name>System.Data</Name>
|
||||
</Reference>
|
||||
<Reference Include="System.Drawing">
|
||||
<Name>System.Drawing</Name>
|
||||
</Reference>
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Windows.Forms">
|
||||
<Name>System.Windows.Forms</Name>
|
||||
</Reference>
|
||||
@@ -139,6 +167,10 @@
|
||||
<Install>true</Install>
|
||||
</BootstrapperPackage>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
|
||||
<PropertyGroup>
|
||||
<PreBuildEvent>
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="FluentNHibernate" version="3.4.0" targetFramework="net472" />
|
||||
<package id="Iesi.Collections" version="4.0.4" targetFramework="net472" />
|
||||
<package id="NHibernate" version="5.5.2" targetFramework="net472" />
|
||||
<package id="Antlr3.Runtime" version="3.5.1" targetFramework="net472" />
|
||||
<package id="Remotion.Linq" version="2.2.0" targetFramework="net472" />
|
||||
<package id="Remotion.Linq.EagerFetching" version="2.2.0" targetFramework="net472" />
|
||||
<package id="VisualBasic.PowerPacks.Vs" version="1.0.0" targetFramework="net472" />
|
||||
</packages>
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?><configuration>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
@@ -27,6 +27,7 @@
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<Prefer32Bit>false</Prefer32Bit>
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<DebugType>pdbonly</DebugType>
|
||||
@@ -36,12 +37,41 @@
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<Prefer32Bit>false</Prefer32Bit>
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
<Reference Include="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Data" />
|
||||
<Reference Include="System.Design" />
|
||||
<Reference Include="System.Drawing" />
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Windows.Forms" />
|
||||
<Reference Include="System.Xml" />
|
||||
</ItemGroup>
|
||||
@@ -103,6 +133,10 @@
|
||||
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
|
||||
</EmbeddedResource>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildBinPath)\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.
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="FluentNHibernate" version="3.4.0" targetFramework="net472" />
|
||||
<package id="Iesi.Collections" version="4.0.4" targetFramework="net472" />
|
||||
<package id="NHibernate" version="5.5.2" targetFramework="net472" />
|
||||
<package id="Antlr3.Runtime" version="3.5.1" targetFramework="net472" />
|
||||
<package id="Remotion.Linq" version="2.2.0" targetFramework="net472" />
|
||||
<package id="Remotion.Linq.EagerFetching" version="2.2.0" targetFramework="net472" />
|
||||
<package id="VisualBasic.PowerPacks.Vs" version="1.0.0" targetFramework="net472" />
|
||||
</packages>
|
||||
@@ -1,6 +1,14 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<configuration>
|
||||
<startup>
|
||||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" />
|
||||
</startup>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
@@ -32,23 +32,41 @@
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="FluentNHibernate">
|
||||
<HintPath>..\packages\FluentNHibernate.2.0.3.0\lib\net40\FluentNHibernate.dll</HintPath>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.0.4000\lib\net40\Iesi.Collections.dll</HintPath>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="log4net">
|
||||
<HintPath>..\packages\log4net.2.0.2\lib\net40-full\log4net.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.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 Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Windows.Forms" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
@@ -62,6 +80,7 @@
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\Config\Config.csproj">
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="FluentNHibernate" version="3.4.0" targetFramework="net472" />
|
||||
<package id="Iesi.Collections" version="4.0.4" targetFramework="net472" />
|
||||
<package id="NHibernate" version="5.5.2" targetFramework="net472" />
|
||||
<package id="Antlr3.Runtime" version="3.5.1" targetFramework="net472" />
|
||||
<package id="Remotion.Linq" version="2.2.0" targetFramework="net472" />
|
||||
<package id="Remotion.Linq.EagerFetching" version="2.2.0" targetFramework="net472" />
|
||||
<package id="VisualBasic.PowerPacks.Vs" version="1.0.0" targetFramework="net472" />
|
||||
</packages>
|
||||
@@ -1,6 +1,14 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<configuration>
|
||||
<startup>
|
||||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" />
|
||||
</startup>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
@@ -32,8 +32,35 @@
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
@@ -46,6 +73,7 @@
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\Common\Common.csproj">
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="FluentNHibernate" version="3.4.0" targetFramework="net472" />
|
||||
<package id="Iesi.Collections" version="4.0.4" targetFramework="net472" />
|
||||
<package id="NHibernate" version="5.5.2" targetFramework="net472" />
|
||||
<package id="Antlr3.Runtime" version="3.5.1" targetFramework="net472" />
|
||||
<package id="Remotion.Linq" version="2.2.0" targetFramework="net472" />
|
||||
<package id="Remotion.Linq.EagerFetching" version="2.2.0" targetFramework="net472" />
|
||||
<package id="VisualBasic.PowerPacks.Vs" version="1.0.0" targetFramework="net472" />
|
||||
</packages>
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?><configuration>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
@@ -11,6 +11,7 @@
|
||||
<AssemblyName>RestClient</AssemblyName>
|
||||
<TargetFrameworkVersion>v4.7.2</TargetFrameworkVersion>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
<LangVersion>7.3</LangVersion>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
@@ -32,11 +33,38 @@
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Newtonsoft.Json.12.0.2\lib\net45\Newtonsoft.Json.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
@@ -53,6 +81,7 @@
|
||||
<Compile Include="Q2PreCorrection.cs" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
|
||||
@@ -1,4 +1,11 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="FluentNHibernate" version="3.4.0" targetFramework="net472" />
|
||||
<package id="Iesi.Collections" version="4.0.4" targetFramework="net472" />
|
||||
<package id="NHibernate" version="5.5.2" targetFramework="net472" />
|
||||
<package id="Antlr3.Runtime" version="3.5.1" targetFramework="net472" />
|
||||
<package id="Newtonsoft.Json" version="12.0.2" targetFramework="net472" />
|
||||
<package id="Remotion.Linq" version="2.2.0" targetFramework="net472" />
|
||||
<package id="Remotion.Linq.EagerFetching" version="2.2.0" targetFramework="net472" />
|
||||
<package id="VisualBasic.PowerPacks.Vs" version="1.0.0" targetFramework="net472" />
|
||||
</packages>
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?><configuration>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
@@ -174,7 +174,7 @@ namespace Results
|
||||
return Batch.GetTestRslt(name, part);
|
||||
}
|
||||
|
||||
public MeterTestRslt GetMeterTestRslt(string name, int wmNr0, CompoundMeterId meterId)
|
||||
public MeterTestRslt GetMeterTestRslt(string name, int wmNr0, CompoundMeterId meterId = CompoundMeterId.Single)
|
||||
{
|
||||
if (Batch.WaterMeters != null && Batch.WaterMeters.Count > wmNr0 && !Batch.WaterMeters[wmNr0].Disabled)
|
||||
{
|
||||
|
||||
+48
-16
@@ -78,11 +78,17 @@ namespace Results
|
||||
|
||||
if (createDB)
|
||||
{
|
||||
return cfg.ExposeConfiguration(BuildSchemaCreate).BuildSessionFactory();
|
||||
return cfg.ExposeConfiguration(BuildSchemaCreate)
|
||||
.BuildConfiguration()
|
||||
.SetProperty("hibernate.connection.connect_timeout", Common.Const.MySqlConnectTimeoutSec)
|
||||
.BuildSessionFactory();
|
||||
}
|
||||
else
|
||||
{
|
||||
return cfg.ExposeConfiguration(BuildSchema).BuildSessionFactory();
|
||||
return cfg.ExposeConfiguration(BuildSchema)
|
||||
.BuildConfiguration()
|
||||
.SetProperty("hibernate.connection.connect_timeout", Common.Const.MySqlConnectTimeoutSec)
|
||||
.BuildSessionFactory();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -180,29 +186,55 @@ namespace Results
|
||||
/// Loads shared data from the database
|
||||
/// </summary>
|
||||
/// <exception>Throws NHibernate exceptions</exception>
|
||||
public static void LoadSharedData()
|
||||
public static void LoadSharedData(ISession session = null)
|
||||
{
|
||||
ISession session = DB.CreateSession();
|
||||
bool openAndCloseSession = (session == null);
|
||||
|
||||
TestDataList = session.QueryOver<TestData>().List();
|
||||
ComponentsList = session.QueryOver<Components>().List();
|
||||
WaterMeterDataList = session.QueryOver<WaterMeterData>().List();
|
||||
}
|
||||
try
|
||||
{
|
||||
if (openAndCloseSession) session = Results.DB.CreateSession();
|
||||
TestDataList = session.QueryOver<TestData>().List();
|
||||
ComponentsList = session.QueryOver<Components>().List();
|
||||
WaterMeterDataList = session.QueryOver<WaterMeterData>().List();
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
log.ErrorFormat("Cannot open results DB: {0}", e.Message);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (openAndCloseSession && session != null && session.IsOpen) session.Close();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Loads shared data from the database
|
||||
/// </summary>
|
||||
/// <exception>Throws NHibernate exceptions</exception>
|
||||
public static int GetMaxSavedBatchNr()
|
||||
public static int GetMaxSavedBatchNr(ISession session = null)
|
||||
{
|
||||
ISession session = DB.CreateSession();
|
||||
IList<Entities.Batch> batches = session.QueryOver<Batch>().List();
|
||||
bool openAndCloseSession = (session == null);
|
||||
int maxBatchNr = 0;
|
||||
|
||||
try
|
||||
{
|
||||
if (openAndCloseSession) session = Results.DB.CreateSession();
|
||||
IList<Entities.Batch> batches = session.QueryOver<Batch>().List();
|
||||
|
||||
foreach (var b in batches)
|
||||
{
|
||||
if (b.BatchNr > maxBatchNr) maxBatchNr = b.BatchNr;
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
log.ErrorFormat("Cannot open results DB: {0}", e.Message);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (openAndCloseSession && session != null && session.IsOpen) session.Close();
|
||||
}
|
||||
|
||||
int maxBatchNr = 0;
|
||||
foreach (var b in batches)
|
||||
{
|
||||
if (b.BatchNr > maxBatchNr) maxBatchNr = b.BatchNr;
|
||||
}
|
||||
return maxBatchNr;
|
||||
}
|
||||
|
||||
|
||||
@@ -40,6 +40,8 @@ namespace Results
|
||||
.Database(MySQLConfiguration.Standard.ConnectionString(connectionString))
|
||||
.Mappings(m => m.FluentMappings.AddFromAssemblyOf<Entities.WaterMeterData>())
|
||||
.ExposeConfiguration(BuildSchema)
|
||||
.BuildConfiguration()
|
||||
.SetProperty("hibernate.connection.connect_timeout", Common.Const.MySqlConnectTimeoutSec)
|
||||
.BuildSessionFactory();
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
///
|
||||
/// Copyright (c) 2015-2021 Sensus Slovensko a.s.
|
||||
/// Copyright (c) 2015-2023 Sensus Slovensko a.s.
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
@@ -24,6 +24,8 @@ namespace Results.Entities
|
||||
public virtual int UserNumber { get; set; }
|
||||
public virtual string ProcedureName { get; set; }
|
||||
public virtual bool IsRemoteProcedure { get; set; } /// Stara Tura, not mapped to DB
|
||||
public virtual string PurchaseOrder { get; set; } /// Stara Tura, Nanjing, not mapped to DB
|
||||
public virtual string Workflow { get; set; } /// Stara Tura, Nanjing, not mapped to DB
|
||||
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
|
||||
@@ -39,6 +41,7 @@ namespace Results.Entities
|
||||
public virtual int Counter10 { get; set; }
|
||||
public virtual DateTime StartTime { get; set; }
|
||||
public virtual DateTime EndTime { get; set; }
|
||||
public virtual DateTime SaveTime { get; set; }
|
||||
public virtual bool Dirty { get; set; }
|
||||
public virtual bool RsltsSent { get; set; }
|
||||
public virtual bool RsltsPrinted { get; set; }
|
||||
@@ -157,6 +160,7 @@ namespace Results.Entities
|
||||
Counter10 = oriBatch.Counter10;
|
||||
StartTime = oriBatch.StartTime;
|
||||
EndTime = oriBatch.EndTime;
|
||||
SaveTime = oriBatch.SaveTime;
|
||||
Dirty = oriBatch.Dirty;
|
||||
RsltsSent = oriBatch.RsltsSent;
|
||||
RsltsPrinted = oriBatch.RsltsPrinted;
|
||||
@@ -321,16 +325,19 @@ namespace Results.Entities
|
||||
|
||||
public override string ToString()
|
||||
{
|
||||
return string.Format("Batch #{0}, Start:{1}, End:{2}, Procedure:{3}", BatchNr, StartTime, EndTime, ProcedureName);
|
||||
return string.Format("Batch {0} ({1}s) Start {2}, End {3}, Proc={4}",
|
||||
BatchNr, (EndTime - StartTime).TotalSeconds, StartTime, EndTime, ProcedureName);
|
||||
}
|
||||
|
||||
public virtual string ToString(int i)
|
||||
{
|
||||
return string.Format("Batch: BatchNr={0} ProgramVersion={1} TestBenchId={2} UserName={3} UserNumber={4} ProcedureName={5}{6} ProcRev={7} ProtocolTitle={8} Remark={9} RealDensity={10} AtTemperature={11} Buoyancy={12} StartTime={13} EndTime={14} Dirty={15} RsltsSent={16} RsltsPrinted={17}",
|
||||
BatchNr, ProgramVersion, TestBenchId, UserName, UserNumber,
|
||||
return string.Format("Batch {0} ({1}s) ver={2} TestBenchId={3} User={4}/{5} Proc={6}{7} Rev={8} Remark={9} RealDensity={10} AtTemperature={11} Buoyancy={12} StartTime={13} EndTime={14} SaveTime={15} RsltsSent={16} RsltsPrinted={17}",
|
||||
BatchNr,
|
||||
(EndTime - StartTime).TotalSeconds,
|
||||
ProgramVersion, TestBenchId, UserName, UserNumber,
|
||||
ProcedureName, (IsRemoteProcedure ? "(R)" : ""), ProcedureRevision,
|
||||
ProtocolTitle, Remark, RealDensity, AtTemperature, Buoyancy,
|
||||
StartTime, EndTime, Dirty, RsltsSent, RsltsPrinted);
|
||||
Remark, RealDensity, AtTemperature, Buoyancy,
|
||||
StartTime, EndTime, SaveTime, RsltsSent, RsltsPrinted);
|
||||
}
|
||||
|
||||
public virtual void WriteBinary(BinaryWriter writer)
|
||||
@@ -364,6 +371,7 @@ namespace Results.Entities
|
||||
writer.Write(Counter10);
|
||||
writer.Write(StartTime.ToString());
|
||||
writer.Write(EndTime.ToString());
|
||||
writer.Write(SaveTime.ToString());
|
||||
writer.Write(Dirty);
|
||||
writer.Write(RsltsSent);
|
||||
writer.Write(RsltsPrinted);
|
||||
@@ -431,6 +439,7 @@ namespace Results.Entities
|
||||
Counter10 = reader.ReadInt32();
|
||||
StartTime = DateTime.Parse(reader.ReadString());
|
||||
EndTime = DateTime.Parse(reader.ReadString());
|
||||
SaveTime = DateTime.Parse(reader.ReadString());
|
||||
Dirty = reader.ReadBoolean();
|
||||
RsltsSent = reader.ReadBoolean();
|
||||
RsltsPrinted = reader.ReadBoolean();
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
///
|
||||
/// Copyright (c) 2015-2020 Sensus Slovensko a.s.
|
||||
/// Copyright (c) 2015-2023 Sensus Slovensko a.s.
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
@@ -148,6 +148,7 @@ namespace Results.Entities
|
||||
|
||||
/// Wrappers
|
||||
public virtual string Name() { return Common.Utils.GetTestName(TestData.Name, TestData.Repeats, RepetitionNr); }
|
||||
public virtual string Key() { return string.Format("{0}~{1}~{2}~{3}", TestData.Name, Part, TestData.Repeats, RepetitionNr); } /// Unique key
|
||||
public virtual int Repeats() { return TestData.Repeats; }
|
||||
public virtual double Qfrom() { return TestData.Qfrom; }
|
||||
public virtual double Qto() { return TestData.Qto; }
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
///
|
||||
/// Copyright (c) 2015-2021 Sensus Slovensko a.s.
|
||||
/// Copyright (c) 2015-2023 Sensus Slovensko a.s.
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
@@ -97,12 +97,10 @@ namespace Results.Entities
|
||||
public virtual int WMTypeRevision { get; set; }
|
||||
public virtual int Pruefindex { get; set; } /// >=1 ... pruefindex, 0 ... unknown (no reading from DB yet)
|
||||
public virtual int HydrPruefung { get; set; }
|
||||
public virtual object RawTestInfos { get; set; } /// Not mapped to DB !!! IList<SensusTestInfo> fetched from Oracle at the beginning of the cycle, not mapped to DB !!!
|
||||
public virtual object CompleteTestInfos { get; set; } /// Not mapped to DB !!! SensusTestInfo[] obtained as a best match at the beginning of the cycle, not mapped to DB !!!
|
||||
#endif
|
||||
public virtual int ProcessId { get; set; } /// Not mapped to DB !!! Tracing DB Process ID
|
||||
public virtual int SessionId { get; set; } /// Not mapped to DB !!! 1 (regular tracing DB session) or 2 (alternative tracing DB session)
|
||||
public virtual bool LastRecordIsNok { get; set; } /// Not mapped to DB !!! Previous record verification result
|
||||
public virtual bool PrintLabel { get; set; } /// Not mapped to DB !!!
|
||||
|
||||
public virtual WaterMeterData WaterMeterData { get; set; }
|
||||
public virtual Batch Batch { get; set; }
|
||||
@@ -111,15 +109,23 @@ namespace Results.Entities
|
||||
///
|
||||
/// Wrappers
|
||||
///
|
||||
public virtual string ProductName() { return WaterMeterData.ProductName; }
|
||||
public virtual string GetEndStateAux() { return Compound() ? EndStateAux : string.Empty; }
|
||||
public virtual void SetEndStateAux(string s) { if (Compound()) EndStateAux = s; }
|
||||
|
||||
public virtual string GetStartState() { return Compound() ? string.Empty : EndStateAux; }
|
||||
public virtual void SetStartState(string s) { if (!Compound()) EndStateAux = s; }
|
||||
|
||||
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 bool NewQnames() { return WaterMeterData.NewQnames; }
|
||||
public virtual FlowNames Qnames() { return (FlowNames)WaterMeterData.Qnames; }
|
||||
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 double ErrLimHiQ() { return WaterMeterData.ErrLimHiQ; }
|
||||
public virtual double ErrLimLoQ() { return WaterMeterData.ErrLimLoQ; }
|
||||
|
||||
public virtual bool Compound() { return WaterMeterData.Compound; }
|
||||
public virtual bool HeatMeter() { return WaterMeterData.HeatMeter; }
|
||||
@@ -128,8 +134,10 @@ namespace Results.Entities
|
||||
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; }
|
||||
#if ORACLE_DB
|
||||
public virtual int WMTypeId() { return WaterMeterData.WMTypeId; }
|
||||
#endif
|
||||
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; }
|
||||
@@ -332,7 +340,7 @@ namespace Results.Entities
|
||||
return GetMeterTestRslt(testName, CompoundMeterId.SingleOrCompound);
|
||||
}
|
||||
|
||||
public virtual MeterTestRslt GetMeterTestRslt(string testName, CompoundMeterId meterId)
|
||||
public virtual MeterTestRslt GetMeterTestRslt(string testName, CompoundMeterId meterId = CompoundMeterId.Single)
|
||||
{
|
||||
if (string.IsNullOrEmpty(testName)) return null;
|
||||
if (Disabled) return null;
|
||||
@@ -448,12 +456,10 @@ namespace Results.Entities
|
||||
WMTypeRevision = 0;
|
||||
Pruefindex = 0;
|
||||
HydrPruefung = 0;
|
||||
RawTestInfos = null;
|
||||
CompleteTestInfos = null;
|
||||
#endif
|
||||
ProcessId = 0;
|
||||
SessionId = 0;
|
||||
LastRecordIsNok = false;
|
||||
PrintLabel = true;
|
||||
}
|
||||
|
||||
|
||||
@@ -512,12 +518,10 @@ namespace Results.Entities
|
||||
WMTypeRevision = src.WMTypeRevision;
|
||||
Pruefindex = src.Pruefindex;
|
||||
HydrPruefung = src.HydrPruefung;
|
||||
RawTestInfos = src.RawTestInfos; /// Not mapped to DB
|
||||
CompleteTestInfos = src.CompleteTestInfos; /// Not mapped to DB
|
||||
#endif
|
||||
ProcessId = src.ProcessId; /// Not mapped to DB
|
||||
SessionId = src.SessionId; /// Not mapped to DB
|
||||
LastRecordIsNok = src.LastRecordIsNok; /// Not mapped to DB
|
||||
PrintLabel = src.PrintLabel; /// Not mapped to DB
|
||||
|
||||
foreach (var mtr in MeterTestRslts)
|
||||
{
|
||||
@@ -694,26 +698,10 @@ namespace Results.Entities
|
||||
writer.Write(WMTypeRevision);
|
||||
writer.Write(Pruefindex);
|
||||
writer.Write(HydrPruefung);
|
||||
|
||||
/// Write RawTestInfos
|
||||
IList<Results.Output.SensusTestInfo> rawTestInfos = RawTestInfos as IList<Results.Output.SensusTestInfo>;
|
||||
writer.Write((rawTestInfos != null) ? rawTestInfos.Count : 0);
|
||||
if (rawTestInfos != null)
|
||||
{
|
||||
for (int i = 0; i < rawTestInfos.Count; i++) rawTestInfos[i].WriteBinary(writer);
|
||||
}
|
||||
|
||||
/// Write CompleteTestInfos
|
||||
Results.Output.SensusTestInfo[] completeTestInfos = CompleteTestInfos as Results.Output.SensusTestInfo[];
|
||||
writer.Write((completeTestInfos != null) ? completeTestInfos.Length : 0);
|
||||
if (completeTestInfos != null)
|
||||
{
|
||||
for (int i = 0; i < completeTestInfos.Length; i++) completeTestInfos[i].WriteBinary(writer);
|
||||
}
|
||||
#endif
|
||||
writer.Write(ProcessId);
|
||||
writer.Write(SessionId);
|
||||
writer.Write(LastRecordIsNok);
|
||||
writer.Write(PrintLabel);
|
||||
|
||||
/// Save WaterMeterData or WaterMeterData.Id
|
||||
if (WaterMeterData != null && savedWMDatas != null && !savedWMDatas.Contains(WaterMeterData))
|
||||
@@ -790,32 +778,10 @@ namespace Results.Entities
|
||||
WMTypeRevision = reader.ReadInt32();
|
||||
Pruefindex = reader.ReadInt32();
|
||||
HydrPruefung = reader.ReadInt32();
|
||||
|
||||
/// Read RawTestInfos
|
||||
int rawTestInfosCount = reader.ReadInt32();
|
||||
IList<Results.Output.SensusTestInfo> rawTestInfos = new List<Results.Output.SensusTestInfo>();
|
||||
for (int i = 0; i < rawTestInfosCount; i++)
|
||||
{
|
||||
Results.Output.SensusTestInfo ti = new Results.Output.SensusTestInfo();
|
||||
ti.ReadBinary(reader);
|
||||
rawTestInfos.Add(ti);
|
||||
}
|
||||
RawTestInfos = rawTestInfos;
|
||||
|
||||
/// Read CompleteTestInfos
|
||||
int completeTestInfosLen = reader.ReadInt32();
|
||||
Results.Output.SensusTestInfo[] completeTestInfos = new Results.Output.SensusTestInfo[completeTestInfosLen];
|
||||
for (int i = 0; i < completeTestInfosLen; i++)
|
||||
{
|
||||
Results.Output.SensusTestInfo ti = new Results.Output.SensusTestInfo();
|
||||
ti.ReadBinary(reader);
|
||||
completeTestInfos[i] = ti;
|
||||
}
|
||||
CompleteTestInfos = completeTestInfos;
|
||||
#endif
|
||||
ProcessId = reader.ReadInt32();
|
||||
SessionId = reader.ReadInt32();
|
||||
LastRecordIsNok = reader.ReadBoolean();
|
||||
PrintLabel = reader.ReadBoolean();
|
||||
|
||||
/// Retrieve TestData
|
||||
if (reader.ReadBoolean())
|
||||
|
||||
@@ -17,11 +17,14 @@ namespace Results.Entities
|
||||
public virtual double DN { get; set; } /// [mm]
|
||||
public virtual double L { get; set; } /// [mm]
|
||||
public virtual Mounting Mounting { get; set; } /// H / V / S / F
|
||||
public virtual bool NewQnames { get; set; } /// Yes = Q3... No = Qn...
|
||||
public virtual sbyte Qnames { get; set; } /// see Common.Enums.FlowNames
|
||||
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 double ErrLimHiQ { get; set; } /// [%]
|
||||
public virtual double ErrLimLoQ { get; set; } /// [%]
|
||||
|
||||
public virtual string MetrologicalClass { get; set; }
|
||||
public virtual TemperatureClass TemperatureClass { get; set; }
|
||||
public virtual PressureLossClass PressureLossClass { get; set; }
|
||||
@@ -66,11 +69,13 @@ namespace Results.Entities
|
||||
DN = oriWMData.DN;
|
||||
L = oriWMData.L;
|
||||
Mounting = oriWMData.Mounting;
|
||||
NewQnames = oriWMData.NewQnames;
|
||||
Qnames = oriWMData.Qnames;
|
||||
Q4_Qmax = oriWMData.Q4_Qmax;
|
||||
Q3_Qn = oriWMData.Q3_Qn;
|
||||
Q2_Qt = oriWMData.Q2_Qt;
|
||||
Q1_Qmin = oriWMData.Q1_Qmin;
|
||||
ErrLimHiQ = oriWMData.ErrLimHiQ;
|
||||
ErrLimLoQ = oriWMData.ErrLimLoQ;
|
||||
MetrologicalClass = oriWMData.MetrologicalClass;
|
||||
TemperatureClass = oriWMData.TemperatureClass;
|
||||
PressureLossClass = oriWMData.PressureLossClass;
|
||||
@@ -109,11 +114,13 @@ namespace Results.Entities
|
||||
if (DN != wmd.DN) return false;
|
||||
if (L != wmd.L) return false;
|
||||
if (Mounting != wmd.Mounting) return false;
|
||||
if (NewQnames != wmd.NewQnames) return false;
|
||||
if (Qnames != wmd.Qnames) 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 (ErrLimHiQ != wmd.ErrLimHiQ) return false;
|
||||
if (ErrLimLoQ != wmd.ErrLimLoQ) return false;
|
||||
if (MetrologicalClass != wmd.MetrologicalClass) return false;
|
||||
if (TemperatureClass != wmd.TemperatureClass) return false;
|
||||
if (PressureLossClass != wmd.PressureLossClass) return false;
|
||||
@@ -167,11 +174,13 @@ namespace Results.Entities
|
||||
writer.Write(DN);
|
||||
writer.Write(L);
|
||||
writer.Write((int)Mounting);
|
||||
writer.Write(NewQnames);
|
||||
writer.Write((int)Qnames);
|
||||
writer.Write(Q4_Qmax);
|
||||
writer.Write(Q3_Qn);
|
||||
writer.Write(Q2_Qt);
|
||||
writer.Write(Q1_Qmin);
|
||||
writer.Write(ErrLimHiQ);
|
||||
writer.Write(ErrLimLoQ);
|
||||
writer.Write((MetrologicalClass != null) ? MetrologicalClass : string.Empty);
|
||||
writer.Write((int)TemperatureClass);
|
||||
writer.Write((int)PressureLossClass);
|
||||
@@ -205,11 +214,13 @@ namespace Results.Entities
|
||||
DN = reader.ReadDouble();
|
||||
L = reader.ReadDouble();
|
||||
Mounting = (Mounting)reader.ReadInt32();
|
||||
NewQnames = reader.ReadBoolean();
|
||||
Qnames = (sbyte)reader.ReadInt32();
|
||||
Q4_Qmax = reader.ReadDouble();
|
||||
Q3_Qn = reader.ReadDouble();
|
||||
Q2_Qt = reader.ReadDouble();
|
||||
Q1_Qmin = reader.ReadDouble();
|
||||
ErrLimHiQ = reader.ReadDouble();
|
||||
ErrLimLoQ = reader.ReadDouble();
|
||||
MetrologicalClass = reader.ReadString();
|
||||
TemperatureClass = (TemperatureClass)reader.ReadInt32();
|
||||
PressureLossClass = (PressureLossClass)reader.ReadInt32();
|
||||
|
||||
+24
-10
@@ -29,13 +29,15 @@
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.tabControl1 = new System.Windows.Forms.TabControl();
|
||||
this.allResultsTabPage = new System.Windows.Forms.TabPage();
|
||||
this.graphsTabPage = new System.Windows.Forms.TabPage();
|
||||
this.productionTracingTabPage = new System.Windows.Forms.TabPage();
|
||||
this.productionTracingSplitContainer = new System.Windows.Forms.SplitContainer();
|
||||
this.messageLabel = new System.Windows.Forms.Label();
|
||||
this.tracingResultsListView = new System.Windows.Forms.ListView();
|
||||
this.allResultsTabPage = new System.Windows.Forms.TabPage();
|
||||
this.oneWMResultsCtrl = new Results.Forms.OneWMResultsRowsCtrl();
|
||||
this.tabControl1.SuspendLayout();
|
||||
this.allResultsTabPage.SuspendLayout();
|
||||
this.productionTracingTabPage.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.productionTracingSplitContainer)).BeginInit();
|
||||
this.productionTracingSplitContainer.Panel1.SuspendLayout();
|
||||
@@ -55,6 +57,17 @@
|
||||
this.tabControl1.Size = new System.Drawing.Size(1195, 448);
|
||||
this.tabControl1.TabIndex = 0;
|
||||
//
|
||||
// allResultsTabPage
|
||||
//
|
||||
this.allResultsTabPage.Controls.Add(this.oneWMResultsCtrl);
|
||||
this.allResultsTabPage.Location = new System.Drawing.Point(4, 22);
|
||||
this.allResultsTabPage.Name = "allResultsTabPage";
|
||||
this.allResultsTabPage.Padding = new System.Windows.Forms.Padding(3);
|
||||
this.allResultsTabPage.Size = new System.Drawing.Size(1187, 422);
|
||||
this.allResultsTabPage.TabIndex = 0;
|
||||
this.allResultsTabPage.Text = "All results";
|
||||
this.allResultsTabPage.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// graphsTabPage
|
||||
//
|
||||
this.graphsTabPage.Location = new System.Drawing.Point(4, 22);
|
||||
@@ -113,6 +126,7 @@
|
||||
//
|
||||
this.tracingResultsListView.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.tracingResultsListView.GridLines = true;
|
||||
this.tracingResultsListView.HideSelection = false;
|
||||
this.tracingResultsListView.Location = new System.Drawing.Point(0, 0);
|
||||
this.tracingResultsListView.Name = "tracingResultsListView";
|
||||
this.tracingResultsListView.Size = new System.Drawing.Size(1187, 366);
|
||||
@@ -120,15 +134,14 @@
|
||||
this.tracingResultsListView.UseCompatibleStateImageBehavior = false;
|
||||
this.tracingResultsListView.View = System.Windows.Forms.View.Details;
|
||||
//
|
||||
// allResultsTabPage
|
||||
// oneWMResultsRowsCtrl
|
||||
//
|
||||
this.allResultsTabPage.Location = new System.Drawing.Point(4, 22);
|
||||
this.allResultsTabPage.Name = "allResultsTabPage";
|
||||
this.allResultsTabPage.Padding = new System.Windows.Forms.Padding(3);
|
||||
this.allResultsTabPage.Size = new System.Drawing.Size(1187, 422);
|
||||
this.allResultsTabPage.TabIndex = 0;
|
||||
this.allResultsTabPage.Text = "All results";
|
||||
this.allResultsTabPage.UseVisualStyleBackColor = true;
|
||||
this.oneWMResultsCtrl.Caption = "---";
|
||||
this.oneWMResultsCtrl.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.oneWMResultsCtrl.Location = new System.Drawing.Point(3, 3);
|
||||
this.oneWMResultsCtrl.Name = "oneWMResultsRowsCtrl";
|
||||
this.oneWMResultsCtrl.Size = new System.Drawing.Size(1181, 416);
|
||||
this.oneWMResultsCtrl.TabIndex = 0;
|
||||
//
|
||||
// MoreWMResultsDlg
|
||||
//
|
||||
@@ -140,6 +153,7 @@
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
|
||||
this.Text = "Water meter results";
|
||||
this.tabControl1.ResumeLayout(false);
|
||||
this.allResultsTabPage.ResumeLayout(false);
|
||||
this.productionTracingTabPage.ResumeLayout(false);
|
||||
this.productionTracingSplitContainer.Panel1.ResumeLayout(false);
|
||||
this.productionTracingSplitContainer.Panel1.PerformLayout();
|
||||
@@ -153,12 +167,12 @@
|
||||
#endregion
|
||||
|
||||
private System.Windows.Forms.TabControl tabControl1;
|
||||
private OneWMResultsRowsCtrl oneWMResultsCtrl;
|
||||
private System.Windows.Forms.TabPage graphsTabPage;
|
||||
private System.Windows.Forms.TabPage productionTracingTabPage;
|
||||
private System.Windows.Forms.SplitContainer productionTracingSplitContainer;
|
||||
private System.Windows.Forms.Label messageLabel;
|
||||
private System.Windows.Forms.ListView tracingResultsListView;
|
||||
private System.Windows.Forms.TabPage allResultsTabPage;
|
||||
private OneWMResultsRowsCtrl oneWMResultsCtrl;
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
///
|
||||
/// Copyright (c) 2019 Sensus Slovensko a.s.
|
||||
/// Copyright (c) 2019-2023 Sensus Slovensko a.s.
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
@@ -14,6 +14,13 @@ namespace Results.Forms
|
||||
{
|
||||
public partial class MoreWMResultsDlg : Form
|
||||
{
|
||||
enum Tabs
|
||||
{
|
||||
Results = 0,
|
||||
Graph,
|
||||
Tracing,
|
||||
}
|
||||
|
||||
public MoreWMResultsDlg(Results.Entities.WaterMeter wm, IList<ReferenceRecord> refRecords)
|
||||
{
|
||||
InitializeComponent();
|
||||
@@ -23,14 +30,15 @@ namespace Results.Forms
|
||||
ShowAllResults(wm);
|
||||
ShowChart(wm);
|
||||
|
||||
/// Select the initial tab page to be displayed
|
||||
if (refRecords == null)
|
||||
{
|
||||
tabControl1.SelectTab(1);
|
||||
tabControl1.TabPages.RemoveAt(2);
|
||||
tabControl1.SelectTab((int)Tabs.Graph);
|
||||
tabControl1.TabPages.RemoveAt((int)Tabs.Tracing);
|
||||
}
|
||||
else
|
||||
{
|
||||
tabControl1.SelectTab(2);
|
||||
tabControl1.SelectTab((int)Tabs.Tracing);
|
||||
ShowTracingResults(wm, refRecords);
|
||||
}
|
||||
}
|
||||
@@ -39,9 +47,9 @@ namespace Results.Forms
|
||||
void Localize()
|
||||
{
|
||||
Text = Strings.Water_meter_results;
|
||||
tabControl1.TabPages[0].Text = Strings.All_results;
|
||||
tabControl1.TabPages[1].Text = Strings.Graphs;
|
||||
tabControl1.TabPages[2].Text = Strings.Production_tracing_results;
|
||||
tabControl1.TabPages[(int)Tabs.Results].Text = Strings.All_results;
|
||||
tabControl1.TabPages[(int)Tabs.Graph].Text = Strings.Graphs;
|
||||
tabControl1.TabPages[(int)Tabs.Tracing].Text = Strings.Production_tracing_results;
|
||||
}
|
||||
|
||||
|
||||
@@ -51,67 +59,63 @@ namespace Results.Forms
|
||||
/// <param name="wMtr">Water meter entity</param>
|
||||
void ShowAllResults(Results.Entities.WaterMeter wMtr)
|
||||
{
|
||||
// string message;
|
||||
// Color commonBackColor = wMtr.GetColorOfResults(false, out message); /// Ony message is used later on
|
||||
//#if ORACLE_DB
|
||||
// oneWMResultsCtrl.Caption = string.Format("{0} ({1}) {2}", (string.IsNullOrEmpty(wMtr.SerialNr) ? string.Empty : wMtr.SerialNr), (wMtr.Pruefindex % 100), message);
|
||||
//#else
|
||||
// oneWMResultsCtrl.Caption = string.Format("s/n = {0}", string.IsNullOrEmpty(wMtr.SerialNr) ? string.Empty : wMtr.SerialNr);
|
||||
//#endif
|
||||
string message;
|
||||
Color commonBackColor = wMtr.GetColorOfResults(false, out message); /// Ony message is used later on
|
||||
#if ORACLE_DB
|
||||
oneWMResultsCtrl.Caption = string.Format("{0} ({1}) {2}", wMtr.SerialNr ?? string.Empty, wMtr.Pruefindex % 100, message);
|
||||
#else
|
||||
oneWMResultsCtrl.Caption = string.Format("s/n = {0}", wMtr.SerialNr ?? string.Empty);
|
||||
#endif
|
||||
|
||||
// IList<Results.WMeterRsltItemSpec> items = Results.WMeterRsltItemSpec.AllItems;
|
||||
IList<Results.WMeterRsltItemSpec> items = Results.WMeterRsltItemSpec.AllItems;
|
||||
|
||||
// // Header
|
||||
// oneWMResultsCtrl.Columns.Add(wMtr.WMPosition.ToString(), 100);
|
||||
// int i = 1;
|
||||
// foreach (var str in wMtr.GetAllDecoratedTestNames())
|
||||
// {
|
||||
// oneWMResultsCtrl.Columns.Add(str, 100);
|
||||
// i++;
|
||||
// }
|
||||
// Header
|
||||
oneWMResultsCtrl.Columns.Add(wMtr.WMPosition.ToString(), 100);
|
||||
int i = 1;
|
||||
foreach (var str in wMtr.GetAllDecoratedTestNames())
|
||||
{
|
||||
oneWMResultsCtrl.Columns.Add(str, 100);
|
||||
i++;
|
||||
}
|
||||
|
||||
// foreach (var item in items)
|
||||
// {
|
||||
// ListViewItem lvi = new ListViewItem(item.Name);
|
||||
foreach (var item in items)
|
||||
{
|
||||
ListViewItem lvi = new ListViewItem(item.Name);
|
||||
|
||||
// foreach (var mtr in wMtr.MeterTestRslts)
|
||||
// {
|
||||
// if (mtr != null && mtr.IsPilotRslt() && mtr.TestDone && mtr.Publish() != Publish.Never &&
|
||||
// mtr.Publish() != Publish.Internal)
|
||||
// {
|
||||
// string str = item.Print(wMtr, mtr.Name());
|
||||
foreach (var mtr in wMtr.MeterTestRslts)
|
||||
{
|
||||
if (mtr != null && mtr.IsPilotRslt() && mtr.TestDone && mtr.Publish() != Common.Publish.Never &&
|
||||
mtr.Publish() != Common.Publish.Internal)
|
||||
{
|
||||
string str = item.Print(wMtr, mtr.Name());
|
||||
|
||||
// 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);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
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);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// oneWMResultsCtrl.Items.Add(lvi);
|
||||
// }
|
||||
oneWMResultsCtrl.Items.Add(lvi);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void ShowChart(Results.Entities.WaterMeter wm)
|
||||
{
|
||||
//chart.ChartAreas[0].AxisX.LabelStyle.Format = "dd.MM.yy";
|
||||
//chart.ChartAreas[0].AxisX.Interval = 1;
|
||||
//chart.ChartAreas[0].AxisX.IntervalType = ;
|
||||
|
||||
tabControl1.TabPages[1].Controls.Add(Results.Output.WMChart.GetChart(wm, false));
|
||||
tabControl1.TabPages[(int)Tabs.Graph].Controls.Add(Results.Output.WMChart.GetChart(wm, false));
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
///
|
||||
/// Copyright (c) 2019 Sensus Slovensko a.s.
|
||||
/// Copyright (c) 2019-2023 Sensus Slovensko a.s.
|
||||
///
|
||||
using System;
|
||||
using System.Drawing;
|
||||
@@ -24,13 +24,16 @@ namespace Results.Forms
|
||||
}
|
||||
}
|
||||
|
||||
public string Caption { set { caption = value; } get { return caption; } }
|
||||
|
||||
public ListView.ListViewItemCollection Items { get { return lView.Items; } }
|
||||
|
||||
bool disabled;
|
||||
int wmPosition; /// 1-based water meter position
|
||||
string caption;
|
||||
Color bkColor;
|
||||
int[] columnWidths;
|
||||
IList<Results.WMeterRsltItemSpec> items;
|
||||
IList<WMeterRsltItemSpec> items;
|
||||
|
||||
|
||||
public bool Disabled { get { return disabled; } } /// Read only
|
||||
@@ -45,7 +48,7 @@ namespace Results.Forms
|
||||
wmPosition = 0;
|
||||
tBox.Text = caption = "---";
|
||||
tBox.BackColor = lView.BackColor = bkColor = Color.White;
|
||||
items = new List<Results.WMeterRsltItemSpec>();
|
||||
items = new List<WMeterRsltItemSpec>();
|
||||
columnWidths = new int[0];
|
||||
}
|
||||
|
||||
@@ -62,7 +65,7 @@ namespace Results.Forms
|
||||
}
|
||||
}
|
||||
|
||||
public void Update(IList<Results.WMeterRsltItemSpec> items)
|
||||
public void Update(IList<WMeterRsltItemSpec> items)
|
||||
{
|
||||
this.items = items;
|
||||
|
||||
|
||||
@@ -343,6 +343,11 @@ namespace Results
|
||||
X9, /// 291
|
||||
|
||||
RadioAddress, /// 292
|
||||
OriRadioAddress, /// 293
|
||||
|
||||
Pls_per_ltr_aux, /// 294 Compound water meter constant (water meter data, not used in calculations)
|
||||
Pulses_main, /// 295 Compound main meter pulses (recalculated so that the gated ref. pulses for this meter are equal to the total ref. pulses)
|
||||
Pulses_aux, /// 296 Compound aux meter pulses (recalculated so that the gated ref. pulses for this meter are equal to the total ref. pulses)
|
||||
|
||||
Count,
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
///
|
||||
/// Copyright (c) 2015-2021 Sensus Slovensko a.s.
|
||||
/// Copyright (c) 2015-2023 Sensus Slovensko a.s.
|
||||
///
|
||||
using FluentNHibernate.Mapping;
|
||||
using Results.Entities;
|
||||
@@ -35,6 +35,7 @@ namespace Results.Mappings
|
||||
|
||||
Map(x => x.StartTime);
|
||||
Map(x => x.EndTime);
|
||||
Map(x => x.SaveTime);
|
||||
Map(x => x.Dirty);
|
||||
Map(x => x.RsltsSent);
|
||||
Map(x => x.RsltsPrinted);
|
||||
|
||||
@@ -18,13 +18,13 @@ namespace Results.Mappings
|
||||
Map(x => x.L);
|
||||
Map(x => x.Mounting);
|
||||
|
||||
#if MUNICH && LANG_DE
|
||||
Map(x => x.NewQnames);
|
||||
#endif
|
||||
Map(x => x.Qnames);
|
||||
Map(x => x.Q4_Qmax);
|
||||
Map(x => x.Q3_Qn);
|
||||
Map(x => x.Q2_Qt);
|
||||
Map(x => x.Q1_Qmin);
|
||||
Map(x => x.ErrLimHiQ);
|
||||
Map(x => x.ErrLimLoQ);
|
||||
|
||||
Map(x => x.MetrologicalClass);
|
||||
Map(x => x.TemperatureClass);
|
||||
|
||||
@@ -526,11 +526,11 @@ namespace Results.Output.Printers.Munich
|
||||
}
|
||||
lineNr++;
|
||||
|
||||
PrintAt(e, Tab1, lineNr * SpacingOne, wm.NewQnames() ? "Q3 :" : "Qn :");
|
||||
PrintAt(e, Tab1, lineNr * SpacingOne, (wm.Qnames() == FlowNames.Q3Q2Q1) ? "Q3 :" : (wm.Qnames() == FlowNames.QpQi) ? "qp :" : "Qn :");
|
||||
PrintAt(e, Tab2, lineNr * SpacingOne, wm.Q3_Qn().ToString());
|
||||
if (compound)
|
||||
{
|
||||
PrintAt(e, Tab3, lineNr * SpacingOne, wm.NewQnames() ? "Q3 :" : "Qn :");
|
||||
PrintAt(e, Tab3, lineNr * SpacingOne, (wm.Qnames() == FlowNames.Q3Q2Q1) ? "Q3 :" : (wm.Qnames() == FlowNames.QpQi) ? "qp :" : "Qn :");
|
||||
PrintAt(e, Tab4, lineNr * SpacingOne, wm.Q3_Qn_Aux().ToString());
|
||||
}
|
||||
lineNr++;
|
||||
|
||||
+108
-15
@@ -1,5 +1,5 @@
|
||||
///
|
||||
/// Copyright (c) 2019-2022 Sensus Metering Systems
|
||||
/// Copyright (c) 2019-2023 Sensus Metering Systems
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
@@ -55,6 +55,9 @@ namespace Results.Output
|
||||
chArea.AxisX.LogarithmBase = 10;
|
||||
chArea.AxisX.IsLabelAutoFit = true;
|
||||
|
||||
Series upperLimit = new Series { Name = Strings.Upper_limit, ChartArea = "ChartArea1", ChartType = SeriesChartType.Line, Color = Color.Red };
|
||||
Series lowerLimit = new Series { Name = Strings.Lower_limit, ChartArea = "ChartArea1", ChartType = SeriesChartType.Line, Color = Color.Red };
|
||||
|
||||
List<double> xs = new List<double>() { 0.0001, 0.0002, 0.0005,
|
||||
0.001, 0.002, 0.005,
|
||||
0.01, 0.02, 0.05,
|
||||
@@ -71,6 +74,8 @@ namespace Results.Output
|
||||
double from = Units.ConvertTo(flowUnit, wm.WaterMeterData.Q1_Qmin);
|
||||
double to = Units.ConvertTo(flowUnit, isQ4 ? wm.WaterMeterData.Q4_Qmax : wm.WaterMeterData.Q3_Qn);
|
||||
bool inRange = false;
|
||||
double qSharp = (wm.WaterMeterData.Qnames == (sbyte)FlowNames.QpQi) ? GetQsharp(wm, flowUnit) : 0;
|
||||
double lastXs = 0;
|
||||
for (int i = 0; i < xs.Count - 3; i += 3)
|
||||
{
|
||||
if (xs[i] <= from && from < xs[i + 3])
|
||||
@@ -88,6 +93,37 @@ namespace Results.Output
|
||||
cl.FromPosition = Math.Log10(xs[j] * spacer);
|
||||
cl.ToPosition = Math.Log10(xs[j] / spacer);
|
||||
chArea.AxisX.CustomLabels.Add(cl);
|
||||
|
||||
if (wm.WaterMeterData.Qnames == (sbyte)FlowNames.QpQi)
|
||||
{
|
||||
if (lastXs != 0)
|
||||
{
|
||||
double insertedXs = Math.Sqrt(lastXs * xs[j]);
|
||||
|
||||
if (lastXs < qSharp && qSharp < insertedXs)
|
||||
{
|
||||
double errLim3 = GetErrorLimit(wm, flowUnit, qSharp);
|
||||
lowerLimit.Points.AddXY(qSharp, -errLim3);
|
||||
upperLimit.Points.AddXY(qSharp, +errLim3);
|
||||
}
|
||||
|
||||
double errLim2 = GetErrorLimit(wm, flowUnit, insertedXs);
|
||||
lowerLimit.Points.AddXY(insertedXs, -errLim2);
|
||||
upperLimit.Points.AddXY(insertedXs, +errLim2);
|
||||
|
||||
if (insertedXs < qSharp && qSharp < xs[j])
|
||||
{
|
||||
double errLim3 = GetErrorLimit(wm, flowUnit, qSharp);
|
||||
lowerLimit.Points.AddXY(qSharp, -errLim3);
|
||||
upperLimit.Points.AddXY(qSharp, +errLim3);
|
||||
}
|
||||
}
|
||||
lastXs = xs[j];
|
||||
|
||||
double errLim = GetErrorLimit(wm, flowUnit, xs[j]);
|
||||
lowerLimit.Points.AddXY(xs[j], -errLim);
|
||||
upperLimit.Points.AddXY(xs[j], +errLim);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -101,6 +137,36 @@ namespace Results.Output
|
||||
cl.ToPosition = Math.Log10(xs[i + 3] / spacer);
|
||||
chArea.AxisX.CustomLabels.Add(cl);
|
||||
|
||||
if (wm.WaterMeterData.Qnames == (sbyte)FlowNames.QpQi)
|
||||
{
|
||||
if (lastXs != 0)
|
||||
{
|
||||
double insertedXs = Math.Sqrt(lastXs * xs[i + 3]);
|
||||
|
||||
if (lastXs < qSharp && qSharp < insertedXs)
|
||||
{
|
||||
double errLim3 = GetErrorLimit(wm, flowUnit, qSharp);
|
||||
lowerLimit.Points.AddXY(qSharp, -errLim3);
|
||||
upperLimit.Points.AddXY(qSharp, +errLim3);
|
||||
}
|
||||
|
||||
double errLim2 = GetErrorLimit(wm, flowUnit, insertedXs);
|
||||
lowerLimit.Points.AddXY(insertedXs, -errLim2);
|
||||
upperLimit.Points.AddXY(insertedXs, +errLim2);
|
||||
|
||||
if (insertedXs < qSharp && qSharp < xs[i + 3])
|
||||
{
|
||||
double errLim3 = GetErrorLimit(wm, flowUnit, qSharp);
|
||||
lowerLimit.Points.AddXY(qSharp, -errLim3);
|
||||
upperLimit.Points.AddXY(qSharp, +errLim3);
|
||||
}
|
||||
}
|
||||
|
||||
double errLim = GetErrorLimit(wm, flowUnit, xs[i + 3]);
|
||||
lowerLimit.Points.AddXY(xs[i + 3], -errLim);
|
||||
upperLimit.Points.AddXY(xs[i + 3], +errLim);
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -111,19 +177,20 @@ namespace Results.Output
|
||||
|
||||
Legend legend1 = new Legend { Name = "Legend1" };
|
||||
|
||||
Series upperLimit = new Series { Name = Strings.Upper_limit, ChartArea = "ChartArea1", ChartType = SeriesChartType.Line, Color = Color.Red };
|
||||
upperLimit.Points.AddXY(Units.ConvertTo(flowUnit, wm.WaterMeterData.Q1_Qmin), 5);
|
||||
upperLimit.Points.AddXY(Units.ConvertTo(flowUnit, wm.WaterMeterData.Q2_Qt), 5);
|
||||
upperLimit.Points.AddXY(Units.ConvertTo(flowUnit, wm.WaterMeterData.Q2_Qt), 2);
|
||||
upperLimit.Points.AddXY(Units.ConvertTo(flowUnit, wm.WaterMeterData.Q3_Qn), 2);
|
||||
if (isQ4) upperLimit.Points.AddXY(Units.ConvertTo(flowUnit, wm.WaterMeterData.Q4_Qmax), 2);
|
||||
if (wm.WaterMeterData.Qnames == (sbyte)FlowNames.Q3Q2Q1 || wm.WaterMeterData.Qnames == (sbyte)FlowNames.QnQtQmin)
|
||||
{
|
||||
upperLimit.Points.AddXY(Units.ConvertTo(flowUnit, wm.WaterMeterData.Q1_Qmin), wm.WaterMeterData.ErrLimLoQ);
|
||||
upperLimit.Points.AddXY(Units.ConvertTo(flowUnit, wm.WaterMeterData.Q2_Qt), wm.WaterMeterData.ErrLimLoQ);
|
||||
upperLimit.Points.AddXY(Units.ConvertTo(flowUnit, wm.WaterMeterData.Q2_Qt), wm.WaterMeterData.ErrLimHiQ);
|
||||
upperLimit.Points.AddXY(Units.ConvertTo(flowUnit, wm.WaterMeterData.Q3_Qn), wm.WaterMeterData.ErrLimHiQ);
|
||||
if (isQ4) upperLimit.Points.AddXY(Units.ConvertTo(flowUnit, wm.WaterMeterData.Q4_Qmax), wm.WaterMeterData.ErrLimHiQ);
|
||||
|
||||
Series lowerLimit = new Series { Name = Strings.Lower_limit, ChartArea = "ChartArea1", ChartType = SeriesChartType.Line, Color = Color.Red };
|
||||
lowerLimit.Points.AddXY(Units.ConvertTo(flowUnit, wm.WaterMeterData.Q1_Qmin), -5);
|
||||
lowerLimit.Points.AddXY(Units.ConvertTo(flowUnit, wm.WaterMeterData.Q2_Qt), -5);
|
||||
lowerLimit.Points.AddXY(Units.ConvertTo(flowUnit, wm.WaterMeterData.Q2_Qt), -2);
|
||||
lowerLimit.Points.AddXY(Units.ConvertTo(flowUnit, wm.WaterMeterData.Q3_Qn), -2);
|
||||
if (isQ4) lowerLimit.Points.AddXY(Units.ConvertTo(flowUnit, wm.WaterMeterData.Q4_Qmax), -2);
|
||||
lowerLimit.Points.AddXY(Units.ConvertTo(flowUnit, wm.WaterMeterData.Q1_Qmin), -wm.WaterMeterData.ErrLimLoQ);
|
||||
lowerLimit.Points.AddXY(Units.ConvertTo(flowUnit, wm.WaterMeterData.Q2_Qt), -wm.WaterMeterData.ErrLimLoQ);
|
||||
lowerLimit.Points.AddXY(Units.ConvertTo(flowUnit, wm.WaterMeterData.Q2_Qt), -wm.WaterMeterData.ErrLimHiQ);
|
||||
lowerLimit.Points.AddXY(Units.ConvertTo(flowUnit, wm.WaterMeterData.Q3_Qn), -wm.WaterMeterData.ErrLimHiQ);
|
||||
if (isQ4) lowerLimit.Points.AddXY(Units.ConvertTo(flowUnit, wm.WaterMeterData.Q4_Qmax), -wm.WaterMeterData.ErrLimHiQ);
|
||||
}
|
||||
|
||||
Series line = new Series { Name = Strings.Relative_error, ChartArea = "ChartArea1", ChartType = SeriesChartType.Line, Color = Color.DeepSkyBlue };
|
||||
Series dots = new Series { Name = Strings.Relative_error + " ", ChartArea = "ChartArea1", ChartType = SeriesChartType.Point, Color = Color.RoyalBlue };
|
||||
@@ -137,12 +204,38 @@ namespace Results.Output
|
||||
|
||||
chart.ChartAreas.Add(chArea);
|
||||
chart.Legends.Add(legend1);
|
||||
chart.Series.Add(upperLimit);
|
||||
chart.Series.Add(lowerLimit);
|
||||
if (upperLimit.Points.Count > 1) chart.Series.Add(upperLimit);
|
||||
if (lowerLimit.Points.Count > 1) chart.Series.Add(lowerLimit);
|
||||
chart.Series.Add(dots);
|
||||
chart.Series.Add(line);
|
||||
|
||||
return chart;
|
||||
}
|
||||
|
||||
static double GetErrorLimit(WaterMeter wm, Unit flowUnit, double x)
|
||||
{
|
||||
double flow_m3 = Units.ConvertFrom(flowUnit, x);
|
||||
switch (Convert.ToInt32(wm.WaterMeterData.Q2_Qt))
|
||||
{
|
||||
default:
|
||||
case 1: return Math.Min(3.5, 1.0 + 0.01 * wm.WaterMeterData.Q3_Qn / flow_m3);
|
||||
case 2: return Math.Min(5.0, 2.0 + 0.02 * wm.WaterMeterData.Q3_Qn / flow_m3);
|
||||
case 3: return Math.Min(5.0, 3.0 + 0.05 * wm.WaterMeterData.Q3_Qn / flow_m3);
|
||||
}
|
||||
}
|
||||
|
||||
static double GetQsharp(WaterMeter wm, Unit flowUnit)
|
||||
{
|
||||
double qSharp;
|
||||
switch (Convert.ToInt32(wm.WaterMeterData.Q2_Qt))
|
||||
{
|
||||
default:
|
||||
case 1: qSharp = (0.01 / 2.5) * wm.WaterMeterData.Q3_Qn; break;
|
||||
case 2: qSharp = (0.02 / 3.0) * wm.WaterMeterData.Q3_Qn; break;
|
||||
case 3: qSharp = (0.05 / 2.0) * wm.WaterMeterData.Q3_Qn; break;
|
||||
}
|
||||
return Units.ConvertTo(flowUnit, qSharp);
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+26
-15
@@ -35,27 +35,45 @@
|
||||
<Prefer32Bit>false</Prefer32Bit>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="FluentNHibernate">
|
||||
<HintPath>..\packages\FluentNHibernate.2.0.3.0\lib\net40\FluentNHibernate.dll</HintPath>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Gma.QrCodeNet.Encoding">
|
||||
<HintPath>..\packages\QrCode.Net.0.4.0.0\net40\Gma.QrCodeNet.Encoding.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.0.4000\lib\net40\Iesi.Collections.dll</HintPath>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="log4net">
|
||||
<HintPath>..\packages\log4net.2.0.2\lib\net40-full\log4net.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.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 Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Drawing" />
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Windows.Forms" />
|
||||
<Reference Include="System.Windows.Forms.DataVisualization" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
@@ -75,12 +93,6 @@
|
||||
<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\IOneWMResultsCtrl.cs" />
|
||||
<Compile Include="Forms\ManualEntryConfigCtrl.cs">
|
||||
<SubType>UserControl</SubType>
|
||||
@@ -213,9 +225,6 @@
|
||||
<Folder Include="Output\FileWriters\OneFilePerMeter\" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<EmbeddedResource Include="Forms\BatchResultsDlg.resx">
|
||||
<DependentUpon>BatchResultsDlg.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Forms\ManualEntryConfigCtrl.resx">
|
||||
<DependentUpon>ManualEntryConfigCtrl.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
@@ -258,6 +267,8 @@
|
||||
<EmbeddedResource Include="Resources\Strings.ru.resx" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
<None Include="packages.config" />
|
||||
<None Include="Resources\Headpic.png" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="FluentNHibernate" version="3.4.0" targetFramework="net472" />
|
||||
<package id="Iesi.Collections" version="4.0.4" targetFramework="net472" />
|
||||
<package id="NHibernate" version="5.5.2" targetFramework="net472" />
|
||||
<package id="Antlr3.Runtime" version="3.5.1" targetFramework="net472" />
|
||||
<package id="Remotion.Linq" version="2.2.0" targetFramework="net472" />
|
||||
<package id="Remotion.Linq.EagerFetching" version="2.2.0" targetFramework="net472" />
|
||||
<package id="VisualBasic.PowerPacks.Vs" version="1.0.0" targetFramework="net472" />
|
||||
</packages>
|
||||
@@ -41,27 +41,45 @@
|
||||
<StartupObject>ResultsBrowser.Program</StartupObject>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="FluentNHibernate">
|
||||
<HintPath>..\packages\FluentNHibernate.2.0.3.0\lib\net40\FluentNHibernate.dll</HintPath>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.0.4000\lib\net40\Iesi.Collections.dll</HintPath>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="log4net">
|
||||
<HintPath>..\packages\log4net.2.0.2\lib\net40-full\log4net.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.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 Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Oracle.DataAccess, Version=4.121.1.0, Culture=neutral, PublicKeyToken=89b483f429c47342, processorArchitecture=x86">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>..\packages\Oracle\Oracle.DataAccess.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Windows.Forms.DataVisualization" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
@@ -293,6 +311,7 @@
|
||||
<DependentUpon>ResultsBrowserWnd.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<None Include="app.config" />
|
||||
<None Include="packages.config" />
|
||||
<None Include="Properties\Settings.settings">
|
||||
<Generator>SettingsSingleFileGenerator</Generator>
|
||||
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
|
||||
|
||||
@@ -1,3 +1,12 @@
|
||||
<?xml version="1.0"?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<configuration>
|
||||
<startup><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2"/></startup></configuration>
|
||||
<startup><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" /></startup>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="FluentNHibernate" version="3.4.0" targetFramework="net472" />
|
||||
<package id="Iesi.Collections" version="4.0.4" targetFramework="net472" />
|
||||
<package id="NHibernate" version="5.5.2" targetFramework="net472" />
|
||||
<package id="Antlr3.Runtime" version="3.5.1" targetFramework="net472" />
|
||||
<package id="Remotion.Linq" version="2.2.0" targetFramework="net472" />
|
||||
<package id="Remotion.Linq.EagerFetching" version="2.2.0" targetFramework="net472" />
|
||||
<package id="VisualBasic.PowerPacks.Vs" version="1.0.0" targetFramework="net472" />
|
||||
</packages>
|
||||
@@ -1,6 +1,14 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<configuration>
|
||||
<startup>
|
||||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" />
|
||||
</startup>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
@@ -31,6 +31,8 @@ namespace ResultsParser
|
||||
.Database(MySQLConfiguration.Standard.ConnectionString(connStr))
|
||||
.Mappings(m => m.FluentMappings.AddFromAssemblyOf<WaterMeterData>())
|
||||
.ExposeConfiguration(BuildSchema)
|
||||
.BuildConfiguration()
|
||||
.SetProperty("hibernate.connection.connect_timeout", Common.Const.MySqlConnectTimeoutSec)
|
||||
.BuildSessionFactory()
|
||||
.OpenSession();
|
||||
|
||||
|
||||
@@ -32,20 +32,38 @@
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="FluentNHibernate">
|
||||
<HintPath>..\..\Production-Monitoring\packages\FluentNHibernate.2.0.3.0\lib\net40\FluentNHibernate.dll</HintPath>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.0.4000\lib\net40\Iesi.Collections.dll</HintPath>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.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 Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
@@ -58,6 +76,7 @@
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\Common\Common.csproj">
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="FluentNHibernate" version="3.4.0" targetFramework="net472" />
|
||||
<package id="Iesi.Collections" version="4.0.4" targetFramework="net472" />
|
||||
<package id="NHibernate" version="5.5.2" targetFramework="net472" />
|
||||
<package id="Antlr3.Runtime" version="3.5.1" targetFramework="net472" />
|
||||
<package id="Remotion.Linq" version="2.2.0" targetFramework="net472" />
|
||||
<package id="Remotion.Linq.EagerFetching" version="2.2.0" targetFramework="net472" />
|
||||
<package id="VisualBasic.PowerPacks.Vs" version="1.0.0" targetFramework="net472" />
|
||||
</packages>
|
||||
@@ -239,7 +239,7 @@ namespace Statistics
|
||||
"SERVER=localhost; DATABASE=genesis-r; UID=root; PASSWORD=; CHARSET=utf8;",
|
||||
};
|
||||
#else
|
||||
BenchNames = new string[] { "WR10", "WR11", "WR13", "WR14", "WR15", "WR18", "WR19", "WR20", "WR21", "PT7" };
|
||||
BenchNames = new string[] { "WR10", "WR11", "WR13", "WR14", "WR15", "WR18", "WR19", "PT7" };
|
||||
MidNames = new string[] { string.Empty, "I1", "I2", "I3", "I4" }; /// Index is MID-id
|
||||
#if true
|
||||
/// Production Stara Tura
|
||||
@@ -247,16 +247,14 @@ namespace Statistics
|
||||
|
||||
ConnectionStrings = new string[]
|
||||
{
|
||||
"SERVER=10.42.130.69; DATABASE=st-wr10-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;",
|
||||
"SERVER=10.42.129.242; DATABASE=st-wr10-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;",
|
||||
"SERVER=10.42.129.27; DATABASE=st-wr11-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;",
|
||||
"SERVER=10.42.130.52; DATABASE=st-wr13-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;",
|
||||
"SERVER=10.42.128.61; DATABASE=st-wr14-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;",
|
||||
"SERVER=10.42.130.71; DATABASE=st-wr15-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;",
|
||||
"SERVER=10.42.130.0; DATABASE=st-wr13-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;",
|
||||
"SERVER=10.42.128.146; DATABASE=st-wr14-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;",
|
||||
"SERVER=10.42.130.70; DATABASE=st-wr15-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;",
|
||||
"SERVER=10.42.130.165; DATABASE=st-wr18-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;",
|
||||
"SERVER=10.42.128.159; DATABASE=st-wr19-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;",
|
||||
"SERVER=10.42.130.76; DATABASE=st-wr20-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;",
|
||||
"SERVER=10.42.130.156; DATABASE=st-wr21-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;",
|
||||
"SERVER=10.42.130.131; DATABASE=iperlspecial-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;",
|
||||
"SERVER=10.42.130.89; DATABASE=iperlspecial-r; UID=vysledky; PASSWORD=GAqx76QUB6NbnpZP; CHARSET=utf8;",
|
||||
};
|
||||
#else
|
||||
/// Off-line demo
|
||||
|
||||
@@ -37,20 +37,38 @@
|
||||
<Prefer32Bit>false</Prefer32Bit>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="FluentNHibernate">
|
||||
<HintPath>..\packages\FluentNHibernate.2.0.3.0\lib\net40\FluentNHibernate.dll</HintPath>
|
||||
<Reference Include="Antlr3.Runtime, Version=3.5.0.2, Culture=neutral, PublicKeyToken=eb42632606e9261f, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Antlr3.Runtime.3.5.1\lib\net40-client\Antlr3.Runtime.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.0.4000\lib\net40\Iesi.Collections.dll</HintPath>
|
||||
<Reference Include="FluentNHibernate, Version=3.4.0.0, Culture=neutral, PublicKeyToken=8aa435e3cb308880, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\FluentNHibernate.3.4.0\lib\net461\FluentNHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Iesi.Collections, Version=4.0.0.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Iesi.Collections.4.0.4\lib\net461\Iesi.Collections.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualBasic.PowerPacks.Vs, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VisualBasic.PowerPacks.Vs.1.0.0\lib\Microsoft.VisualBasic.PowerPacks.Vs.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 Include="NHibernate, Version=5.5.0.0, Culture=neutral, PublicKeyToken=aa95f207798dfdb4, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NHibernate.5.5.2\lib\net461\NHibernate.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.2.2.0\lib\net45\Remotion.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Remotion.Linq.EagerFetching, Version=2.2.0.0, Culture=neutral, PublicKeyToken=fee00910d6e5f53b, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Remotion.Linq.EagerFetching.2.2.0\lib\net45\Remotion.Linq.EagerFetching.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Windows.Forms.DataVisualization" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
@@ -122,6 +140,7 @@
|
||||
<DependentUpon>StatisticsCtrl.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<None Include="app.config" />
|
||||
<None Include="packages.config" />
|
||||
<None Include="Properties\Settings.settings">
|
||||
<Generator>SettingsSingleFileGenerator</Generator>
|
||||
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
|
||||
@@ -133,6 +152,10 @@
|
||||
</Compile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\Common\Common.csproj">
|
||||
<Project>{c8939821-ba5c-4988-a3d0-bf53b74865c7}</Project>
|
||||
<Name>Common</Name>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\Results\Results.csproj">
|
||||
<Project>{9D0DCC88-DC81-47EB-9FDD-4C3907871BFB}</Project>
|
||||
<Name>Results</Name>
|
||||
|
||||
@@ -13,6 +13,7 @@ using NHibernate;
|
||||
using FluentNHibernate;
|
||||
using FluentNHibernate.Cfg;
|
||||
using FluentNHibernate.Cfg.Db;
|
||||
using Common;
|
||||
using Results;
|
||||
using Results.Entities;
|
||||
using Statistics.Resources;
|
||||
@@ -98,6 +99,8 @@ namespace Statistics
|
||||
.Database(MySQLConfiguration.Standard.ConnectionString(connStr))
|
||||
.Mappings(m => m.FluentMappings.AddFromAssemblyOf<Results.Entities.Batch>())
|
||||
.ExposeConfiguration(BuildSchema)
|
||||
.BuildConfiguration()
|
||||
.SetProperty("hibernate.connection.connect_timeout", Const.MySqlConnectTimeoutSec)
|
||||
.BuildSessionFactory();
|
||||
}
|
||||
catch (Exception)
|
||||
|
||||
+11
-2
@@ -1,3 +1,12 @@
|
||||
<?xml version="1.0"?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<configuration>
|
||||
<startup><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2"/></startup></configuration>
|
||||
<startup><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" /></startup>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.5.0.0" newVersion="5.5.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user