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

Table name prefix for join table #296

Open
mitfik opened this issue Nov 4, 2014 · 0 comments · May be fixed by #432
Open

Table name prefix for join table #296

mitfik opened this issue Nov 4, 2014 · 0 comments · May be fixed by #432

Comments

@mitfik
Copy link

mitfik commented Nov 4, 2014

Hi,

Is there any way to tell rolify to set prefix name for join table users_roles to have something like prefix_users_roles ?

As I can see in the source code you are using tableize on the role_cname:

https://github.com/RolifyCommunity/rolify/blob/master/lib/rolify.rb#L20

self.role_table_name = self.role_cname.tableize.gsub(/\//, "_")

which in my understanding will never resolve proper table name if we will set in ActiveRecord table_name_prefix.
Is that correct or I am missing something?

Please advise me how to set proper table_name_prefix for all tables used by rolify.
Thanks a lot

@zaru zaru linked a pull request Jan 18, 2017 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant