public function loadDefaultValues($skipIfSet = true)
{
foreach ($this->_properties as $property) {
if (!$skipIfSet || $this->{$property->code} === null) {
$this->{$property->code} = $property->defaultValue;
}
}
return $this;
/*foreach (static::getTableSchema()->columns as $column) {
if ($column->defaultValue !== null && (!$skipIfSet || $this->{$column->name} === null)) {
$this->{$column->name} = $column->defaultValue;
}
}
return $this;*/
}