zoukankan      html  css  js  c++  java
  • 点击的页面跟定义的变量

    static int index = 1;
    static int size = 3;
    static int count = 0;//总条数
    static int page = 0;//总页数
    string Where = "";//条件
    static string orderCol = " a.ID asc";//排序

    /// <summary>
    /// 首页
    /// </summary>
    /// <returns></returns>
    public ActionResult First()
    {
    XiaoQu();
    DongHao();
    HuXing();
    ZhuangTai();
    List<UserInfoModel> list = ShowPage();
    return View("Index", list);
    }
    /// <summary>
    /// 上一页
    /// </summary>
    /// <returns></returns>
    public ActionResult ShangYiYe()
    {
    XiaoQu();
    DongHao();
    HuXing();
    ZhuangTai();
    if (index > 1)
    {
    index--;
    }
    List<UserInfoModel> list = ShowPage();
    return View("Index", list);
    }
    /// <summary>
    ///// 下一页
    /// </summary>
    /// <returns></returns>
    public ActionResult Next()
    {
    XiaoQu();
    DongHao();
    HuXing();
    ZhuangTai();
    if (index < page) //当前页小于总页数
    {
    index++;
    }
    List<UserInfoModel> list = ShowPage();
    return View("Index", list);
    }
    /// <summary>
    /// 尾页
    /// </summary>
    /// <returns></returns>
    public ActionResult WeiYe()
    {
    XiaoQu();
    DongHao();
    HuXing();
    ZhuangTai();
    List<UserInfoModel> list = ShowPage();
    return View("Index", list);
    }

  • 相关阅读:
    【Longest Common Prefix】cpp
    【WildCard Matching】cpp
    【 Regular Expression Matching 】cpp
    【Longest Palindromic Substring】cpp
    【Add binary】cpp
    【String to Integer (atoi) 】cpp
    【Implement strStr() 】cpp
    【Valid Palindrome】cpp
    【LRU Cache】cpp
    【Reorder List】cpp
  • 原文地址:https://www.cnblogs.com/MenBe/p/9521728.html
Copyright © 2011-2022 走看看