From 6e31e691450b201a3d19c029d1ca4d1fa8285a22 Mon Sep 17 00:00:00 2001
From: mcramer <m.cramer@pixcept.de>
Date: Tue, 09 Jul 2013 04:25:14 -0400
Subject: [PATCH] - Changed: made used quota and used files in website quota stats sortable
---
interface/web/sites/list/user_quota_stats.list.php | 3 +++
interface/web/sites/templates/user_quota_stats_list.htm | 4 ++--
interface/web/sites/user_quota_stats.php | 1 +
3 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/interface/web/sites/list/user_quota_stats.list.php b/interface/web/sites/list/user_quota_stats.list.php
index c3999c2..646da27 100644
--- a/interface/web/sites/list/user_quota_stats.list.php
+++ b/interface/web/sites/list/user_quota_stats.list.php
@@ -42,6 +42,9 @@
// Enable auth
$liste["auth"] = "yes";
+// mark columns for php sorting (no real mySQL columns)
+$liste["phpsort"] = array('used_sort', 'files');
+
/*****************************************************
* Suchfelder
diff --git a/interface/web/sites/templates/user_quota_stats_list.htm b/interface/web/sites/templates/user_quota_stats_list.htm
index e20b991..1403a01 100644
--- a/interface/web/sites/templates/user_quota_stats_list.htm
+++ b/interface/web/sites/templates/user_quota_stats_list.htm
@@ -9,10 +9,10 @@
<tr class="caption">
<th class="tbl_col_domain" scope="col"><tmpl_var name="domain_txt"></th>
<th class="tbl_col_system_user" scope="col"><tmpl_var name="system_user_txt"></th>
- <th class="tbl_col_used tbl_col_nosort" scope="col"><tmpl_var name="used_txt"></th>
+ <th class="tbl_col_used_sort" scope="col"><tmpl_var name="used_txt"></th>
<th class="tbl_col_soft tbl_col_nosort" scope="col"><tmpl_var name="soft_txt"></th>
<th class="tbl_col_hard tbl_col_nosort" scope="col"><tmpl_var name="hard_txt"></th>
- <th class="tbl_col_files tbl_col_nosort" scope="col"><tmpl_var name="files_txt"></th>
+ <th class="tbl_col_files" scope="col"><tmpl_var name="files_txt"></th>
<th class="tbl_col_limit" scope="col">{tmpl_var name='search_limit'}</th>
</tr>
<tr class="filter">
diff --git a/interface/web/sites/user_quota_stats.php b/interface/web/sites/user_quota_stats.php
index c00f893..32aa706 100644
--- a/interface/web/sites/user_quota_stats.php
+++ b/interface/web/sites/user_quota_stats.php
@@ -42,6 +42,7 @@
$username = $rec['system_user'];
$rec['used'] = $monitor_data['user'][$username]['used'];
+ $rec['used_sort'] = $rec['used'];
$rec['soft'] = $monitor_data['user'][$username]['soft'];
$rec['hard'] = $monitor_data['user'][$username]['hard'];
$rec['files'] = $monitor_data['user'][$username]['files'];
--
Gitblit v1.9.1