The seven faceted browse facet types now implement FacetedBrowse's getShowAllValues() contract, added in omeka-s-modules/FacetedBrowse#59. The older path is kept alongside it so that installs running a FacetedBrowse from before that change keep working: their data forms pass a url, and the table is fetched from this module's own controller instead of FacetedBrowse's endpoint. On a current FacetedBrowse none of it runs.
That path is 205 lines, 156 of them code, in eight places:
src/Controller/SiteAdmin/FacetedBrowse/IndexController.php
src/Service/Controller/SiteAdmin/FacetedBrowse/IndexControllerFactory.php
- the
router block in config/module.config.php
- the
controllers entry in config/module.config.php
- the two
Cannot add all strings in js_translate_strings, which only this path can reach
url in the seven facet data forms
- the flat
property_id query parameter beside it in those forms, which only this controller reads. The nested facet_data[property_id] serves the new endpoint and stays.
numericAddAll() and the #add-all switch in asset/js/faceted-browse/category-form.js
These have to come out together. Removing url on its own is the dangerous one: the released show-all.phtml renders data-url unguarded, so an absent url produces data-url="" and the resulting $.get('') injects the whole admin page into the sidebar.
There is no declarative way to require a FacetedBrowse version, since module.ini constrains only the Omeka version and Omeka has no inter-module dependency mechanism. So this is a judgement about how widespread the newer FacetedBrowse has become, stated in the release notes, or a runtime check through Omeka\Module\Manager if a hard gate is wanted.
Implemented in feature/show-all-contract.
The seven faceted browse facet types now implement FacetedBrowse's
getShowAllValues()contract, added in omeka-s-modules/FacetedBrowse#59. The older path is kept alongside it so that installs running a FacetedBrowse from before that change keep working: their data forms pass aurl, and the table is fetched from this module's own controller instead of FacetedBrowse's endpoint. On a current FacetedBrowse none of it runs.That path is 205 lines, 156 of them code, in eight places:
src/Controller/SiteAdmin/FacetedBrowse/IndexController.phpsrc/Service/Controller/SiteAdmin/FacetedBrowse/IndexControllerFactory.phprouterblock inconfig/module.config.phpcontrollersentry inconfig/module.config.phpCannot add allstrings injs_translate_strings, which only this path can reachurlin the seven facet data formsproperty_idquery parameter beside it in those forms, which only this controller reads. The nestedfacet_data[property_id]serves the new endpoint and stays.numericAddAll()and the#add-allswitch inasset/js/faceted-browse/category-form.jsThese have to come out together. Removing
urlon its own is the dangerous one: the releasedshow-all.phtmlrendersdata-urlunguarded, so an absenturlproducesdata-url=""and the resulting$.get('')injects the whole admin page into the sidebar.There is no declarative way to require a FacetedBrowse version, since
module.iniconstrains only the Omeka version and Omeka has no inter-module dependency mechanism. So this is a judgement about how widespread the newer FacetedBrowse has become, stated in the release notes, or a runtime check throughOmeka\Module\Managerif a hard gate is wanted.Implemented in
feature/show-all-contract.