Cnode是用mongodb的吗?他是怎么分页的我没看见它传什么参数上去的哦
回复 (9)
P
引用 hexie提供一个线索 views/index.html <% partial('topic/list', { topics: topics, pages: pages, current pages: ...
那个current_pages 是什么值啊 是不是前一个页面的值
H
P
引用 hexie提供一个线索 views/index.html <% partial('topic/list', { topics: topics, pages: pages, current pages: ...
@hexie offset 这个我没见到这接口哦 是什么mongodb 模块啊
H
H
提供一个线索
views/index.html
<%- partial('topic/list', {
topics: topics,
pages: pages,
current_pages: current_page,
base: keyword ? ('/?q=' + keyword) : '/'
}) %>
通过pages 和 current_pages ,计算出 分页,和数据库索引
P
引用 hexie提供一个线索 views/index.html <% partial('topic/list', { topics: topics, pages: pages, current pages: ...
就是 他只是post传递了一个page 啊 没其他参数啊
P
H
引用 hexie提供一个线索 views/index.html <% partial('topic/list', { topics: topics, pages: pages, current pages: ...
@prophet 不用啊,只需要统计出总数,和当前页的偏移量 offset 就可以了
P
引用 hexie提供一个线索 views/index.html <% partial('topic/list', { topics: topics, pages: pages, current pages: ...
@hexie 不能用,不能skip 太多,我用page_num实现了 ,或说你有 NAE邀请码吗 给我一个我做好了 很厉害的哦
参与回复
登录后即可参与回复。登录