private function _postList()
{
$map['weiba_id'] = array('in', getSubByKey(D('weiba')->where('is_del=0 and status=1')->field('weiba_id')->findAll(), 'weiba_id'));
$map['top'] = array('neq', 2);
$map['is_del'] = 0;
$postList = D('weiba_post')->where($map)->order('post_time desc')->findpage(20);
if ($postList['nowPage'] == 1) {
//列表第一页加上全局置顶的帖子
$map['top'] = 2;
$topPostList = D('weiba_post')->where($map)->order('post_time desc')->findAll();
!$topPostList && ($topPostList = array());
!$postList['data'] && ($postList['data'] = array());
$postList['data'] = array_merge($topPostList, $postList['data']);
}
$weiba_ids = getSubByKey($postList['data'], 'weiba_id');
$nameArr = $this->_getWeibaName($weiba_ids);
foreach ($postList['data'] as $k => $v) {
$postList['data'][$k]['weiba'] = $nameArr[$v['weiba_id']];
/* # 解析emoji */
$postList['data'][$k]['title'] = formatEmoji(false, $v['title']);
$postList['data'][$k]['content'] = formatEmoji(false, $v['content']);
}
//dump($postList);exit;
$post_uids = getSubByKey($postList['data'], 'post_uid');
$reply_uids = getSubByKey($postList['data'], 'last_reply_uid');
$uids = array_unique(array_merge($post_uids, $reply_uids));
$this->_assignUserInfo($uids);
//微吧排行榜
$this->_weibaOrder();
$this->assign('postList', $postList);
}