pbRelationship
Snippet for relationship output
Parameters
| Parameter | Default | Description |
|---|---|---|
| relationType | one_to_one | Type of relationship. Possible values: one_to_one, one_to_many, many_to_one, many_to_many |
| primaryTable | pbTableValue | Primary table. Possible values: pbBlockValue,pbTableValue,pbResource,pbUser |
| primaryId | ID of the primary record | |
| relatedTable | pbTableValue | Related table. Possible values: pbBlockValue,pbTableValue,pbResource,pbUser |
| relatedId | ID of the related record |
Examples
php
{'!pbRelationship'|snippet: [
'relationType' => 'one_to_many',
'primaryTable' => 'pbBlockValue',
'primaryId' => 1,
'relatedTable' => 'pbResource',
'tpl' => 'product'
]}