dropload上拉加载更多

<link href="~/Scripts/dropload/dropload.min.css" rel="stylesheet" />
<script src="~/Scripts/dropload/dropload.min.js"></script>

  <div id="lists">
</div>

 

var pageindex = 2;
            $("#lists").dropload({
                scrollArea: window,
                loadDownFn: function (me) {
                    $.ajax({
                        type: 'GET',
                        url: purl+'Favorite/Index?pageIndex=' + pageindex,
                        success: function (data) {
                            $("#lists").append(data)
                            mytouch($('.paylist' + pageindex + ' .pay-each'));
                            pageindex++;
                            me.resetload();
          
                        },
                        error: function (xhr, type) {
                            alert('无网络连接');
                            me.resetload();
                        }
                    });
                }

            });

 

posted @ 2017-07-28 10:52  过一天日子修一天缘  阅读(1219)  评论(0编辑  收藏  举报