Пример #1
0
        void ObjectsItemEndEdit(IEditableObject sender)
        {
            RecursoBasicaViewModel UIObject = sender as RecursoBasicaViewModel;

            try
            {
                RecursoBasicaDataAccess.UpdateRecursoBasica(UIObject.GetDataObject());
            }
            catch (Exception ex)
            {
                log.Error(ex.StackTrace);
            }
        }
Пример #2
0
 void ObjectsCollectionChanged(object sender, NotifyCollectionChangedEventArgs e)
 {
     if (e.Action == NotifyCollectionChangedAction.Remove)
     {
         try
         {
             foreach (object item in e.OldItems)
             {
                 RecursoBasicaViewModel UIObject = item as RecursoBasicaViewModel;
                 RecursoBasicaDataAccess.DeleteRecursoBasica(UIObject.GetDataObject());
             }
         }
         catch (Exception ex)
         {
             log.Error(ex.StackTrace);
         }
     }
 }