public bool update(Product product)
 {
     db.Products.Attach(product);
     db.Entry(product).State = EntityState.Modified;
     if (Convert.ToBoolean(db.SaveChanges()))
     {
         return(true);
     }
     return(false);
 }
 public bool update(Company company)
 {
     db.Companies.Attach(company);
     db.Entry(company).State = EntityState.Modified;
     if (Convert.ToBoolean(db.SaveChanges()))
     {
         return(true);
     }
     return(false);
 }
 public bool update(Buy buy)
 {
     db.Buys.Attach(buy);
     db.Entry(buy).State = EntityState.Modified;
     if (Convert.ToBoolean(db.SaveChanges()))
     {
         return(true);
     }
     return(false);
 }
Exemple #4
0
 public bool update(BankCard bankCard)
 {
     db.BankCards.Attach(bankCard);
     db.Entry(bankCard).State = EntityState.Modified;
     if (Convert.ToBoolean(db.SaveChanges()))
     {
         return(true);
     }
     return(false);
 }
Exemple #5
0
 public bool update(CategoriesFeature categoriesFeature)
 {
     db.CategoriesFeatures.Attach(categoriesFeature);
     db.Entry(categoriesFeature).State = EntityState.Modified;
     if (Convert.ToBoolean(db.SaveChanges()))
     {
         return(true);
     }
     return(false);
 }
 public bool update(Person person)
 {
     db.People.Attach(person);
     db.Entry(person).State = EntityState.Modified;
     if (Convert.ToBoolean(db.SaveChanges()))
     {
         return(true);
     }
     return(false);
 }
 public bool update(PhoneSupport phoneSupport)
 {
     db.PhoneSupports.Attach(phoneSupport);
     db.Entry(phoneSupport).State = EntityState.Modified;
     if (Convert.ToBoolean(db.SaveChanges()))
     {
         return(true);
     }
     return(false);
 }