forked from ayaaop/VKify-theme-2016
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path@listViewVid.xml
More file actions
84 lines (76 loc) · 3.7 KB
/
@listViewVid.xml
File metadata and controls
84 lines (76 loc) · 3.7 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
{extends "@layoutVid.xml"}
{block wrap}
<div class="wrap2">
<div class="wrap1">
<div class="page_wrap padding_top">
<div n:ifset="tabs" n:ifcontent class="tabs stupid-fix">
{include tabs}
</div>
{ifset size}
{include size, x => $dat}
{/ifset}
{ifset before_content}
{include before_content, x => $dat}
{/ifset}
{ifset specpage}
{include specpage, x => $dat}
{else}
<div class="container_gray {ifset noscroll}no_scroll_container{else}scroll_container{/ifset}">
{var $data = is_array($iterator) ? $iterator : iterator_to_array($iterator)}
{var $itemsPerRow = 8} {* Возвращено к 8 объектам в ряду *}
{var $chunks = array_chunk($data, $itemsPerRow)}
{ifset top}
{include top, x => $dat}
{/ifset}
{if sizeof($data) > 0}
<table class="video-grid">
<tbody n:attr="id => is_null($table_body_id) ? NULL : $table_body_id">
{foreach $chunks as $rowItems}
<tr>
{foreach $rowItems as $dat}
<td class="video-grid-item">
<div>
<a href="{include link, x => $dat}">
{include preview, x => $dat}
</a>
<a href="{include link, x => $dat}">
<b>{include name, x => $dat}</b>
</a>
<br/>
{include description, x => $dat}
<span n:ifset="actions" class="action_links">
{include actions, x => $dat}
</span>
</div>
</td>
{/foreach}
{for $i = 0; $i < $itemsPerRow - count($rowItems); $i++}
<td class="video-grid-item empty-cell"></td>
{/for}
</tr>
{/foreach}
</tbody>
</table>
{include "components/paginator.xml", conf => (object) [
"page" => $page,
"count" => $count,
"amount" => sizeof($data),
"perPage" => $perPage ?? OPENVK_DEFAULT_PER_PAGE,
"atBottom" => true,
]}
{else}
{ifset customErrorMessage}
{include customErrorMessage}
{else}
{include "components/nothing.xml"}
{/ifset}
{/if}
</div>
{/ifset}
{ifset bottom}
{include bottom}
{/ifset}
</div>
</div>
</div>
{/block}