• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

"Oldest First" Report comments

Nudaii

Well-known member
#1
Howdy is there a way to make the report comments show chronologically (Oldest First)?

As the staff at the forums i tech admin may find it alittle confusing with newest first
 

Jake Bunce

XenForo moderator
Staff member
#2
library/XenForo/Model/Report.php

Change the DESC to ASC. That should do it:

Code:
	public function getActiveReports()
	{
		return $this->fetchAllKeyed('
			SELECT report.*,
				user.*,
				assigned.username AS assigned_username
			FROM xf_report AS report
			LEFT JOIN xf_user AS assigned ON (assigned.user_id = report.assigned_user_id)
			LEFT JOIN xf_user AS user ON (user.user_id = report.content_user_id)
			WHERE report.report_state IN (\'open\', \'assigned\')
			ORDER BY report.last_modified_date DESC
		', 'report_id');
	}
For a more permanent solution you can create an addon that extends XenForo_Model_Report::getActiveReports.