예제 #1
0
 public bool Insert(item_factura item)
 {
     try
     {
         db.item_factura.Add(item);
         db.SaveChanges();
         return(true);
     }
     catch (Exception e)
     {
         return(false);
     }
 }
예제 #2
0
 public item_factura SrcItem(int id, int idF)
 {
     try
     {
         item_factura srcItemBill = (from f in db.item_factura
                                     where f.Producto == id && f.Factura == idF
                                     select f).First();
         return(srcItemBill);
     }
     catch
     {
         return(null);
     }
 }