Exemplo n.º 1
0
        public ActionResult SharingTmpRead(int page = 1)
        {
            if (!CheckMemberlogin)
            {
                return RedirectToAction("login");
            }
            else
            {
                leftModel();
                var currentpage = page < 1 ? 1 : page;
                var pagesize = 10;
                var model = new SharingTmpViewModel()
                {
                    SharingTmp = shtd.Get().OrderByDescending(a => a.num).ToPagedList(currentpage, pagesize)

                };

                return View(model);
            }
        }
Exemplo n.º 2
0
        public ActionResult SharingTmpEdit(int num, int cl = 0)
        {
            if (!CheckMemberlogin)
            {
                return RedirectToAction("login");
            }
            else
            {
                leftModel();

                sht.num = num;
                sht.isRead = 1;
                shtd.Update_Read(sht);

                var model = new SharingTmpViewModel()
                {
                    SharingTmp_nopage = shtd.Get().ToList().Where(a => a.num == num).OrderByDescending(a => a.num)

                };

                return View(model);
            }
        }