Exemple #1
0
 private void pnl_location_linkEdit_Click(object sender, int intLocationId)
 {
     crud_modal.Visibility = System.Windows.Visibility.Visible;
     cntrl.location objLocation = new cntrl.location();
     locationViewSource.View.MoveCurrentTo(entity.db.app_location.Where(x => x.id_location == intLocationId).FirstOrDefault());
     objLocation.app_locationViewSource = locationViewSource;
     objLocation._entity = entity;
     crud_modal.Children.Add(objLocation);
 }
Exemple #2
0
        private void btnNew_Click(object sender, RoutedEventArgs e)
        {
            crud_modal.Visibility = System.Windows.Visibility.Visible;
            cntrl.location objLocation  = new cntrl.location();
            app_location   app_location = new app_location();

            entity.db.app_location.Add(app_location);
            locationViewSource.View.MoveCurrentToLast();
            objLocation.app_locationViewSource = locationViewSource;
            objLocation._entity = entity;
            crud_modal.Children.Add(objLocation);
        }