public ActionResult Create(MdoelOrgCompanyCreate model, FormCollection collection) { try { model.Save(); return Content(WebTools.ScriptCloseEmbeddedFrameDialog(DialogOption.GetDefaultInstance())); } catch { //操作失败! Error = OASys.Resources.Properties.Resources.M00002E; model.RetriveData(); return View(model); } }
/// <summary> /// 创建 修改 查看 企业 /// </summary> public ActionResult Create(MdoelOrgCompanyCreate model) { ViewBag.PageState = model.PageState; model.RetriveData(); return View(model); }
/// <summary> /// 验证税务登记证号是否已经存在 /// </summary> public ActionResult RemoteCheckTaxRegisterNo(MdoelOrgCompanyCreate model) { if (!string.IsNullOrEmpty(Request.Params["UTOrgCompanyEntity.IsNeedTaxRegisterNoValidate"]) && Request.Params["UTOrgCompanyEntity.IsNeedTaxRegisterNoValidate"] == "false") return Json(true, JsonRequestBehavior.AllowGet); if (model.UTOrgCompanyEntity.ID != null) return bizUTOrgCompany.CountBy(x => x.ID != model.UTOrgCompanyEntity.ID && x.TaxRegisterNo == model.UTOrgCompanyEntity.TaxRegisterNo) > 0 ? Json(false, JsonRequestBehavior.AllowGet) : Json(true, JsonRequestBehavior.AllowGet); else return bizUTOrgCompany.CountBy(x => x.TaxRegisterNo == model.UTOrgCompanyEntity.TaxRegisterNo) > 0 ? Json(false, JsonRequestBehavior.AllowGet) : Json(true, JsonRequestBehavior.AllowGet); }