Пример #1
0
 async Task Upload(String url)
 {
     if (Request.HttpMethod != "POST")
     {
         throw new RequestModelException("Invalid HttpMethod for upload");
     }
     if (IsNotAjax())
     {
         return;
     }
     Response.ContentType = "application/json";
     try
     {
         var files = Request.Files;
         await _baseController.SaveUploads(url, files, SetSqlQueryParams, Response.Output);
     }
     catch (Exception ex)
     {
         WriteExceptionStatus(ex);
     }
 }