From: Matthias Schmidt Date: Tue, 27 Dec 2011 16:19:53 +0000 (+0100) Subject: Replaces template variables with template events X-Git-Tag: 2.0.0_Beta_1~1472^2~1^2 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=5348d3d2dd576d18b2f9d5f72b80b029633c9436;p=GitHub%2FWoltLab%2FWCF.git Replaces template variables with template events I mostly replaced existing template variables with events and added some new events for consistency reasons. --- diff --git a/wcfsetup/install/files/acp/templates/acpSessionLog.tpl b/wcfsetup/install/files/acp/templates/acpSessionLog.tpl index 13cf6f6367..a964177296 100644 --- a/wcfsetup/install/files/acp/templates/acpSessionLog.tpl +++ b/wcfsetup/install/files/acp/templates/acpSessionLog.tpl @@ -28,7 +28,7 @@ {lang}wcf.acp.sessionLog.requestURI{/lang}{if $sortField == 'requestURI'} {/if} {lang}wcf.acp.sessionLog.requestMethod{/lang}{if $sortField == 'requestMethod'} {/if} - {if $additionalColumnHeads|isset}{@$additionalColumnHeads}{/if} + {event name='headColumns'} @@ -43,8 +43,8 @@

{$sessionAccessLog->className}

{if !$sessionAccessLog->hasProtectedURI()}{$sessionAccessLog->requestURI|truncate:50}{else}{$sessionAccessLog->requestURI|truncate:50}{/if}

{$sessionAccessLog->requestMethod}

- - {if $additionalColumns.$sessionAccessLog->sessionAccessLogID|isset}{@$additionalColumns.$sessionAccessLog->sessionAccessLogID}{/if} + + {event name='columns'} {/foreach} {/content} diff --git a/wcfsetup/install/files/acp/templates/acpSessionLogList.tpl b/wcfsetup/install/files/acp/templates/acpSessionLogList.tpl index f007cb9a63..798b266e92 100644 --- a/wcfsetup/install/files/acp/templates/acpSessionLogList.tpl +++ b/wcfsetup/install/files/acp/templates/acpSessionLogList.tpl @@ -28,7 +28,7 @@ {lang}wcf.acp.sessionLog.lastActivityTime{/lang}{if $sortField == 'lastActivityTime'} {/if} {lang}wcf.acp.sessionLog.accesses{/lang}{if $sortField == 'accesses'} {/if} - {if $additionalColumnHeads|isset}{@$additionalColumnHeads}{/if} + {event name='headColumns'} @@ -44,7 +44,7 @@

{@$sessionLog->lastActivityTime|time}

{#$sessionLog->accesses}

- {if $additionalColumns.$sessionLog->sessionLogID|isset}{@$additionalColumns.$sessionLog->sessionLogID}{/if} + {event name='columns'} {/foreach} {/content} diff --git a/wcfsetup/install/files/acp/templates/cacheList.tpl b/wcfsetup/install/files/acp/templates/cacheList.tpl index 85b88052d1..14bbcee9dc 100644 --- a/wcfsetup/install/files/acp/templates/cacheList.tpl +++ b/wcfsetup/install/files/acp/templates/cacheList.tpl @@ -45,14 +45,15 @@
{#$cacheData.files}
{/if} - {if $additionalFields|isset}{@$additionalFields}{/if} + {event name='dataFields'}
@@ -100,7 +101,8 @@ diff --git a/wcfsetup/install/files/acp/templates/cronjobAdd.tpl b/wcfsetup/install/files/acp/templates/cronjobAdd.tpl index b879cb716a..c6eee63c1d 100644 --- a/wcfsetup/install/files/acp/templates/cronjobAdd.tpl +++ b/wcfsetup/install/files/acp/templates/cronjobAdd.tpl @@ -22,7 +22,11 @@ @@ -55,6 +59,8 @@ + + {event name='dataFields'}
@@ -124,9 +130,11 @@ {lang}wcf.acp.cronjob.startDow.description{/lang} + + {event name='timingFields'}
- {if $additionalFields|isset}{@$additionalFields}{/if} + {event name='fieldsets'}
diff --git a/wcfsetup/install/files/acp/templates/cronjobList.tpl b/wcfsetup/install/files/acp/templates/cronjobList.tpl index 6ee91b01b7..d0939b6992 100644 --- a/wcfsetup/install/files/acp/templates/cronjobList.tpl +++ b/wcfsetup/install/files/acp/templates/cronjobList.tpl @@ -37,13 +37,19 @@
{pages print=true assign=pagesLinks controller="CronjobList" link="pageNo=%d&sortField=$sortField&sortOrder=$sortOrder"} - {if $__wcf->session->getPermission('admin.system.cronjob.canAddCronjob')} + {hascontent} - {/if} + {/hascontent}
{hascontent} @@ -64,7 +70,7 @@ {lang}wcf.acp.cronjob.description{/lang}{if $sortField == 'description'} {/if} {lang}wcf.acp.cronjob.nextExec{/lang}{if $sortField == 'nextExec'} {/if} - {if $additionalHeadColumns|isset}{@$additionalHeadColumns}{/if} + {event name='headColumns'} @@ -99,7 +105,8 @@ {else} {/if} - {if $additionalButtons[$cronjob->cronjobID]|isset}{@$additionalButtons[$cronjob->cronjobID]}{/if} + + {event name='buttons'}

{@$cronjob->cronjobID}

{$cronjob->startMinute|truncate:30:' ...'}

@@ -120,7 +127,7 @@ {/if} - {if $additionalColumns[$cronjob->cronjobID]|isset}{@$additionalColumns[$cronjob->cronjobID]}{/if} + {event name='columns'} {/foreach} {/content} @@ -132,6 +139,7 @@
diff --git a/wcfsetup/install/files/acp/templates/packageUninstallationDependencies.tpl b/wcfsetup/install/files/acp/templates/packageUninstallationDependencies.tpl index b5ad9c4a46..9f05aa6892 100644 --- a/wcfsetup/install/files/acp/templates/packageUninstallationDependencies.tpl +++ b/wcfsetup/install/files/acp/templates/packageUninstallationDependencies.tpl @@ -60,7 +60,7 @@
{if $packageObj->authorURL}{$packageObj->author}{else}{$packageObj->author}{/if}
- {if $additionalFields|isset}{@$additionalFields}{/if} + {event name='propertyFields'} {if $dependentPackages|count > 0} @@ -84,7 +84,7 @@ {lang}wcf.acp.package.list.version{/lang} {lang}wcf.acp.package.list.date{/lang} - {if $additionalColumns|isset}{@$additionalColumns}{/if} + {event name='headColumns'} @@ -103,7 +103,7 @@ {/if} - {if $package.additionalButtons|isset}{@$package.additionalButtons}{/if} + {event name='buttons'}

{@$package.packageID}

@@ -120,7 +120,7 @@

{$package.packageVersion}

{@$package.packageDate|date}

- {if $package.additionalColumns|isset}{@$package.additionalColumns}{/if} + {event name='columns'} {/foreach} diff --git a/wcfsetup/install/files/acp/templates/packageView.tpl b/wcfsetup/install/files/acp/templates/packageView.tpl index edcb48d14f..f6ab9fd515 100644 --- a/wcfsetup/install/files/acp/templates/packageView.tpl +++ b/wcfsetup/install/files/acp/templates/packageView.tpl @@ -91,7 +91,7 @@
{if $package->authorURL}{$package->author}{else}{$package->author}{/if}
- {if $additionalFields|isset}{@$additionalFields}{/if} + {event name='propertyFields'} {if $package->packageDescription} @@ -127,8 +127,8 @@ {lang}wcf.acp.package.list.author{/lang} {lang}wcf.acp.package.list.version{/lang} {lang}wcf.acp.package.list.date{/lang} - - {if $additionalColumns|isset}{@$additionalColumns}{/if} + + {event name='requirementHeadColumns'} @@ -162,6 +162,8 @@ {if $requiredPackage.authorURL}

{$requiredPackage.author}{else}{$requiredPackage.author}

{/if}

{$requiredPackage.packageVersion}

{@$requiredPackage.packageDate|date}

+ + {event name='requirementColumns'} {/foreach} {/content} @@ -185,8 +187,8 @@ {lang}wcf.acp.package.list.author{/lang} {lang}wcf.acp.package.list.version{/lang} {lang}wcf.acp.package.list.date{/lang} - - {if $additionalColumns|isset}{@$additionalColumns}{/if} + + {event name='dependencyHeadColumns'} @@ -220,6 +222,8 @@ {if $dependentPackage.authorURL}

{$dependentPackage.author}{else}{$dependentPackage.author}

{/if}

{$dependentPackage.packageVersion}

{@$dependentPackage.packageDate|date}

+ + {event name='dependencyColumns'} {/foreach} {/content} @@ -239,17 +243,28 @@ {/if} {/foreach} - +{hascontent} + +{/hascontent} {include file='footer'} diff --git a/wcfsetup/install/files/acp/templates/updateServerAdd.tpl b/wcfsetup/install/files/acp/templates/updateServerAdd.tpl index 832f97ae56..502ac14df5 100644 --- a/wcfsetup/install/files/acp/templates/updateServerAdd.tpl +++ b/wcfsetup/install/files/acp/templates/updateServerAdd.tpl @@ -23,6 +23,8 @@
@@ -65,9 +67,10 @@ - {if $additionalFields|isset}{@$additionalFields}{/if} + {event name='dataFields'} + {event name='fieldsets'}
diff --git a/wcfsetup/install/files/acp/templates/updateServerList.tpl b/wcfsetup/install/files/acp/templates/updateServerList.tpl index 61ba2b52d3..51f7f3d3a6 100644 --- a/wcfsetup/install/files/acp/templates/updateServerList.tpl +++ b/wcfsetup/install/files/acp/templates/updateServerList.tpl @@ -26,6 +26,8 @@
@@ -46,7 +48,7 @@ {lang}wcf.acp.updateServer.errorMessage{/lang}{if $sortField == 'errorMessage'} {/if} {lang}wcf.acp.updateServer.lastUpdateTime{/lang}{if $sortField == 'lastUpdateTime'} {/if} - {if $additionalHeadColumns|isset}{@$additionalHeadColumns}{/if} + {event name='headColumns'} @@ -59,7 +61,7 @@ - {if $additionalButtons[$updateServer->packageUpdateServerID]|isset}{@$additionalButtons[$updateServer->packageUpdateServerID]}{/if} + {event name='buttons'}

{@$updateServer->packageUpdateServerID}

{$updateServer->serverURL}

@@ -68,7 +70,7 @@

{@$updateServer->errorMessage|truncate:"30"}

{if $updateServer->lastUpdateTime}{@$updateServer->lastUpdateTime|time}{/if}

- {if $additionalColumns[$updateServer->packageUpdateServerID]|isset}{@$additionalColumns[$updateServer->packageUpdateServerID]}{/if} + {event name='columns'} {/foreach} {/content} @@ -83,6 +85,8 @@ diff --git a/wcfsetup/install/files/acp/templates/userAdd.tpl b/wcfsetup/install/files/acp/templates/userAdd.tpl index 9e7169b66e..6549be3706 100644 --- a/wcfsetup/install/files/acp/templates/userAdd.tpl +++ b/wcfsetup/install/files/acp/templates/userAdd.tpl @@ -32,7 +32,8 @@ @@ -142,7 +143,7 @@ {/if} - {if $additionalFields|isset}{@$additionalFields}{/if} + {event name='fieldsets'} {if $optionTree|count || $additionalTabs|isset}
diff --git a/wcfsetup/install/files/acp/templates/userGroupAdd.tpl b/wcfsetup/install/files/acp/templates/userGroupAdd.tpl index b51ee8b014..4779bb6160 100644 --- a/wcfsetup/install/files/acp/templates/userGroupAdd.tpl +++ b/wcfsetup/install/files/acp/templates/userGroupAdd.tpl @@ -35,7 +35,8 @@
@@ -63,10 +64,10 @@ - {if $additionalFields|isset}{@$additionalFields}{/if} + {event name='dataFields'} - {if $additionalFieldSets|isset}{@$additionalFieldSets}{/if} + {event name='fieldsets'}
@@ -30,7 +31,7 @@ {lang}wcf.acp.group.groupName{/lang}{if $sortField == 'groupName'} {/if} {lang}wcf.acp.group.members{/lang}{if $sortField == 'members'} {/if} - {if $additionalHeadColumns|isset}{@$additionalHeadColumns}{/if} + {event name='headColumns'} @@ -49,14 +50,14 @@ {else} {/if} - - {if $additionalButtons[$group->groupID]|isset}{@$additionalButtons[$group->groupID]}{/if} + + {event name='buttons'}

{@$group->groupID}

{if $group->isEditable()}

{lang}{$group->groupName}{/lang}{else}{lang}{$group->groupName}{/lang}

{/if}

{#$group->members}

- {if $additionalColumns[$group->groupID]|isset}{@$additionalColumns[$group->groupID]}{/if} + {event name='columns'} {/foreach} {/content} @@ -70,7 +71,8 @@ diff --git a/wcfsetup/install/files/acp/templates/userList.tpl b/wcfsetup/install/files/acp/templates/userList.tpl index fe4793735f..283052bb4f 100644 --- a/wcfsetup/install/files/acp/templates/userList.tpl +++ b/wcfsetup/install/files/acp/templates/userList.tpl @@ -28,7 +28,8 @@
  • {lang}wcf.acp.user.add{/lang}
  • {/if}
  • {lang}wcf.acp.user.search{/lang}
  • - {if $additionalLargeButtons|isset}{@$additionalLargeButtons}{/if} + + {event name='largeButtons'} @@ -37,7 +38,8 @@ @@ -53,7 +55,7 @@ {lang}{$columnLanguageVariable}{/lang}{if $sortField == $column} {/if} {/foreach} - {if $additionalColumnHeads|isset}{@$additionalColumnHeads}{/if} + {event name='headColumns'} @@ -74,7 +76,7 @@ {/if} - {if $additionalButtons[$user->userID]|isset}{@$additionalButtons[$user->userID]}{/if} + {event name='buttons'}

    {@$user->userID}

    {if $user->editable}{$user->username}{else}{$user->username}{/if}

    @@ -83,7 +85,7 @@

    {if $columnValues[$user->userID][$column]|isset}{@$columnValues[$user->userID][$column]}{/if}

    {/foreach} - {if $additionalColumns[$user->userID]|isset}{@$additionalColumns[$user->userID]}{/if} + {event name='columns'} {/foreach} {/content} @@ -103,7 +105,8 @@
  • {lang}wcf.acp.user.add{/lang}
  • {/if}
  • {lang}wcf.acp.user.search{/lang}
  • - {if $additionalLargeButtons|isset}{@$additionalLargeButtons}{/if} + + {event name='largeButtons'} diff --git a/wcfsetup/install/files/acp/templates/userMail.tpl b/wcfsetup/install/files/acp/templates/userMail.tpl index 22c8e375f2..509010dd31 100644 --- a/wcfsetup/install/files/acp/templates/userMail.tpl +++ b/wcfsetup/install/files/acp/templates/userMail.tpl @@ -36,7 +36,8 @@ @@ -145,9 +146,10 @@ - {if $additionalFields|isset}{@$additionalFields}{/if} + {event name='mailFields'} + {event name='fieldsets'}
    diff --git a/wcfsetup/install/files/acp/templates/userSearch.tpl b/wcfsetup/install/files/acp/templates/userSearch.tpl index 6c440af346..874af1a1d2 100644 --- a/wcfsetup/install/files/acp/templates/userSearch.tpl +++ b/wcfsetup/install/files/acp/templates/userSearch.tpl @@ -32,6 +32,8 @@
  • {lang}wcf.acp.user.add{/lang}
  • {/if}
  • {lang}wcf.acp.menu.link.user.list{/lang}
  • + + {event name='largeButtons'}
    @@ -108,13 +110,17 @@ {/if} - {if $additionalFields|isset}{@$additionalFields}{/if} + {event name='fieldsets'}
    @@ -128,7 +134,7 @@
    {/if} - {if $additionalTabContents|isset}{@$additionalTabContents}{/if} + {event name='tabMenuContent'}