public ActionResult Login(Models.Home.UIModel_Login model) { EcdrpSite ecdrpSite = EcdrpSite.Admin; LoginEnum result = LoginEnum.Empty; bool IsValid = false; IBLL.IBase_UserManager u = new BLL.Base_UserManager(); if (!string.IsNullOrEmpty(model.CheckCode) && model.CheckCode.Equals(Session["ValidateCode"] ?? "")) { IsValid = true; } if (IsValid) { LoginInputDto input = new LoginInputDto(); //参数实体 input.UserName = model.accountName; //用户名 input.UserPwd = model.password; //密码 input.IP = HttpRequestHelper.GetIP(this.Request); //登录IP地址 input.Browser = HttpRequestHelper.GetBrowser(this.Request); //浏览器版本号 result = u.Login(input, out ecdrpSite); //验证测试系统是否存在自动上传 //var obj = new ZiXin.ERP.PublicModels.PublicData().CheckAutoUpload(); //if (obj.Tag == -1) //{//测试系统中存在自动上传功能 // result = -9; //} } else { result = LoginEnum.CheckCodeErr; //验证码错误,返回9 } return(Json(new { result = result, site = ecdrpSite.ToString(), par = System.Web.HttpUtility.UrlEncode(model.accountName) })); }