You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When publishing or unpublishing a document in a version collection with drafts enabled, the UI does not directly show the status and data change, a manual reload is required. This is a quite relevant problem because it prevents interaction with the document on its most recent state, for example publishing directly after unpublishing is not possible without manually reloading the page.
Status bar before unpublishing (correct state):
Status bar after unpublishing (outdated state):
Status bar after a manual reload of the page (correct state):
This also applies to the data itself, not just the published status. When using a Hook to generate data on publish (collection-level beforeChange Hook), the generated data is also only visible after manually reloading the page.
Another case where this is impeding interaction is when validation fails on publish. After doing this, the UI displays the document as published and thus disables the publish button. Like before, the correct state is shown again after reloading the page manually.
Reproduction Steps
This issue was produced with Payload running with the Next Dev Server.
Create a collection with the following version configuration:
Describe the Bug.
When publishing or unpublishing a document in a version collection with drafts enabled, the UI does not directly show the status and data change, a manual reload is required. This is a quite relevant problem because it prevents interaction with the document on its most recent state, for example publishing directly after unpublishing is not possible without manually reloading the page.
Status bar before unpublishing (correct state):
Status bar after unpublishing (outdated state):
Status bar after a manual reload of the page (correct state):
This also applies to the data itself, not just the published status. When using a Hook to generate data on publish (collection-level beforeChange Hook), the generated data is also only visible after manually reloading the page.
Another case where this is impeding interaction is when validation fails on publish. After doing this, the UI displays the document as published and thus disables the publish button. Like before, the correct state is shown again after reloading the page manually.
Reproduction Steps
This issue was produced with Payload running with the Next Dev Server.
The collection I tested with also contained a Hook to generate data for a field, validations on some fields and access control.
Environment Info
The text was updated successfully, but these errors were encountered: