pallets-eco / pallets-eco/flask-admin

File Admin pagination?

Open
#2,154 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement files
Dominant language
Python
Stars
6.1k
Forks
1.6k
Avg merge
6d 14h
Merged PRs (30d)
1

Description

Aside from difficulties in implementing a custom FileAdmin (documentation is a bit lacking), one thought I had while reviewing the code of both existing FileAdmin modules was "Why can't I find any sort of pagination?". If I were to have thousands of hosted images, given the current structure of FileAdmin all images would be requested from the api in one go and rendered with pagination on the front-end. This seems terribly inefficient (and costly in terms of API rate-limits).

Is it possible to implement proper ajax pagination to FileAdmin? I saw in the original pull request #1154 that implemented the s3 FileAdmin there was a comment about implementing pagination (link), but it never seemed to make it into the FileAdmin.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by comparing the two existing FileAdmin modules and reviewing the pagination discussion in pull request #1154. Trace how hosted images are currently fetched from the API and rendered on the front end; the work is done when FileAdmin requests and displays pages through AJAX instead of fetching all images at once.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
api, full-stack
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.