Change Group dynamically
Hello Team, i have a problem. I want to change the parameter GroupBy on a ListView, the thing is i want to change it dynamically when i click on a button, but it doesn't work.
When the component is initialized i set the parameter to one of the properties of the class, and it works, the listview is grouped. But when i click the button and i change the value of the parameter to another property, it does nothing, there is no visual change.
This is my code, i know that some parts are missing and got some hard-coded, but its just to make the group to work:
<SfListView @ref="listView" TValue="Email" DataSource="@emails">
<ListViewFieldSettings Id="email_id" Text="asunto" GroupBy="@agrupacion"></ListViewFieldSettings></SfListView>
<SfButton OnClick="Change">Change Group</SfButton>
public class Email
{
public int email_id { get; set; }
public string de { get; set; }
public string para { get; set; }
public string asunto { get; set; }
public string cuerpo { get; set; }
public DateTime fecha_recepcion { get; set; }}public string agrupacion { get; set; }private List<Email> emails { get; set; }private SfListView<Email> listView { get; set; }
private void
Change()
{
agrupacion = "fecha_recepcion";
}protected override async Task OnInitializedAsync()
{
agrupacion
= "para";
}Thank you for your time and i hope you can help me.
SIGN IN To post a reply.
2 Replies
1 reply marked as answer
SM
Shalini Maragathavel
Syncfusion Team
August 24, 2021 01:44 PM UTC
Hi Jose,
Greetings from Syncfusion support.
We have validated your reported issue with ListView component and considered the reported scenario “ListView items are not grouped while dynamically updating the GroupBy field” as a bug from our end. The fix for this issue will be included in the mid-week patch release of September, 2021.
You can track the status of your reported problem through the below portal link.
Until then, we appreciate your patience.
Regards,
Shalini M.
SM
Shalini Maragathavel
Syncfusion Team
October 1, 2021 01:01 PM UTC
Hi Jose,
We are glad to announce that our Essential Studio 2021 Volume 3 release v19.3.0.43 is rolled out and is available for download under the following link.
The issue with the “ListView items are not grouped while dynamically updating the GroupBy field” has been resolved in this release. Please upgrade your package to latest version (v19.3.0.43) to resolve the issue.
Please find the below sample for your reference.
Sample: https://www.syncfusion.com/downloads/support/directtrac/general/ze/BlazorApp12-869460226.zip
We thank you for your support and appreciate your patience in waiting for this release. Please get in touch with us if you would require any further assistance.
Regards,
Shalini M.
Marked as answer
SIGN IN To post a reply.
- 2 Replies
- 2 Participants
- Marked answer
-
JP José paula
- Aug 23, 2021 12:13 PM UTC
- Oct 1, 2021 01:01 PM UTC