public async Task <IActionResult> Update([FromBody] ModifyExpenseDto modifyExpenseDto, int expenseId) { var result = await _expenseService.UpdateExpense(modifyExpenseDto, expenseId, UserId); if (!result.Succedeed) { return(BadRequest()); } return(NoContent()); }
public async Task <IActionResult> CreateNew([FromBody] ModifyExpenseDto modifyExpenseDto) { var result = await _expenseService.CreateExpense(modifyExpenseDto, UserId); if (!result.Succedeed) { return(BadRequest()); } return(Ok(result.Value)); }