-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Introduce allowed_ransackable_scopes #4956
Introduce allowed_ransackable_scopes #4956
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, @RyanofWoods! Looks legit 🙂
ae1765d
to
708794c
Compare
ransackable_scopes is currently declared on two models, although other ransackable methods are declared through RansackableAttributes. By this move, the codebase becomes more consistent.
By using allowed_ransackable_scopes which was introduced in the last commit, stores will be able to easily concatenate to the arrays already declared on Product and Promotion in Solidus.
708794c
to
a68e768
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @RyanofWoods, this makes sense. I left a detective question 🕵️♂️, to better understand any possible backward compatibility issue.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!!!
Summary
Introduce
allowed_ransackable_scopes
to:ransackable_scopes
values already onProduct
andPromotion
(by usingallowed_ransackable_scopes
).Checklist
Check out our PR guidelines for more details.
The following are mandatory for all PRs:
The following are not always needed: