-
Notifications
You must be signed in to change notification settings - Fork 5
Description
Hello,
I'm make some tests with the apartmentex and I have a doubt.
I'm try to use a prefix configuration for a schema name e for one reason do not works very well, always the application use the default prefix "tenant_".
My project is a umbrella project and inside a config.exs of the projects that's have a Ecto dependence I put:
config :apartmentex, schema_prefix: "client_"
Unfortanely do not work. I did a search and I found out that the
https://groups.google.com/forum/#!msg/elixir-lang-talk/5yX9hBNEXe0/7UYWeTKmjaYJ
Using the strategy of the previous post the configuration works: config :tenant_prefix, :apartmentex, %{ schema_prefix: "client_" }
However I need change the call in apartmentex for: Application.get_env(:tenant_prefix, :apartmentex).schema_prefix
A another way is change the "key" :apartmentex for the my application name. Ex:
config :my_app, schema_prefix: "client_"
And change the call in apartmentex for Application.get_env(:my_app, :schema_prefix)
How should I proceed?
Sorry for english mistakes.
PS: I'm using Ecto 3.0. When the compatibility will be available in Hex?