码迷,mamicode.com
首页 > 其他好文 > 详细

控制器

时间:2018-07-30 11:18:38      阅读:136      评论:0      收藏:0      [点我收藏+]

标签:ges   count   roc   turn   result   ble   ret   res   esc   

Stubll bll = new Stubll();
public static int pages;
public static string TableName = "Stu";
public static string IndexCol = "ID";
public static int PageSize = 3;
public static int PageIndex = 0;
public static string OrderCol = "ID desc";
public static string Where = "";
public static string Columns = "*";

public ActionResult Index()
{
ProcPrams p = new ProcPrams
{
TableName = TableName,
IndexCol = IndexCol,
PageSize = PageSize,
PageIndex = PageIndex,
OrderCol = OrderCol,
Where = Where,
Columns = Columns
};

PagesOut<Stu> li = bll.GetDataList(p);
List<Stu> lis = li.list;

int count = li.SumCount; //总行数
pages = (count % PageSize > 0) ? count / PageSize + 1 : count / PageSize;
return View(lis);
}

控制器

标签:ges   count   roc   turn   result   ble   ret   res   esc   

原文地址:https://www.cnblogs.com/xiaoandong/p/9388654.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!