Fix limit
This commit is contained in:
parent
73422b2149
commit
7377c30bfe
@ -868,7 +868,15 @@ class Categorie extends CommonObject
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($limit) $sql.= $this->db->plimit($limit + 1, $offset);
|
if ($limit) {
|
||||||
|
if ($page < 0)
|
||||||
|
{
|
||||||
|
$page = 0;
|
||||||
|
}
|
||||||
|
$offset = $limit * $page;
|
||||||
|
|
||||||
|
$sql.= $this->db->plimit($limit + 1, $offset);
|
||||||
|
}
|
||||||
|
|
||||||
$result = $this->db->query($sql);
|
$result = $this->db->query($sql);
|
||||||
if ($result)
|
if ($result)
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user