-
Notifications
You must be signed in to change notification settings - Fork 351
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
Not a symbol. #313
Comments
You have to setup the model to have a composite key. That is generally done like this: class MyClass |
I have that exactly in my code, as the documentation says, but I still get the error. |
I had the exact same error. When you look at the stack can see that it comes from the generated title
You can simply fix it by overriding the page title of the ActiveAdmin Ressource view this way :
Now ActiveAdmin works well with composite-primary-key |
I am using CPK so that I can edit a join table in Active Admin. I have a table category_recipes, with two columns, recipe_id and category_id. This is the model I am using for the table's index page in Active Admin.
My exact error is ["category_id", "recipe_id"] is not a symbol.
The error is being thrown in Active Admin's display_helper, in this block:
Using Rails 4.2, ActiveRecord 4.2, composite_primary_keys 8.1.0.
The text was updated successfully, but these errors were encountered: