Ejemplo n.º 1
0
        // Set Up Test List
        public ActionResult SetUpTest(long id)
        {
            ViewBag.IdBatch = id; // mengirim bath id

            List <TestViewModel> data = TestRepo.All("");

            foreach (var item in data)
            {
                BatchTestViewModel btmodel = BatchRepo.Check(id, item.id);
                if (btmodel.batch_id == 0)
                {
                    item.check = true;
                }
                else
                {
                    item.check = false;
                }
            }

            return(PartialView("_SetUpTest", data));
        }