Пример #1
0
 public bool addCustomer(customerModel coustomer)
 {
     try{
         coustomer.createon = System.DateTime.Now;
         coustomer.createby = 1;
         context.Add(coustomer);
         context.SaveChanges();
         return(true);
     }
     catch {
         return(false);
     }
 }
 public bool addPurches(purchaseModel purchase)
 {
     try
     {
         purchase.createon = System.DateTime.Now;
         purchase.createby = 1;
         context.Add(purchase);
         context.SaveChanges();
         return(true);
     }
     catch
     {
         return(false);
     }
 }
Пример #3
0
 public bool addOffer(offerModel offer)
 {
     try
     {
         offer.createon = System.DateTime.Now;
         offer.createby = 1;
         context.Add(offer);
         context.SaveChanges();
         return(true);
     }
     catch
     {
         return(false);
     }
 }