Exemplo n.º 1
0
        public ActionResult SubCategory(FormCollection frm)
        {

            Session["ControllerName"] = "Sub Category";
            //string str = EnterSubCat(Convert.ToInt32(frm[0]), frm[1]);
            if (Session["loginDetails"] != null)
            {
                ProductAdminBLL bll = new ProductAdminBLL();
                int str = bll.EnterSubCat(Convert.ToInt32(frm[0]), frm[1]);
                //return str;
                if (str > 0)
                {

                    return RedirectToAction("SubCategory");
                }
                else
                {
                    ViewBag.CatSuccess = "Fail to Insert";
                    GetSubCategoryDDL();
                    return View();

                }

            }
            else
            {
                return RedirectToAction("Error");
            }
          
        }