<?php
/**
 * 列出所有成员（供技术部使用）
 * @return void
 */
class ListUsersAction extends BaseAction
{
	public function run()
	{
        $criteria=new CDbCriteria;
        $criteria->select = array('id','username');
		$pages = new CPagination(Manager::model()->count($criteria));
		$pages->pageSize = 10;
		$pages->applyLimit($criteria);

        $users=Manager::model()->findAll($criteria);
		$this->getController()->render('listallusers', array(
            'users' => $users,
            'title' => '用户列表',
            'pages' => $pages,
        ));
	}
}