From 9a81ff78df78392541b372cef4c6679e6464201c Mon Sep 17 00:00:00 2001 From: IlhemEssaadi Date: Wed, 11 Oct 2023 12:18:08 +0100 Subject: [PATCH] feat: Add wallet and reward nodes to platform settings navigation - EXO-66546 - Meeds-io/MIPs#88 --- translations.properties | 1 + .../portal/administration_en.properties | 20 +++++++ .../conf/wallet/portal-configuration.xml | 32 ++++++++++ .../portal/administration/navigation.xml | 51 ++++++++++++++++ .../portal/portal/administration/pages.xml | 60 +++++++++++++++++++ 5 files changed, 164 insertions(+) create mode 100644 wallet-webapps/src/main/resources/locale/navigation/portal/administration_en.properties create mode 100644 wallet-webapps/src/main/webapp/WEB-INF/conf/wallet/portal/portal/administration/navigation.xml create mode 100644 wallet-webapps/src/main/webapp/WEB-INF/conf/wallet/portal/portal/administration/pages.xml diff --git a/translations.properties b/translations.properties index da338d5e40..e328bf544d 100644 --- a/translations.properties +++ b/translations.properties @@ -26,3 +26,4 @@ Portlets.properties=wallet-services/src/main/resources/locale/portlet/Portlets_e webui_en.properties=wallet-webapps/src/main/resources/locale/navigation/portal/global_en.properties RewardingGroupNavigation.properties=wallet-webapps/src/main/resources/locale/navigation/group/platform/rewarding_en.properties NotificationAdministration.properties=wallet-webapps/src/main/resources/locale/portlet/NotificationAdministration_en.properties +navigation/administration.properties=wallet-webapps/src/main/resources/locale/navigation/portal/administration_en.properties \ No newline at end of file diff --git a/wallet-webapps/src/main/resources/locale/navigation/portal/administration_en.properties b/wallet-webapps/src/main/resources/locale/navigation/portal/administration_en.properties new file mode 100644 index 0000000000..a5e123f9e6 --- /dev/null +++ b/wallet-webapps/src/main/resources/locale/navigation/portal/administration_en.properties @@ -0,0 +1,20 @@ +# +# This file is part of the Meeds project (https://meeds.io/). +# Copyright (C) 2023 Meeds Association +# contact@meeds.io +# This program is free software; you can redistribute it and/or +# modify it under the terms of the GNU Lesser General Public +# License as published by the Free Software Foundation; either +# version 3 of the License, or (at your option) any later version. +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# Lesser General Public License for more details. +# You should have received a copy of the GNU Lesser General Public License +# along with this program; if not, write to the Free Software Foundation, +# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. +# +portal.administration.home=Platform settings +portal.administration.recognition=Recognition +portal.administration.wallet=Wallet +portal.administration.reward=Reward diff --git a/wallet-webapps/src/main/webapp/WEB-INF/conf/wallet/portal-configuration.xml b/wallet-webapps/src/main/webapp/WEB-INF/conf/wallet/portal-configuration.xml index 64765a98b5..04e884bfaa 100644 --- a/wallet-webapps/src/main/webapp/WEB-INF/conf/wallet/portal-configuration.xml +++ b/wallet-webapps/src/main/webapp/WEB-INF/conf/wallet/portal-configuration.xml @@ -77,5 +77,37 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + + new.portal.config.user.listener + initListener + org.exoplatform.portal.config.NewPortalConfigListener + this listener init the portal configuration + + + portal.configuration + + + + + administration + + + + + portal + + + war:/conf/wallet/portal + + + ${exo.wallet.portalConfig.administration.override:true} + + + ${exo.wallet.portalConfig.administration.importmode:merge} + + + + + \ No newline at end of file diff --git a/wallet-webapps/src/main/webapp/WEB-INF/conf/wallet/portal/portal/administration/navigation.xml b/wallet-webapps/src/main/webapp/WEB-INF/conf/wallet/portal/portal/administration/navigation.xml new file mode 100644 index 0000000000..93df4635ed --- /dev/null +++ b/wallet-webapps/src/main/webapp/WEB-INF/conf/wallet/portal/portal/administration/navigation.xml @@ -0,0 +1,51 @@ + + + + 3 + + + + home + + fas fa-cog + + recognition + + fas fa-trophy + + wallet + + fas fa-wallet + portal::administration::walletAdministration + + + reward + + fas fa-coins + portal::administration::rewardAdministration + + + + + diff --git a/wallet-webapps/src/main/webapp/WEB-INF/conf/wallet/portal/portal/administration/pages.xml b/wallet-webapps/src/main/webapp/WEB-INF/conf/wallet/portal/portal/administration/pages.xml new file mode 100644 index 0000000000..693686a8b1 --- /dev/null +++ b/wallet-webapps/src/main/webapp/WEB-INF/conf/wallet/portal/portal/administration/pages.xml @@ -0,0 +1,60 @@ + + + + + walletAdministration + Wallet adminsitration + *:/platform/rewarding + manager:/platform/rewarding + + *:/platform/users + + + wallet + WalletAdmin + + Wallet adminsitration + *:/platform/rewarding + false + + + + + rewardAdministration + Reward administration + *:/platform/rewarding + manager:/platform/rewarding + + *:/platform/users + + + wallet + RewardAdmin + + Reward administration + *:/platform/rewarding + false + + + + \ No newline at end of file