Beispiel #1
0
        public ActionResult ViewDB(string DbContext)
        {
            try
            {
                if (!Authen.Certification(Session["UserClass"].ToString(), Authen.UserClass.Admin))
                {
                    return(RedirectToAction("PermitionEr", "Error"));
                }
                HomeworkDBContext       homeworkDB       = new HomeworkDBContext();
                CommentDBContext        commentDB        = new CommentDBContext();
                UserDBContext           userDB           = new UserDBContext();
                CategoryDBContext       categoryDB       = new CategoryDBContext();
                UserCategoriesDBcontext userCategoriesDB = new UserCategoriesDBcontext();
                NoteCatDBContext        noteCatDB        = new NoteCatDBContext();
                ClassNotiDBcontext      classNotiDB      = new ClassNotiDBcontext();



                return(View());
            }
            catch
            {
                return(RedirectToAction("LoginEr", "Error"));
            }
        }
Beispiel #2
0
 public CategoryService(CategoryDBContext dbContext)
 {
     this._dbContext = dbContext;
 }
Beispiel #3
0
 public CategoryService(CategoryDBContext dbContext, IMemoryCache cache)
 {
     this._dbContext = dbContext;
     this._cache     = cache;
 }