1C-Bitrix
25.700.0
Загрузка...
Поиск...
Не найдено
blockcontent.php
См. документацию.
1
<?
8
namespace
Bitrix\Fileman\Block\Content
;
9
10
use
Bitrix\Main\Localization\Loc
;
11
12
Loc::loadMessages(__FILE__);
13
14
class
BlockContent
15
{
16
CONST
TYPE_STYLES
=
'STYLES'
;
17
CONST
TYPE_BLOCKS
=
'BLOCKS'
;
18
19
protected
$list
=
array
();
20
21
public
function
__construct
()
22
{
23
24
}
25
26
public
function
add
(
$type
, $place, $value)
27
{
28
$this->list[] =
array
(
29
'type'
=>
$type
,
30
'place'
=> $place,
31
'value'
=> $value,
32
);
33
}
34
35
public
function
getStyles
()
36
{
37
return
$this->
filterListByType
(self::TYPE_STYLES);
38
}
39
40
public
function
getBlocks
()
41
{
42
return
$this->
filterListByType
(self::TYPE_BLOCKS);
43
}
44
45
public
function
setList
(
array
$list
)
46
{
47
$this->list = [];
48
foreach
(
$list
as $item)
49
{
50
$this->
add
($item[
'type'
], $item[
'place'
], $item[
'value'
]);
51
}
52
53
return
$this;
54
}
55
56
public
function
getList
()
57
{
58
return
$this->list
;
59
}
60
61
protected
function
filterListByType
(
$type
)
62
{
63
$result
=
array
();
64
foreach
($this->list as $item)
65
{
66
if
($item[
'type'
] !=
$type
)
67
{
68
continue
;
69
}
70
71
//$result[$item['code']] = $item['value'];
72
$result
[] = $item;
73
}
74
75
return
$result
;
76
}
77
}
$type
$type
Определения
options.php:106
Bitrix\Fileman\Block\Content\BlockContent
Определения
blockcontent.php:15
Bitrix\Fileman\Block\Content\BlockContent\__construct
__construct()
Определения
blockcontent.php:21
Bitrix\Fileman\Block\Content\BlockContent\getBlocks
getBlocks()
Определения
blockcontent.php:40
Bitrix\Fileman\Block\Content\BlockContent\TYPE_STYLES
CONST TYPE_STYLES
Определения
blockcontent.php:16
Bitrix\Fileman\Block\Content\BlockContent\getStyles
getStyles()
Определения
blockcontent.php:35
Bitrix\Fileman\Block\Content\BlockContent\$list
$list
Определения
blockcontent.php:19
Bitrix\Fileman\Block\Content\BlockContent\getList
getList()
Определения
blockcontent.php:56
Bitrix\Fileman\Block\Content\BlockContent\add
add($type, $place, $value)
Определения
blockcontent.php:26
Bitrix\Fileman\Block\Content\BlockContent\filterListByType
filterListByType($type)
Определения
blockcontent.php:61
Bitrix\Fileman\Block\Content\BlockContent\TYPE_BLOCKS
CONST TYPE_BLOCKS
Определения
blockcontent.php:17
Bitrix\Fileman\Block\Content\BlockContent\setList
setList(array $list)
Определения
blockcontent.php:45
Bitrix\Main\Localization\Loc
Определения
loc.php:12
array
</td ></tr ></table ></td ></tr >< tr >< td class="bx-popup-label bx-width30"><?=GetMessage("PAGE_NEW_TAGS")?> array( $site)
Определения
file_new.php:804
$result
$result
Определения
get_property_values.php:14
Bitrix\Fileman\Block\Content
Определения
blockcontent.php:8
bitrix
modules
fileman
lib
block
content
blockcontent.php
Создано системой
1.14.0