Code Monkey home page Code Monkey logo

Comments (2)

798love avatar 798love commented on August 22, 2024

把下面的代码加入 journals.ftl 文件37行

<div class="bg-white p-4 hover:shadow-lg duration-300 mb-12">
        <nav aria-label="Page navigation">
            <ul class="flex justify-between list-style-none space-x-3">
                <@paginationTag method="${journals}" page="${journals.number?c}" total="${journals.totalPages}" display="3" slug="${slug!}" keyword="${keyword!}">
                    <li class="page-item">
                        <#if pagination.hasPrev>
                            <a class="page-link relative block py-1.5 px-3 rounded border-0 bg-transparent outline-none transition-all duration-300 rounded text-gray-800 hover:text-gray-800 hover:bg-gray-200 focus:shadow-none"
                               href="${pagination.prevPageFullPath!}"  style="color: rgb(31 41 55/var(--tw-text-opacity));">上一页</a>
                        </#if>
                    </li>
                    <li>
                                    <span class="page-link relative block py-1.5 px-3 rounded border-0 outline-none transition-all duration-300 rounded text-gray-800 text-gray-800 bg-gray-200 shadow-none">
                                        ${journals.number + 1} / ${journals.totalPages}
                                    </span>
                    </li>

                    <li class="page-item">
                        <#if pagination.hasNext>
                            <a class="page-link relative block py-1.5 px-3 rounded border-0 bg-transparent outline-none transition-all duration-300 rounded text-gray-800 hover:text-gray-800 hover:bg-gray-200 focus:shadow-none"
                               href="${pagination.nextPageFullPath!}" style="color: rgb(31 41 55/var(--tw-text-opacity));">下一页</a>
                        </#if>
                    </li>
                </@paginationTag>
            </ul>
        </nav>
    </div>

from halo-theme-daisy.

Yaklo avatar Yaklo commented on August 22, 2024

把下面的代码加入 journals.ftl 文件37行

<div class="bg-white p-4 hover:shadow-lg duration-300 mb-12">
        <nav aria-label="Page navigation">
            <ul class="flex justify-between list-style-none space-x-3">
                <@paginationTag method="${journals}" page="${journals.number?c}" total="${journals.totalPages}" display="3" slug="${slug!}" keyword="${keyword!}">
                    <li class="page-item">
                        <#if pagination.hasPrev>
                            <a class="page-link relative block py-1.5 px-3 rounded border-0 bg-transparent outline-none transition-all duration-300 rounded text-gray-800 hover:text-gray-800 hover:bg-gray-200 focus:shadow-none"
                               href="${pagination.prevPageFullPath!}"  style="color: rgb(31 41 55/var(--tw-text-opacity));">上一页</a>
                        </#if>
                    </li>
                    <li>
                                    <span class="page-link relative block py-1.5 px-3 rounded border-0 outline-none transition-all duration-300 rounded text-gray-800 text-gray-800 bg-gray-200 shadow-none">
                                        ${journals.number + 1} / ${journals.totalPages}
                                    </span>
                    </li>

                    <li class="page-item">
                        <#if pagination.hasNext>
                            <a class="page-link relative block py-1.5 px-3 rounded border-0 bg-transparent outline-none transition-all duration-300 rounded text-gray-800 hover:text-gray-800 hover:bg-gray-200 focus:shadow-none"
                               href="${pagination.nextPageFullPath!}" style="color: rgb(31 41 55/var(--tw-text-opacity));">下一页</a>
                        </#if>
                    </li>
                </@paginationTag>
            </ul>
        </nav>
    </div>

有页码也有按钮了,但是点击下一页没反应

from halo-theme-daisy.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.