Is there a possibility to override the direction parameter? I needed to have two different buttons for ASC and DESC so the toggle did not work for me. I could not find the workaround, so I suggest the following edit to the code to support this by using the queryParameters['direction']:
Edits
determineDirection() function
Added third $queryParameters parameter
Added override condition which uses the direction from query parameters if $queryParameters['direction'] exists :
Is there a possibility to override the direction parameter? I needed to have two different buttons for
ASC
andDESC
so the toggle did not work for me. I could not find the workaround, so I suggest the following edit to the code to support this by using thequeryParameters['direction']
:Edits
determineDirection() function
$queryParameters
parameterAdded override condition which uses the direction from query parameters if
$queryParameters['direction']
exists :render() function
Calling
self::determineDirection()
function with third$queryParameters
parameter.Usage
View
Added pull request: https://github.com/Kyslik/column-sortable/pull/188