public void EditRegular(Regular regular) { _appDbContext.Regular.Update(regular); regular.Payment = new DateTime(DateTime.Now.Year, DateTime.Now.Month, regular.DayOfPayment); regular.ShoppingDate = regular.Payment.ToShortDateString(); _appDbContext.SaveChanges(); }
public void DeleteRegular(Regular regular) { _appDbContext.Regular.Remove(regular); _appDbContext.SaveChanges(); }
public void ChangeStatus(Regular regular) { regular.Status = true; _appDbContext.SaveChanges(); }