Bitrix-D7
23.9
Загрузка...
Поиск...
Не найдено
colorpicker.php
1
<?php
2
3
namespace
Bitrix\Report\VisualConstructor\Fields\Valuable
;
4
5
use
Bitrix\Main\Localization\Loc
;
6
12
class
ColorPicker
extends
BaseValuable
13
{
14
const
JS_EVENT_ON_SELECT
=
'onSelect'
;
15
private
$mode;
16
private
$pickerFieldHidden =
false
;
17
24
public
function
__construct
($key, $mode =
'simple'
)
25
{
26
parent::__construct($key);
27
$this->
setLabel
(
Loc::getMessage
(
'REPORT_DEFAULT_COLOR_FIELD_LABEL'
));
28
$this->
setDefaultValue
(
'inherit'
);
29
$this->
setMode
($mode);
30
}
31
32
39
public
function
printContent
()
40
{
41
$templateName = $this->
getMode
() ==
'simple'
?
'simplecolorpicker'
:
'colorpicker'
;
42
$this->
includeFieldComponent
($templateName);
43
}
44
48
public
function
getMode
()
49
{
50
return
$this->mode;
51
}
52
59
public
function
setMode
($mode)
60
{
61
$this->mode = $mode;
62
}
63
70
public
function
isPickerFieldHidden
()
71
{
72
return
$this->pickerFieldHidden;
73
}
74
81
public
function
setPickerFieldHidden
($pickerFieldHidden)
82
{
83
$this->pickerFieldHidden = $pickerFieldHidden;
84
}
85
86
87
}
Bitrix\Main\Localization\Loc
Definition
loc.php:11
Bitrix\Main\Localization\Loc\getMessage
static getMessage($code, $replace=null, $language=null)
Definition
loc.php:29
Bitrix\Report\VisualConstructor\Fields\Base\includeFieldComponent
includeFieldComponent($templateName, $params=array())
Definition
base.php:530
Bitrix\Report\VisualConstructor\Fields\Base\setLabel
setLabel($label)
Definition
base.php:243
Bitrix\Report\VisualConstructor\Fields\Valuable\BaseValuable
Definition
basevaluable.php:11
Bitrix\Report\VisualConstructor\Fields\Valuable\BaseValuable\setDefaultValue
setDefaultValue($defaultValue)
Definition
basevaluable.php:40
Bitrix\Report\VisualConstructor\Fields\Valuable\ColorPicker
Definition
colorpicker.php:13
Bitrix\Report\VisualConstructor\Fields\Valuable\ColorPicker\printContent
printContent()
Definition
colorpicker.php:39
Bitrix\Report\VisualConstructor\Fields\Valuable\ColorPicker\setPickerFieldHidden
setPickerFieldHidden($pickerFieldHidden)
Definition
colorpicker.php:81
Bitrix\Report\VisualConstructor\Fields\Valuable\ColorPicker\__construct
__construct($key, $mode='simple')
Definition
colorpicker.php:24
Bitrix\Report\VisualConstructor\Fields\Valuable\ColorPicker\getMode
getMode()
Definition
colorpicker.php:48
Bitrix\Report\VisualConstructor\Fields\Valuable\ColorPicker\isPickerFieldHidden
isPickerFieldHidden()
Definition
colorpicker.php:70
Bitrix\Report\VisualConstructor\Fields\Valuable\ColorPicker\JS_EVENT_ON_SELECT
const JS_EVENT_ON_SELECT
Definition
colorpicker.php:14
Bitrix\Report\VisualConstructor\Fields\Valuable\ColorPicker\setMode
setMode($mode)
Definition
colorpicker.php:59
Bitrix\Report\VisualConstructor\Fields\Valuable
Definition
basevaluable.php:2
modules
report
lib
visualconstructor
fields
valuable
colorpicker.php
Создано системой
1.10.0