Exemplo n.º 1
0
        private void ShowHistoryCommandExecuted(EventUpdateModel update)
        {
            RaisePropertyChanged("DisableParentWindow");

            var window = new UpdatesHistoryView(update.UpdatesHistory);
            window.ShowDialog();

            RaisePropertyChanged("EnableParentWindow");
        }
Exemplo n.º 2
0
        private void ProcessNotesUpdates()
        {
            var updatesgroups = _allEventUpdates.Where(x => x.Field == "Notes").OrderByDescending(x => x.Date).GroupBy(x => x.ItemId);

            foreach (var updatesgroup in updatesgroups)
            {
                var updateHiistList = updatesgroup.Select(eventUpdate => new UpdatesHistoryModel()
              {
                  EventUpdate = eventUpdate

              }).ToList();

                var updateModel = new EventUpdateModel(updatesgroup.FirstOrDefault());
                if (updateModel.EventUpdate != null)
                {
                    updateModel.UpdatesHistory = updateHiistList.OrderBy(eventUpdate => eventUpdate.EventUpdate.Date).ToList();
                    AllEventUpdates.Add(updateModel);
                }
            }
            AllEventUpdates = new ObservableCollection<EventUpdateModel>(AllEventUpdates.OrderByDescending(eventUpdate => eventUpdate.EventUpdate.Date));
        }