FileManager in Grid freezes application on Edit - v18.04.30

Hi all,

I have a FileManager in a Grid <EditTemplate> that appears to freeze the app when "Edit" is selected in the Grid (NB: I am using a Dialog for the Edit).

This was working fine until I upgraded to v18.04.30.

I have added a TValue, but I am not sure it's correct? I am also using Authentication via IdentityServer4 in a Blazor Webassembly app.

My Razor page is in the attached file.

Thanks in advance for your reply.

Simon



Attachment: LanguageDataGrid_c567b5bf.7z

4 Replies 1 reply marked as answer

SP Sowmiya Padmanaban Syncfusion Team December 21, 2020 09:53 AM UTC

Hi Simon,  
 
Greetings from Syncfusion support. 
 
We have checked your reported problem with FileManager component. We found out that your reported problem occurs due to TValue is not properly mapped in FileManager component initialization code. 
 
Note: Please note that we have introduced several API breaking changes in Blazor FileManager component from Volume 4 release (v18.4.30). We would like you to review the breaking changes from the following location before you upgrade. 
 
 
Please, refer the solution code sample to resolve your reported problem. 
 
<SfFileManager TValue="FileManagerDirectoryContent"> 
                    <FileManagerNavigationPaneSettings Visible="false"></FileManagerNavigationPaneSettings> 
                    <FileManagerContextMenuSettings Visible="false"></FileManagerContextMenuSettings> 
                    <FileManagerToolbarSettings Visible="false"></FileManagerToolbarSettings> 
                    <FileManagerAjaxSettings Url="https://ej2-aspcore-service.azurewebsites.net/api/FileManager/FileOperations" 
                                             UploadUrl="https://ej2-aspcore-service.azurewebsites.net/api/FileManager/Upload" 
                                             DownloadUrl="https://ej2-aspcore-service.azurewebsites.net/api/FileManager/Download" 
                                             GetImageUrl="https://ej2-aspcore-service.azurewebsites.net/api/FileManager/GetImage"> 
                    </FileManagerAjaxSettings> 
                </SfFileManager> 
 
 
Please, refer the sample link with the above solution. 
 
 
Please let us know, if you need any further assistance. 
 
Regards,  
Sowmiya.P 



SI Simon December 21, 2020 10:49 PM UTC

Hi Sowmiya,

Thanks for the reply.

The only bit not now working is the auto-selection of previously selected values. This was working fine in the previous version??

If the folder files are all ".png" files, what should I populate in the 'SelectedItems="@selectedIcons"' line? I have tried with, for example, 'arabic.png' and with the full path, but the value is NOT showing as selected.

BTW, I did check the Release Notes, and noted that it now requires a TValue. However, it didn't specify what the TValue should be, just showed "FileManagerDirectoryContent" in the NOW section, without really explaining what it should be (pretty much all of the others I've used relate to some form of data. i.e. lists etc.).

In future, it might be useful to actually specify what should go in the TValue when a change like this occurs?

Thanks again for your help.

Regards

Simon


SP Sowmiya Padmanaban Syncfusion Team December 22, 2020 12:47 PM UTC

Hi Simon,  
 
Thanks for your valuable feedback. 
 
TValue in FileManager component: 
 
We will consider to include the details about TValue for FileManager component in our Documentation soon. 
 
By default, we have used TValue for most of our Blazor component. TValue denotes the model class used to bind data to the component. 
 
Similarly, we have process data for FileManager based on FileManagerDirectoryContent model class properties and also we have handled the ajax request based on this class. 
 
Query2- SelectedItems is not working. 
 
We have checked your reported problem. We have consider this as a bug from our end. We will include the fix for this bug in our next patch release which is expected to rolled out by the end of December 2020.  
  
You can track the status of this issue fix through the following feedback portal link.  
 
 
Until then, we suggest you to use OnSuccess event for selecting the files/folder in FileManager component. 
 
Please, refer the below code snippet. 
 
@using Syncfusion.Blazor.FileManager 
 
<SfFileManager TValue="FileManagerDirectoryContent"  @bind-SelectedItems="@selectedItems"> 
    <FileManagerEvents TValue="FileManagerDirectoryContent" OnSuccess="success"></FileManagerEvents> 
    </FileManagerAjaxSettings> 
</SfFileManager> 
 
@code { 
   public string[] selectedItems { get; set; }  
    public async Task success(Syncfusion.Blazor.FileManager.SuccessEventArgs<FileManagerDirectoryContent> args) 
    { 
        await Task.Delay(100); 
        selectedItems = new string[] { "Documents" }; 
    }  
} 
 
 
Please, refer the sample link below. 
 
 
Please let us know, if you need any further assistance. 
 
Regards,  
Sowmiya.P 



IL Indhumathy Loganathan Syncfusion Team December 30, 2020 10:51 AM UTC

Hi Simon  
 
Thanks for your patience. 
 
We are glad to announce that our patch release (V18.4.32) is rolled out successfully. The issue with “SelectedItems not maintained properly in FileManager component at initial loading” has been resolved in this release. To access this fix, we suggest you to update the Syncfusion packages to its latest version 18.4.32. 
 
Please, refer the below sample link. 
 
 
Please let us know, if you need any further assistance. 
 
Regards, 
Indhumathy L 


Marked as answer
Loader.
Up arrow icon