mirror of
https://gitlab.easter-eggs.com/ee/ldapsaisie.git
synced 2024-11-22 18:09:06 +01:00
LSformElement_quota : changed factor values
This commit is contained in:
parent
1d0c786bac
commit
6f59a44d42
1 changed files with 9 additions and 9 deletions
|
@ -36,9 +36,9 @@ class LSformElement_quota extends LSformElement {
|
||||||
|
|
||||||
var $sizeFacts = array(
|
var $sizeFacts = array(
|
||||||
1 => 'o',
|
1 => 'o',
|
||||||
1000 => 'Ko',
|
1024 => 'Ko',
|
||||||
1000000 => 'Mo',
|
1048576 => 'Mo',
|
||||||
1000000000 => 'Go'
|
1073741824 => 'Go'
|
||||||
);
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -58,14 +58,14 @@ class LSformElement_quota extends LSformElement {
|
||||||
$infos = array(
|
$infos = array(
|
||||||
'size' => ceil($regs[1]/$this -> getFactor())
|
'size' => ceil($regs[1]/$this -> getFactor())
|
||||||
);
|
);
|
||||||
if ($infos['size'] >= 1000000000) {
|
if ($infos['size'] >= 1073741824) {
|
||||||
$infos['valueSizeFact']=1000000000;
|
$infos['valueSizeFact']=1073741824;
|
||||||
}
|
}
|
||||||
else if ($infos['size'] >= 1000000) {
|
else if ($infos['size'] >= 1048576) {
|
||||||
$infos['valueSizeFact']=1000000;
|
$infos['valueSizeFact']=1048576;
|
||||||
}
|
}
|
||||||
else if ($infos['size'] >= 1000) {
|
else if ($infos['size'] >= 1024) {
|
||||||
$infos['valueSizeFact']=1000;
|
$infos['valueSizeFact']=1024;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$infos['valueSizeFact']=1;
|
$infos['valueSizeFact']=1;
|
||||||
|
|
Loading…
Reference in a new issue