public async Task <IActionResult> InsertPhotoGalleryAsync( [FromBody] InsertPhotoGralleryRequest insertPhotoGralleryRequest) { await _awsCloudFacade.InsertAsync(insertPhotoGralleryRequest); return(Ok()); }
public async Task InsertAsync(InsertPhotoGralleryRequest insertPhotoGralleryRequest) { StringContent stringContent = GetStringContent(insertPhotoGralleryRequest); HttpResponseMessage httpResponseMessage = await HttpClient.PostAsync("api/AwsPhotoGallery", stringContent); await httpResponseMessage.ThrowIfResponseHasInvalidStatusCode(); }
public async Task OnInvalidSubmitAsync() { await OnTryCatchAsync(async() => { await PhotoGaleryHttpService.InsertAsync(InsertPhotoGralleryRequest); }); InsertPhotoGralleryRequest = new InsertPhotoGralleryRequest(); await OnAddedCallback.InvokeAsync(); }
public static PhotoGalleryModel ToPhotoGalleryModel( this InsertPhotoGralleryRequest insertPhotoGralleryRequest) { if (insertPhotoGralleryRequest == null) { return(null); } return(new PhotoGalleryModel { Id = Guid.NewGuid().ToString(), Name = insertPhotoGralleryRequest.Name, BucketName = "BucketItemTest", KeyName = "KeyName1" }); }
public async Task InsertAsync(InsertPhotoGralleryRequest insertPhotoGralleryRequest) { await _noSqlDbCloudService.InsertAsync(insertPhotoGralleryRequest.ToPhotoGalleryModel()); }