mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-07-22 01:12:17 +00:00
- Added Zusatzfelder tab for UDF in FAS, students and employees
- UDF for person and prestudent only - Added CSS for widgets - Fixed checkbox - Improved aesthetics of widgets
This commit is contained in:
@@ -1070,23 +1070,8 @@ class CheckboxWidget extends Widget
|
||||
const VALUE_FIELD = 'value';
|
||||
// Name of the property that will be used to store the value between the option tags
|
||||
const DESCRIPTION_FIELD = 'description';
|
||||
// The name of the element of the data array given to the view
|
||||
// this element is used to tell what element of the dropdown is selected
|
||||
const CHECKED_ELEMENT = 'checkedElement';
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
protected function setValue($value)
|
||||
{
|
||||
$tmpValue = $value;
|
||||
if (is_array($value) && count($value) > 0)
|
||||
{
|
||||
$tmpValue = array_values($value)[0];
|
||||
}
|
||||
|
||||
$this->_args[CheckboxWidget::VALUE_FIELD] = $tmpValue;
|
||||
}
|
||||
// Value of value attribute of the checkbox
|
||||
const CHECKBOX_VALUE = 'true';
|
||||
|
||||
/**
|
||||
*
|
||||
@@ -1105,17 +1090,8 @@ class CheckboxWidgetUDF extends CheckboxWidget
|
||||
/**
|
||||
*
|
||||
*/
|
||||
public function render($parameters)
|
||||
public function render()
|
||||
{
|
||||
if ($parameters != null)
|
||||
{
|
||||
$this->setValue($parameters);
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->setValue('');
|
||||
}
|
||||
|
||||
$this->loadCheckboxView();
|
||||
|
||||
echo $this->content();
|
||||
|
||||
Reference in New Issue
Block a user