public void ProcessRequest(HttpContext context) { context.Response.ContentType = "text/plain"; string title = context.Request.QueryString["title"]; string page; System.Data.DataTable dt = new FoWoSoft.Platform.Log().GetPagerData(out page, "", title, "", "", "", ""); System.Text.StringBuilder sb = new System.Text.StringBuilder(); foreach (System.Data.DataRow user in dt.Rows) { sb.Append("<tr><td value='" + user["ID"] + "'>" + user["Title"] + "</td><td>" + user["Type"] + "</td><td>" + user["UserName"] + "</td><td>" + user["WriteTime"] + "</td></tr>"); } context.Response.Write("{\"count\":" + new FoWoSoft.Platform.Log().GetCount() + ",\"data\":\"" + sb.ToString() + "\"}"); }
public void ProcessRequest(HttpContext context) { context.Response.ContentType = "text/plain"; string values = context.Request.QueryString["values"]; string xx; var logs = new FoWoSoft.Platform.Log().GetPagerData(out xx, "", "", "", "", "", ""); System.Text.StringBuilder sb = new System.Text.StringBuilder(); foreach (System.Data.DataRow dr in logs.Rows) { string selected = ("," + values + ",").Contains("," + dr["ID"].ToString() + ",", StringComparison.CurrentCultureIgnoreCase) ?" selected=\"selected\"":""; sb.AppendFormat("<option value=\"{0}\"{1}>{2}</option>", dr["ID"], selected, dr["Title"]); } context.Response.Write(sb.ToString()); }
public void ProcessRequest(HttpContext context) { context.Response.ContentType = "text/plain"; long count = 0; string title = context.Request.QueryString["title"]; string type = context.Request.QueryString["type"]; string date1 = context.Request.QueryString["date1"]; string date2 = context.Request.QueryString["date2"]; string userid = context.Request.QueryString["userid"]; string size = context.Request.QueryString["pagesize"]; string number = context.Request.QueryString["pagenumber"]; FoWoSoft.Platform.Log blog = new FoWoSoft.Platform.Log(); System.Data.DataTable dt = new System.Data.DataTable(); //blog.GetPagerData(out count, size.ToInt(), number.ToInt(), "", title, type, date1, date2, userid); string data = FoWoSoft.Utility.Tools.DataTableToJsonString(dt); context.Response.Write("{\"count\":" + count.ToString() + ",\"data\":" + data + "}"); }
public void CreateAllUser() { var ss = new FoWoSoft.Platform.Guid_id().GetAll(); var kk = new FoWoSoft.Platform.UsersRelation().GetAll(); var ll = new FoWoSoft.Platform.Log().GetAll(); for (int i = ss.Count - 1; i > 0; i--) { var useid = ss[i].useId.Trim(); var or = ll.FirstOrDefault(s => s.Contents == useid); if (or != null) { continue; } //Task.Factory.StartNew(new Action(() => CreateUser(useid))); CreateUser(useid); } }
protected void Page_Load(object sender, EventArgs e) { string title = string.Empty; string type = string.Empty; string date1 = string.Empty; string date2 = string.Empty; string userid = string.Empty; if (!IsPostBack) { title = Request.QueryString["Title1"]; type = Request.QueryString["Type"]; date1 = Request.QueryString["Date1"]; date2 = Request.QueryString["Date2"]; userid = Request.QueryString["UserID"]; } else { title = Request.Form["Title"]; type = Request.Form["Type"]; date1 = Request.Form["Date1"]; date2 = Request.Form["Date2"]; userid = Request.Form["UserID"]; } FoWoSoft.Platform.Log blog = new FoWoSoft.Platform.Log(); Query = string.Format("&appid={0}&tabid={1}&Title={2}&Type={3}&Date1={4}&Date2={5}&UserID={6}", Request.QueryString["appid"], Request.QueryString["tabid"], title.UrlEncode(), type.UrlEncode(), date1, date2, userid ); string pager; Dt = blog.GetPagerData(out pager, Query, title, type, date1, date2, userid); this.TypeOptions.Text = blog.GetTypeOptions(type); this.Pager.Text = pager; }
public void ProcessRequest(HttpContext context) { context.Response.ContentType = "text/plain"; string values = context.Request.QueryString["values"]; System.Text.StringBuilder texts = new System.Text.StringBuilder(); FoWoSoft.Platform.Log Log = new FoWoSoft.Platform.Log(); foreach (string value in values.Split(new string[] { "," }, StringSplitOptions.RemoveEmptyEntries)) { if (value.IsGuid()) { var log = Log.Get(value.ToGuid()); if (log != null) { texts.Append(log.Title); texts.Append(","); } } } context.Response.Write(texts.ToString().TrimEnd(',')); }