Previous Page
_addRelated()

Solar_Example_Model_Users
_belongsTo()

Next Page
_createTableAndIndexes()

_belongsTo()

protected void _belongsTo ( string $name, array $opts default NULL )

Adds a named belongs-to relationship.

Inherited from Solar_Sql_Model.

Parameters

  • (string) $name: The relationship name, which will double as a property when records are fetched from the model.
  • (array) $opts: Additional options for the relationship.

Returns

  • (void)

Description

Adds a named belongs-to relationship.