ExtensionList.html 4.78 KB
Newer Older
1 2
{namespace terfe2=T3o\TerFe2\ViewHelpers}

3
<f:if condition="{extensions}">
4 5
    <f:then>
        <div class="ter-ext-list-count">
Markus Sommer's avatar
Markus Sommer committed
6
            <f:translate key="extensions_found" arguments="{0: '{f:count(subject : extensions)}'}" />
7
        </div>
8

9 10 11 12
        <f:widget.paginate objects="{extensions}" as="paginateExtensions"
                           configuration="{itemsPerPage: settings.listCount, insertAbove: 0, insertBelow: 1}">
            <f:for each="{paginateExtensions}" as="extension">
                <div class="ter-ext-list-row cl">
13

14 15 16
                    <!-- Headline -->
                    <div class="ter-ext-list-row-head">
                        <terfe2:extensionIcon version="{extension.lastVersion}" alt="{extension.lastVersion.title}"
Markus Sommer's avatar
Markus Sommer committed
17
                                              class="ter-ext-icon" />
18 19 20 21 22
                        <f:link.action controller="Extension" action="show" arguments="{extension : extension}">
                            {extension.lastVersion.title}
                        </f:link.action>
                        <span class="ter-ext-list-row-key">{extension.extKey}</span>
                    </div>
23

24 25
                    <!-- Content area -->
                    <div class="ter-ext-list-row-regular cl">
26

27 28 29
                        <!-- Description -->
                        <div class="ter-ext-list-row-description">
                            <div class="ter-ext-list-meta">
Markus Sommer's avatar
Markus Sommer committed
30
                                <f:translate key="by" />
31 32 33 34 35
                                {extension.lastVersion.author.name}
                            </div>
                            <terfe2:crop length="{settings.descriptionLength}">{extension.lastVersion.description}
                            </terfe2:crop>
                        </div>
36

37 38 39 40 41
                        <!-- General information -->
                        <div class="ter-ext-list-row-info ter-ext-info">
                            <table>
                                <tr>
                                    <th>
Markus Sommer's avatar
Markus Sommer committed
42
                                        <f:translate key="version" />
43 44
                                    </th>
                                    <td>{extension.lastVersion.versionString} <span
Markus Sommer's avatar
Markus Sommer committed
45
                                        class="ter-ext-state ter-ext-state-{extension.lastVersion.state}">{extension.lastVersion.state}</span>
46 47 48 49
                                    </td>
                                </tr>
                                <tr>
                                    <th>
Markus Sommer's avatar
Markus Sommer committed
50
                                        <f:translate key="last_updated" />
51 52 53 54 55 56 57 58 59
                                    </th>
                                    <td>
                                        <terfe2:dateTime format="{settings.dateFormat}">
                                            {extension.lastVersion.uploadDate}
                                        </terfe2:dateTime>
                                    </td>
                                </tr>
                                <tr>
                                    <th>
Markus Sommer's avatar
Markus Sommer committed
60
                                        <f:translate key="downloads" />
61 62 63 64 65
                                    </th>
                                    <td>{extension.downloads}</td>
                                </tr>
                                <tr>
                                    <th>
Markus Sommer's avatar
Markus Sommer committed
66
                                        <f:translate key="manual" />
67 68 69 70 71
                                    </th>
                                    <td>{documentationLink}</td>
                                </tr>
                            </table>
                        </div>
72

73
                    </div>
74

75 76 77 78
                    <div class="ter-ext-list-row-downloads">
                        <f:link.action controller="Extension" action="download"
                                       arguments="{extension : extension, versionString : extension.lastVersion.versionString, format : 't3x'}"
                                       class="ter-download-icon ter-download-icon-t3x">
Markus Sommer's avatar
Markus Sommer committed
79
                            <f:translate key="download_t3x" />
80 81 82 83 84
                        </f:link.action>
                        <f:if condition="{extension.lastVersion.hasZipFile}">
                            <f:link.action controller="Extension" action="download"
                                           arguments="{extension : extension, versionString : extension.lastVersion.versionString, format : 'zip'}"
                                           class="ter-download-icon ter-download-icon-zip">
Markus Sommer's avatar
Markus Sommer committed
85
                                <f:translate key="download_zip" />
86 87 88
                            </f:link.action>
                        </f:if>
                    </div>
sventb's avatar
sventb committed
89

90 91 92 93 94
                </div>
            </f:for>
        </f:widget.paginate>
    </f:then>
    <f:else>
Markus Sommer's avatar
Markus Sommer committed
95
        <f:translate key="msg.no_entries_found" />
96
    </f:else>
97
</f:if>