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

[5.x] Localized entry dates fall back to the origin #10282

Merged

Conversation

arthurperton
Copy link
Contributor

This PR fixes #3440.

If an entry does not have a date of itself, it will now fall back to the date of the origin.

See also the discussion in #6634.

@arthurperton arthurperton changed the title Fall back to the date of the origin [5.x] Fall back to the date of the origin Jun 10, 2024
@jasonvarga
Copy link
Member

Thanks Arthur. What you did was correct - when a date was missing from an entry object (or the entry filename) it would fall back correctly.

But the only way that would ever happen is if you created the entry programmatically or manually removed the date from the filename.

I've added logic so that the date doesn't get put onto the localizations when using the control panel

Now the date will only be added to the entry if its out of sync with the origin, just like other fields.

CleanShot 2024-06-28 at 17 10 25

If you have existing localized entries with dates, you can click sync there, save, and the date will be gone and fallback to the origin.

@jasonvarga jasonvarga changed the title [5.x] Fall back to the date of the origin [5.x] Localized entry dates fall back to the origin Jun 28, 2024
@jasonvarga jasonvarga merged commit 9476896 into statamic:5.x Jun 28, 2024
16 checks passed
@arthurperton arthurperton deleted the pr/issue-3440-date-origin-fallback branch December 19, 2024 07:52
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.

Date doesn't update for Multisite Entries.
2 participants