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

Move default row count and pagination to the top of the table #334

Closed
live-act opened this issue Oct 18, 2023 · 8 comments
Closed

Move default row count and pagination to the top of the table #334

live-act opened this issue Oct 18, 2023 · 8 comments
Labels
enhancement New feature or request

Comments

@live-act
Copy link

Is your feature request related to a problem? Please describe.
Move the default row count and pagiantion to the the top of the table - similar to other more modern approach as shown in the flask-appbuilder example below

image

Describe the solution you'd like
For large tables (100K+ ), it makes more sense for users have a sense of how many records that they see and then apply filter to check what records need to be kept in viewing. The user experience is pretty bad when the row count and page number are down in the botton.

Describe alternatives you've considered
I have been using flask-appbuilder for building admin panels but I would like to try using starlette-admin in a new project.

@live-act live-act added the enhancement New feature or request label Oct 18, 2023
@hasansezertasan
Copy link
Contributor

hasansezertasan commented Oct 18, 2023

A better approach would be adding an option to pick a location for the bar when defining an instance of Admin. Maybe in the future it would be configurable by the users, like dark/light theme which is like a good to have for a web page.

Edit: All that for nothing! I was playing with Starlette Admin Configuration, I found out a super cool stuff...

308 resolves your issue but you have to wait for 0.12.0.

Let me help you a bit more: How to display pagination on the top — DataTables forums

Datatables are awesome. I'm planning to create a pydantic model to validate datatables_options attribute. How is that sounds like @jowilf, do you think we need that?

@live-act
Copy link
Author

Thank you @hasansezertasan ..! I will wait for 0.12.0 then. Appreciate your help.

@hasansezertasan
Copy link
Contributor

You're welcome, can you close this issue?

@live-act
Copy link
Author

Yes, of course. Thank you

@jowilf
Copy link
Owner

jowilf commented Oct 19, 2023

Thank you for your help @hasansezertasan.

I'm planning to create a pydantic model to validate datatables_options attribute. How is that sounds like @jowilf, do you think we need that?

I think it's necessary, we can't make pydantic a required dependency just to validate the datatables_options

@hasansezertasan
Copy link
Contributor

Thank you for your help @hasansezertasan.

I'm planning to create a pydantic model to validate datatables_options attribute. How is that sounds like @jowilf, do you think we need that?

I think it's necessary, we can't make pydantic a required dependency just to validate the datatables_options

Oh, I'm confused. Should we have a validator for datatables_options or not?

@jowilf
Copy link
Owner

jowilf commented Oct 29, 2023

Oh, I'm confused. Should we have a validator for datatables_options or not?

Sorry i was saying it's not necessary

@hasansezertasan
Copy link
Contributor

Thank you for your response.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants