fixed pagination
This commit is contained in:
@@ -31,12 +31,12 @@
|
||||
</div>
|
||||
|
||||
<div class="col-1">
|
||||
<label class="form-label" for="filter_countrycode">Countrycode</label>
|
||||
<label class="form-label" for="filter_countrycode">Landeskennzahl</label>
|
||||
<input type="text" class="form-control" name="filter[countrycode]" id="filter_countrycode" value="<?=$filter['countrycode']?>" />
|
||||
</div>
|
||||
|
||||
<div class="col-1">
|
||||
<label class="form-label" for="filter_areacode">Areacode</label>
|
||||
<label class="form-label" for="filter_areacode">Ortskennzahl</label>
|
||||
<input type="text" class="form-control" name="filter[areacode]" id="filter_areacode" value="<?=$filter['areacode']?>" />
|
||||
</div>
|
||||
|
||||
|
||||
@@ -41,7 +41,6 @@ class VoicenumberblockController extends mfBaseController {
|
||||
$pagination['maxItems'] = VoicenumberblockModel::count($filter);
|
||||
$blocks = VoicenumberblockModel::search($filter, $pagination);
|
||||
|
||||
|
||||
$this->layout()->set("blocks", $blocks);
|
||||
$this->layout()->set("pagination", $pagination);
|
||||
|
||||
|
||||
@@ -94,8 +94,6 @@ class VoicenumberblockModel {
|
||||
WHERE $where
|
||||
ORDER BY countrycode, areacode, first, last";
|
||||
|
||||
$res = $db->query($sql);
|
||||
|
||||
if(is_array($limit) && count($limit)) {
|
||||
if(is_numeric($limit['start']) && is_numeric($limit['count'])) {
|
||||
$sql .= " LIMIT ".$limit['start'].", ".$limit['count'];
|
||||
@@ -104,7 +102,9 @@ class VoicenumberblockModel {
|
||||
}
|
||||
}
|
||||
|
||||
mfLoghandler::singleton()->debug($sql);
|
||||
$res = $db->query($sql);
|
||||
|
||||
//mfLoghandler::singleton()->debug($sql);
|
||||
|
||||
if($db->num_rows($res)) {
|
||||
while($data = $db->fetch_object($res)) {
|
||||
|
||||
Reference in New Issue
Block a user