Skip to content

Conversation

@jasonvarga
Copy link
Member

@jasonvarga jasonvarga commented Jul 10, 2024

Requires statamic/cms#10383 to be merged and tagged.

The blink cache for the entry uri is cleared before saving the model, which allows the uri to be added correctly to the database.

Fixes #220


This also implements the Eloquent equivalent entry repository methods in statamic/cms#10383.

This will allow the uri, order, and data->parent values to be updated appropriately when reordering a collection's tree.

Fixes #260


Other notes:

  • updateEntryUris and updateEntryOrder have basically just been moved from the collection repo to the entry repo. updateParents wasn't even there at all, so this has been added.
  • The UpdateCollectionEntryParent job has been added which is essentially a copy of the UpdateCollectionEntryOrder job.
  • The UpdateStructuredEntryOrderlistener has been removed since the entry repository method will be called directly.

Todo:

  • Bump composer requirement of cms to whatever version the cms PR makes it into.

@jasonvarga jasonvarga marked this pull request as ready for review July 10, 2024 19:42
@jasonvarga jasonvarga merged commit 12c8d80 into master Jul 10, 2024
@jasonvarga jasonvarga deleted the fix/clear-entry-uri-cache-on-save branch July 10, 2024 19:42
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.

Reorder collection does not working Uri field not saved on first save when Orderable is true and max depth is 1

3 participants