Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Steur <thomas.steur@gmail.com>2014-01-23 07:50:03 +0400
committerThomas Steur <thomas.steur@gmail.com>2014-01-23 07:50:03 +0400
commit3bffe9eed2a6dca88bd6df947b03d02246037714 (patch)
tree18cd876b27d100bca97ebb23af309303b104e024
parent0ffbe10c2ac6ed050724ef9db9796a320cb60896 (diff)
refs #2589 added some translations
-rw-r--r--lang/en.json5
-rw-r--r--plugins/UsersManager/UsersManager.php3
-rw-r--r--plugins/UsersManager/javascripts/usersManager.js12
-rw-r--r--plugins/UsersManager/templates/index.twig4
4 files changed, 15 insertions, 9 deletions
diff --git a/lang/en.json b/lang/en.json
index 7a52f5d99c..69e1439616 100644
--- a/lang/en.json
+++ b/lang/en.json
@@ -2105,6 +2105,11 @@
"PluginDescription": "Users Management in Piwik: add a new User, edit an existing one, update the permissions. All the actions are also available through the API.",
"UsersManagement": "Users Management",
"UsersManagementMainDescription": "Create new users or update the existing users. You can then set their permissions above.",
+ "SuperUserAccessManagement": "Super User Access Management",
+ "SuperUserAccessManagementMainDescription": "Super users have the highest permissions. They can perform administrative tasks such as adding new websites to monitor, adding users, changing user permissions, and enabling and disabling plugins and they have access to all websites. Beside the super user defined during the installation which always exist you can grant here super user access to additional users.",
+ "ConfirmGrantSuperUserAccess": "Do you really want to grant '%s' super user access? The user will have access to all websites and will be able to perform administrative tasks.",
+ "ConfirmProhibitOtherUsersSuperUserAccess": "Do you really want to prohibit '%s' super user access? The user will lose all permissions and access to all websites. Make sure to add access to needed websites afterwards if necessary.",
+ "ConfirmProhibitMySuperUserAccess": "Do you really want to remove your (%s) super user access? You will lose all permissions and access to all websites and therefore you will be logged out afterwards.",
"ThereAreCurrentlyNRegisteredUsers": "There are currently %s registered users.",
"ManageAccess": "Manage access",
"MainDescription": "Decide which users have which Piwik access on your Websites. You can also set the permissions on all the Websites at once.",
diff --git a/plugins/UsersManager/UsersManager.php b/plugins/UsersManager/UsersManager.php
index 8fe05b4a53..19910d9bc0 100644
--- a/plugins/UsersManager/UsersManager.php
+++ b/plugins/UsersManager/UsersManager.php
@@ -142,5 +142,8 @@ class UsersManager extends \Piwik\Plugin
$translationKeys[] = "General_Save";
$translationKeys[] = "General_Done";
$translationKeys[] = "UsersManager_DeleteConfirm";
+ $translationKeys[] = "UsersManager_ConfirmGrantSuperUserAccess";
+ $translationKeys[] = "UsersManager_ConfirmProhibitOtherUsersSuperUserAccess";
+ $translationKeys[] = "UsersManager_ConfirmProhibitMySuperUserAccess";
}
}
diff --git a/plugins/UsersManager/javascripts/usersManager.js b/plugins/UsersManager/javascripts/usersManager.js
index 2ec6ee400c..fa2d9a2d8b 100644
--- a/plugins/UsersManager/javascripts/usersManager.js
+++ b/plugins/UsersManager/javascripts/usersManager.js
@@ -121,18 +121,16 @@ function bindUpdateSuperUserAccess() {
var login = $(this).parents('td').data('login');
var hasAccess = parseInt($(this).data('hasaccess'), 10);
- var message = 'Do_You_Really_Want_To_Grant_%s_SuperUser_Permission?_The_User_Will_Have_Access_To_All_Websites_And_Users_...';
- if (hasAccess) {
- message = 'Do_You_Really_Want_To_Remove_%s_SuperUser_Permission?_The_User_Will_Lose_Access_To_All_Websites_And_Users_...';
+ var message = 'UsersManager_ConfirmGrantSuperUserAccess';
+ if (hasAccess && login == piwik.userLogin) {
+ message = 'UsersManager_ConfirmProhibitMySuperUserAccess';
+ } else if (hasAccess) {
+ message = 'UsersManager_ConfirmProhibitOtherUsersSuperUserAccess';
}
message = _pk_translate(message);
message = message.replace('%s', login)
- if (login == piwik.userLogin && hasAccess) {
- message += _pk_translate('As_This_Is_Your_User_You_Will_Be_Logged_Out_Afterwards_And_Not_Able_To_Log_In_Again');
- }
-
$('#superUserAccessConfirm h2').text(message);
piwikHelper.modalConfirm('#superUserAccessConfirm', {yes: function () {
diff --git a/plugins/UsersManager/templates/index.twig b/plugins/UsersManager/templates/index.twig
index 885f87501a..3b164b4bb6 100644
--- a/plugins/UsersManager/templates/index.twig
+++ b/plugins/UsersManager/templates/index.twig
@@ -152,8 +152,8 @@
</div>
- <h2>{{ 'Super_User_Management'|translate }}</h2>
- <p>{{ 'Super_User_Management_MainDescription'|translate }}</p>
+ <h2>{{ 'UsersManager_SuperUserAccessManagement'|translate }}</h2>
+ <p>{{ 'UsersManager_SuperUserAccessManagementMainDescription'|translate }}</p>
{{ ajax.errorDiv('ajaxErrorSuperUsersManagement') }}
{{ ajax.loadingDiv('ajaxLoadingSuperUsersManagement') }}