Hi,
On Sat, Oct 15, 2016, at 22:10, Usman Shahid wrote:
> Actually these tables and models are dynamically added to the database,
> every addition requires creating a new model in the system which contains
> nothing but the table name. I'm trying to avoid that by creating a single
> model which ca
Actually these tables and models are dynamically added to the database,
every addition requires creating a new model in the system which contains
nothing but the table name. I'm trying to avoid that by creating a single
model which can handle multiple tables given a table name using
ActiveRecord qu
What Colin said. Alternatively, you could write a concern and include it in
models you want to support in the search feature.
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it
On 15 October 2016 at 10:07, Usman Shahid wrote:
> I cannot find an alternative to this. What i'm trying to do is write a
> generic interface which can answer generic queries like search based on
> specific column and aggregate queries etc. Underlying table is provided to
> the Model on initializ
I cannot find an alternative to this. What i'm trying to do is write a
generic interface which can answer generic queries like search based on
specific column and aggregate queries etc. Underlying table is provided to
the Model on initialization and I want it hooked with that table so that I
can ru
Probably doable (hackable) but I think it’d be extremely unidiomatic Rails. If
you could tell us what you’re trying to achieve we might be able to suggest a
better solution.
Cheers
Greg
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
T
6 matches
Mail list logo