What does the primary flag indicator on entity relations actually do?
is it to mark that the relationship is a PK field?
the primary relationship?
what happens if i get it wrong?
I haven't seen it do anything after trying it both ways so i'm not sure what the point of it is.
is it to mark that the relationship is a PK field?
the primary relationship?
what happens if i get it wrong?
I haven't seen it do anything after trying it both ways so i'm not sure what the point of it is.
Code:
$structure->relations = [
'MyRelation' => [
'entity' => 'MyNs\MyAddon:MyOtherEntity',
'type' => self::TO_ONE,
'conditions' => [['id', '=', '$relation_id']],
'primary' => false
],