Bitrix-D7
23.9
Загрузка...
Поиск...
Не найдено
sectionpropertytable.php
1
<?php
2
namespace
Bitrix\Iblock
;
3
4
use
Bitrix\Main\Entity
;
5
use
Bitrix\Main\Localization\Loc
;
6
40
class
SectionPropertyTable
extends
Entity\DataManager
41
{
42
//ABCDE - for numbers
43
public
const
NUMBERS_WITH_SLIDER
=
'A'
;
44
public
const
NUMBERS
=
'B'
;
45
//FGHIJ - for checkboxes
46
public
const
CHECKBOXES
=
'F'
;
47
public
const
CHECKBOXES_WITH_PICTURES
=
'G'
;
48
public
const
CHECKBOXES_WITH_PICTURES_AND_LABELS
=
'H'
;
49
//KLMNO - for radio buttons
50
public
const
RADIO_BUTTONS
=
'K'
;
51
//PQRST - for drop down
52
public
const
DROPDOWN
=
'P'
;
53
public
const
DROPDOWN_WITH_PICTURES_AND_LABELS
=
'R'
;
54
//UWXYZ - reserved
55
public
const
CALENDAR
=
'U'
;
56
62
public
static
function
getTableName
(): string
63
{
64
return
'b_iblock_section_property'
;
65
}
66
72
public
static
function
getMap
(): array
73
{
74
return
array(
75
'IBLOCK_ID'
=> array(
76
'data_type'
=>
'integer'
,
77
'primary'
=>
true
,
78
'title'
=>
Loc::getMessage
(
'IBLOCK_SECTION_PROPERTY_ENTITY_IBLOCK_ID_FIELD'
),
79
),
80
'SECTION_ID'
=> array(
81
'data_type'
=>
'integer'
,
82
'primary'
=>
true
,
83
'title'
=>
Loc::getMessage
(
'IBLOCK_SECTION_PROPERTY_ENTITY_SECTION_ID_FIELD'
),
84
),
85
'PROPERTY_ID'
=> array(
86
'data_type'
=>
'integer'
,
87
'primary'
=>
true
,
88
'title'
=>
Loc::getMessage
(
'IBLOCK_SECTION_PROPERTY_ENTITY_PROPERTY_ID_FIELD'
),
89
),
90
'SMART_FILTER'
=> array(
91
'data_type'
=>
'boolean'
,
92
'values'
=> array(
'N'
,
'Y'
),
93
'title'
=>
Loc::getMessage
(
'IBLOCK_SECTION_PROPERTY_ENTITY_SMART_FILTER_FIELD'
),
94
),
95
'DISPLAY_TYPE'
=> array(
96
'data_type'
=>
'enum'
,
97
'values'
=> array(
98
self::NUMBERS_WITH_SLIDER,
99
self::NUMBERS,
100
self::CHECKBOXES,
101
self::CHECKBOXES_WITH_PICTURES,
102
self::CHECKBOXES_WITH_PICTURES_AND_LABELS,
103
self::RADIO_BUTTONS,
104
self::DROPDOWN,
105
self::DROPDOWN_WITH_PICTURES_AND_LABELS,
106
self::CALENDAR
107
),
108
'title'
=>
Loc::getMessage
(
'IBLOCK_SECTION_PROPERTY_ENTITY_DISPLAY_TYPE_FIELD'
),
109
),
110
'DISPLAY_EXPANDED'
=> array(
111
'data_type'
=>
'boolean'
,
112
'values'
=> array(
'N'
,
'Y'
),
113
'title'
=>
Loc::getMessage
(
'IBLOCK_SECTION_PROPERTY_ENTITY_DISPLAY_EXPANDED_FIELD'
),
114
),
115
'FILTER_HINT'
=> array(
116
'data_type'
=>
'string'
,
117
'title'
=>
Loc::getMessage
(
'IBLOCK_SECTION_PROPERTY_ENTITY_FILTER_HINT_FIELD'
),
118
'validation'
=> array(__CLASS__,
'validateFilterHint'
),
119
),
120
'IBLOCK'
=> array(
121
'data_type'
=>
'Bitrix\Iblock\Iblock'
,
122
'reference'
=> array(
'=this.IBLOCK_ID'
=>
'ref.ID'
),
123
),
124
'PROPERTY'
=> array(
125
'data_type'
=>
'Bitrix\Iblock\Property'
,
126
'reference'
=> array(
'=this.PROPERTY_ID'
=>
'ref.ID'
),
127
),
128
'SECTION'
=> array(
129
'data_type'
=>
'Bitrix\Iblock\Section'
,
130
'reference'
=> array(
'=this.SECTION_ID'
=>
'ref.ID'
),
131
),
132
);
133
}
134
140
public
static
function
validateFilterHint
(): array
141
{
142
return
array(
143
new
Entity
\Validator\Length(
null
, 255),
144
);
145
}
146
}
Bitrix\Iblock\SectionPropertyTable
Definition
sectionpropertytable.php:41
Bitrix\Iblock\SectionPropertyTable\NUMBERS
const NUMBERS
Definition
sectionpropertytable.php:44
Bitrix\Iblock\SectionPropertyTable\CHECKBOXES_WITH_PICTURES_AND_LABELS
const CHECKBOXES_WITH_PICTURES_AND_LABELS
Definition
sectionpropertytable.php:48
Bitrix\Iblock\SectionPropertyTable\getMap
static getMap()
Definition
sectionpropertytable.php:72
Bitrix\Iblock\SectionPropertyTable\RADIO_BUTTONS
const RADIO_BUTTONS
Definition
sectionpropertytable.php:50
Bitrix\Iblock\SectionPropertyTable\CHECKBOXES
const CHECKBOXES
Definition
sectionpropertytable.php:46
Bitrix\Iblock\SectionPropertyTable\validateFilterHint
static validateFilterHint()
Definition
sectionpropertytable.php:140
Bitrix\Iblock\SectionPropertyTable\CHECKBOXES_WITH_PICTURES
const CHECKBOXES_WITH_PICTURES
Definition
sectionpropertytable.php:47
Bitrix\Iblock\SectionPropertyTable\DROPDOWN_WITH_PICTURES_AND_LABELS
const DROPDOWN_WITH_PICTURES_AND_LABELS
Definition
sectionpropertytable.php:53
Bitrix\Iblock\SectionPropertyTable\CALENDAR
const CALENDAR
Definition
sectionpropertytable.php:55
Bitrix\Iblock\SectionPropertyTable\DROPDOWN
const DROPDOWN
Definition
sectionpropertytable.php:52
Bitrix\Iblock\SectionPropertyTable\NUMBERS_WITH_SLIDER
const NUMBERS_WITH_SLIDER
Definition
sectionpropertytable.php:43
Bitrix\Iblock\SectionPropertyTable\getTableName
static getTableName()
Definition
sectionpropertytable.php:62
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\Main\ORM\Entity
Definition
entity.php:26
Bitrix\Iblock
modules
iblock
lib
sectionpropertytable.php
Создано системой
1.10.0