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

Implement API to determine if owned object need to be published #420

Closed
maxime-rainville opened this issue Oct 11, 2023 · 1 comment
Closed

Comments

@maxime-rainville
Copy link
Contributor

maxime-rainville commented Oct 11, 2023

As a developer, I want the capability to determined if they are any outstanding changes on a child object that need to be published.

Context

@mfendeksilverstripe has already implemented this in a PR #328. This issue is just backfilling.

Note that "owned" in this context is a bit ambiguous, as the PR includes cascade_duplicates in its concept of "owned".

Acceptance criteria

  • Versioned as a new method that can be called to determined if child object need to be published.
  • Owned "children of children" are considered when making a determination of the state of a parent object ... even if the first child is unversioned.
  • Any "compromises" that are needed to make this API shippable in a minor release are documented and a follow up card is created to remove them in the next major.

Notes

  • For context, ownership here refers to the private static $owns array.

Edge cases

  • Calling the stagesDifferRecursive on a DataObject in the LIVE stage.
  • Do we care about "unversioned" DataObjects that owned other DataObject?
  • What happens for "versioned" DataObject that do not use stages?

Pull requests

Parent epic

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

No branches or pull requests

2 participants