Exemplo n.º 1
0
 public static void Create(LesSessionDeFormation ST)
 {
     try
     {
         using (BDDContext context = new BDDContext())
         {
             context.SessionFormations.Add(ST);
             context.SaveChanges();
         }
     }
     catch (Exception ex)
     {
     }
 }
Exemplo n.º 2
0
 public static void Update(LesSessionDeFormation St)
 {
     try
     {
         using (BDDContext context = new BDDContext())
         {
             LesSessionDeFormation Sf = context.SessionFormations.FirstOrDefault(S => S.LesSessionDeFormationId == St.LesSessionDeFormationId);
             Sf.Description   = St.Description;
             Sf.LesFormateurs = St.LesFormateurs;
             Sf.SessionCursus = St.SessionCursus;
             context.SaveChanges();
         }
     }
     catch (Exception ex)
     {
     }
 }