...
- change the "
c:
OnAfterRebuildThemes
" event to unserialize values of "$files
" array (all at once) before using them later - 0.3h - create the "
CategoriesEventHandler::sortByDependencies(array $files)
" method, that will: - 0.5h- accept $files associative array, that is built in "
c:OnAfterRebuildThemes
" event, where:- key is relative path to a template in theme
- value is array, that was parsed from template meta comment
- for each array entry (the template file) build a sorting key like this:
- take array from "section" key of template info (if missing use empty array)
- append value of "name" key to that array (if missing use
'_Auto: ' . $template
) - combine using a separator (e.g. "||")
- sort array using sort key built above (will ensure, that parent templates will be listed prior to child templates)
- return sorted "$files" array
- accept $files associative array, that is built in "
- in the "
c:
OnAfterRebuildThemes
" event call the "CategoriesEventHandler::sortByDependencies
" method on the "$files
" array prior to creating categories from it - 0.2h
Quote: 1h*1.4=1.5h
Related Tasks