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

did't show pagination.links #110

Open
extym opened this issue Mar 22, 2024 · 1 comment
Open

did't show pagination.links #110

extym opened this issue Mar 22, 2024 · 1 comment

Comments

@extym
Copy link

extym commented Mar 22, 2024

Code:
total = cursor.rowcount
pagination = Pagination(page=page, total=total, search=True,
per_page=limit, css_framework='bootstrap3')

html:

{% for row in rows %}

{{ row[1] }}

                                        <td>{{ row[3] }}</td>
                                        <td>{{ row[2] }}</td>
                                        <td>{{ row[4] }}</td>
                                        <td>{{ row[6] }}</td>
                                        <td>{{ row[7] }}</td>
                                        <td>{{ row[8] }}</td>
                                        <td>{{ row[9] }}</td>
                                        <td>{{ row[21] }}</td>
                                        <td>{{ row[20] }}</td>
                                    </tr>
                                    {% endfor %}
                                    </tbody>
                                    <tr>
                                        {{ pagination.info }}
                                        {{ pagination.links }}
                                    </tr>
                                </table>
                                {{ pagination.info }}{{ pagination.links }}
                            </div>

but we see pagination.info only, and the total is 0, but cursor.rowcount == 9

Screenshot from 2024-03-22 08-43-29

flask-paginate last version

@lixxu
Copy link
Owner

lixxu commented Mar 27, 2024

you need pass found=found for search pagination, and pagination link is empty if only one page

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

No branches or pull requests

2 participants