public ActionResult Create(ThespianManagementThespian thespian) { var createActorPreCommand = createActorPreCommandAccessor(); createActorPreCommand.FirstName = thespian.FirstName; createActorPreCommand.LastName = thespian.LastName; createActorPreCommand.ProfileImageLocation = thespian.ProfileImageLocation; createActorPreCommand.ProfileThumbnailImageLocation = thespian.ProfileThumbnailImageLocation; createActorPreCommand.Email = thespian.Email; createActorPreCommand.DateOfBirth = thespian.DateOfBirth; createActorPreCommand.Gender = thespian.Gender; createActorPreCommand.Location = thespian.Location; createActorPreCommand.Height = thespian.Height; createActorPreCommand.Weight = thespian.Weight; createActorPreCommand.PlayingAge = thespian.PlayingAge; createActorPreCommand.EyeColour = thespian.EyeColour; createActorPreCommand.HairLength = thespian.HairLength; createActorPreCommand.Summary = thespian.Summary; createActorPreCommand.Twitter = thespian.Twitter; createActorPreCommand.Facebook = thespian.Facebook; createActorPreCommand.Spotlight = thespian.Spotlight; createActorPreCommand.Imdb = thespian.Imdb; createActorPreCommand.ThespianType = thespian.ThespianType; createActorPreCommand.CreatedBy = currentUserDetails.Username; createActorPreCommand.Execute(); return Json(createActorPreCommand.Results); }
public CreateThespianViewModel() { Thespian = new ThespianManagementThespian(); }
public void Validate() { ThespianManagementThespian thespian = new ThespianManagementThespian { FirstName = FirstName, LastName = LastName, ProfileImageLocation = ProfileImageLocation, ProfileThumbnailImageLocation = ProfileThumbnailImageLocation, DateOfBirth = DateOfBirth, Email = Email, Gender = Gender, Location = Location, Height = Height, Weight = Weight, PlayingAge = PlayingAge, EyeColour = EyeColour, HairLength = HairLength, Summary = Summary, Twitter = Twitter, Facebook = Facebook, Spotlight = Spotlight, Imdb = Imdb, ThespianType = ThespianType, CreatedBy = CreatedBy }; Results = validatorResolver.CreateValidator().Validate(thespian); }