Jump to content

Back-office records sorting in ascending or descending order on fields


Recommended Posts


I can sort records in the back office in ascending or descending on record ID using the below code. ($_defaultOrderWay = 'DESC';)

I have different columns and I want to know how to sort in other fields.

Attached screenshot for reference.

class AdminSfkseoschemaControllerCore extends AdminController {

	protected $_defaultOrderWay = 'DESC';
    public function __construct() {
        $this->bootstrap = true;
        $this->table = 'sfkseoschema';



Edited by Zohaib-fk (see edit history)
Link to comment
Share on other sites

  • 2 weeks later...


Thanks for your message.

Do you know which function is used in the admin controller to perform search operations on fields. I want to write the same in my admin controller like other functions.

Like other functions "initToolbar","renderForm","postProcess" etc

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...