andybroomfield → created an issue.
This is fixed in localgov_alert_banner 1.7.6.
Thanks for your contribution adinancenci.
I think this issue might have cropped up again, just trying the config above in fresh webform and experincing this issue.
Thanks Adinancenci for spotting the issue and the patch.
I've opened a PR on Github repo for testing
https://github.com/localgovdrupal/localgov_alert_banner/pull/319
andybroomfield → created an issue.
It looks like the method createDbQuery in modules/search_api_db/src/Plugin/search_api/backend/Database.php is where the locations fields are addded
$this->addLocationConditions($condition_group, $query);
But since this gets called not just when assembling the original query but also when facets are being built in the getFacets method
I've managed to resolve the issue I encountered with the facets by cloning the $query in createDbQuery with the passed in $query, patch attached.
Thanks for the work on this patch.
This is working for when there are multiple locations.
I've discovered there is an issue when adding facets to a search api view with location, where the query looks like its adding the location query multiple times and is preventing the query working with this patch.
I get this error: A database exception occurred while searching.
and then no search results.
I've pushed a rebased branch that removes the .install modifications.
The module still installs on Drupal 10 and tests are passing so this is ready for review again.
Have tested this and selecting add indefinatly does ban the IP address with a date set to 2038 (max unix time stamp).
Hopefully I've got the merge request ok, otherwise I can submit as a standard patch.
andybroomfield → created an issue.
andybroomfield → created an issue.
We've encounterd this issue and applied the patch in comment 9.
Its been working well so far and not had a reoccurance of this issue, though there is a strange side effect that may be related.
After a cache clear, our editors told us they could not access /admin/content anymore. This was due to a PHP error
Symfony\Component\Routing\Exception\RouteNotFoundException: Route "view.block_content.page_1" does not exist. in Drupal\Core\Routing\RouteProvider->getRouteByName() (line 206 of /mnt/www/html/docroot/core/lib/Drupal/Core/Routing/RouteProvider.php).
As this patch removes routes that start with view. if they override an admin listing (entitiy collection), I believe this is now getting removed by this patch. Not sure why this would then not work like the other admin views that override entity collections?
We can work around this issue by disabling the content block view, which we don't use content blocks anyway.
andybroomfield → created an issue.
andybroomfield → created an issue.
Tests are now passing on Drupal CI.
There are still linter and coding standards warnings, though I suggest that is handled in a new issue.
This also builds on current dev work so should now install on Drupal 10.
andybroomfield → created an issue.
I have reviewed this in a fresh install on Drupal 10 (using the composer drupal lenient plugin) and then applied the patch in #11.
I tested assigning VAPN to a basic page and then verifying that only users with the appropriate role could access the selected content.
I'd be happy for this to be merged for Drupal 10.
andybroomfield → created an issue.
We're actually having a little trouble replicating this exactly.
It does seem to happen, but the circumnstaces are weirdly specific. It's when one of the pages was previously published, then set back to draft with the latest revision, but the previous revision is left published. Then trying to use preview link on some (but not all) the child pages results in the error.
I don't actully think Book is at fault here, it must be something to do with the way the preview link is interacting with workflow and content revisions, but will need more investigation. The patch fixes the error in that the navigation block can then display, though thats probably not the real problem.
andybroomfield → created an issue.
I have tested this and it workd for me on a couple of the few Drupal 7 sites I still support.
Have added patch / MR.
Noticed another issue whist fixing (might be a PHP 8.1 issue) that passing the result of $this->getPublishStatusLink directly into Drupal renderer was throwing a 'Only variables should be passed by reference' when I fixed the operations link.