public IActionResult OnGet() { NhanvienIndexVm = NhanvienService.GetTen(); cart = SessionHelper.GetObjectFromJson <List <Item> >(HttpContext.Session, "cart"); if (cart != null) { Total = cart.Sum(i => i.Product.GiaBan * i.Quantity); return(Page()); } else { Total = 0; return(Page()); } }
public void OnGet(string searchString, int pageIndex = 1) { NhanvienIndexVm = _service.GetNhanvienListVm(searchString, pageIndex); }