Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🐛 Bug Report: Collections sub-navigation only shows 25 #1359

Open
2 tasks done
Ricolo53 opened this issue Sep 20, 2024 · 2 comments
Open
2 tasks done

🐛 Bug Report: Collections sub-navigation only shows 25 #1359

Ricolo53 opened this issue Sep 20, 2024 · 2 comments
Labels
bug Something isn't working product / databases Fixes and upgrades for the Appwrite Databases

Comments

@Ricolo53
Copy link

👟 Reproduction steps

By default, 25 documents are returned, which is fine, but the panel on the left only displays 25 collections, so you have to go back to the listing page, search for the collection you want to go to, and click on it. Or have a pagnination in this panel?

This code call this function without limit queries

👍 Expected behavior

Since the left-hand panel is sorted alphabetically, I think it would be interesting to have all the collections here.

👎 Actual Behavior

Only 25, sorted in descending order of creation

🎲 Appwrite version

Appwrite Cloud

💻 Operating system

Linux

🧱 Your Environment

No response

👀 Have you spent some time to check if this issue has been raised before?

  • I checked and didn't find similar issue

🏢 Have you read the Code of Conduct?

@Ricolo53 Ricolo53 added the bug Something isn't working label Sep 20, 2024
@stnguyen90 stnguyen90 added the product / databases Fixes and upgrades for the Appwrite Databases label Sep 23, 2024
@stnguyen90
Copy link
Contributor

@Ricolo53 thanks for creating this issue! 🙏🏼

You're definitely on the right track. The sub navigation only returns 25 because that's the default limit. The related code that fetches the collections for the sub-navigation, however, is here:

sdk.forProject.databases.listCollections(params.database, [Query.orderDesc('')])

I'll make sure the team knows about this.

@stnguyen90 stnguyen90 changed the title 🐛 Bug Report: left panel list all collections - show all 🐛 Bug Report: Collections sub-navigation only shows 25 Sep 23, 2024
@pushkar707
Copy link

This issue seems to be fixed with a new limit of 100 collections:
console/src/routes/(console)/project-[project]/databases/database-[database]/collection-[collection]/+layout.ts

Line 17: Query.limit(100)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working product / databases Fixes and upgrades for the Appwrite Databases
Projects
None yet
Development

No branches or pull requests

3 participants