Der Datentyp ezauthor (Autoren)
Klasse eZAuthorType in kernel/classes/datatypes/ezauthor/ezauthortype.php; Bezeichner ezauthor, aufgeführt in settings/content.ini [DataTypeSettings] AvailableDataTypes[].
Was er speichert
Die Spalten der Attributtabellen, die seine Klasse liest oder schreibt: data_text (data_text, data_int, data_float und sort_key_* gehören zum Objektattribut; data_text1 ... data_int4 sind die Einstellungen des Klassenattributs). Durch Lesen der Klasse ermittelt: eine Heuristik.
Er ist von der Suche indiziert.
In Templates
my_attribute steht für den Bezeichner eines Attributs dieses Typs in Ihrer Klasse:
def $attribute = $node.data_map.my_attribute
if $attribute.has_content
attribute_view_gui attribute=$attribute
/if
{* der Wert, wie der Datentyp ihn zurückgibt (objectAttributeContent()) *}
$attribute.content|attribute( show, 1 )Das ausgelieferte Template, das ihn anzeigt (attribute_view_gui), design/standard/templates/content/datatype/view/ezauthor.tpl:
{* DO NOT EDIT THIS FILE! Use an override template instead. *}
section var=Authors loop=$attribute.content.author_list
$Authors.item.name|wash( xhtml ) <$Authors.item.email|wash( email )>delimiter,/delimiter
/sectionDas ausgelieferte Template, das ihn bearbeitet (attribute_edit_gui), design/standard/templates/content/datatype/edit/ezauthor.tpl (die ersten 25 Zeilen):
{* DO NOT EDIT THIS FILE! Use an override template instead. *}
default attribute_base=ContentObjectAttribute
section show=$attribute.content.author_list
<table class="list" cellspacing="0">
<tr>
<th class="tight"> </th>
<th>'Name'|i18n( 'design/standard/content/datatype' )</th>
<th>'Email'|i18n( 'design/standard/content/datatype' )</th>
</tr>
section name=Author loop=$attribute.content.author_list sequence=array( bglight, bgdark )
<tr class="$Author:sequence">
{* Remove. *}
<td><input id="ezcoa-if ne( $attribute_base, 'ContentObjectAttribute' )$attribute_base-/if$attribute.contentclassattribute_id_$attribute.contentclass_attribute_identifier_check_$Author:index" class="ezcc-$attribute.object.content_class.identifier ezcca-$attribute.object.content_class.identifier_$attribute.contentclass_attribute_identifier" type="checkbox" name="$attribute_base_data_author_remove_$attribute.id[]" value="$Author:item.id|wash" title="'Select author row for removal.'|i18n( 'design/standard/content/datatype' )" /></td>
{* Name. *}
<td>
<input id="ezcoa-if ne( $attribute_base, 'ContentObjectAttribute' )$attribute_base-/if$attribute.contentclassattribute_id_$attribute.contentclass_attribute_identifier_name_$Author:index" class="box ezcc-$attribute.object.content_class.identifier ezcca-$attribute.object.content_class.identifier_$attribute.contentclass_attribute_identifier" type="text" name="$attribute_base_data_author_name_$attribute.id[]" value="$Author:item.name|wash" />
<input type="hidden" name="$attribute_base_data_author_id_$attribute.id[]" value="$Author:item.id|wash" />
</td>
{* Email. *}
<td><input id="ezcoa-if ne( $attribute_base, 'ContentObjectAttribute' )$attribute_base-/if$attribute.contentclassattribute_id_$attribute.contentclass_attribute_identifier_email_$Author:index" class="box ezcc-$attribute.object.content_class.identifier ezcca-$attribute.object.content_class.identifier_$attribute.contentclass_attribute_identifier" type="text" name="$attribute_base_data_author_email_$attribute.id[]" value="$Author:item.email|wash" /></td>
Überschreiben Sie sie für ein Klassenattribut in einer override.ini.append.php mit Source=content/datatype/view/ezauthor.tpl und einer Bedingung auf attribute_identifier (siehe Ein Template-Override).
Siehe auch
Erzeugt von ./console exp:help:examples --language=ger-de aus kernel/classes/datatypes/ezauthor/ezauthortype.php, settings/content.ini, design/standard/templates/content/datatype/view/ezauthor.tpl, design/standard/templates/content/datatype/edit/ezauthor.tpl. Bearbeiten Sie diese Seite nicht: Ändern Sie die Quelle oder die deutsche Übersetzung und erzeugen Sie sie neu (wie). Freie Dokumentation: GFDL 1.3 oder später.