How can we know the relationships on any table in controller.
I have made a common controller where I have created common list, view, add, delete methods.
I just want to add the Contains dynamically in above methods.
So, how is it possible?
Do you mean you want to get the names of the relationships or just get values from the relationships?
@FinlayDaG33k : want to create dynamic relationships to fetch the values.
creating relationships on the fly can’t be done afaik.
What you could do it create a relationship in the model, then access it in your controller like:
$table = 'news';
ok. I will try this. Thanks!