Exemplo n.º 1
0
        public ActionResult EditReferences(int Id = 0)
        {
            ApplicationReferenceViewModel model = new ApplicationReferenceViewModel();

            if (Id != 0)
            {
                var entity = refService.GetById(Id);
                model = ReferencesMapper.ToViewModel(entity);
            }
            ViewBag.ListReferences = refService.GetAll
                                     .Where(x => x.IsParent && !x.IsDelete);
            return(View(model));
        }
Exemplo n.º 2
0
        public void TestGetById()
        {
            IReferencesService service = DALBuild.GetObj <IReferencesService>("BLL", "ReferencesService");

            Console.WriteLine(service.GetById(2).SchoolName);
        }