예제 #1
0
        public async Task <IActionResult> UpdateAsync(int settlementId, [FromBody] CreateSettlementDto request)
        {
            if (!ModelState.IsValid)
            {
                return(BadRequest(ModelState.GetErrorMessages()));
            }

            await _settlementService.UpdateAsync(settlementId, request);

            return(ApiResponseOk(null));
        }
예제 #2
0
 public async Task HandleAsync(UpdateSettlement command)
 => await _settlementService.UpdateAsync(command.SettlementId, command.CurrentUserId, command.Name, command.Description);