output message if quota is exceeded

This commit is contained in:
steinm 2012-12-19 10:11:48 +00:00
parent ab1a241a16
commit 653cefe14f

View File

@ -43,6 +43,9 @@ class LetoDMS_View_MyAccount extends LetoDMS_Bootstrap_Style {
$this->contentStart();
$this->pageNavigation(getMLText("my_account"), "my_account");
if(($remain = checkQuota()) < 0) {
$this->warningMsg(getMLText('quota_warning', array('bytes'=>LetoDMS_Core_File::format_filesize(abs($remain)))));
}
$this->contentHeading(getMLText("user_info"));
$this->contentContainerStart();
@ -77,6 +80,14 @@ class LetoDMS_View_MyAccount extends LetoDMS_Bootstrap_Style {
print "<td>".htmlspecialchars($user->getPwdExpiration())."</td>\n";
print "</tr>\n";
}
print "<tr>\n";
print "<td>".getMLText("quota")." : </td>\n";
print "<td>".LetoDMS_Core_File::format_filesize($user->getQuota())."</td>\n";
print "</tr>\n";
print "<tr>\n";
print "<td>".getMLText("used_discspace")." : </td>\n";
print "<td>".LetoDMS_Core_File::format_filesize($user->getUsedDiskSpace())."</td>\n";
print "</tr>\n";
print "</table>\n";
print "</div>\n";
print "</div>\n";