/// <summary> /// 返回编辑页面的值 /// </summary> /// <param name="pContext"></param> /// <returns></returns> private List <DefindControlEntity> GetStoreEditData(HttpContext pContext) { StoreDefindModuleBLL b = new StoreDefindModuleBLL(CurrentUserInfo, "Store"); string pKeyValue = pContext.Request["pKeyValue"]; return(b.GetStoreEditData(pKeyValue)); }
/// <summary> /// 不分页查询全部数据 /// </summary> /// <param name="pContext"></param> /// <returns></returns> public DataTable GetStoreData(HttpContext pContext) { StoreDefindModuleBLL b = new StoreDefindModuleBLL(CurrentUserInfo, "Store"); string pSearch = pContext.Request["pSearch"]; List <DefindControlEntity> l = new List <DefindControlEntity>(); if (!string.IsNullOrEmpty(pSearch)) { l = pSearch.DeserializeJSONTo <List <DefindControlEntity> >(); } return(b.GetStoreData(l)); }
private string GetRepeatRowCount(HttpContext pContext) { StoreDefindModuleBLL b = new StoreDefindModuleBLL(CurrentUserInfo, "Store"); string pKeyValue = pContext.Request["pKeyValue"]; string pSearch = pContext.Request["pSearch"]; List <DefindControlEntity> l = new List <DefindControlEntity>(); if (!string.IsNullOrEmpty(pSearch)) { l = pSearch.DeserializeJSONTo <List <DefindControlEntity> >(); } return(b.GetRepeatRowCount(l, pKeyValue)); }
/// <summary> /// 删除终端 /// </summary> /// <param name="pContext"></param> /// <returns></returns> private string Delete(HttpContext pContext) { StoreDefindModuleBLL b = new StoreDefindModuleBLL(CurrentUserInfo, "Store"); string pKeyValue = pContext.Request["pKeyValue"]; string checkRes = ""; bool res = b.Delete(pKeyValue, out checkRes); if (res == true) { return("{success:true}"); } else { return("{success:false,msg:\"" + checkRes + "\"}"); } }
protected override void AjaxRequest(HttpContext pContext) { string res = ""; switch (this.Method) { //case "InitGridData": //初使化终端编辑列表的数据 // res = GetInitGridData(pContext).ToJSON(); //break; case "PageGridData": //查询数据分页查询 res = GetPageData(pContext).ToJSON(); break; case "QueryView": //得到查询控件 res = new StoreDefindModuleBLL(CurrentUserInfo, "VIP").GetEditControls().ToJSON(); break; } pContext.Response.Write(res); pContext.Response.End(); }
/// <summary> /// 添加终端 /// </summary> /// <param name="pContext"></param> /// <returns></returns> private string Create(HttpContext pContext) { StoreDefindModuleBLL b = new StoreDefindModuleBLL(CurrentUserInfo, "Store"); string pEditValue = pContext.Request["pEditValue"]; List <DefindControlEntity> l = new List <DefindControlEntity>(); if (!string.IsNullOrEmpty(pEditValue)) { l = pEditValue.DeserializeJSONTo <List <DefindControlEntity> >(); } bool res = b.Create(l); if (res == true) { return("[{success:true}]"); } else { return("[{success:false}]"); } }
/// <summary> /// 终端管理分页查询 /// </summary> /// <param name="pContext"></param> /// <returns></returns> public PageResultEntity GetStorePageData(HttpContext pContext) { StoreDefindModuleBLL b = new StoreDefindModuleBLL(CurrentUserInfo, "Store"); string pSearch = pContext.Request["pSearch"]; List <DefindControlEntity> l = new List <DefindControlEntity>(); if (!string.IsNullOrEmpty(pSearch)) { l = pSearch.DeserializeJSONTo <List <DefindControlEntity> >(); } int?pPageIndex = null; int?pPageSize = null; if (!string.IsNullOrEmpty(pContext.Request["pPageIndex"])) { pPageIndex = Convert.ToInt32(pContext.Request["pPageIndex"]); } if (!string.IsNullOrEmpty(pContext.Request["pPageSize"])) { pPageSize = Convert.ToInt32(pContext.Request["pPageSize"]); } return(b.GetStorePageData(l, pPageSize, pPageIndex)); }
/// <summary> /// 获取终端列表表头定义 /// </summary> /// <param name="pContext"></param> /// <returns></returns> public List <GridColumnEntity> GetStoreGridColumns(HttpContext pContext) { StoreDefindModuleBLL b = new StoreDefindModuleBLL(CurrentUserInfo, "Store"); return(b.GetGridColumns()); }
/// <summary> /// 得到编辑页面控件 /// </summary> /// <param name="pContext"></param> /// <returns></returns> private List <DefindControlEntity> GetStoreEditControls(HttpContext pContext) { StoreDefindModuleBLL b = new StoreDefindModuleBLL(CurrentUserInfo, "Store"); return(b.GetEditControls()); }
/// <summary> /// 获取终端查询控件 /// </summary> /// <param name="pContext"></param> /// <returns></returns> public List <DefindControlEntity> GetStoreQueryConditionControls(HttpContext pContext) { StoreDefindModuleBLL b = new StoreDefindModuleBLL(CurrentUserInfo, "Store"); return(b.GetQueryConditionControls()); }
/// <summary> /// 获取终端查询控件 /// </summary> /// <param name="pContext"></param> /// <returns></returns> private List <DefindControlEntity> GetStoreQueryConditionControls(HttpContext pContext) { StoreDefindModuleBLL b = new StoreDefindModuleBLL(new SessionManager().CurrentUserLoginInfo, "Store"); return(b.GetQueryConditionControls()); }