From e111c33bc87acf40202f9e5423e21b087a366f07 Mon Sep 17 00:00:00 2001 From: Roy Ben-Shabat Date: Mon, 7 Jan 2019 16:06:38 +0200 Subject: Added new events !!! --- .../Modules/Tango.MachineStudio.Logging/ViewModels/EventsViewVM.cs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Logging/ViewModels') diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Logging/ViewModels/EventsViewVM.cs b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Logging/ViewModels/EventsViewVM.cs index 1f93a96dc..c813e9752 100644 --- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Logging/ViewModels/EventsViewVM.cs +++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Logging/ViewModels/EventsViewVM.cs @@ -140,8 +140,6 @@ namespace Tango.MachineStudio.Logging.ViewModels _db = ObservablesContext.CreateDefault(); _db.EventTypes.Load(); - _db.EventTypesCategories.Load(); - _db.EventTypesGroups.Load(); DateTime now = DateTime.UtcNow.AddMonths(-1); @@ -183,7 +181,7 @@ namespace Tango.MachineStudio.Logging.ViewModels private void OnSelectedEventChanged() { - if (SelectedEvent != null && SelectedEvent.Type != BL.Enumerations.EventTypes.ApplicationStarted && !_dialog_shown) + if (SelectedEvent != null && SelectedEvent.Type != BL.Enumerations.EventTypes.APPLICATION_STARTED && !_dialog_shown) { _dialog_shown = true; _notification.ShowModalDialog(new EventDetailsViewVM(SelectedEvent), (x) => @@ -198,7 +196,7 @@ namespace Tango.MachineStudio.Logging.ViewModels private void DisplayTimeline(MachinesEvent ev) { - var events = Events.OrderBy(x => x.DateTime).SkipWhile(x => x != ev).Skip(1).TakeWhile(x => x.DateTime > ev.DateTime && x.Type != BL.Enumerations.EventTypes.ApplicationStarted).ToObservableCollection(); + var events = Events.OrderBy(x => x.DateTime).SkipWhile(x => x != ev).Skip(1).TakeWhile(x => x.DateTime > ev.DateTime && x.Type != BL.Enumerations.EventTypes.APPLICATION_STARTED).ToObservableCollection(); events.Insert(0, ev); TimelineViewVM.Initialize(events.ToList()); -- cgit v1.3.1