We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
destroy
update
Is your feature request related to a problem? Please describe. My resource has the following update action:
update :close do change set_attribute(:status, "closed") end
When exposing it via JSON:API I think the most reasonable thing to do is expose it as a DELETE endpoint.
DELETE
Describe the solution you'd like Allow delete route entities to accept update actions in addition to destroy and generic actions.
delete
Describe alternatives you've considered
routes do base "/tickets" patch :close, route: "/:id/close" end
Express the feature either with a change to resource syntax, or with a change to the resource interface
routes do base "/tickets" delete :close end
Additional context 🐚
The text was updated successfully, but these errors were encountered:
Makes sense to me. In the short term, you could make your update action a destroy action with `soft? true.
destroy :close do soft? true change set_attribute(:status, "closed") end
Sorry, something went wrong.
No branches or pull requests
Is your feature request related to a problem? Please describe.
My resource has the following update action:
When exposing it via JSON:API I think the most reasonable thing to do is expose it as a
DELETE
endpoint.Describe the solution you'd like
Allow
delete
route entities to accept update actions in addition to destroy and generic actions.Describe alternatives you've considered
Express the feature either with a change to resource syntax, or with a change to the resource interface
Additional context
🐚
The text was updated successfully, but these errors were encountered: