Exemple #1
0
        public ActionResult Editdetail(int id)
        {
            var data = dmapping.ToObj(unitOfWork.DigitalResourceMasterRepository.GetByID(id));

            ViewBag.count = data.DigitalResourceFiles.Count - 1;
            return(View(data));
        }
Exemple #2
0
        public ActionResult Add(int?id)
        {
            DigitalResourceMasterModel model = new DigitalResourceMasterModel();

            if (id != null)
            {
                model = dmapping.ToObj(unitOfWork.DigitalResourceMasterRepository.GetByID(id));
                foreach (var item in model.DigitalResourceClasses)
                {
                    int clasid = (int)item.ClassId;
                    model.Selecteditems.Add(clasid);
                }
            }
            var clas = mapping.ToList(unitOfWork.LessonPlanClassRepository.Get().ToList());

            model.LessonPlanClassModellist = clas;
            return(View(model));
        }