Exemple #1
0
 public void OnGet(string searchString, int pageIndex = 1)
 {
     UserIndexVM = _userService.GetUserListVm(SearchString, UserRole, pageIndex);
     if (string.IsNullOrEmpty(HttpContext.Session.GetString("IDUser")))
     {
         Response.Redirect("http://localhost:5000/Login");
     }
 }
Exemple #2
0
        public IActionResult Index(string searchString, int pageIndex = 1, int pageSize = 5, int?status = null)
        {
            if (HttpContext.Session.GetInt32("LoginLevel") != 2)
            {
                ViewBag.checkLogin = 0;
                return(View("../Home/AddCart"));
            }
            IndexVm UserIndexVM = _userService.GetUserListVm(searchString, pageIndex, pageSize, status);

            ViewBag.pageSize = pageSize;
            ViewBag.status   = status;
            return(View(UserIndexVM));
        }