Esempio n. 1
0
 public ActionResult Update(int id)
 {
     ViewBag.Technology   = new SelectList(TechnologyRepo.All(null), "id", "name");
     ViewBag.Trainer      = new SelectList(TrainerRepo.All(null), "id", "name");
     ViewBag.BootcampType = new SelectList(BootcampTypeRepo.All(), "id", "name");
     ViewBag.Room         = new SelectList(RoomRepo.All(), "id", "name");
     return(PartialView("_Update", BatchRepo.Get(id)));
 }
Esempio n. 2
0
 public ActionResult Create()
 {
     ViewBag.Technology   = new SelectList(TechnologyRepo.All(null), "id", "name");
     ViewBag.Trainer      = new SelectList(TrainerRepo.All(null), "id", "name");
     ViewBag.BootcampType = new SelectList(BootcampTypeRepo.All(), "id", "name");
     ViewBag.Room         = new SelectList(RoomRepo.All(), "id", "name");
     return(PartialView("_Create"));
 }
Esempio n. 3
0
        // Create
        public ActionResult Create()
        {
            ViewBag.roomList         = new SelectList(RoomRepo.All(), "id", "name");
            ViewBag.BootcampTypeList = new SelectList(BootcampTypeRepo.All(), "id", "name");

            ViewBag.technologyList = new SelectList(TechnologyRepo.All(), "id", "name");
            ViewBag.TerainerList   = new SelectList(TrainerRepo.ByTechnology(0), "id", "name"); // Mencari Berdasarkan Technologi

            return(PartialView("_Create"));
        }
Esempio n. 4
0
        // Edit
        public ActionResult Edit(long id)
        {
            BatchViewModel model = new BatchViewModel();

            model = BatchRepo.ById(id);

            ViewBag.tanggalmulai   = model.periodFrom?.ToString("yyyy'-'MM'-'dd");
            ViewBag.tanggalselesai = model.periodTo?.ToString("yyyy'-'MM'-'dd");

            ViewBag.roomList         = new SelectList(RoomRepo.All(), "id", "name");
            ViewBag.BootcampTypeList = new SelectList(BootcampTypeRepo.All(), "id", "name");

            ViewBag.technologyList = new SelectList(TechnologyRepo.All(), "id", "name");
            ViewBag.TerainerList   = new SelectList(TrainerRepo.ByTechnology(model.technologyId), "id", "name"); // Mencari Berdasarkan Technologi

            return(PartialView("_Edit", model));
        }
Esempio n. 5
0
 public ActionResult List(string search)
 {
     return(PartialView("_List", TechnologyRepo.All(search)));
 }
Esempio n. 6
0
 // GET: Technology
 public ActionResult Index(string search)
 {
     return(View(TechnologyRepo.All(search)));
 }
Esempio n. 7
0
 public ActionResult List()
 {
     return(PartialView("_List", TechnologyRepo.All()));
 }