-
Notifications
You must be signed in to change notification settings - Fork 288
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
Activeadmin v3 support #477
Conversation
Now required in AA v3 / Ransack v4
Mainly, the 'contains' predicate, that was used as default in some components. These predicates were removed from activeadmin v3, since they were backports. More info here activeadmin/activeadmin#8010
d838ab2
to
faea79f
Compare
@@ -92,4 +92,18 @@ def self.colors | |||
def set_default_state | |||
self.state ||= 'pending' | |||
end | |||
|
|||
def self.ransackable_attributes(_auth_object = nil) |
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.
I understand that now it is mandatory to do this, right?
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.
Can we get a release of this before the whole v2 overhaul? |
@jgmontoya even though we won't be backporting things to v1, this seems important enough that we can release it for a last v1 update. I opened #479 for this, so we should be releasing that in the short run |
@jgmontoya we just released v1.10.1 , please let us know how it goes if you try it out |
Motivation / Background
This Pull Request has been created because ActiveAdmin released v3 🎉 . It has some breaking changes, including requiring of ransack v4, so some changes needed to be done on our part to support it.
Detail
This Pull Request applies a couple of backwards compatible changes that allow this gem to work well with AA v3, and for tests to pass using that version:
ransackable_attributes
andransackable_associations
to dummy app models, as it is now explicitly required by ransack v4contains
), that are now removed from AA. These predicates were backports in AA, and they have been replaced by their already existent Ransack equivalentsAdditional information
Closes #475
Checklist
Before submitting the PR make sure the following are checked: