public T_Shipping updateShipping(T_Shipping item) { var data = context.T_Shipping.FirstOrDefault(m => m.id == item.id); if (data != null) { context.Entry(data).CurrentValues.SetValues(item); context.SaveChanges(); return(data); } else { return(null); } }
public T_Shipping createShippingDoc(T_Shipping shipping) { context.T_Shipping.Add(shipping); context.SaveChanges(); return(shipping); }
public T_Shipping addShipping(T_Shipping item) { context.T_Shipping.Add(item); context.SaveChanges(); return(item); }