示例#1
0
        ///// <summary>
        ///// 得到一个对象实体,从缓存中
        ///// </summary>
        //public Model.dt_manager GetModelByCache(int id)
        //{

        //    string CacheKey = "dt_managerModel-" + id;
        //    object objModel = Common.DataCache.GetCache(CacheKey);
        //    if (objModel == null)
        //    {
        //        try
        //        {
        //            objModel = dal.GetModel(id);
        //            if (objModel != null)
        //            {
        //                int ModelCache = Common.ConfigHelper.GetConfigInt("ModelCache");
        //                Common.DataCache.SetCache(CacheKey, objModel, DateTime.Now.AddMinutes(ModelCache), TimeSpan.Zero);
        //            }
        //        }
        //        catch{}
        //    }
        //    return (Model.dt_manager)objModel;
        //}

        /// <summary>
        /// 获得数据列表
        /// </summary>
        public DataSet GetList(string strWhere)
        {
            return(dal.GetList(strWhere));
        }
示例#2
0
 /// <summary>
 /// 获得查询分页数据
 /// </summary>
 public DataSet GetList(int pageSize, int pageIndex, string strWhere, string filedOrder, out int recordCount)
 {
     return(dal.GetList(pageSize, pageIndex, strWhere, filedOrder, out recordCount));
 }