Users Awaiting Approval, chronological order?

jonsidneyb

Well-known member
Is there a way to get Users Awaiting Approval in, chronological order rather than alphabetical order?
 
library/XenForo/ControllerAdmin/User.php

Add the red code:

Rich (BB code):
	/**
	 * Shows a list of moderated users and allows them to be managed.
	 *
	 * @return XenForo_ControllerResponse_Abstract
	 */
	public function actionModerated()
	{
		$users = $this->_getUserModel()->getUsers(array(
			'user_state' => 'moderated'
		), array('order' => 'register_date', 'direction' => 'ASC'));
		if (!$users)
		{
			return $this->responseMessage(new XenForo_Phrase('no_users_awaiting_approval'));
		}

		$viewParams = array(
			'users' => $users
		);

		return $this->responseView('XenForo_ViewAdmin_User_Moderated', 'user_moderated', $viewParams);
	}

That should do it.
 
library/XenForo/ControllerAdmin/User.php

Add the red code:

Rich (BB code):
/**
* Shows a list of moderated users and allows them to be managed.
*
* @return XenForo_ControllerResponse_Abstract
*/
public function actionModerated()
{
$users = $this->_getUserModel()->getUsers(array(
'user_state' => 'moderated'
), array('order' => 'register_date', 'direction' => 'ASC'));
if (!$users)
{
return $this->responseMessage(new XenForo_Phrase('no_users_awaiting_approval'));
}
 
$viewParams = array(
'users' => $users
);
 
return $this->responseView('XenForo_ViewAdmin_User_Moderated', 'user_moderated', $viewParams);
}

That should do it.

Thanks
 
Back
Top Bottom