コード例 #1
0
        public ActionResult Create(Agency agency)
        {
            if (ModelState.IsValid)
            {
                AgencyService.AddAgency(agency);

                return AgencyList();
            }

            return PartialView("_CreateAgency", agency);
        }
コード例 #2
0
        public void AddAgency(Agency agency)
        {
            UnitOfWork.Agencies.Insert(agency);

            UnitOfWork.Commit();
        }
コード例 #3
0
        public ActionResult Create()
        {
            var agency = new Agency();

            return PartialView("_CreateAgency", agency);
        }