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

Handle Documentation order_id update from Strapi admin panel #9

Open
ChrisHinchey opened this issue Oct 18, 2022 · 0 comments
Open
Labels
bug Something isn't working
Milestone

Comments

@ChrisHinchey
Copy link
Contributor

ChrisHinchey commented Oct 18, 2022

Possible Alternative (https://market.strapi.io/plugins/@retikolo-drag-drop-content-types)

Relates to: https://feedback.strapi.io/customization/p/ordering-content-type-entries-in-the-list-view

Currently the creation and deletion of a documentation section will correctly increment and decrement an order_id using the beforeCreate and afterDelete lifecycle hooks provided by Strapi. As the default Strapi update function is used to update the entries on creation and deletion, handling the update of an order_id will cause a recursive update of all the entries order_ids.

A likely fix to this problem is to use a custom update "service" to update entries on creation, deletion, and update.

Strapi also seems to have a feature planned for future release that may help: https://feedback.strapi.io/developer-experience/p/ability-to-define-custom-indexes-in-the-schema

Resources that may be helpful:

@ChrisHinchey ChrisHinchey added the bug Something isn't working label Oct 18, 2022
@ChrisHinchey ChrisHinchey changed the title Handle order_id update from Strapi admin panel Handle Documentation order_id update from Strapi admin panel Oct 28, 2022
@ChrisHinchey ChrisHinchey moved this to 📋 Backlog in SAF Site Feb 15, 2023
@ChrisHinchey ChrisHinchey added this to the V2 milestone Feb 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: 📋 Backlog
Development

No branches or pull requests

1 participant