예제 #1
0
        public ActionResult Index()
        {
            var model = new FileIndexModel();

            model.Files       = TSFiles.LoadStubs();
            model.Permissions = Permissions.Load(User);
            string userID = User.GetUserID();

            model.Files.MineFilter = UserPreferences.Get <bool>(userID, "PageIndexMine");
            return(View(model));
        }
예제 #2
0
        public ActionResult Recent()
        {
            var model = new PageIndexModel();

            model.Recent      = true;
            model.Pages       = Pages.LoadStubs(-1, null, 100);
            model.Permissions = Permissions.Load(User);
            string userID = User.GetUserID();

            model.Pages.ZoneFilter    = UserPreferences.Get <int>(userID, "PageIndexZone");
            model.Pages.PrimaryFilter = UserPreferences.Get <bool>(userID, "PageIndexPrimary");
            model.Pages.MineFilter    = UserPreferences.Get <bool>(userID, "PageIndexMine");
            return(View("Index", model));
        }
예제 #3
0
 public ActionResult Get(string ID)
 {
     if (string.IsNullOrWhiteSpace(ID))
     {
         return(AllowGet(null));
     }
     try
     {
         string userID = User.GetUserID();
         string val    = UserPreferences.Get(userID, ID);
         return(AllowGet(val));
     }
     catch { }
     return(AllowGet(null));
 }