Open Closed

MAUI Mobile app LoadMore items button not visible #6472


User avatar
0
rferrarin created

Check the docs before asking a question: https://docs.abp.io/en/commercial/latest/ Check the samples to see the basic tasks: https://docs.abp.io/en/commercial/latest/samples/index The exact solution to your question may have been answered before, and please first use the search on the homepage. Provide us with the following info:

  • ABP Framework version: v8.0.1
  • UI Type: MAUI Mobile
  • Database System: EF Core (SQL Server)
  • Exception message and full stack trace:
  • Steps to reproduce the issue: create a mobile maui app using abp suite, add 10+ new users to the app, view the users via mobile app...you cannot load more than 10 items because the LoadMore button is not visible

this is from site...users are correctly visible/paged

this is from the mobile maui app...the LoadMore button is not visibile/present

From the generated code in file IdentityUserPageViewModel.cs this is the check CanLoadMore = result.Items.Count >= Input.MaxResultCount;

which I think should be (in GetUsersAsync()) CanLoadMore = result.TotalCount >= Input.MaxResultCount;

and (in LoadMore()) CanLoadMore = result.TotalCount >= Input.SkipCount + Input.MaxResultCount;

Besides the effectiveness of the above check, even if CanLoadMore is true, button is still not visible

thanx


1 Answer(s)
  • User Avatar
    0
    enisn created
    Support Team .NET Developer

    Hi, the Load More Button is only for desktop UIs, on mobile devices, it automatically loads when scrolled to the last item.

    According to my investigations, there are some missing attributes in IdentityUserPage.xaml file for CollectionView.

    RemainingItemsThreshold and RemainingItemsThresholdReachedCommand are missing. They exist in TenantsPage.xaml but missing in IdentityUserPage, can you add them and try again?

     <CollectionView
         ItemsSource="{Binding Items}"
         SelectionMode="None"
         RemainingItemsThreshold="2"
         RemainingItemsThresholdReachedCommand="{Binding LoadMoreCommand}">
    

    We'll update the templates as soon as possible. Thanks for your feedback.

    Your credit is also refunded.

Made with ❤️ on ABP v9.1.0-preview. Updated on December 26, 2024, 06:07