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

changed group_membership but it still looking for a table group_membership #66

Open
kainio opened this issue Jul 12, 2017 · 3 comments
Open
Labels

Comments

@kainio
Copy link

kainio commented Jul 12, 2017

When i do
User.as(:admin)
knowing that I changed the group_membership to organization_membership in the initializer
I got
User Load (1.0ms) SELECT users.* FROM users INNER JOIN organization_memberships ON organization_memberships.member_id = users.id AND organization_memberships.member_type = 'User' WHERE group_memberships.membership_type = 'admin' LIMIT 11
ActiveRecord::StatementInvalid: Mysql2::Error: Unknown column 'group_memberships.membership_type' in 'where clause': SELECT users.* FROM users INNER JOIN organization_memberships ON organization_memberships.member_id = users.id AND organization_memberships.member_type = 'User' WHERE group_memberships.membership_type = 'admin' LIMIT 11
Why it's still looking for group_memberships table ?

@dwbutler
Copy link
Owner

This was fixed in #64 but hasn't been released yet.

@kainio
Copy link
Author

kainio commented Jul 13, 2017

I am using now the latest version of groupify repo in my gemfile and it's working fine, but named groups are still not working.

@joelvh
Copy link
Collaborator

joelvh commented Sep 7, 2017

@kainio major refactor in #61 - would you be willing to test that out?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants