public CharacterEntity(DragonBallPostRequest request) { Name = request.Name; Kind = request.Kind; BirthDate = request.BirthDate; }
public async Task <ServicesResult> CreateAsync(DragonBallPostRequest request) { var entity = await _characterRepository.CreateAsync(new CharacterEntity(request), true); return(Created(entity)); }
public async Task <IActionResult> Post([FromBody] DragonBallPostRequest request) { var result = await _services.CreateAsync(request); return(ParseResult(result, nameof(GetCharacter))); }