Exemple #1
0
        void ObjectsItemEndEdit(IEditableObject sender)
        {
            UnidadPeriodoViewModel UIObject = sender as UnidadPeriodoViewModel;

            try
            {
                UnidadPeriodoDataAccess.UpdateUnidadPeriodo(UIObject.GetDataObject());
            }
            catch (Exception ex)
            {
                log.Error(ex.StackTrace);
            }
        }
Exemple #2
0
 void ObjectsCollectionChanged(object sender, NotifyCollectionChangedEventArgs e)
 {
     if (e.Action == NotifyCollectionChangedAction.Remove)
     {
         try
         {
             foreach (object item in e.OldItems)
             {
                 UnidadPeriodoViewModel UIObject = item as UnidadPeriodoViewModel;
                 UnidadPeriodoDataAccess.DeleteUnidadPeriodo(UIObject.GetDataObject());
             }
         }
         catch (Exception ex)
         {
             log.Error(ex.StackTrace);
         }
     }
 }