Esempio n. 1
0
 public DataTable ListUserPage(ref int Total, SqlPageParam Param)
 {
     //DataSet ds = SqlHelper.PageResult(SqlHelper.SQLConnString, Param.TableName, Param.PrimaryKey, Param.Fields, Param.PageSize, Param.PageIndex, Param.Filter, Param.Group, Param.Order, ref Total);
     //return ds.Tables[0];
     DataTable dt = dal.PageResult(Param.TableName, Param.PrimaryKey, Param.Fields, Param.PageSize, Param.PageIndex, Param.Filter, Param.Group, Param.Order, ref Total);
     return dt;
 }
Esempio n. 2
0
 /// <summary>
 /// 翻页查询当前用户好友
 /// </summary>
 /// <param name="Total">总条数</param>
 /// <param name="pageSize">一页大小</param>
 /// <param name="pageIndex">当前页索引</param>
 /// <param name="filter">条件</param>
 /// <returns></returns>
 public IList<FriendDto> ListFriendPage(ref int Total, int pageSize, int pageIndex, string filter)
 {
     SqlPageParam param = new SqlPageParam();
     param.TableName = "TUserFriends inner join TUsers on TUserFriends.Pcid = TUsers.id";
     param.PrimaryKey = "TUserFriends.id";
     param.Fields = "TUserFriends.Userid,TUserFriends.Pcid,TUsers.UserName,TUsers.NickName,TrueName,TUsers.Phone";
     param.PageSize = pageSize;
     param.PageIndex = pageIndex;
     param.Filter = filter;
     param.Group = "";
     param.Order = "TUserFriends.id";
     IList<FriendDto> list = DataTableToList.ModelConvertHelper<FriendDto>.ConvertToModel(_dal.ListUserPage(ref Total, param));
     return list;
 }
Esempio n. 3
0
 public IList<OrderDto> ListOrderPage(ref int Total, int pageSize, int pageIndex)
 {
     SqlPageParam param = new SqlPageParam();
     param.TableName = "Orders";
     param.PrimaryKey = "id";
     param.Fields = "id,OrderNo,PeoperNum,PeoperMoney,InputDate,Remark,MoneySendType,MeetType,MeetNum,FirstExtraDate,ExtraDate,State";
     param.PageSize = pageSize;
     param.PageIndex = pageIndex;
     param.Filter = "";
     param.Group = "";
     param.Order = "id";
     IList<OrderDto> list = DataTableToList.ModelConvertHelper<OrderDto>.ConvertToModel(_dal.ListOrderPage(ref Total, param));
     return list;
 }
Esempio n. 4
0
 public IList<OrderDto> ListOrderPage(ref int Total, int pageSize, int pageIndex, string filter)
 {
     SqlPageParam param = new SqlPageParam();
     param.TableName = "View_OrderUser";
     param.PrimaryKey = "id";
     param.Fields = "id,OrderNo,PeoperNum,PeoperMoney,MoneySendType,MeetType,MeetNum,FirstDate,InputDate,State,Remark,LowestMoney,TouUserid,TouTrueName,FirstExtraDate,ExtraDate,Address,MeetExtNum";
     param.PageSize = pageSize;
     param.PageIndex = pageIndex;
     param.Filter = filter;
     param.Group = "";
     param.Order = "id";
     IList<OrderDto> list = DataTableToList.ModelConvertHelper<OrderDto>.ConvertToModel(_dal.ListOrderPage(ref Total, param));
     foreach (var item in list) {
         item.MSType = Enum.GetName(typeof(MnSdTypeEnum), (int)item.MoneySendType);
     }
     return list;
 }
Esempio n. 5
0
 public IList<Nsoup_ImgDetailDto> ListImgTitlePage(ref int Total, int pageSize, int pageIndex, string filter)
 {
     SqlPageParam param = new SqlPageParam();
     param.TableName = "Nsoup_ImgTitle";
     param.PrimaryKey = "id";
     param.Fields = "[id],[Type],[Title] TitleName";
     param.PageSize = pageSize;
     param.PageIndex = pageIndex;
     param.Filter = filter;
     param.Group = "";
     param.Order = "id desc";
     IList<Nsoup_ImgDetailDto> list = DataTableToList.ModelConvertHelper<Nsoup_ImgDetailDto>.ConvertToModel(dal.ListDetailPage(ref Total, param));
     return list;
 }
Esempio n. 6
0
 public IList<Nsoup_ImgDetailDto> ListImgPage(ref int Total, int pageSize, int pageIndex, string filter)
 {
     SqlPageParam param = new SqlPageParam();
     param.TableName = "V_NsoupImg";
     param.PrimaryKey = "id";
     param.Fields = "[id],[Type],[TitleId],TitleName,[ImgUrl],Convert(varchar(19),[AddTime],12) AddTime,[ImgName]";
     param.PageSize = pageSize;
     param.PageIndex = pageIndex;
     param.Filter = filter;
     param.Group = "";
     param.Order = "id desc";
     IList<Nsoup_ImgDetailDto> list = DataTableToList.ModelConvertHelper<Nsoup_ImgDetailDto>.ConvertToModel(dal.ListDetailPage(ref Total, param));
     return list;
 }
Esempio n. 7
0
 public IList<TUserDto> ListTUserPage(ref int Total, int pageSize, int pageIndex)
 {
     SqlPageParam param = new SqlPageParam();
     param.TableName = "TUsers";
     param.PrimaryKey = "Userid";
     param.Fields = "id,UserName,NickName,UserJb,IdentityNum,Phone,TxUrl,State,Addtime";
     param.PageSize = pageSize;
     param.PageIndex = pageIndex;
     param.Filter = "";
     param.Group = "";
     param.Order = "Userid";
     IList<TUserDto> list = DataTableToList.ModelConvertHelper<TUserDto>.ConvertToModel(_dal.ListUserPage(ref Total, param));
     return list;
 }