请稍等 ...
×

采纳答案成功!

向帮助你的同学说点啥吧!感谢那些助人为乐的人

TypeError: Cannot set property 'pageNum' of undefined

$(document).on('click','.pg-item',function () {
        console.log('1');
       var $this = $(this);
        if($this.hasClass('active') || $this.hasClass('disabled')){
            return;
        }
        typeof _this.option.onSelectPage === 'function'
            ? _this.option.onSelectPage($this.data('value')) : null;
          console.log('1'); 
    });


//加载分页信息
    loadPageination :function (pageInfo) {
      !this.pageination && (this.pageination = new pageination());
        this.pageination.render($.extend({}, pageInfo, {
            container : $('.pagination'),
            onSelectPage :function (pageNum) {
                _this.listParam.pageNum = pageNum;
                _this.loadList();
            }
        }));
    }https://img1.sycdn.imooc.com/szimg/59e340840001c7a808190460.jpg

正在回答 回答被采纳积分+3

3回答

mikyyz 2017-10-24 16:28:05

_this.data.listParam.pageNum = pageNum;

0 回复 有任何疑惑可以回复我~
_张敏258zm_ 2017-10-23 16:49:17

var _this = this;

0 回复 有任何疑惑可以回复我~
Rosen 2017-10-15 21:23:03

_this.listParam.pageNum = pageNum; 在这句断点,看_this.listParam是什么东西就知道了

0 回复 有任何疑惑可以回复我~
问题已解决,确定采纳
还有疑问,暂不采纳
微信客服

购课补贴
联系客服咨询优惠详情

帮助反馈 APP下载

慕课网APP
您的移动学习伙伴

公众号

扫描二维码
关注慕课网微信公众号