summaryrefslogtreecommitdiffstats
path: root/lib/kolab_client_task.php
diff options
context:
space:
mode:
authorTimotheus Pokorra (Tbits.net) <tp@tbits.net>2013-06-25 14:58:51 +0100
committerJeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com>2013-06-25 14:58:51 +0100
commit1ee1a17592e8cf53c5c1c6674bfd57d041f9e18e (patch)
tree04d40c946e934da1f1bce6948cbf7b0f19862a9d /lib/kolab_client_task.php
parentd181a4079f8c6a3ad998b4f05372683e2b1edd5e (diff)
downloadwebadmin-1ee1a17592e8cf53c5c1c6674bfd57d041f9e18e.tar.gz
In Kolab 3, the mail quota is displayed in KB.
A quota of 2 GB becomes 2*1024*1024 = 2097152 This is quite difficult to read and to calculate as well. The attached patch finds the closest unit that works without cutting something off (only use the next unit if modulo is 0). The admin is presented a select box for KB, MB and GB. The value is displayed either in KB, MB or GB. When saving, the value is replaced again with the KB value, depending on the selected unit. See: https://issues.kolab.org/show_bug.cgi?id=1966
Diffstat (limited to 'lib/kolab_client_task.php')
-rw-r--r--lib/kolab_client_task.php4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/kolab_client_task.php b/lib/kolab_client_task.php
index bcfa292..4e937a5 100644
--- a/lib/kolab_client_task.php
+++ b/lib/kolab_client_task.php
@@ -854,6 +854,10 @@ class kolab_client_task
}
break;
+ case 'text-quota':
+ $result['type'] = kolab_form::INPUT_TEXTQUOTA;
+ break;
+
default:
$result['type'] = kolab_form::INPUT_TEXT;
if (isset($field['maxlength'])) {