Exemple #1
0
 public bool AddCategoria(GS_Categorias categoria)
 {
     try
     {
         Categorias cat = new Categorias();
         cat.nombre      = categoria.nombre;
         cat.descripcion = categoria.descripcion;
         model.Categorias.Add(cat);
         model.SaveChanges();
         return(true);
     }
     catch
     {
         return(false);
     }
 }
Exemple #2
0
 public bool AddCategoria(GS_Categorias categoria)
 {
     return(data.AddCategoria(categoria));
 }