public async Task <IActionResult> Add([FromRoute] Guid activityId, [FromForm] CreatePhotoModel model) { var(_, isFailure, value, error) = await _photosService.Add(activityId, model); if (isFailure) { return(BadRequest(error)); } return(Created(value.Id.ToString(), null)); }
public async Task <IActionResult> Add([FromRoute] Guid couponId, [FromForm] CreatePhotoModel model) { var result = await _photosService.Add(couponId, model); return(Created(result.Id.ToString(), null)); }