Welcome Guest, Not a member yet? Register   Sign In
Relation CRUD
#1

[eluser]oliwin[/eluser]
Guys, I need your help, i can not create a relationship at CRUD. I want to keep SELECT list(HTML) of selected elements.
I have two tables:

Menu and Menu_title
They are linked by fields Menu.id_menu = Menu_title.id_menu

Have this code:
Code:
$ crud = new grocery_CRUD ();
$ crud-> set_table ('menu');


$ crud-> set_relation ('id_menu', 'menu_title', 'title');
$ crud-> display_as ('description', 'Summary');
$ crud-> set_relation ('id_menu', 'menu_title', 'title');


where
Code:
$ crud-> set_relation ('id_menu', 'menu_title', 'title');
Documentation connects two tables by field id_menu with output from the second table of the field title. It seems true.

Here's an example in the documentation: http://www.grocerycr.../set_a_relation
I have that does not work, time delivery of the project there are 2 hours - the resolution is not found ((
#2

[eluser]Unknown[/eluser]
Your link was broken. http://www.grocerycrud.com/examples/set_a_relation




Theme © iAndrew 2016 - Forum software by © MyBB