From 86805f9c5b077bd0e06676f7354ce33370c03b1d Mon Sep 17 00:00:00 2001
From: Cyperghost
Date: Wed, 6 Nov 2024 13:12:17 +0100
Subject: [PATCH] Add a new user menu item to manage the avatar
---
com.woltlab.wcf/page.xml | 15 +---------
com.woltlab.wcf/templates/pageHeaderUser.tpl | 12 ++++++++
com.woltlab.wcf/userMenu.xml | 6 +---
.../UserAvatarFileProcessor.class.php | 28 +++++++++++++------
wcfsetup/install/lang/de.xml | 1 +
wcfsetup/install/lang/en.xml | 1 +
6 files changed, 35 insertions(+), 28 deletions(-)
diff --git a/com.woltlab.wcf/page.xml b/com.woltlab.wcf/page.xml
index 59b2f271b0..856395a425 100644
--- a/com.woltlab.wcf/page.xml
+++ b/com.woltlab.wcf/page.xml
@@ -100,20 +100,6 @@
Benutzerkonto-Sicherheit
-
- system
- wcf\form\AvatarEditForm
- Avatar-Verwaltung
- Avatar Management
- 1
- com.woltlab.wcf.AccountManagement
-
- Avatar Management
-
-
- Avatar-Verwaltung
-
-
system
wcf\form\EmailActivationForm
@@ -888,6 +874,7 @@ E-Mail: [E-Mail-Adresse der verantwortlichen Stelle]
Verantwortliche Stell
+
diff --git a/com.woltlab.wcf/templates/pageHeaderUser.tpl b/com.woltlab.wcf/templates/pageHeaderUser.tpl
index 2038b6d5b3..b2a4490bb0 100644
--- a/com.woltlab.wcf/templates/pageHeaderUser.tpl
+++ b/com.woltlab.wcf/templates/pageHeaderUser.tpl
@@ -54,6 +54,18 @@
{/if}
+ {if $__wcf->getSession()->getPermission('user.profile.avatar.canUploadAvatar') && !$__wcf->getUserProfileHandler()->disableAvatar}
+
+ {/if}
{if $__wcf->session->getPermission('admin.general.canUseAcp')}