From 92e66899bf4c46d6dcb7e39fd77a5daa10d24e05 Mon Sep 17 00:00:00 2001 From: hickert Date: Thu, 1 Apr 2010 14:03:19 +0000 Subject: [PATCH] Updated fax listing git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@17471 594d385d-05f5-0310-b6e9-bd551577e9d8 --- gosa-plugins/gofax/gofax/faxreports/class_faxreport.inc | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/gosa-plugins/gofax/gofax/faxreports/class_faxreport.inc b/gosa-plugins/gofax/gofax/faxreports/class_faxreport.inc index 2772a9b86..f3f2bc49b 100644 --- a/gosa-plugins/gofax/gofax/faxreports/class_faxreport.inc +++ b/gosa-plugins/gofax/gofax/faxreports/class_faxreport.inc @@ -257,7 +257,8 @@ class faxreport extends plugin $query_entries = "SELECT id,uid,date_format(queuing_time, '%Y%m%d%H%i%s') as queuing_time,". "status,sender_id,receiver_id,pages FROM faxlog ". "WHERE {$userfilter} AND queuing_time <= {$end} AND ". - "queuing_time >= {$start} ORDER BY ".$this->fields[$this->sort]. + "queuing_time >= {$start} ". + "ORDER BY ".$this->fields[$this->sort]. " {$desc } "; @@ -355,10 +356,12 @@ class faxreport extends plugin mysql_close($link); $entry_count = count($report_list); + if($this->start >=$entry_count) $this->start =0; /* Generate output */ $mod= 0; $output= ""; + $report_list = array_slice($report_list, $this->start, $this->range); foreach ($report_list as $val){ $output.= "\n{$val}"; } -- 2.30.2