Template factory.
More...
|
static | create ($path, array $columns) |
| Create template object from database columns. More...
|
|
static | getTemplate ($path, array $columns) |
| Create template from database columns. More...
|
|
static | defaults () |
| Set or retireve default parameters of the object. More...
|
|
Template factory.
Build grid, form or tpl from list of database columns. Usage: $grid = TemplateFactory::create('grid.tpl', $columns);
◆ create()
static create |
( |
|
$path, |
|
|
array |
$columns |
|
) |
| |
|
static |
Create template object from database columns.
- Parameters
-
string | $path | Path to generator template (see assets/tpl for defaults) |
array | $columns | List of database columns (see Db->columns() method) |
- Returns
- Tpl|Form|Grid $object
◆ getTemplate()
static getTemplate |
( |
|
$path, |
|
|
array |
$columns |
|
) |
| |
|
static |
Create template from database columns.
- Parameters
-
string | $path | Path to generator template (see assets/tpl for defaults) |
array | $columns | List of database columns (see Db->columns() method) |
- Returns
- string $template Template source
The documentation for this class was generated from the following file: