/** * @desc 关于某人的 右侧说说动态 */ public function ajaxSmallTalk() { $id = I('get.id'); $sql = D('SmallTalk'); $count = $sql->where('user_id=' . $id . ' and in_trash = 0 ')->cache(true)->count(); $page = new \Think\Page($count, 8); $show = $page->ajaxShow(); $smallList = $sql->where('user_id=' . $id . ' and in_trash = 0 ')->order('pubtime desc ')->limit($page->firstRow . ',' . $page->listRows)->cache(true)->select(); $this->assign('smallTalk', $smallList); $this->assign('smallShow', $show); $this->display('Personal/ajaxSmallTalk'); }