Exemple #1
0
        /// <summary>
        /// 获取应用程序分页数据
        /// </summary>
        /// <param name="page"></param>
        /// <param name="size"></param>
        /// <param name="kw">搜索关键词</param>
        /// <returns></returns>
        public ActionResult PageData(int page = 1, int size = 10, string kw = "")
        {
            var where = string.IsNullOrEmpty(kw) ? (Expression <Func <ClientApp, bool> >)(a => true) : (a => a.AppName.Contains(kw) || a.Description.Contains(kw));
            List <ClientAppOutputDto> list = ClientAppBll.LoadPageEntitiesNoTracking <int, ClientAppOutputDto>(page, size, out int total, where, a => a.Id, false).ToList();

            return(PageResult(list, size, total));
        }