Skip to content

Commit

Permalink
Keep fileTree sorting order when changing selection (see contao#2267)
Browse files Browse the repository at this point in the history
Description
-----------

| Q                | A
| -----------------| ---
| Fixed issues     | Fixes contao#2266

Commits
-------

b63977f Keep fileTree sorting order when changing selection
  • Loading branch information
ausi authored and Alexej Kossmann committed Apr 6, 2021
1 parent 374ee45 commit c3e6a22
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions core-bundle/src/Resources/contao/classes/Ajax.php
Original file line number Diff line number Diff line change
Expand Up @@ -376,6 +376,9 @@ public function executePostActions(DataContainer $dc)
}
}

// Keep the previous sorting order when reloading the widget
$varValue = ArrayUtil::sortByOrderField($varValue, $dc->activeRecord->$strField);

$varValue = serialize($varValue);
}

Expand Down

0 comments on commit c3e6a22

Please sign in to comment.