Commit e4057ebc authored by Benjamin Sonntag's avatar Benjamin Sonntag
Browse files

Closes #676, quota show totals

parent ced98746
...@@ -220,7 +220,7 @@ if (is_array($val)) { ...@@ -220,7 +220,7 @@ if (is_array($val)) {
</table> </table>
</form> </form>
<?php <?php
printf("<p>".__("%s accounts")."</p>",count($r)); printf("<p>"._("%s accounts")."</p>",count($r));
} }
?> ?>
</body> </body>
......
...@@ -37,6 +37,9 @@ include("head.php"); ...@@ -37,6 +37,9 @@ include("head.php");
<?php <?php
$quota_utilise = 0;
$tot = 0;
if ($mem->user['uid'] == "2000") if ($mem->user['uid'] == "2000")
$user_list = $admin->get_list(1); $user_list = $admin->get_list(1);
else{ else{
...@@ -74,11 +77,17 @@ foreach($sequence as $key) { ...@@ -74,11 +77,17 @@ foreach($sequence as $key) {
} else { } else {
$style = ''; $style = '';
} }
$quota_utilise = $quota_utilise + $q['u'];
$tot = $tot + $q['t'];
print "<td $style>".str_replace(" ", "&nbsp;", m_quota::display_val($key, $q['u']).'/'.m_quota::display_val($key, $q['t'])).'</td>'; print "<td $style>".str_replace(" ", "&nbsp;", m_quota::display_val($key, $q['u']).'/'.m_quota::display_val($key, $q['t'])).'</td>';
} }
print "</tr>"; print "</tr>";
$mem->unsu(); $mem->unsu();
} }
echo "<br><tr height=\"15\"></tr><tr><td>"._("Total")."</td><td $style>";
echo format_size($quota_utilise)." / ".format_size($tot)."</td></tr>";
print "</table>"; print "</table>";
?> ?>
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment