summaryrefslogtreecommitdiffstats
path: root/settings/users.php
diff options
context:
space:
mode:
authorThomas Müller <thomas.mueller@tmit.eu>2012-12-20 15:35:36 +0100
committerThomas Müller <thomas.mueller@tmit.eu>2012-12-20 15:35:36 +0100
commit436df6b67d1bcb9c4b5bd659319f2c0d38a0645b (patch)
tree5360b8d3fbd5c57681f92c8f027386480030c94c /settings/users.php
parent74d41b8b96e48fa7ac6aaca132340c94ccd50964 (diff)
downloadnextcloud-server-436df6b67d1bcb9c4b5bd659319f2c0d38a0645b.tar.gz
nextcloud-server-436df6b67d1bcb9c4b5bd659319f2c0d38a0645b.zip
enable translations for quota sizes 'none' and 'default'
Diffstat (limited to 'settings/users.php')
-rw-r--r--settings/users.php12
1 files changed, 9 insertions, 3 deletions
diff --git a/settings/users.php b/settings/users.php
index 2fd10f1d6ec..3dee152bb15 100644
--- a/settings/users.php
+++ b/settings/users.php
@@ -30,10 +30,15 @@ if($isadmin) {
}
foreach($accessibleusers as $i) {
+ $quota=OC_Preferences::getValue($i, 'files', 'quota', 'default');
+ // translation of old value 'none' to 'unlimited'
+ if ($quota=='none')
+ $quota='unlimited';
+
$users[] = array(
"name" => $i,
"groups" => join( ", ", /*array_intersect(*/OC_Group::getUserGroups($i)/*, OC_SubAdmin::getSubAdminsGroups(OC_User::getUser()))*/),
- 'quota'=>OC_Preferences::getValue($i, 'files', 'quota', 'Default'),
+ 'quota'=>OC_Preferences::getValue($i, 'files', 'quota', 'default'),
'subadmin'=>implode(', ', OC_SubAdmin::getSubAdminsGroups($i)));
}
@@ -41,13 +46,14 @@ foreach( $accessiblegroups as $i ) {
// Do some more work here soon
$groups[] = array( "name" => $i );
}
-$quotaPreset=OC_Appconfig::getValue('files', 'quota_preset', 'Default, Unlimited, 1 GB, 5 GB, 10 GB');
+$quotaPreset=OC_Appconfig::getValue('files', 'quota_preset', '1 GB, 5 GB, 10 GB');
$quotaPreset=explode(',', $quotaPreset);
foreach($quotaPreset as &$preset) {
$preset=trim($preset);
}
+$quotaPreset=array_diff($quotaPreset, array('default', 'none'));
-$defaultQuota=OC_Appconfig::getValue('files', 'default_quota', 'Unlimited');
+$defaultQuota=OC_Appconfig::getValue('files', 'default_quota', 'none');
$tmpl = new OC_Template( "settings", "users", "user" );
$tmpl->assign( "users", $users );