public ActionResult Edit(CommodityOwnerTypeViewModel atvm)
 {
     try
     {
         _ownerTypeViewModelBuilder.Save(atvm);
    
         TempData["msg"] = "CommodityOwnerType Successfully Edited";
         return RedirectToAction("ListCommodityOwnerTypes");
     }
     catch (DomainValidationException dve)
     {
         ValidationSummary.DomainValidationErrors(dve, ModelState);
         return View();
     }
     catch (Exception ex)
     {
         _log.Debug("Failed to edit CommodityOwnerType" + ex.Message);
         _log.Error("Failed to edit CommodityOwnerType" + ex.ToString());
         return View();
     }
 }
        public ActionResult Create(CommodityOwnerTypeViewModel atvm)
        {
            try
            {
                atvm.Id = Guid.NewGuid();
                _ownerTypeViewModelBuilder.Save(atvm);
                TempData["msg"] = "CommodityOwnerType Successfully Created";
                return RedirectToAction("ListCommodityOwnerTypes");
            }
            catch (DomainValidationException dve)
            {
                ValidationSummary.DomainValidationErrors(dve, ModelState);
             
                return View();
            }
            catch (Exception ex)
            {
                ViewBag.msg = ex.Message;
                return View();
            }

        }