public function ConfigPagesTypeController::create in Config Pages 7
Create a config_pages type - we first set up the values that are specific to our config_pages type schema but then also go through the EntityAPIController function.
Parameters
$type: The machine-readable type of the config_pages.
Return value
A config_pages type object with all default fields initialized.
Overrides EntityAPIController::create
File
- ./
config_pages.module, line 572 - This module is based on Model module (https://drupal.org/project/model) and most of the comments left untouched but have entity types renamed. Suuport for features added.
Class
- ConfigPagesTypeController
- The Controller for ConfigPages entities
Code
public function create(array $values = array()) {
// Add values that are specific to our ConfigPages
$values += array(
'id' => '',
'is_new' => TRUE,
'data' => '',
);
$config_pages_type = parent::create($values);
return $config_pages_type;
}