diff --git a/.github/workflows/build_and_test.yml b/.github/workflows/build_and_test.yml index 2d74d00f0e17..9b27cdbd7daf 100644 --- a/.github/workflows/build_and_test.yml +++ b/.github/workflows/build_and_test.yml @@ -4,7 +4,7 @@ on: release: types: [published] pull_request: - branches: '**' + branches: 'develop' push: branches: - develop diff --git a/app/authorization/server/startup.js b/app/authorization/server/startup.js index 16b2f8906580..1d1be2167446 100644 --- a/app/authorization/server/startup.js +++ b/app/authorization/server/startup.js @@ -72,6 +72,8 @@ Meteor.startup(function() { { _id: 'user-generate-access-token', roles: ['admin'] }, { _id: 'view-d-room', roles: ['admin', 'user', 'bot', 'app', 'guest'] }, { _id: 'view-full-other-user-info', roles: ['admin'] }, + { _id: 'view-full-other-user-info_last_login', roles: ['admin'] }, + { _id: 'view-full-other-user-info_created_at', roles: ['admin'] }, { _id: 'view-history', roles: ['admin', 'user', 'anonymous'] }, { _id: 'view-joined-room', roles: ['guest', 'bot', 'app', 'anonymous'] }, { _id: 'view-join-code', roles: ['admin'] }, diff --git a/app/ui-flextab/client/tabs/userInfo.html b/app/ui-flextab/client/tabs/userInfo.html index 69e6128cf614..f54466616c42 100644 --- a/app/ui-flextab/client/tabs/userInfo.html +++ b/app/ui-flextab/client/tabs/userInfo.html @@ -81,14 +81,18 @@

{{/if}} {{#if createdAt}} -
- - -
-
- - -
+ {{#if hasPermission 'view-full-other-user-info_created_at'}} +
+ + +
+ {{/if}} + {{#if hasPermission 'view-full-other-user-info_last_login'}} +
+ + +
+ {{/if}} {{/if}} {{#if shouldDisplayReason}}
diff --git a/packages/rocketchat-i18n/i18n/en.i18n.json b/packages/rocketchat-i18n/i18n/en.i18n.json index 24b939428ce0..02dc9b817ae6 100644 --- a/packages/rocketchat-i18n/i18n/en.i18n.json +++ b/packages/rocketchat-i18n/i18n/en.i18n.json @@ -3620,6 +3620,8 @@ "view-d-room": "View Direct Messages", "view-d-room_description": "Permission to view direct messages", "view-full-other-user-info": "View Full Other User Info", + "view-full-other-user-info_created_at": "View Created At field", + "view-full-other-user-info_last_login": "View Last Login field", "view-full-other-user-info_description": "Permission to view full profile of other users including account creation date, last login, etc.", "view-history": "View History", "view-history_description": "Permission to view the channel history",