silverstripe-framework/templates/TableListField.ss
Ingo Schommer 00ffe72944 Translations: Switch to Transifex format
- Based on new (last) translation download from getlocalization.com
- Removed untranslated strings. Getlocalization started including those at some point
which is highly annoying, unnecessary and breaks the new transfix system,
since it'll mark all of the english strings as actual translations
- Avoid dots in entities. It confuses the Transifex YML parser
- Removed some locales unknown to Transifex which didn't have any translations anyway
- Removed "lolcat" locale, uses custom notation (en@lolcal)
  which SilverStripe's i18n system can't handle
  (needs mapping from SS naming to Zend naming)
- Renamed "Te Reo/Maori" locale from "mi_NZ" to "mi" (Transifex/CLDR notation)
- Namespaced all entities used in templates (deprecated usage)
- Converted dots to underscores where template filenames are used for namespaces,
since Transifex YML parsing handles them as separate YML keys otherwise
- Removed whitespace in entity names, SilverStripe i18n can't handle it
- Only allow selection of locales registered through i18n::$all_locales to avoid
  issues with unknown locales in Zend's CLDR database
2013-08-07 00:25:16 +02:00

86 lines
2.4 KiB
Scheme

<div id="$id" class="$CSSClasses $extraClass field nolabel">
<% if Print %><% else %>
<% if Markable %>
<% include TableListField_SelectOptions %>
<% end_if %>
<% include TableListField_PageControls %>
<% end_if %>
<table class="data">
<thead>
<tr>
<% if Markable %><th width="16"><% if MarkableTitle %>$MarkableTitle<% else %>&nbsp;<% end_if %></th><% end_if %>
<% if Print %>
<% loop Headings %>
<th class="$Name">
$Title
</th>
<% end_loop %>
<% else %>
<% loop Headings %>
<th class="$Name">
<% if IsSortable %>
<span class="sortTitle">
<a href="$SortLink">$Title</a>
</span>
<span class="sortLink <% if SortBy %><% else %>sortLinkHidden<% end_if %>">
<% if SortDirection = desc %>
<a href="$SortLink"><img src="$ModulePath(framework)/images/bullet_arrow_up.png" alt="<% _t('TableListField_ss.SORTDESC', 'Sort in descending order') %>" /></a>
<% else %>
<a href="$SortLink"><img src="$ModulePath(framework)/images/bullet_arrow_down.png" alt="<% _t('TableListField_ss.SORTASC', 'Sort in ascending order') %>" /></a>
<% end_if %>
</a>
&nbsp;
</span>
<% else %>
<span>$Title</span>
<% end_if %>
</th>
<% end_loop %>
<% end_if %>
<% if Can(delete) %><th width="18">&nbsp;</th><% end_if %>
</tr>
</thead>
<% if HasSummary %>
<tfoot>
<tr class="summary">
<% include TableListField_Summary %>
</tr>
</tfoot>
<% end_if %>
<tbody>
<% if HasGroupedItems %>
<% loop GroupedItems %>
<% loop Items %>
<% include TableListField_Item %>
<% end_loop %>
<tr class="summary partialSummary">
<% include TableListField_Summary %>
</tr>
<% end_loop %>
<% else %>
<% if Items %>
<% loop Items %>
<% include TableListField_Item %>
<% end_loop %>
<% else %>
<tr class="notfound">
<% if Markable %><th width="18">&nbsp;</th><% end_if %>
<td colspan="$Headings.Count"><i><% _t('TableListField_ss.NOITEMSFOUND','No items found') %></i></td>
<% if Can(delete) %><td width="18">&nbsp;</td><% end_if %>
</tr>
<% end_if %>
<% if Can(add) %>
$AddRecordAsTableRow
<% end_if %>
<% end_if %>
</tbody>
</table>
<% if Print %><% else %><div class="utility">
<% loop Utility %>
<span class="item"><a href="$Link">$Title</a></span>
<% end_loop %>
</div><% end_if %>
</div>