public function init()
{
if (empty($_POST)) {
if (isset($this->element->{$this->field})) {
$this->checked[$this->field] = (bool) $this->element->{$this->field};
} else {
$this->checked[$this->field] = false;
}
} else {
$this->checked[$this->field] = (bool) @$_POST[CHtml::modelName($this->element)][$this->field];
}
}