getAttribute('formatResult');
$formatCondition = null;
if (!empty($formatResult)) {
$formatCondition = ',
formatResult : '.$formatResult.',
formatSelection : '.$formatResult.',';
}
$defaultValues = $this->getAttribute('defaults');
$dataCondition = null;
$tags = null;
if (!empty($defaultValues)) {
$result = json_encode($defaultValues);
$result = str_replace('"id"', 'id', $result);
$result = str_replace('"text"', 'text', $result);
$dataCondition = '$("#'.$this->getAttribute('name').'").select2("data", '.$result.')';
$tags = ', tags : function() { return '.$result.'} ';
}
$html .= '';
$html .= '';
return $html;
}
}