Show list of directories that are over quota when you click "Recalculate"

This commit is contained in:
nathan 2022-11-24 11:02:54 -07:00
parent b2e0e176a5
commit 917271c349
2 changed files with 27 additions and 2 deletions

View File

@ -388,6 +388,7 @@ class filemanager_admin extends filemanager_ui
if(is_array($content))
{
$button = key($content['button']);
unset($content['button']);
switch($button)
{
case 'recalculate':
@ -417,7 +418,11 @@ class filemanager_admin extends filemanager_ui
}
}
$content = [];
$content = $content ?: [];
if($button == 'recalculate')
{
$content['check_oversize'] = true;
}
$readonlys['quota'] = !($GLOBALS['egw_info']['apps']['stylite']);
$tpl = new Etemplate('filemanager.quota');
$GLOBALS['egw_info']['flags']['app_header'] = lang('Quota');

View File

@ -8,7 +8,27 @@
<textbox label="Group home quota" id="group_quota" blur="(EPL Only)" disabled="true"
help-text="Enter a file size, e.g. 100K, 200M or 2G"/>
<button label="Recalculate" id="button[recalculate]" statustext="Recalculate directory sizes"/>
<grid id="oversize" disabled="!@oversize">
<columns>
<column/>
<column/>
<column/>
<column/>
</columns>
<rows>
<row class="th">
<description value="Path"/>
<description value="quota"/>
<description value="Size"/>
</row>
<row>
<vfs id="${row}"/>
<vfs-size id="${row}[quota]"/>
<vfs-size id="${row}[size]"/>
<url-email id="${row}[account_email]" readonly="true" class="adminOverflowEllipsis"/>
</row>
</rows>
</grid>
<hbox span="2" class="dialogFooterToolbar">
<button label="Save" id="button[save]"/>
<button label="Apply" id="button[apply]"/>