2011-08-10 Miguel de Dios <miguel.dedios@artica.es>
* godmode/groups/modu_group_list.php: added pagination to list. Fixes: #3389009 git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@4697 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
ed12ce449f
commit
47d9b44932
|
@ -1,3 +1,9 @@
|
|||
2011-08-10 Miguel de Dios <miguel.dedios@artica.es>
|
||||
|
||||
* godmode/groups/modu_group_list.php: added pagination to list.
|
||||
|
||||
Fixes: #3389009
|
||||
|
||||
2011-08-09 Javier Lanz <javier.lanz@artica.es>
|
||||
|
||||
* operation/incidents/incident.incident.php,
|
||||
|
|
|
@ -129,9 +129,41 @@ if ($delete_group) {
|
|||
echo "<h3 class='suc'>".__('Group successfully deleted')."</h3>";
|
||||
}
|
||||
|
||||
$sql = "SELECT *
|
||||
FROM tmodule_group ";
|
||||
$groups = db_get_all_rows_sql ($sql, true);
|
||||
$total_groups = db_get_num_rows('SELECT * FROM tmodule_group');
|
||||
|
||||
$url = ui_get_url_refresh (array ('offset' => false));
|
||||
|
||||
$offset = (int)get_parameter('offset', 0);
|
||||
|
||||
ui_pagination($total_groups, $url, $offset);
|
||||
|
||||
switch ($config["dbtype"]) {
|
||||
case "mysql":
|
||||
$sql = "SELECT *
|
||||
FROM tmodule_group
|
||||
ORDER BY name ASC
|
||||
LIMIT " . $offset . ", " . $config['block_size'];
|
||||
break;
|
||||
case "postgresql":
|
||||
$sql = "SELECT *
|
||||
FROM tmodule_group
|
||||
ORDER BY name ASC
|
||||
LIMIT " . $config['block_size'] . " OFFSET " . $offset;
|
||||
break;
|
||||
case "oracle":
|
||||
$set = array ();
|
||||
$set['limit'] = $config["block_size"];
|
||||
$set['offset'] = $offset;
|
||||
|
||||
$sql = "SELECT *
|
||||
FROM tmodule_group
|
||||
ORDER BY name ASC";
|
||||
|
||||
$sql = oracle_recode_query ($sql, $set);
|
||||
break;
|
||||
}
|
||||
|
||||
$groups = db_get_all_rows_sql($sql);
|
||||
|
||||
$table->width = '98%';
|
||||
|
||||
|
|
Loading…
Reference in New Issue