]> source.dussan.org Git - nextcloud-server.git/commitdiff
enh(settings): Set main heading for User management
authorChristopher Ng <chrng8@gmail.com>
Fri, 8 Dec 2023 02:53:32 +0000 (18:53 -0800)
committerbackportbot-nextcloud[bot] <backportbot-nextcloud[bot]@users.noreply.github.com>
Fri, 8 Dec 2023 16:15:40 +0000 (16:15 +0000)
Signed-off-by: Christopher Ng <chrng8@gmail.com>
apps/settings/src/views/Users.vue

index 831663248a3c618002ba993ed424ea02ba72c75c..dc17b9f936202d4a6c6170377debc267de1c0693 100644 (file)
                                </template>
                        </NcAppNavigation>
 
-                       <NcAppContent>
+                       <NcAppContent :page-heading="pageHeading">
                                <UserList :selected-group="selectedGroupDecoded"
                                        :external-actions="externalActions" />
                        </NcAppContent>
@@ -212,6 +212,17 @@ export default {
        },
 
        computed: {
+               pageHeading() {
+                       if (this.selectedGroupDecoded === null) {
+                               return t('settings', 'Active users')
+                       }
+                       const matchHeading = {
+                               admin: t('settings', 'Admins'),
+                               disabled: t('settings', 'Disabled users'),
+                       }
+                       return matchHeading[this.selectedGroupDecoded] ?? t('settings', 'User group: {group}', { group: this.selectedGroupDecoded })
+               },
+
                showConfig() {
                        return this.$store.getters.getShowConfig
                },