js layui 分页脚本
//分页
layui.use(['laypage'], function(){
var laypage = layui.laypage;
laypage.render({
elem: 'page'
,count:<?=$page_count?>
,curr:<?=$page?>
,limit:20
,jump: function(obj,first){
//首次不执行
if(!first){
var o = GetRequest();
o.page = obj.curr;
o.url = '/goods/lists';
window.location.href = createUrl(o);
}
}
});
});