public async Task <IActionResult> Create([FromBody] AddObjectDto objectDto) { var result = await _objectService.AddObject(objectDto); return(StatusCode(result, () => new { Message = "The object has been added", ObjectId = result.Result.Id })); }
public Task <CommandResult <OfferedObject> > AddObject(AddObjectDto objectDto) { return(_objectService.AddObject(objectDto)); }