public async System.Threading.Tasks.Task <IHttpActionResult> PostLotPhotoAsync([FromUri] int lotId, [FromBody] LotPhotoModel[] value)
 {
     if (!ModelState.IsValid)
     {
         return(BadRequest(ModelState));
     }
     try
     {
         await lotPhotosOperationsHandler.AddPhotosToExistingLotAsync(lotId, mapper.Map <LotPhoto[]>(value), System.Web.Hosting.HostingEnvironment.MapPath(@"~"), Request.RequestUri.GetLeftPart(UriPartial.Authority));
     }
     catch (WrongIdException ex)
     {
         return(Content(HttpStatusCode.NotFound, ex.Message));
     }
     catch (WrongModelException ex)
     {
         return(BadRequest(ex.Message));
     }
     catch (Exception ex)
     {
         return(InternalServerError(ex));
     }
     return(Ok());
 }