Esempio n. 1
0
 public CommandActionResult<CreateNewDojo> Create(CreateSchoolForm form)
 {
     var address = new Address
                       {
                           State = form.State,
                           City = form.City,
                           PostalCode = form.PostalCode,
                           Street = form.StreetName,
                           StreetNumber = form.StreetNumber,
                       };
     return Command(
         new CreateNewDojo(_currentUserProvider.CurrentLoggedInUser().Id, form.Id, form.Name, address,form.Description),
         () => RedirectToAction("List", "Schools"));
 }
Esempio n. 2
0
 public ActionResult Create()
 {
     var model = new CreateSchoolForm();
     return ContextualView(model);
 }