-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Deleted service status updates only disappear from landing page after a cache rebuild #229
Comments
I've not looked at the logic of this very much, but am I correct that what you mean by the 'landing page' not being updated is the block on the 'service landingpage'? If so looking at it localgov_services/modules/localgov_services_status/src/Plugin/Block/ServiceStatusMessage.php Line 95 in 00a9ac7
Or if we don't mind all of the status blocks getting invalidated when new status' are posted node_list:localgov_service_status cache tag might even make that presave unnecessary? |
So |
I've been testing the linked PR, and I can't recreate the original issue. (Although I have found a sort of related one...) With either the 2.1.5 release, or the code in the PR, the behaviour is the same for me:
So for me, removing the status works with or without the code in the PR. Adding a new status does not. |
@dedavidson Just to check, is your issue with the block, or the deprecated updates panel? See #129 for a screenshot of the panel. |
@rupertj it was the panel. |
@rupertj This error can be reproduced on the https://test.localgovdrupal.org/ site. I have deleted the 'Adult social care service is working normally' service status, but it still appears on this page: https://test.localgovdrupal.org/adult-health-and-social-care If you're testing locally make sure all the caches are enabled; they're disabled in Lando by default. |
I haven't been able to fully test this yet but I believe that modules/localgov_services_status/localgov_services_status.module should include an implementation of
hook_ENTITY_TYPE_predelete()
so that the landing page cache is invalidated when a status is deleted in same way as it is in the implementation ofhook_ENTITY_TYPE_presave()
when a status page is saved.The text was updated successfully, but these errors were encountered: