예제 #1
0
파일: Login.ashx.cs 프로젝트: wkxuan/code
        public void ProcessRequest(HttpContext context)
        {
            LoginResponseDTO res;
            LoginRequestDTO  dto = new LoginRequestDTO()
            {
                PlatformId   = HttpExtension.GetRequestParam("PlatformId"),
                UserCode     = HttpExtension.GetRequestParam("UserCode"),
                UserPassword = HttpExtension.GetRequestParam("UserPassword")
            };

            if (dto.PlatformId.IsEmpty() || dto.UserCode.IsEmpty() || dto.UserPassword.IsEmpty())
            {
                res = new LoginResponseDTO()
                {
                    Success  = false,
                    ErrorMsg = "登陆信息不完整"
                };
            }
            else
            {
                res = new CommonController().Login(dto);
            }

            context.Response.ContentType = "text/plain";
            context.Response.Write(res.ToJson());
        }
예제 #2
0
파일: SearchItem.cs 프로젝트: zgyzgy/ERP
        public static SearchItem GetAllPram()
        {
            SearchItem item = new Results.SearchItem();

            item.Values   = HttpExtension.GetRequestParam <Dictionary <string, string> >("Data");
            item.PageInfo = PageInfo.GetPageinfoFormUI();
            return(item);
        }
예제 #3
0
파일: Do.ashx.cs 프로젝트: wkxuan/code
 public void ProcessRequest(HttpContext context)
 {
     var res = new CommonController().Do(new RequestDTO()
     {
         SecretKey = HttpExtension.GetRequestParam("SecretKey"),
         ServiceName = HttpExtension.GetRequestParam("ServiceName"),
         Context = HttpExtension.GetRequestParam("Context")
     });
     context.Response.ContentType = "text/plain";
     context.Response.Write(res.ToJson());
 }
예제 #4
0
파일: PageInfo.cs 프로젝트: zgyzgy/ERP
        public static PageInfo GetPageinfoFormUI()
        {
            PageInfo p = new DbDomain.PageInfo();

            if (string.IsNullOrEmpty(HttpExtension.GetRequestParam("page")))
            {
                p.PageIndex = p.PageSize = 0;
            }
            else
            {
                p.PageIndex = HttpExtension.GetRequestParam("page").ToInt() - 1;
                p.PageSize  = HttpExtension.GetRequestParam("rows").ToInt();
            }
            return(p);
        }