aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB/Converters
diff options
context:
space:
mode:
authorRoy Ben-Shabat <Roy@Twine-s.com>2019-01-07 16:06:38 +0200
committerRoy Ben-Shabat <Roy@Twine-s.com>2019-01-07 16:06:38 +0200
commite111c33bc87acf40202f9e5423e21b087a366f07 (patch)
treefac6d85ec3589620b1daea9a9f740a2120b0ca10 /Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB/Converters
parent6da42fd28ffbb680d85bb9e695520713ff51022a (diff)
downloadTango-e111c33bc87acf40202f9e5423e21b087a366f07.tar.gz
Tango-e111c33bc87acf40202f9e5423e21b087a366f07.zip
Added new events !!!
Diffstat (limited to 'Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB/Converters')
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB/Converters/EventTypeActionsToStringConverter.cs40
1 files changed, 0 insertions, 40 deletions
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB/Converters/EventTypeActionsToStringConverter.cs b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB/Converters/EventTypeActionsToStringConverter.cs
deleted file mode 100644
index b33259e3e..000000000
--- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB/Converters/EventTypeActionsToStringConverter.cs
+++ /dev/null
@@ -1,40 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Globalization;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Windows.Data;
-using Tango.BL.Entities;
-using Tango.MachineStudio.DB.ViewModels;
-
-namespace Tango.MachineStudio.DB.Converters
-{
- /// <summary>
- /// Converts an event type action to string representation.
- /// </summary>
- /// <seealso cref="System.Windows.Data.IValueConverter" />
- public class EventTypeActionsToStringConverter : IValueConverter
- {
- public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
- {
- if (value == null) return "";
-
- if (value is IEnumerable<EventTypesAction>)
- {
- IEnumerable<EventTypesAction> eventActions = value as IEnumerable<EventTypesAction>;
- return String.Join(", ", eventActions.Select(x => x.ActionType.Name));
- }
- else
- {
- IEnumerable<MultiComboVM<ActionType>> eventActions = value as IEnumerable<MultiComboVM<ActionType>>;
- return String.Join(", ", eventActions.Where(x => x.IsSelected).Select(x => x.Entity.Name));
- }
- }
-
- public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
- {
- throw new NotImplementedException();
- }
- }
-}