Vaskovsky Web Application
3.17.0306
|
Catalog page pattern. More...
Public Member Functions | |
doSelect () | |
The SELECT action. More... | |
doGet () | |
The GET action. More... | |
doAdd () | |
The ADD action. More... | |
doInsert () | |
The INSERT action. More... | |
doUpdate () | |
The UPDATE action. More... | |
doDelete () | |
The DELETE action. More... | |
![]() | |
getClass () | |
Returns new \ReflectionClass($this) . | |
getPageName () | |
Returns short class name without 'Page' suffix. | |
show () | |
Handles a server request and displays this page. | |
Protected Member Functions | |
create () | |
Returns an associative array that contains an initial model data; never null. | |
sanitize ($x) | |
Sanitizes a model data. More... | |
validateUpdate ($x) | |
Validates a model data to update model. More... | |
validateInsert ($x) | |
Validates a model data to insert model. More... | |
validateKey ($x) | |
Validates primary key in a model. More... | |
select ($x) | |
Returns an iterable list of objects that contains the selected models; never null. More... | |
get ($x) | |
Returns an object that contains the model data or null if the model with the specified key is not found. More... | |
insert ($x) | |
Inserts a new model in the database. More... | |
update ($x) | |
Updates a model in the database. More... | |
delete ($x) | |
Deletes a model from the database. More... | |
![]() | |
setApplicationURL ($url) | |
Sets the application URL. More... | |
getApplicationURL ($path) | |
Returns a path relative to the application URL. More... | |
setApplicationDirectory ($directory) | |
Sets the application directory. More... | |
getApplicationFile ($filename) | |
Returns a file path relative to the application directory. More... | |
setLocale ($locale) | |
Sets a locale to use with this page. More... | |
openPDO ($dsn, $user="", $password="") | |
Opens a database connection to use in this application. More... | |
getPDO () | |
Returns a PDO connection. More... | |
setAuthentication (AbstractAuthentication $auth) | |
Sets an authentication to use with this page. More... | |
getAuthentication () | |
Returns an AbstractAuthentication object; never null. More... | |
authorize () | |
Performs authorization. More... | |
authorizeByAttribute ($attribute) | |
Performs authorization by the account attribute. More... | |
authorizeByPageName (array $public_pages=array()) | |
Performs authorization by the page name. More... | |
render ($template, array $view_data=array(), $code=200) | |
Renders a view. More... | |
renderError ($message, $code=500) | |
Renders an error. More... | |
renderException (\Exception $ex) | |
Renders an exception. More... | |
Catalog page pattern.
|
protected |
Deletes a model from the database.
object | $x | is an object that contains a sanitized model data with the valid primary key; never null. |
doAdd | ( | ) |
doDelete | ( | ) |
doGet | ( | ) |
doInsert | ( | ) |
doSelect | ( | ) |
doUpdate | ( | ) |
|
protected |
Returns an object that contains the model data or null if the model with the specified key is not found.
object | $x | is an object that contains a sanitized model data with the valid primary key; never null. |
|
protected |
Inserts a new model in the database.
object | $x | is an object that contains a valid model data; never null. |
|
protected |
Sanitizes a model data.
object | $x | is an object that contains a model data; never null. |
|
protected |
Returns an iterable list of objects that contains the selected models; never null.
object | $x | is an object that contains a sanitized model data; never null. |
|
protected |
Updates a model in the database.
object | $x | is an object that contains a valid model data; never null. |
|
protected |
Validates a model data to insert model.
The default implementation uses $this->validateUpdate($x)
.
object | $x | is an object that contains a sanitized model data; never null. |
Definition at line 187 of file CatalogPage.php.
|
protected |
Validates primary key in a model.
object | $x | is an object that contains a sanitized model data; never null. |
Definition at line 191 of file CatalogPage.php.
|
protected |
Validates a model data to update model.
object | $x | is an object that contains a sanitized model data; never null. |