Ejemplo n.º 1
0
        public ActionResult HienThiDsBaiThi(int id)
        {
            var dethilist = new DeThiDao().ListDeThiMoi();

            ViewBag.dethilist = dethilist;
            return(View(db.TAILIEUx.Where(x => x.IDMON == id).ToList()));
        }
Ejemplo n.º 2
0
        public ActionResult XemChiTiet(int id)
        {
            var dethilist = new DeThiDao().ListDeThiMoi();

            ViewBag.dethilist = dethilist;
            return(View(db.TAILIEUx.Find(id)));
        }
Ejemplo n.º 3
0
        // GET: TinTucGiaoDuc
        public ActionResult Index()
        {
            var dethilist = new DeThiDao().ListDeThiMoi();

            ViewBag.dethilist = dethilist;
            return(View(db.TINTUCs.ToList()));
        }
Ejemplo n.º 4
0
        // GET: NguoiDungClient/Edit/5
        public ActionResult Edit(int id)
        {
            var dethilist = new DeThiDao().ListDeThiMoi();

            ViewBag.dethilist = dethilist;
            return(View(db.NGUOIDUNGs.Find(id)));
        }
Ejemplo n.º 5
0
        public ActionResult Creates()
        {
            var dethilist = new DeThiDao().ListDeThiMoi();

            ViewBag.dethilist = dethilist;
            return(View());
        }
Ejemplo n.º 6
0
        public ActionResult ChiTietCauHoidathi(int id)
        {
            var dethilist = new DeThiDao().ListDeThiMoi();

            ViewBag.dethilist = dethilist;
            ViewBag.cauHoi    = db.CAUHOIs.Find(id);
            return(View());
        }
Ejemplo n.º 7
0
        public ActionResult DoiMatKhauClient(int id)
        {
            var dethilist = new DeThiDao().ListDeThiMoi();

            ViewBag.dethilist = dethilist;
            ViewBag.nguoidung = db.NGUOIDUNGs.Find(id);
            return(View());
        }
Ejemplo n.º 8
0
        // GET: ThongBaoClient
        public ActionResult Index()
        {
            var dethilist = new DeThiDao().ListDeThiMoi();

            ViewBag.dethilist = dethilist;
            var thongbao = new ThongBaoDao();

            ViewBag.ListThongBao = thongbao.toList();
            return(View());
        }
Ejemplo n.º 9
0
        // GET: NguoiDungClient/Delete/5
        public ActionResult LichSuThi(int id)
        {
            var dethilist = new DeThiDao().ListDeThiMoi();

            ViewBag.dethilist = dethilist;
            var dao = new BaiLamDao().toListLichSuThi(id);

            ViewBag.ds = dao;
            return(View());
        }
Ejemplo n.º 10
0
        //GET: BaiLam/Create

        public ActionResult Create(int id)
        {
            var dethilist = new DeThiDao().ListDeThiMoi();

            ViewBag.dethilist = dethilist;
            var dao = new DeThiDao();

            ViewBag.dethi = dao.getDeThiSingle(id);
            return(View());
        }
Ejemplo n.º 11
0
        public ActionResult xemtin(int id)
        {
            var dethilist = new DeThiDao().ListDeThiMoi();

            ViewBag.dethilist = dethilist;
            var tintuc = new TinTucDao();

            ViewBag.tintuc = tintuc.listtintucsapxep();
            return(View(db.TINTUCs.Find(id)));
        }
Ejemplo n.º 12
0
        public ActionResult DSDeThi(int id)
        {
            var dethilist = new DeThiDao().ListDeThiMoi();

            ViewBag.dethilist = dethilist;
            var DeThi = new DeThiDao().toListDeThiID(id);

            ViewBag.dethi  = DeThi;
            ViewBag.monthi = db.MONTHIs.Find(id);
            return(View(ViewBag.dethi));
        }
Ejemplo n.º 13
0
        public ActionResult XemDeThi(int id)
        {
            var dethilist = new DeThiDao().ListDeThiMoi();

            ViewBag.dethilist = dethilist;
            var dao = new CT_CauHoi_DeThi();

            ViewBag.dsCauHoi  = dao.ToListCauHoiDeThi(id);
            ViewBag.soCauDaCo = db.CT_DETHI_CAUHOI.Count(x => x.IDDETHI == id);
            return(View(db.DETHIs.Find(id)));
        }
Ejemplo n.º 14
0
        public ActionResult DSDeThiCNDH(int id)
        {
            var dethilist = new DeThiDao().ListDeThiMoi();

            ViewBag.dethilist = dethilist;
            var Monthi = new ChuyenNganhDao().toListCNDH(id);

            ViewBag.monthi = Monthi;
            var dethi = new DeThiDao();

            ViewBag.dethi = dethi.toList();
            return(View());
        }
Ejemplo n.º 15
0
        public ActionResult Edit(DETHI model, FormCollection collection)
        {
            DeThiDao dao = new DeThiDao();

            var ketqua = dao.SuaDeThi(model);

            if (ketqua != 0)
            {
                return(RedirectToAction("Index"));
            }
            else
            {
                ModelState.AddModelError("", "loi error");
            }
            return(View("Index"));
        }
Ejemplo n.º 16
0
        public ActionResult Index()
        {
            var dethilist = new DeThiDao().ListDeThiMoi();

            ViewBag.dethilist = dethilist;
            var dao = new ShowGiaoDienChinhDao();

            ViewBag.MenuChinh = dao.ListCapThi();
            ViewBag.MenuCon   = dao.ListMonThi();
            var thongbao = new ThongBaoDao();

            ViewBag.ListThongBao = thongbao.toList();
            var socau = new SoCauDao();

            ViewBag.socau = socau.toList();
            var thoigian = new ThoiGianDao();

            ViewBag.thoigian = thoigian.toList();
            var chuyennganh = new ChuyenNganhDao();

            ViewBag.chuyennganh = chuyennganh.toList();
            var dethi = new DeThiDao();

            ViewBag.dethi = dethi.toList();
            var dao0 = new MucDoDao();

            ViewBag.MucDoID = new SelectList(dao0.toList(), "IDMUCDO", "TENMUCDO");
            var dao1 = new MonThiDao();

            ViewBag.MonThiID = new SelectList(dao1.toList(), "IDMON", "TENMON");
            var dao2 = new ThoiGianDao();

            ViewBag.ThoiGianID = new SelectList(dao2.toList(), "IDTHOIGIAN", "THOIGIAN1");
            var dao3 = new SoCauDao();

            ViewBag.SoCauID = new SelectList(dao3.toList(), "IDSOCAU", "SOCAU1");
            var dao4 = new CapThiDao();

            ViewBag.CapThiID = new SelectList(dao4.toList(), "IDCAPTHI", "TENCAPTHI");

            var tintuc = new TinTucDao();

            ViewBag.tintuc    = tintuc.listtintucsapxep();
            ViewBag.tintuctop = tintuc.tintuctop1();

            return(View());
        }
Ejemplo n.º 17
0
        public ActionResult Delete(int id, FormCollection collection)
        {
            var dao = new DeThiDao();

            var ketqua = dao.XoaDeThi(id);

            if (ketqua != -1)
            {
                return(RedirectToAction("Index"));
            }
            else
            {
                ModelState.AddModelError("", "loi error");
                return(View("Error_404"));
            }
            return(View("Index"));
        }
Ejemplo n.º 18
0
        // GET: BaiLam/Details/5
        public ActionResult Details(int id)
        {
            var dethilist = new DeThiDao().ListDeThiMoi();

            ViewBag.dethilist = dethilist;
            BAILAM timbailam = db.BAILAMs.Find(id);
            var    dethi     = db.CT_DETHI_CAUHOI.Where(x => x.IDDETHI == timbailam.IDDETHI).ToList();

            ViewBag.dscauhoi = dethi;
            int iddethi        = timbailam.DETHI.IDDETHI;
            int idbailam       = timbailam.IDBAILAM;
            var sosanh         = new BaiLamDao();
            var tongDiemBaiThi = sosanh.SoSanhDapAn(iddethi, idbailam);

            timbailam.DIEM = tongDiemBaiThi;
            db.SaveChanges();
            return(View(db.BAILAMs.Find(id)));
        }
Ejemplo n.º 19
0
        // GET: TaiLieuHocTap
        public ActionResult Index()
        {
            var dethilist = new DeThiDao().ListDeThiMoi();

            ViewBag.dethilist = dethilist;
            var monthi = new MonThiDao().toList();

            ViewBag.monthi = monthi;
            var capthi = new CapThiDao().toList();

            ViewBag.capthi = capthi;
            var chuyennganh = new ChuyenNganhDao();

            ViewBag.chuyennganh = chuyennganh.toList();
            var ct_chuyennganh = new CT_ChuyenNganh_MonDao();

            ViewBag.CT_chuyennganh = ct_chuyennganh.ToList();
            return(View(db.TAILIEUx.ToList()));
        }
Ejemplo n.º 20
0
        public ActionResult Create(DETHI model, FormCollection collection)
        {
            var dao = new DeThiDao();

            // TODO: Add insert logic here
            if (ModelState.IsValid)
            {
                var ketqua = dao.ThemDeThi(model);
                if (!ketqua)
                {
                    return(View("Index"));
                }
                return(RedirectToAction("ThemCauHoi", new { id = model.IDDETHI }));
            }
            else
            {
                ModelState.AddModelError("", "Loi error");
            }
            return(View("Index"));
        }