File Manager action value is always "read" with different actions performed

Hi,

I am currently using File Manager v. 19.1.0.58. What I wanted to do was to detect a successful file upload operation. I was planning on achieving this using FileManagerEvents with the OnSuccess property. Here's the code that is in question.

<SfFileManager TValue="FileManagerDirectoryContent">
   <FileManagerEvents TValue="FileManagerDirectoryContent" OnSuccess="OnSuccess"></FileManagerEvents>
   <FileManagerAjaxSettings Url="/api/FileManager/FileOperations"
                            DownloadUrl="/api/FileManager/Download"
                            UploadUrl="/api/FileManager/Upload">
   </FileManagerAjaxSettings>
</SfFileManager>  

@code {
   public async Task OnSuccess(SuccessEventArgs<FileManagerDirectoryContent> e)
   {
      if (e.Action == "upload")
         await JSRuntime.InvokeVoidAsync("alertSuccessfulUpload", null);
      else if (e.Action == "delete")
         await JSRuntime.InvokeVoidAsync("alertSuccessfulDeletion", null);
   }
}

Upon uploading a file, the e.Action property will return a value of "read" even when the file has just been uploaded. This also happens with a delete event. The Action property will also return a "read" value.

I have noticed that this issue has already happened in the past: OnSuccess event action parameter has wrong value after performing an upload. | Blazor Forums | Syncfusion though this was in previous version. Is there a different way now of detecting a successful upload event?

Please advise on what needs to be done in order for us to detect a successful upload or delete event.

Thanks!

1 Reply

IL Indhumathy Loganathan Syncfusion Team April 30, 2021 03:25 PM UTC

Hi Denzel, 
 
Greetings from Syncfusion support. 
 
We have validated your reported query in FileManager component. We have already considered the upload action issue as a bug and the fix will be included in Volume 1 SP 1 release which is expected to be released by the mid of May 2021.  You can track the status through the below link. 
 
 
Also, we have considered the delete action in OnSuccess event as a bug in our end. Fix for this issue will be included in the last week patch release of May, 2021. Please track the status through the below link. 
 
 
We appreciate your patience. 
 
Regards, 
Indhumathy L 


Loader.
Up arrow icon