aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio
diff options
context:
space:
mode:
authorRoy Ben-Shabat <Roy@Twine-s.com>2020-01-22 18:00:55 +0200
committerRoy Ben-Shabat <Roy@Twine-s.com>2020-01-22 18:00:55 +0200
commitbf432bf7b7faa7c51e74462e19eb3e50c28b4aa8 (patch)
tree2cce2090c2455f2cadc3f8288f05688ae60a9ed5 /Software/Visual_Studio
parent287af6d4bed5333087cb9d702d20035b1ad9a326 (diff)
downloadTango-bf432bf7b7faa7c51e74462e19eb3e50c28b4aa8.tar.gz
Tango-bf432bf7b7faa7c51e74462e19eb3e50c28b4aa8.zip
Implemented StringFormat control for db properties.
Added StringFormat 0.000 for FeederTension on ProcessParameters.
Diffstat (limited to 'Software/Visual_Studio')
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/JobView.xaml2
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/ProcessParametersView.xaml2
-rw-r--r--Software/Visual_Studio/Tango.BL/DTO/EventTypeDTOBase.cs5
-rw-r--r--Software/Visual_Studio/Tango.BL/DTO/HardwareBlowerDTOBase.cs5
-rw-r--r--Software/Visual_Studio/Tango.BL/DTO/HardwareMotorDTOBase.cs5
-rw-r--r--Software/Visual_Studio/Tango.BL/DTO/JobDTOBase.cs5
-rw-r--r--Software/Visual_Studio/Tango.BL/DTO/JobRunDTOBase.cs5
-rw-r--r--Software/Visual_Studio/Tango.BL/DTO/TechValveDTOBase.cs5
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/ActionLogBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/AddressBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/ApplicationDisplayPanelVersionBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/ApplicationFirmwareVersionBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/ApplicationOsVersionBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/BrushStopBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/CartridgeTypeBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/CatBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/CctBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/ColorCatalogBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/ColorCatalogsGroupBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/ColorCatalogsItemBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/ColorCatalogsItemsRecipeBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/ColorSpaceBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/ConfigurationBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/ContactBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/CustomerBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/DispenserBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/DispenserTypeBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/EmbeddedFirmwareVersionBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/EventTypeBase.cs6
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/FiberShapeBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/FiberSynthBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/HardwareBlowerBase.cs9
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/HardwareBlowerTypeBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/HardwareBreakSensorBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/HardwareBreakSensorTypeBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/HardwareDancerBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/HardwareDancerTypeBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/HardwareMotorBase.cs6
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/HardwareMotorTypeBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/HardwarePidControlBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/HardwarePidControlTypeBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/HardwareSpeedSensorBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/HardwareSpeedSensorTypeBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/HardwareVersionBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/HardwareWinderBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/HardwareWinderTypeBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/IdsPackBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/IdsPackFormulaBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/JobBase.cs6
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/JobRunBase.cs6
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/LinearMassDensityUnitBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/LiquidTypeBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/LiquidTypesRmlBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/MachineBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/MachineStudioVersionBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/MachineVersionBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/MachinesEventBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/MediaConditionBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/MediaMaterialBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/MediaPurposBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/MidTankTypeBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/OrganizationBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/PermissionBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/ProcessParametersTableBase.cs3
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/ProcessParametersTablesGroupBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/RmlBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/RoleBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/RolesPermissionBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/SegmentBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/SiteBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/SitesCatalogBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/SitesRmlBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/SpoolBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/SpoolTypeBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/SyncConfigurationBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/SysdiagramBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/TangoUpdateBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/TangoVersionBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/TechControllerBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/TechDispenserBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/TechHeaterBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/TechIoBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/TechMonitorBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/TechValveBase.cs6
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/UserBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/UsersRoleBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.BL/Entities/WindingMethodBase.cs1
-rw-r--r--Software/Visual_Studio/Tango.CodeGeneration/DbPropertyExtensionModel.cs36
-rw-r--r--Software/Visual_Studio/Tango.CodeGeneration/EntityCodeFile.cs2
-rw-r--r--Software/Visual_Studio/Tango.CodeGeneration/RangeDescriptionModel.cs15
-rw-r--r--Software/Visual_Studio/Tango.CodeGeneration/Tango.CodeGeneration.csproj4
-rw-r--r--Software/Visual_Studio/Tango.CodeGeneration/Templates/EntityCodeFile.cshtml25
-rw-r--r--Software/Visual_Studio/Tango.Core/CustomAttributes/StringFormatAttribute.cs24
-rw-r--r--Software/Visual_Studio/Tango.Core/ExtensionMethods/IParameterizedExtensions.cs7
-rw-r--r--Software/Visual_Studio/Tango.Core/ParameterItem.cs13
-rw-r--r--Software/Visual_Studio/Tango.Core/Tango.Core.csproj3
-rw-r--r--Software/Visual_Studio/Utilities/Tango.DBObservablesGenerator.CLI/ObservablesGenerator.cs21
-rw-r--r--Software/Visual_Studio/Utilities/Tango.PMRGenerator.CLI/Program.cs4
98 files changed, 207 insertions, 95 deletions
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/JobView.xaml b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/JobView.xaml
index 3e6ffd396..b49f1407c 100644
--- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/JobView.xaml
+++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/JobView.xaml
@@ -1553,7 +1553,7 @@
<ContentControl>
<StackPanel>
<TextBlock IsHitTestVisible="False" Margin="0 5 0 5" Text="{Binding Name}" FontSize="11" Foreground="{StaticResource MainWindow.Foreground}"></TextBlock>
- <mahapps:NumericUpDown FontSize="20" Minimum="0" Margin="0 0 5 0" HideUpDownButtons="True" HorizontalContentAlignment="Center" Maximum="10000" StringFormat="0.0" InterceptArrowKeys="True" Background="Transparent" BorderThickness="0" InterceptMouseWheel="True" HasDecimals="True" Value="{Binding Value,Mode=TwoWay}" Foreground="{StaticResource MainWindow.Foreground}"></mahapps:NumericUpDown>
+ <mahapps:NumericUpDown FontSize="20" Minimum="0" Margin="0 0 5 0" HideUpDownButtons="True" HorizontalContentAlignment="Center" Maximum="10000" StringFormat="{Binding StringFormat}" InterceptArrowKeys="True" Background="Transparent" BorderThickness="0" InterceptMouseWheel="True" HasDecimals="True" Value="{Binding Value,Mode=TwoWay}" Foreground="{StaticResource MainWindow.Foreground}"></mahapps:NumericUpDown>
</StackPanel>
</ContentControl>
</Grid>
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/ProcessParametersView.xaml b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/ProcessParametersView.xaml
index b85fd2c12..cae614aeb 100644
--- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/ProcessParametersView.xaml
+++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/ProcessParametersView.xaml
@@ -70,7 +70,7 @@
<DataTemplate>
<DockPanel>
<TextBlock IsHitTestVisible="False" Margin="0 5 0 5" Text="{Binding Name}" FontSize="11"></TextBlock>
- <mahapps:NumericUpDown HorizontalAlignment="Right" Minimum="0" Margin="0 0 5 0" HideUpDownButtons="True" HorizontalContentAlignment="Right" Maximum="10000" StringFormat="0.0" InterceptArrowKeys="True" Background="Transparent" BorderThickness="0" InterceptMouseWheel="True" HasDecimals="True" Value="{Binding Value,Mode=TwoWay}"></mahapps:NumericUpDown>
+ <mahapps:NumericUpDown HorizontalAlignment="Right" Minimum="0" Margin="0 0 5 0" HideUpDownButtons="True" HorizontalContentAlignment="Right" Maximum="10000" StringFormat="{Binding StringFormat}" InterceptArrowKeys="True" Background="Transparent" BorderThickness="0" InterceptMouseWheel="True" HasDecimals="True" Value="{Binding Value,Mode=TwoWay}"></mahapps:NumericUpDown>
</DockPanel>
</DataTemplate>
</editors:ParameterizedEditor.DoubleTemplate>
diff --git a/Software/Visual_Studio/Tango.BL/DTO/EventTypeDTOBase.cs b/Software/Visual_Studio/Tango.BL/DTO/EventTypeDTOBase.cs
index 7b8e30dff..a708cccaf 100644
--- a/Software/Visual_Studio/Tango.BL/DTO/EventTypeDTOBase.cs
+++ b/Software/Visual_Studio/Tango.BL/DTO/EventTypeDTOBase.cs
@@ -18,11 +18,6 @@ using Tango.BL.Entities;
namespace Tango.BL.DTO
{
-
- /// <summary>
- ///
- /// </summary>
-
public abstract class EventTypeDTOBase : ObservableEntityDTO<EventTypeDTO, EventType>
{
diff --git a/Software/Visual_Studio/Tango.BL/DTO/HardwareBlowerDTOBase.cs b/Software/Visual_Studio/Tango.BL/DTO/HardwareBlowerDTOBase.cs
index 9fb6b0bdd..4420c2d2c 100644
--- a/Software/Visual_Studio/Tango.BL/DTO/HardwareBlowerDTOBase.cs
+++ b/Software/Visual_Studio/Tango.BL/DTO/HardwareBlowerDTOBase.cs
@@ -18,11 +18,6 @@ using Tango.BL.Entities;
namespace Tango.BL.DTO
{
-
- /// <summary>
- ///
- /// </summary>
-
public abstract class HardwareBlowerDTOBase : ObservableEntityDTO<HardwareBlowerDTO, HardwareBlower>
{
diff --git a/Software/Visual_Studio/Tango.BL/DTO/HardwareMotorDTOBase.cs b/Software/Visual_Studio/Tango.BL/DTO/HardwareMotorDTOBase.cs
index 4c3125bf7..fcd36bb5d 100644
--- a/Software/Visual_Studio/Tango.BL/DTO/HardwareMotorDTOBase.cs
+++ b/Software/Visual_Studio/Tango.BL/DTO/HardwareMotorDTOBase.cs
@@ -18,11 +18,6 @@ using Tango.BL.Entities;
namespace Tango.BL.DTO
{
-
- /// <summary>
- ///
- /// </summary>
-
public abstract class HardwareMotorDTOBase : ObservableEntityDTO<HardwareMotorDTO, HardwareMotor>
{
diff --git a/Software/Visual_Studio/Tango.BL/DTO/JobDTOBase.cs b/Software/Visual_Studio/Tango.BL/DTO/JobDTOBase.cs
index 073d833f2..ddf76bff0 100644
--- a/Software/Visual_Studio/Tango.BL/DTO/JobDTOBase.cs
+++ b/Software/Visual_Studio/Tango.BL/DTO/JobDTOBase.cs
@@ -18,11 +18,6 @@ using Tango.BL.Entities;
namespace Tango.BL.DTO
{
-
- /// <summary>
- ///
- /// </summary>
-
public abstract class JobDTOBase : ObservableEntityDTO<JobDTO, Job>
{
diff --git a/Software/Visual_Studio/Tango.BL/DTO/JobRunDTOBase.cs b/Software/Visual_Studio/Tango.BL/DTO/JobRunDTOBase.cs
index 40d0a14c4..61d36d1e5 100644
--- a/Software/Visual_Studio/Tango.BL/DTO/JobRunDTOBase.cs
+++ b/Software/Visual_Studio/Tango.BL/DTO/JobRunDTOBase.cs
@@ -18,11 +18,6 @@ using Tango.BL.Entities;
namespace Tango.BL.DTO
{
-
- /// <summary>
- ///
- /// </summary>
-
public abstract class JobRunDTOBase : ObservableEntityDTO<JobRunDTO, JobRun>
{
diff --git a/Software/Visual_Studio/Tango.BL/DTO/TechValveDTOBase.cs b/Software/Visual_Studio/Tango.BL/DTO/TechValveDTOBase.cs
index 2e28dfce7..a7b07fb0c 100644
--- a/Software/Visual_Studio/Tango.BL/DTO/TechValveDTOBase.cs
+++ b/Software/Visual_Studio/Tango.BL/DTO/TechValveDTOBase.cs
@@ -18,11 +18,6 @@ using Tango.BL.Entities;
namespace Tango.BL.DTO
{
-
- /// <summary>
- ///
- /// </summary>
-
public abstract class TechValveDTOBase : ObservableEntityDTO<TechValveDTO, TechValve>
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/ActionLogBase.cs b/Software/Visual_Studio/Tango.BL/Entities/ActionLogBase.cs
index 077c834d2..060d81f8b 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/ActionLogBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/ActionLogBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/AddressBase.cs b/Software/Visual_Studio/Tango.BL/Entities/AddressBase.cs
index f88efdb71..7e1229b98 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/AddressBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/AddressBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/ApplicationDisplayPanelVersionBase.cs b/Software/Visual_Studio/Tango.BL/Entities/ApplicationDisplayPanelVersionBase.cs
index 1671069b3..82a5ea94b 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/ApplicationDisplayPanelVersionBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/ApplicationDisplayPanelVersionBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/ApplicationFirmwareVersionBase.cs b/Software/Visual_Studio/Tango.BL/Entities/ApplicationFirmwareVersionBase.cs
index c54fe23d6..a816c7ad3 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/ApplicationFirmwareVersionBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/ApplicationFirmwareVersionBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/ApplicationOsVersionBase.cs b/Software/Visual_Studio/Tango.BL/Entities/ApplicationOsVersionBase.cs
index 0e06e48db..20b58dbf2 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/ApplicationOsVersionBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/ApplicationOsVersionBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/BrushStopBase.cs b/Software/Visual_Studio/Tango.BL/Entities/BrushStopBase.cs
index 0f742cc0b..89114f2c3 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/BrushStopBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/BrushStopBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/CartridgeTypeBase.cs b/Software/Visual_Studio/Tango.BL/Entities/CartridgeTypeBase.cs
index 6281c7606..e0684e304 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/CartridgeTypeBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/CartridgeTypeBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/CatBase.cs b/Software/Visual_Studio/Tango.BL/Entities/CatBase.cs
index 17bfd3f87..0c73be9ab 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/CatBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/CatBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/CctBase.cs b/Software/Visual_Studio/Tango.BL/Entities/CctBase.cs
index 92f4f17b9..158615777 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/CctBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/CctBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/ColorCatalogBase.cs b/Software/Visual_Studio/Tango.BL/Entities/ColorCatalogBase.cs
index f19eda455..df1056469 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/ColorCatalogBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/ColorCatalogBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/ColorCatalogsGroupBase.cs b/Software/Visual_Studio/Tango.BL/Entities/ColorCatalogsGroupBase.cs
index 3e0491ec5..bc20a0c2e 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/ColorCatalogsGroupBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/ColorCatalogsGroupBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/ColorCatalogsItemBase.cs b/Software/Visual_Studio/Tango.BL/Entities/ColorCatalogsItemBase.cs
index fe026fc32..30d77a051 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/ColorCatalogsItemBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/ColorCatalogsItemBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/ColorCatalogsItemsRecipeBase.cs b/Software/Visual_Studio/Tango.BL/Entities/ColorCatalogsItemsRecipeBase.cs
index a0a324b9f..19b3aed14 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/ColorCatalogsItemsRecipeBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/ColorCatalogsItemsRecipeBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/ColorSpaceBase.cs b/Software/Visual_Studio/Tango.BL/Entities/ColorSpaceBase.cs
index 9098a2eab..b35ca0431 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/ColorSpaceBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/ColorSpaceBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/ConfigurationBase.cs b/Software/Visual_Studio/Tango.BL/Entities/ConfigurationBase.cs
index 6b19ebb7f..d7a90bcfd 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/ConfigurationBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/ConfigurationBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/ContactBase.cs b/Software/Visual_Studio/Tango.BL/Entities/ContactBase.cs
index 610fcc27b..6fd8c9f4c 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/ContactBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/ContactBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/CustomerBase.cs b/Software/Visual_Studio/Tango.BL/Entities/CustomerBase.cs
index 1d3dd576c..68e6b2df1 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/CustomerBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/CustomerBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/DispenserBase.cs b/Software/Visual_Studio/Tango.BL/Entities/DispenserBase.cs
index a908da29c..8343fdb65 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/DispenserBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/DispenserBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/DispenserTypeBase.cs b/Software/Visual_Studio/Tango.BL/Entities/DispenserTypeBase.cs
index 04f4dc261..829ea0cba 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/DispenserTypeBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/DispenserTypeBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/EmbeddedFirmwareVersionBase.cs b/Software/Visual_Studio/Tango.BL/Entities/EmbeddedFirmwareVersionBase.cs
index 148d53c6c..25c7df99f 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/EmbeddedFirmwareVersionBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/EmbeddedFirmwareVersionBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/EventTypeBase.cs b/Software/Visual_Studio/Tango.BL/Entities/EventTypeBase.cs
index f0100fe06..49675a89b 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/EventTypeBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/EventTypeBase.cs
@@ -19,14 +19,10 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
-
- /// <summary>
- ///
- /// </summary>
-
[Table("EVENT_TYPES")]
public abstract class EventTypeBase : ObservableEntity<EventType>
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/FiberShapeBase.cs b/Software/Visual_Studio/Tango.BL/Entities/FiberShapeBase.cs
index cdc9bb76c..cfb335f62 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/FiberShapeBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/FiberShapeBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/FiberSynthBase.cs b/Software/Visual_Studio/Tango.BL/Entities/FiberSynthBase.cs
index d04050c4a..dfb34224b 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/FiberSynthBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/FiberSynthBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/HardwareBlowerBase.cs b/Software/Visual_Studio/Tango.BL/Entities/HardwareBlowerBase.cs
index bbc55d245..5cc6c4931 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/HardwareBlowerBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/HardwareBlowerBase.cs
@@ -19,14 +19,10 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
-
- /// <summary>
- ///
- /// </summary>
-
[Table("HARDWARE_BLOWERS")]
public abstract class HardwareBlowerBase : ObservableEntity<HardwareBlower>
{
@@ -131,8 +127,11 @@ namespace Tango.BL.Entities
[Column("VOLTAGE")]
[Description("Voltage Description")]
+
[Range(-10000,1000000)]
+ [StringFormat("0.0")]
+
public Double Voltage
{
get
diff --git a/Software/Visual_Studio/Tango.BL/Entities/HardwareBlowerTypeBase.cs b/Software/Visual_Studio/Tango.BL/Entities/HardwareBlowerTypeBase.cs
index dc614bd0c..99dadd1f5 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/HardwareBlowerTypeBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/HardwareBlowerTypeBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/HardwareBreakSensorBase.cs b/Software/Visual_Studio/Tango.BL/Entities/HardwareBreakSensorBase.cs
index 9cbaac688..1ca65ab51 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/HardwareBreakSensorBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/HardwareBreakSensorBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/HardwareBreakSensorTypeBase.cs b/Software/Visual_Studio/Tango.BL/Entities/HardwareBreakSensorTypeBase.cs
index 5d69f19b5..77a53c9a0 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/HardwareBreakSensorTypeBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/HardwareBreakSensorTypeBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/HardwareDancerBase.cs b/Software/Visual_Studio/Tango.BL/Entities/HardwareDancerBase.cs
index a3fa5c1aa..65d60714a 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/HardwareDancerBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/HardwareDancerBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/HardwareDancerTypeBase.cs b/Software/Visual_Studio/Tango.BL/Entities/HardwareDancerTypeBase.cs
index 3cd885790..7bff7c035 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/HardwareDancerTypeBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/HardwareDancerTypeBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/HardwareMotorBase.cs b/Software/Visual_Studio/Tango.BL/Entities/HardwareMotorBase.cs
index e08a2b5b0..a0fb6f66e 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/HardwareMotorBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/HardwareMotorBase.cs
@@ -19,14 +19,10 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
-
- /// <summary>
- ///
- /// </summary>
-
[Table("HARDWARE_MOTORS")]
public abstract class HardwareMotorBase : ObservableEntity<HardwareMotor>
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/HardwareMotorTypeBase.cs b/Software/Visual_Studio/Tango.BL/Entities/HardwareMotorTypeBase.cs
index a63a148da..59ceeada9 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/HardwareMotorTypeBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/HardwareMotorTypeBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/HardwarePidControlBase.cs b/Software/Visual_Studio/Tango.BL/Entities/HardwarePidControlBase.cs
index e12e40f32..ccd56bca3 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/HardwarePidControlBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/HardwarePidControlBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/HardwarePidControlTypeBase.cs b/Software/Visual_Studio/Tango.BL/Entities/HardwarePidControlTypeBase.cs
index dbb8d2a1d..d148ea177 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/HardwarePidControlTypeBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/HardwarePidControlTypeBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/HardwareSpeedSensorBase.cs b/Software/Visual_Studio/Tango.BL/Entities/HardwareSpeedSensorBase.cs
index 3b7bb1e72..5661225cb 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/HardwareSpeedSensorBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/HardwareSpeedSensorBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/HardwareSpeedSensorTypeBase.cs b/Software/Visual_Studio/Tango.BL/Entities/HardwareSpeedSensorTypeBase.cs
index 74ff9761d..384462516 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/HardwareSpeedSensorTypeBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/HardwareSpeedSensorTypeBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/HardwareVersionBase.cs b/Software/Visual_Studio/Tango.BL/Entities/HardwareVersionBase.cs
index c3bc80696..3d7d555dc 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/HardwareVersionBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/HardwareVersionBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/HardwareWinderBase.cs b/Software/Visual_Studio/Tango.BL/Entities/HardwareWinderBase.cs
index 4c2808581..8bcc5bb14 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/HardwareWinderBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/HardwareWinderBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/HardwareWinderTypeBase.cs b/Software/Visual_Studio/Tango.BL/Entities/HardwareWinderTypeBase.cs
index 8c8055c1e..340748f97 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/HardwareWinderTypeBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/HardwareWinderTypeBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/IdsPackBase.cs b/Software/Visual_Studio/Tango.BL/Entities/IdsPackBase.cs
index b3e62f1fe..650d93098 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/IdsPackBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/IdsPackBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/IdsPackFormulaBase.cs b/Software/Visual_Studio/Tango.BL/Entities/IdsPackFormulaBase.cs
index 0108dc3f5..62d88bc77 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/IdsPackFormulaBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/IdsPackFormulaBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/JobBase.cs b/Software/Visual_Studio/Tango.BL/Entities/JobBase.cs
index 45e0e3437..a535a78bd 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/JobBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/JobBase.cs
@@ -19,14 +19,10 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
-
- /// <summary>
- ///
- /// </summary>
-
[Table("JOBS")]
public abstract class JobBase : ObservableEntity<Job>
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/JobRunBase.cs b/Software/Visual_Studio/Tango.BL/Entities/JobRunBase.cs
index 5e8a3b62c..7d56f3fa8 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/JobRunBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/JobRunBase.cs
@@ -19,14 +19,10 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
-
- /// <summary>
- ///
- /// </summary>
-
[Table("JOB_RUNS")]
public abstract class JobRunBase : ObservableEntity<JobRun>
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/LinearMassDensityUnitBase.cs b/Software/Visual_Studio/Tango.BL/Entities/LinearMassDensityUnitBase.cs
index ccd78a60b..8f3ca38e8 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/LinearMassDensityUnitBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/LinearMassDensityUnitBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/LiquidTypeBase.cs b/Software/Visual_Studio/Tango.BL/Entities/LiquidTypeBase.cs
index 7683eadbc..723b8aaa7 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/LiquidTypeBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/LiquidTypeBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/LiquidTypesRmlBase.cs b/Software/Visual_Studio/Tango.BL/Entities/LiquidTypesRmlBase.cs
index 5aad28034..ef9e80cb9 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/LiquidTypesRmlBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/LiquidTypesRmlBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/MachineBase.cs b/Software/Visual_Studio/Tango.BL/Entities/MachineBase.cs
index c02b103dd..b1fd12a53 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/MachineBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/MachineBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/MachineStudioVersionBase.cs b/Software/Visual_Studio/Tango.BL/Entities/MachineStudioVersionBase.cs
index 83bf72451..65630a630 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/MachineStudioVersionBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/MachineStudioVersionBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/MachineVersionBase.cs b/Software/Visual_Studio/Tango.BL/Entities/MachineVersionBase.cs
index 30602025e..440eaf723 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/MachineVersionBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/MachineVersionBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/MachinesEventBase.cs b/Software/Visual_Studio/Tango.BL/Entities/MachinesEventBase.cs
index 0a3377dce..161e25d77 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/MachinesEventBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/MachinesEventBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/MediaConditionBase.cs b/Software/Visual_Studio/Tango.BL/Entities/MediaConditionBase.cs
index 12405642a..ec7501ba4 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/MediaConditionBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/MediaConditionBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/MediaMaterialBase.cs b/Software/Visual_Studio/Tango.BL/Entities/MediaMaterialBase.cs
index 2d0529506..860337fae 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/MediaMaterialBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/MediaMaterialBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/MediaPurposBase.cs b/Software/Visual_Studio/Tango.BL/Entities/MediaPurposBase.cs
index 91fd93bd4..7a099ebeb 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/MediaPurposBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/MediaPurposBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/MidTankTypeBase.cs b/Software/Visual_Studio/Tango.BL/Entities/MidTankTypeBase.cs
index 2467bcd8c..34c40f2a0 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/MidTankTypeBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/MidTankTypeBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/OrganizationBase.cs b/Software/Visual_Studio/Tango.BL/Entities/OrganizationBase.cs
index c83d1a7c9..7fb8699af 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/OrganizationBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/OrganizationBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/PermissionBase.cs b/Software/Visual_Studio/Tango.BL/Entities/PermissionBase.cs
index 7f6ba7499..d86097af1 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/PermissionBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/PermissionBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/ProcessParametersTableBase.cs b/Software/Visual_Studio/Tango.BL/Entities/ProcessParametersTableBase.cs
index 2757b0625..1cc189e70 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/ProcessParametersTableBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/ProcessParametersTableBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
@@ -186,6 +187,8 @@ namespace Tango.BL.Entities
[Column("FEEDER_TENSION")]
+ [StringFormat("0.000")]
+
public Double FeederTension
{
get
diff --git a/Software/Visual_Studio/Tango.BL/Entities/ProcessParametersTablesGroupBase.cs b/Software/Visual_Studio/Tango.BL/Entities/ProcessParametersTablesGroupBase.cs
index 79e252b44..005dd5b40 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/ProcessParametersTablesGroupBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/ProcessParametersTablesGroupBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/RmlBase.cs b/Software/Visual_Studio/Tango.BL/Entities/RmlBase.cs
index 86545b913..6901fb973 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/RmlBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/RmlBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/RoleBase.cs b/Software/Visual_Studio/Tango.BL/Entities/RoleBase.cs
index cca6b7600..ed8d67233 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/RoleBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/RoleBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/RolesPermissionBase.cs b/Software/Visual_Studio/Tango.BL/Entities/RolesPermissionBase.cs
index bdaaaac3c..6fa2adf77 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/RolesPermissionBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/RolesPermissionBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/SegmentBase.cs b/Software/Visual_Studio/Tango.BL/Entities/SegmentBase.cs
index 40f86a34c..f98239bf3 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/SegmentBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/SegmentBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/SiteBase.cs b/Software/Visual_Studio/Tango.BL/Entities/SiteBase.cs
index f4881ae79..071dd7ea9 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/SiteBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/SiteBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/SitesCatalogBase.cs b/Software/Visual_Studio/Tango.BL/Entities/SitesCatalogBase.cs
index 15f7ef6df..4f4665203 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/SitesCatalogBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/SitesCatalogBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/SitesRmlBase.cs b/Software/Visual_Studio/Tango.BL/Entities/SitesRmlBase.cs
index 6893099e4..d9111def7 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/SitesRmlBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/SitesRmlBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/SpoolBase.cs b/Software/Visual_Studio/Tango.BL/Entities/SpoolBase.cs
index 5794da91b..303f2ecbb 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/SpoolBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/SpoolBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/SpoolTypeBase.cs b/Software/Visual_Studio/Tango.BL/Entities/SpoolTypeBase.cs
index 55edff2e0..778369948 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/SpoolTypeBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/SpoolTypeBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/SyncConfigurationBase.cs b/Software/Visual_Studio/Tango.BL/Entities/SyncConfigurationBase.cs
index 91b1ca9ac..ea816c4f3 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/SyncConfigurationBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/SyncConfigurationBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/SysdiagramBase.cs b/Software/Visual_Studio/Tango.BL/Entities/SysdiagramBase.cs
index 2e99df9b0..6be908bb4 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/SysdiagramBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/SysdiagramBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/TangoUpdateBase.cs b/Software/Visual_Studio/Tango.BL/Entities/TangoUpdateBase.cs
index 57475977b..677886b47 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/TangoUpdateBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/TangoUpdateBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/TangoVersionBase.cs b/Software/Visual_Studio/Tango.BL/Entities/TangoVersionBase.cs
index ddf7561af..f39df936a 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/TangoVersionBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/TangoVersionBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/TechControllerBase.cs b/Software/Visual_Studio/Tango.BL/Entities/TechControllerBase.cs
index 72fe76f3c..b060ded50 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/TechControllerBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/TechControllerBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/TechDispenserBase.cs b/Software/Visual_Studio/Tango.BL/Entities/TechDispenserBase.cs
index ccb3e7c03..ba6309950 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/TechDispenserBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/TechDispenserBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/TechHeaterBase.cs b/Software/Visual_Studio/Tango.BL/Entities/TechHeaterBase.cs
index 2fc68c69c..5dc7d2a5a 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/TechHeaterBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/TechHeaterBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/TechIoBase.cs b/Software/Visual_Studio/Tango.BL/Entities/TechIoBase.cs
index 0b140690f..e027e81b1 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/TechIoBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/TechIoBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/TechMonitorBase.cs b/Software/Visual_Studio/Tango.BL/Entities/TechMonitorBase.cs
index d7ff856b6..f9f9c7140 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/TechMonitorBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/TechMonitorBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/TechValveBase.cs b/Software/Visual_Studio/Tango.BL/Entities/TechValveBase.cs
index 5275c924b..e22bd450e 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/TechValveBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/TechValveBase.cs
@@ -19,14 +19,10 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
-
- /// <summary>
- ///
- /// </summary>
-
[Table("TECH_VALVES")]
public abstract class TechValveBase : ObservableEntity<TechValve>
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/UserBase.cs b/Software/Visual_Studio/Tango.BL/Entities/UserBase.cs
index cb7692b2d..5e3fa1a8f 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/UserBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/UserBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/UsersRoleBase.cs b/Software/Visual_Studio/Tango.BL/Entities/UsersRoleBase.cs
index 2927d05f1..877f66c72 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/UsersRoleBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/UsersRoleBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.BL/Entities/WindingMethodBase.cs b/Software/Visual_Studio/Tango.BL/Entities/WindingMethodBase.cs
index ce4c22313..e64f989aa 100644
--- a/Software/Visual_Studio/Tango.BL/Entities/WindingMethodBase.cs
+++ b/Software/Visual_Studio/Tango.BL/Entities/WindingMethodBase.cs
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
diff --git a/Software/Visual_Studio/Tango.CodeGeneration/DbPropertyExtensionModel.cs b/Software/Visual_Studio/Tango.CodeGeneration/DbPropertyExtensionModel.cs
new file mode 100644
index 000000000..873aabe1e
--- /dev/null
+++ b/Software/Visual_Studio/Tango.CodeGeneration/DbPropertyExtensionModel.cs
@@ -0,0 +1,36 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace Tango.CodeGeneration
+{
+ public class DbPropertyExtensionModel
+ {
+ public String Description { get; set; }
+ public double Min { get; set; }
+ public double Max { get; set; }
+ public String StringFormat { get; set; }
+
+ public bool HasDescription
+ {
+ get { return Description != null; }
+ }
+
+ public bool HasRange
+ {
+ get { return Min != Max; }
+ }
+
+ public bool HasStringFormat
+ {
+ get { return StringFormat != null; }
+ }
+
+ public DbPropertyExtensionModel()
+ {
+ StringFormat = "0.0";
+ }
+ }
+}
diff --git a/Software/Visual_Studio/Tango.CodeGeneration/EntityCodeFile.cs b/Software/Visual_Studio/Tango.CodeGeneration/EntityCodeFile.cs
index 24d61bb0a..8126c8bc4 100644
--- a/Software/Visual_Studio/Tango.CodeGeneration/EntityCodeFile.cs
+++ b/Software/Visual_Studio/Tango.CodeGeneration/EntityCodeFile.cs
@@ -66,7 +66,7 @@ namespace Tango.CodeGeneration
public String DbDescription { get; set; }
- public RangeDescriptionModel RangeDescription { get; set; }
+ public DbPropertyExtensionModel PropertyExtension { get; set; }
public bool IsForeignKey { get; set; }
diff --git a/Software/Visual_Studio/Tango.CodeGeneration/RangeDescriptionModel.cs b/Software/Visual_Studio/Tango.CodeGeneration/RangeDescriptionModel.cs
deleted file mode 100644
index 4600460b7..000000000
--- a/Software/Visual_Studio/Tango.CodeGeneration/RangeDescriptionModel.cs
+++ /dev/null
@@ -1,15 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-
-namespace Tango.CodeGeneration
-{
- public class RangeDescriptionModel
- {
- public String Description { get; set; }
- public double Min { get; set; }
- public double Max { get; set; }
- }
-}
diff --git a/Software/Visual_Studio/Tango.CodeGeneration/Tango.CodeGeneration.csproj b/Software/Visual_Studio/Tango.CodeGeneration/Tango.CodeGeneration.csproj
index 6bff5b42e..4c2793367 100644
--- a/Software/Visual_Studio/Tango.CodeGeneration/Tango.CodeGeneration.csproj
+++ b/Software/Visual_Studio/Tango.CodeGeneration/Tango.CodeGeneration.csproj
@@ -77,7 +77,7 @@
<Compile Include="ProtoEnumFile.cs" />
<Compile Include="ProtoMessageFile.cs" />
<Compile Include="ProtoProperty.cs" />
- <Compile Include="RangeDescriptionModel.cs" />
+ <Compile Include="DbPropertyExtensionModel.cs" />
<Compile Include="TangoDAOJavaFile.cs" />
<Compile Include="EnumerationFileJava.cs" />
<Compile Include="EnumerationFile.cs" />
@@ -129,7 +129,7 @@
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<ProjectExtensions>
<VisualStudio>
- <UserProperties BuildVersion_AssemblyInfoFilename="Properties\AssemblyInfo.cs" BuildVersion_UpdateAssemblyVersion="True" BuildVersion_BuildVersioningStyle="None.None.Increment.TimeStamp" BuildVersion_UseGlobalSettings="False" BuildVersion_StartDate="2000/1/1" />
+ <UserProperties BuildVersion_StartDate="2000/1/1" BuildVersion_UseGlobalSettings="False" BuildVersion_BuildVersioningStyle="None.None.Increment.TimeStamp" BuildVersion_UpdateAssemblyVersion="True" BuildVersion_AssemblyInfoFilename="Properties\AssemblyInfo.cs" />
</VisualStudio>
</ProjectExtensions>
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
diff --git a/Software/Visual_Studio/Tango.CodeGeneration/Templates/EntityCodeFile.cshtml b/Software/Visual_Studio/Tango.CodeGeneration/Templates/EntityCodeFile.cshtml
index 950e24f79..780cc2647 100644
--- a/Software/Visual_Studio/Tango.CodeGeneration/Templates/EntityCodeFile.cshtml
+++ b/Software/Visual_Studio/Tango.CodeGeneration/Templates/EntityCodeFile.cshtml
@@ -19,6 +19,7 @@ using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
+using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
@@ -67,12 +68,26 @@ namespace Tango.BL.Entities
@(prop.IsForeignKey ? "[ForeignKey(\"" + prop.ForeignKeyName + "\")]" : "")
@(prop.XmlIgnore ? "[XmlIgnore]" : "")
@(prop.XmlIgnore ? "[JsonIgnore]" : "")
- @if (prop.RangeDescription != null)
+ @if (prop.PropertyExtension != null)
{
- <div>
- [Description("@(prop.RangeDescription.Description)")]
- [Range(@(prop.RangeDescription.Min),@(prop.RangeDescription.Max))]
- </div>
+ if (prop.PropertyExtension.HasDescription)
+ {
+ <div>
+ [Description("@(prop.PropertyExtension.Description)")]
+ </div>
+ }
+ if (prop.PropertyExtension.HasRange)
+ {
+ <div>
+ [Range(@(prop.PropertyExtension.Min),@(prop.PropertyExtension.Max))]
+ </div>
+ }
+ if (prop.PropertyExtension.HasStringFormat)
+ {
+ <div>
+ [StringFormat("@(prop.PropertyExtension.StringFormat)")]
+ </div>
+ }
}
public @(prop.Construct || prop.Complex ? "virtual" : "") @(prop.Type) @(prop.Name)
{
diff --git a/Software/Visual_Studio/Tango.Core/CustomAttributes/StringFormatAttribute.cs b/Software/Visual_Studio/Tango.Core/CustomAttributes/StringFormatAttribute.cs
new file mode 100644
index 000000000..e7089b64d
--- /dev/null
+++ b/Software/Visual_Studio/Tango.Core/CustomAttributes/StringFormatAttribute.cs
@@ -0,0 +1,24 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace Tango.Core.CustomAttributes
+{
+ [AttributeUsage(AttributeTargets.Property)]
+ public class StringFormatAttribute : Attribute
+ {
+ public String Format { get; set; }
+
+ public StringFormatAttribute()
+ {
+ Format = "0.0";
+ }
+
+ public StringFormatAttribute(String format) : this()
+ {
+ Format = format;
+ }
+ }
+}
diff --git a/Software/Visual_Studio/Tango.Core/ExtensionMethods/IParameterizedExtensions.cs b/Software/Visual_Studio/Tango.Core/ExtensionMethods/IParameterizedExtensions.cs
index 7107b9ee9..4850ccc25 100644
--- a/Software/Visual_Studio/Tango.Core/ExtensionMethods/IParameterizedExtensions.cs
+++ b/Software/Visual_Studio/Tango.Core/ExtensionMethods/IParameterizedExtensions.cs
@@ -9,6 +9,7 @@ using System.Text;
using System.Threading.Tasks;
using System.Windows;
using Tango.Core;
+using Tango.Core.CustomAttributes;
/// <summary>
/// Contains extension methods for <see cref="IParameterized"/>.
@@ -112,6 +113,12 @@ public static class IParameterizedExtensions
item.Minimum = rangeAtt.Minimum;
item.Maximum = rangeAtt.Maximum;
}
+
+ StringFormatAttribute formatAtt = propertyInfo.GetCustomAttribute<StringFormatAttribute>();
+ if (formatAtt != null)
+ {
+ item.StringFormat = formatAtt.Format;
+ }
}
if (mode == ParameterItemMode.Event)
diff --git a/Software/Visual_Studio/Tango.Core/ParameterItem.cs b/Software/Visual_Studio/Tango.Core/ParameterItem.cs
index ee7acfdd0..0ce682e01 100644
--- a/Software/Visual_Studio/Tango.Core/ParameterItem.cs
+++ b/Software/Visual_Studio/Tango.Core/ParameterItem.cs
@@ -138,6 +138,19 @@ namespace Tango.Core
/// <summary>
+ /// Gets or sets the parameter string format.
+ /// </summary>
+ public String StringFormat
+ {
+ get { return (String)GetValue(StringFormatProperty); }
+ set { SetValue(StringFormatProperty, value); }
+ }
+ public static readonly DependencyProperty StringFormatProperty =
+ DependencyProperty.Register("StringFormat", typeof(String), typeof(ParameterItem), new PropertyMetadata("0.0"));
+
+
+
+ /// <summary>
/// Gets a value indicating whether this instance requires custom editor.
/// </summary>
public bool HasCustomEditor
diff --git a/Software/Visual_Studio/Tango.Core/Tango.Core.csproj b/Software/Visual_Studio/Tango.Core/Tango.Core.csproj
index 54d7e3259..1dc51c2cf 100644
--- a/Software/Visual_Studio/Tango.Core/Tango.Core.csproj
+++ b/Software/Visual_Studio/Tango.Core/Tango.Core.csproj
@@ -89,6 +89,7 @@
<Link>GlobalVersionInfo.cs</Link>
</Compile>
<Compile Include="Components\CmdCommand.cs" />
+ <Compile Include="CustomAttributes\StringFormatAttribute.cs" />
<Compile Include="ExtensionMethods\ByteArrayExtensions.cs" />
<Compile Include="IO\KnownFolders.cs" />
<Compile Include="Json\ProtobufContractResolver.cs" />
@@ -200,7 +201,7 @@
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<ProjectExtensions>
<VisualStudio>
- <UserProperties BuildVersion_StartDate="2000/1/1" BuildVersion_UseGlobalSettings="False" BuildVersion_BuildVersioningStyle="None.None.Increment.TimeStamp" BuildVersion_UpdateAssemblyVersion="True" BuildVersion_AssemblyInfoFilename="Properties\AssemblyInfo.cs" />
+ <UserProperties BuildVersion_AssemblyInfoFilename="Properties\AssemblyInfo.cs" BuildVersion_UpdateAssemblyVersion="True" BuildVersion_BuildVersioningStyle="None.None.Increment.TimeStamp" BuildVersion_UseGlobalSettings="False" BuildVersion_StartDate="2000/1/1" />
</VisualStudio>
</ProjectExtensions>
<Import Project="..\packages\System.Data.SQLite.Core.1.0.108.0\build\net46\System.Data.SQLite.Core.targets" Condition="Exists('..\packages\System.Data.SQLite.Core.1.0.108.0\build\net46\System.Data.SQLite.Core.targets')" />
diff --git a/Software/Visual_Studio/Utilities/Tango.DBObservablesGenerator.CLI/ObservablesGenerator.cs b/Software/Visual_Studio/Utilities/Tango.DBObservablesGenerator.CLI/ObservablesGenerator.cs
index 92eab0857..ac20feb04 100644
--- a/Software/Visual_Studio/Utilities/Tango.DBObservablesGenerator.CLI/ObservablesGenerator.cs
+++ b/Software/Visual_Studio/Utilities/Tango.DBObservablesGenerator.CLI/ObservablesGenerator.cs
@@ -53,7 +53,7 @@ namespace Tango.DBObservablesGenerator.CLI
String table_description = null;
var db_des = dbDescriptions.FirstOrDefault(x => x.TableName == table.Name);
- if (db_des != null)
+ if (db_des != null && !String.IsNullOrWhiteSpace(db_des.TableDescription))
{
table_description = db_des.TableDescription;
}
@@ -121,24 +121,31 @@ namespace Tango.DBObservablesGenerator.CLI
if (column_description != null)
{
- RangeDescriptionModel rangeDescription = null;
+ DbPropertyExtensionModel dbPropertyExtensionModel = null;
try
{
- rangeDescription = JsonConvert.DeserializeObject<RangeDescriptionModel>(column_description);
+ dbPropertyExtensionModel = JsonConvert.DeserializeObject<DbPropertyExtensionModel>(column_description, new JsonSerializerSettings()
+ {
+ NullValueHandling = NullValueHandling.Ignore,
+ MissingMemberHandling = MissingMemberHandling.Ignore,
+ });
}
catch { }
- if (rangeDescription != null && rangeDescription.Description != null)
+ if (dbPropertyExtensionModel != null)
{
- codeField.RangeDescription = rangeDescription;
- codeField.DbDescription = rangeDescription.Description.ToLines().Select(x => "/// " + x).Join(Environment.NewLine);
+ codeField.PropertyExtension = dbPropertyExtensionModel;
+
+ if (dbPropertyExtensionModel.Description != null)
+ {
+ codeField.DbDescription = dbPropertyExtensionModel.Description.ToLines().Select(x => "/// " + x).Join(Environment.NewLine);
+ }
}
else
{
codeField.DbDescription = column_description.ToLines().Select(x => "/// " + x).Join(Environment.NewLine);
}
-
}
if (field.PropertyType.IsGenericType)
diff --git a/Software/Visual_Studio/Utilities/Tango.PMRGenerator.CLI/Program.cs b/Software/Visual_Studio/Utilities/Tango.PMRGenerator.CLI/Program.cs
index 78a9d0380..1b33e13d2 100644
--- a/Software/Visual_Studio/Utilities/Tango.PMRGenerator.CLI/Program.cs
+++ b/Software/Visual_Studio/Utilities/Tango.PMRGenerator.CLI/Program.cs
@@ -748,11 +748,11 @@ namespace Tango.PMRGenerator.CLI
if (db_des != null)
{
- RangeDescriptionModel rangeDescription = null;
+ DbPropertyExtensionModel rangeDescription = null;
try
{
- rangeDescription = JsonConvert.DeserializeObject<RangeDescriptionModel>(db_des.ColumnDescription);
+ rangeDescription = JsonConvert.DeserializeObject<DbPropertyExtensionModel>(db_des.ColumnDescription);
}
catch { }