From 84f9fc4958d360d1206560b4050da2f49142bc50 Mon Sep 17 00:00:00 2001 From: Matthias Schmidt Date: Thu, 10 Jul 2014 22:38:03 +0200 Subject: [PATCH] Add canViewTag permission --- com.woltlab.wcf/templates/tagInput.tpl | 41 ++++++++++--------- com.woltlab.wcf/userGroupOption.xml | 8 ++++ .../files/lib/page/TaggedPage.class.php | 5 +++ 3 files changed, 35 insertions(+), 19 deletions(-) diff --git a/com.woltlab.wcf/templates/tagInput.tpl b/com.woltlab.wcf/templates/tagInput.tpl index dd779043c3..aeb8daaf84 100644 --- a/com.woltlab.wcf/templates/tagInput.tpl +++ b/com.woltlab.wcf/templates/tagInput.tpl @@ -1,19 +1,22 @@ -
-
-
-
- - {lang}wcf.tagging.tags.description{/lang} -
-
- \ No newline at end of file +{if $__wcf->session->getPermission('user.tag.canViewTag')} +
+
+
+
+ + {lang}wcf.tagging.tags.description{/lang} +
+
+ + +{/if} diff --git a/com.woltlab.wcf/userGroupOption.xml b/com.woltlab.wcf/userGroupOption.xml index 65706b31e9..1141a04be6 100644 --- a/com.woltlab.wcf/userGroupOption.xml +++ b/com.woltlab.wcf/userGroupOption.xml @@ -734,6 +734,14 @@ png]]> 1 1 + + + diff --git a/wcfsetup/install/files/lib/page/TaggedPage.class.php b/wcfsetup/install/files/lib/page/TaggedPage.class.php index 45f766129f..7591f65654 100644 --- a/wcfsetup/install/files/lib/page/TaggedPage.class.php +++ b/wcfsetup/install/files/lib/page/TaggedPage.class.php @@ -22,6 +22,11 @@ class TaggedPage extends MultipleLinkPage { */ public $neededModules = array('MODULE_TAGGING'); + /** + * @see \wcf\page\AbstractPage::$neededPermissions + */ + public $neededPermissions = array('user.tag.canViewTag'); + /** * tag id * @var integer -- 2.20.1