public ActionResult Create(Category category)
        {
            category.CategoryDate = DateTime.Now;
            category.ModifiedDate = DateTime.Now;

            if (ModelState.IsValid)
            {
                category.CategoryID = Guid.NewGuid();
                db.Categories.Add(category);
                db.SaveChanges();
                return RedirectToAction("Index");
            }

            return View(category);
        }
 public ActionResult Edit(Category category)
 {
     if (ModelState.IsValid)
     {
         db.Entry(category).State = EntityState.Modified;
         db.SaveChanges();
         return RedirectToAction("Index");
     }
     return View(category);
 }