public ActionResult SoilHandlingPlanRedistributionThicknessEdit(int PermitKey, int Id)
 {
     RedistributionThicknessDO RT = SoilHandlingPlanBLL.GetRedistributionThickness(Id);
     RedistributionThicknessVM model = new RedistributionThicknessVM(RT);
     return PartialView("SoilHandlingPlanRedistributionThicknessAddEdit", model);
 }
        public ActionResult SoilHandlingPlanRedistributionThicknessEdit(int PermitKey, RedistributionThicknessVM model)
        {
            if (!ModelState.IsValid)
                return PartialView("SoilHandlingPlanRedistributionThicknessAddEdit", model);

            try
            {
                RedistributionThicknessDO data = model.WriteRedistributionThickness();
                SoilHandlingPlanBLL.SaveRedistributionThickness(data);
                AjaxResult result = new AjaxResult(AjaxResult.AjaxStatus.OK, "Redistribution Thickness was saved");
                return Json(result);
            }
            catch (Exception ex)
            {
                AjaxResult result = new AjaxResult(AjaxResult.AjaxStatus.ERROR, ex.Message);
                return Json(result);
            }
        }
 public ActionResult SoilHandlingPlanRedistributionThicknessAdd(int PermitKey)
 {
     RedistributionThicknessVM model = new RedistributionThicknessVM();
     model.PermitKey = PermitKey;
     return PartialView("SoilHandlingPlanRedistributionThicknessAddEdit", model);
 }