DB
class DB
The Database Model provides a base class for all database models.
Properties
protected QueryBuilder | $queryBuilder | The query builder instance. |
Methods
__construct($table, $primaryKey = 'id')
No description
setPrimaryKey($primaryKey)
Set the primary key for the model.
__call(string $name, array $arguments)
Proxy method for the query builder.
Details
at line 21
__construct($table, $primaryKey = 'id')
at line 41
static DB
table($table, $primaryKey = 'id')
Instantiate a new DB model with the given table name.
at line 57
setPrimaryKey($primaryKey)
Set the primary key for the model.
at line 76
__call(string $name, array $arguments)
Proxy method for the query builder.