mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-02-04 20:40:14 +01:00
Moved to use the new limit_query() function
This commit is contained in:
parent
c8359e22ac
commit
ce2c7d262c
@ -139,11 +139,6 @@
|
|||||||
$querymethod = " AND (cat_name like '%$query%' OR cat_description like '%$query%') ";
|
$querymethod = " AND (cat_name like '%$query%' OR cat_description like '%$query%') ";
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($limit)
|
|
||||||
{
|
|
||||||
$limitmethod = " " . $this->db->limit($start);
|
|
||||||
}
|
|
||||||
|
|
||||||
$sql = "SELECT * from phpgw_categories WHERE (cat_appname='" . $this->app_name . "' $parent_filter AND "
|
$sql = "SELECT * from phpgw_categories WHERE (cat_appname='" . $this->app_name . "' $parent_filter AND "
|
||||||
. " $grant_cats) $public_cats $querymethod $filter";
|
. " $grant_cats) $public_cats $querymethod $filter";
|
||||||
|
|
||||||
@ -151,7 +146,14 @@
|
|||||||
|
|
||||||
$this->total_records = $this->db2->num_rows();
|
$this->total_records = $this->db2->num_rows();
|
||||||
|
|
||||||
$this->db->query($sql . $ordermethod . $limitmethod,__LINE__,__FILE__);
|
if ($limit)
|
||||||
|
{
|
||||||
|
$this->db->limit_query($sql . $ordermethod,$start,__LINE__,__FILE__);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$this->db->query($sql . $ordermethod,__LINE__,__FILE__);
|
||||||
|
}
|
||||||
|
|
||||||
//echo '<b>TEST:</b>' . $sql;
|
//echo '<b>TEST:</b>' . $sql;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user