I'm trying to wrap my head around entity framework today. I see you can specify a relationship like this:
PHP:
However, if the table I have has a column called created_by_user_id, how...
Read more
Читать далее...
PHP:
Код:
$structure->relations = [
'User' => [
'entity' => 'XF:User',
'type' => self::TO_ONE,
'conditions' => 'user_id',
'primary' => true,
]
];
$structure->defaultWith = [
'User'
];
However, if the table I have has a column called created_by_user_id, how...
Read more
Читать далее...