Someone
public text v1 · immutablehow I add a new element with a field link with another table with one-two-one
I have test :
$obj = new $Table();
$obj->name = "toto";
$obj->langue->code = "EN";
$obj->save();
when I do that I insert a new line in the langue table
and I would like to take the obj take the id of langue and set it for my new element
I must call new Langue() for get it ?