Skip to content
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

BUGFIX: Display flash messages in Fusion based backend modules #3999

Conversation

mficzel
Copy link
Member

@mficzel mficzel commented Jan 10, 2023

Previously flash messages were not displayed in fusion based backend modules because the rendering was implemented in the BackendSubModule. This layout which was used by all BackendSubModules which had to use the same or a cloned layout.

This change moves the rendering to the template of the backend module controller which renders around all modules. This makes sense because first this is not a layout task at all and second it makes sense to always render flash messages in the backend.

Resolves. #3998

Checklist

  • Code follows the PSR-2 coding style
  • Tests have been created, run and adjusted as needed
  • The PR is created against the lowest maintained branch
  • Reviewer - PR Title is brief but complete and starts with FEATURE|TASK|BUGFIX
  • Reviewer - The first section explains the change briefly for change-logs
  • Reviewer - Breaking Changes are marked with !!! and have upgrade-instructions

@mficzel mficzel requested a review from Sebobo January 10, 2023 08:20
@mficzel
Copy link
Member Author

mficzel commented Jan 10, 2023

@Sebobo since i know you ran into this issue already. Do you think this is a viable solution.

@mficzel mficzel force-pushed the bugfix/displayFlashMessagesInFusionBasedBackendModules branch from e298164 to 8699c4d Compare January 10, 2023 08:26
Previously flash messages were not displayed in fusion based backend modules because the rendering was implemented in the BackendSubModule.
This layout which was used by all BackendSubModules which had to use the same or a cloned layout.

This change moves the rendering to the template of the backend module controller. This makes sense because first this is not a layout task at all and second
it makes sense to always render flash messages in the backend.

Resolves. neos#3998
@mficzel mficzel force-pushed the bugfix/displayFlashMessagesInFusionBasedBackendModules branch from 8699c4d to 4507194 Compare January 10, 2023 08:44
@Sebobo
Copy link
Member

Sebobo commented Jan 10, 2023

Looks like a smart solution, we should have done years ago 🥳

But how can we prevent duplicate flash messages with all existing modules?

@mficzel
Copy link
Member Author

mficzel commented Jan 10, 2023

@Sebobo as far as i know the rendering removes flash messages from the pool. So i assume there will ne no duplicate rendering.

@Sebobo
Copy link
Member

Sebobo commented Jan 10, 2023

I'll test with my modules and get back to you :)

Copy link
Member

@Sebobo Sebobo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Works perfect, thx!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants