[TASK] Streamline ElementInformation template
[Packages/TYPO3.CMS.git] / typo3 / sysext / backend / Resources / Private / Templates / ContentElement / ElementInformation.html
1 {namespace core = TYPO3\CMS\Core\ViewHelpers}
2
3 <h1>
4 <f:if condition="{table}">
5 <small>{table}</small><br />{icon -> f:format.raw()}{title}
6 </f:if>
7 </h1>
8 <f:if condition="{missingFile}">
9 <f:be.infobox title="{f:translate(key:'LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:warning.file_missing')}" state="1">{missingFile}</f:be.infobox>
10 </f:if>
11 <f:if condition="{fileRenderer}">
12 <p>
13 {fileRenderer -> f:format.raw()}
14 </p>
15 </f:if>
16 <f:if condition="{fileObject}">
17 <p>
18 <f:media file="{fileObject}"
19 width="{width}"
20 height="{height}"
21 />
22 </p>
23 </f:if>
24 <f:if condition="{url}">
25 <p>
26 <a class="btn btn-default" href="{url}" target="_blank">
27 <core:icon identifier="actions-document-view" size="small" alternativeMarkupIdentifier="inline" />
28 <f:translate key="LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:labels.show" />
29 </a>
30 </p>
31 </f:if>
32 <div class="table-fit table-fit-wrap">
33 <table class="table table-striped table-hover">
34 <f:for each="{extraFields}" as="extraField">
35 <f:render section="extraFieldRow" arguments="{row: extraField}" />
36 </f:for>
37 <f:for each="{fields}" as="field">
38 <f:render section="fieldRow" arguments="{row: field}" />
39 </f:for>
40 </table>
41 </div>
42 <f:if condition="{returnUrl}">
43 <a class="btn btn-primary" href="{returnUrl}">
44 <core:icon identifier="actions-view-go-back" size="small" />
45 <f:translate key="LLL:EXT:lang/Resources/Private/Language/locallang_common.xlf:back" />
46 </a>
47 </f:if>
48 <f:if condition="{refLines}">
49 <h3><f:translate key="LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:show_item.php.referencesToThisItem" /></h3>
50 <div class="table-fit">
51 <table class="table table-striped table-hover">
52 <thead>
53 <tr>
54 <th class="col-icon"></th>
55 <th class="col-title"><f:translate key="LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:show_item.php.title" /></th>
56 <th><f:translate key="LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:show_item.php.table" /></th>
57 <th><f:translate key="LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:show_item.php.uid" /></th>
58 <th><f:translate key="LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:show_item.php.field" /></th>
59 <th><f:translate key="LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:show_item.php.flexpointer" /></th>
60 <th><f:translate key="LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:show_item.php.softrefKey" /></th>
61 <th><f:translate key="LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:show_item.php.sorting" /></th>
62 <th class="col-control"></th>
63 </tr>
64 </thead>
65 <tbody>
66 <f:for each="{refLines}" as="refLine">
67 <f:render section="refLineRow" arguments="{line: refLine}" />
68 </f:for>
69 </tbody>
70 </table>
71 </div>
72 </f:if>
73 <f:if condition="{refFromLines}">
74 <h3><f:translate key="LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:show_item.php.referencesFromThisItem" /></h3>
75 <div class="table-fit">
76 <table class="table table-striped table-hover">
77 <thead>
78 <tr>
79 <th class="col-icon"></th>
80 <th class="col-title"><f:translate key="LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:show_item.php.title" /></th>
81 <th><f:translate key="LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:show_item.php.table" /></th>
82 <th><f:translate key="LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:show_item.php.uid" /></th>
83 <th><f:translate key="LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:show_item.php.field" /></th>
84 <th><f:translate key="LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:show_item.php.flexpointer" /></th>
85 <th><f:translate key="LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:show_item.php.softrefKey" /></th>
86 <th><f:translate key="LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:show_item.php.sorting" /></th>
87 <th><f:translate key="LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:show_item.php.refString" /></th>
88 <th class="col-control"></th>
89 </tr>
90 </thead>
91 <tbody>
92 <f:for each="{refFromLines}" as="refFromLine">
93 <f:render section="refFromLineRow" arguments="{line: refFromLine}" />
94 </f:for>
95 </tbody>
96 </table>
97 </div>
98 </f:if>
99
100
101 <f:section name="extraFieldRow">
102 <tr>
103 <th class="col-nowrap">{row.fieldLabel}</th>
104 <td>
105 <f:if condition="{row.creatorRecord}">
106 <div class="media">
107 <div class="media-left">
108 {row.creatorRecord.icon -> f:format.raw()}
109 </div>
110 <div class="media-body">
111 <strong>{row.creatorRecord.username}</strong><br>
112 {row.creatorRecord.realName}
113 </div>
114 </div>
115 </f:if>
116 <f:if condition="{row.value}">
117 {row.value}
118 </f:if>
119 </td>
120 </tr>
121 </f:section>
122
123 <f:section name="fieldRow">
124 <tr>
125 <th class="col-nowrap">{row.fieldLabel}</th>
126 <td>{row.fieldValue}</td>
127 </tr>
128 </f:section>
129
130 <f:section name="refLineRow">
131 <tr>
132 <f:if condition="{line.record}">
133 <f:then>
134 <td class="col-icon"><a href="{line.url}" title="id={line.record.uid}">{line.icon -> f:format.raw()}</a></td>
135 <td class="col-title"><a href="{line.url}" title="id={line.record.uid}" >{line.recordTitle}</a></td>
136 <td>{line.title}</td>
137 <td><span title="{f:translate(key: 'LLL:EXT:lang/Resources/Private/Language/locallang_common.xlf:page')}: {line.parentRecordTitle} (uid={line.record.pid})">
138 {line.record.uid}
139 </span></td>
140 </f:then>
141 <f:else>
142 <td class="col-icon"></td>
143 <td class="col-title"><f:translate key="LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:show_item.php.missing_record" /> (uid={line.row.recuid}</td>
144 <td>{line.row.title}</td>
145 <td></td>
146 </f:else>
147 </f:if>
148 <td>{line.labelForTableColumn}</td>
149 <td>{line.row.flexpointer}</td>
150 <td>{line.row.softref_key}</td>
151 <td>{line.row.sorting}</td>
152 <td class="col-control">
153 <f:render section="action" arguments="{line: line.actions}" />
154 </td>
155 </tr>
156 </f:section>
157
158 <f:section name="refFromLineRow">
159 <tr>
160 <f:if condition="{line.record}">
161 <f:then>
162 <td class="col-icon"><a href="{line.url}" title="id={line.record.uid}">{line.icon -> f:format.raw()}</a></td>
163 <td class="col-title"><a href="{line.url}" title="id={line.record.uid}" >{line.recordTitle}</a></td>
164 <td>{line.title}</td>
165 <td>{line.row.ref_uid}</td>
166 </f:then>
167 <f:else>
168 <td class="col-icon"></td>
169 <td class="col-title"><f:translate key="LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:show_item.php.missing_record" /> (uid={line.row.recuid}</td>
170 <td>{line.row.title}</td>
171 <td></td>
172 </f:else>
173 </f:if>
174 <td>{line.labelForTableColumn}</td>
175 <td>{line.row.flexpointer}</td>
176 <td>{line.row.softref_key}</td>
177 <td>{line.row.sorting}</td>
178 <td>{line.row.ref_string}</td>
179 <td class="col-control">
180 <f:render section="action" arguments="{line: line.actions}" />
181 </td>
182 </tr>
183 </f:section>
184
185 <f:section name="action">
186 <div class="btn-group" role="group">
187 <f:if condition="{line.webListUrl}">
188 <a class="btn btn-default btn-sm" href="#" onclick="{line.viewOnClick}" title="{f:translate(key: 'LLL:EXT:lang/Resources/Private/Language/locallang_common.xlf:labels.showPage')}">
189 <core:icon identifier="actions-document-view" size="small" />
190 </a>
191 </f:if>
192 <a class="btn btn-default btn-sm" href="{line.recordEditUrl}">
193 <core:icon identifier="actions-open" size="small" />
194 </a>
195 </div>
196 <div class="btn-group" role="group">
197 <a class="btn btn-default btn-sm" href="{line.recordHistoryUrl}">
198 <core:icon identifier="actions-document-history-open" size="small" />
199 </a>
200 </div>
201 <f:if condition="{line.webListUrl}">
202 <div class="btn-group" role="group">
203 <a class="btn btn-default btn-sm" href="{line.webListUrl}" title="{f:translate(key: 'LLL:EXT:lang/Resources/Private/Language/locallang_common.xlf:labels.showList')}">
204 <core:icon identifier="actions-system-list-open" size="small" />
205 </a>
206 </div>
207 </f:if>
208 </f:section>