Commit 222ea214 authored by cfoe's avatar cfoe
Browse files

standard sorting by main characteristic for most lists

parent 14b91f58
......@@ -101,7 +101,7 @@ class page_action extends tform_actions {
global $app;
$sql = "SELECT template_id,template_name FROM client_template WHERE template_type = 'a'";
$sql = "SELECT template_id,template_name FROM client_template WHERE template_type = 'a' ORDER BY template_name ASC";
$tpls = $app->db->queryAllRecords($sql);
$option = '';
$tpl = array();
......
......@@ -44,5 +44,6 @@ $app->auth->check_module_permissions('client');
if(!$_SESSION["s"]["user"]["typ"] == 'admin') die('Client-Templates are only for Admins.');
$app->uses('listform_actions');
$app->listform_actions->SQLOrderBy = 'ORDER BY template_name';
$app->listform_actions->onLoad();
?>
......@@ -235,13 +235,12 @@ $form["tabs"]['address'] = array (
),
'country' => array (
'datatype' => 'VARCHAR',
'formtype' => 'SELECT',
'default' => (isset($conf['language']) ? strtoupper($conf['language']) : ''),
'datasource' => array ( 'type' => 'SQL',
'querystring' => 'SELECT iso,printable_name FROM country ORDER BY printable_name',
'keyfield'=> 'iso',
'valuefield'=> 'printable_name'
'querystring' => 'SELECT iso,printable_name FROM country ORDER BY iso ASC',
'keyfield' => 'iso',
'valuefield' => 'printable_name'
),
'value' => ''
),
......
......@@ -94,12 +94,11 @@ $liste["item"][] = array( 'field' => "city",
$liste["item"][] = array( 'field' => "country",
'datatype' => "VARCHAR",
'formtype' => "TEXT",
'op' => "like",
'prefix' => "%",
'suffix' => "%",
'formtype' => "SELECT",
'op' => "=",
'prefix' => "",
'suffix' => "",
'width' => "",
'value' => "");
?>
\ No newline at end of file
......@@ -85,12 +85,11 @@ $liste["item"][] = array( 'field' => "city",
$liste["item"][] = array( 'field' => "country",
'datatype' => "VARCHAR",
'formtype' => "TEXT",
'op' => "like",
'prefix' => "%",
'suffix' => "%",
'formtype' => "SELECT",
'op' => "=",
'prefix' => "",
'suffix' => "",
'width' => "",
'value' => "");
?>
\ No newline at end of file
......@@ -32,7 +32,7 @@
<td class="tbl_col_contact_name"><input type="text" name="search_contact_name" value="{tmpl_var name='search_contact_name'}" style="width:120px;" /></td>
<td class="tbl_col_username"><input type="text" name="search_username" value="{tmpl_var name='search_username'}" style="width:120px;" /></td>
<td class="tbl_col_city"><input type="text" name="search_city" value="{tmpl_var name='search_city'}" style="width:120px;" /></td>
<td class="tbl_col_country"><input type="text" name="search_country" value="{tmpl_var name='search_country'}" style="width:30px;" /></td>
<td class="tbl_col_country"><select name="search_country" style="width:120px;">{tmpl_var name='search_country'}</select></td>
<td class="tbl_col_buttons"><div class="buttons"><button type="button" class="icons16 icoFilter" name="Filter" id="Filter" value="{tmpl_var name="filter_txt"}" onClick="submitForm('pageForm','client/client_list.php');"><span>{tmpl_var name="filter_txt"}</span></button></div></td>
</tr>
</thead>
......
......@@ -30,7 +30,7 @@
<td class="tbl_col_company_name"><input type="text" name="search_company_name" value="{tmpl_var name='search_company_name'}" style="width:120px;" /></td>
<td class="tbl_col_contact_name"><input type="text" name="search_contact_name" value="{tmpl_var name='search_contact_name'}" style="width:120px;" /></td>
<td class="tbl_col_city"><input type="text" name="search_city" value="{tmpl_var name='search_city'}" style="width:120px;" /></td>
<td class="tbl_col_country"><input type="text" name="search_country" value="{tmpl_var name='search_country'}" style="width:30px;" /></td>
<td class="tbl_col_country"><select name="search_country" style="width:120px;">{tmpl_var name='search_country'}</select></td>
<td class="tbl_col_buttons"><div class="buttons"><button type="button" class="icons16 icoFilter" name="Filter" id="Filter" value="{tmpl_var name="filter_txt"}" onClick="submitForm('pageForm','client/reseller_list.php');"><span>{tmpl_var name="filter_txt"}</span></button></div></td>
</tr>
</thead>
......
......@@ -18,6 +18,7 @@ $app->auth->check_module_permissions('dns');
$app->uses('listform_actions');
// $app->listform_actions->SQLExtWhere = "access = 'REJECT'";
$app->listform_actions->SQLOrderBy = 'ORDER BY name';
$app->listform_actions->onLoad();
......
......@@ -56,7 +56,7 @@ if($_SESSION['s']['user']['typ'] == 'admin') {
// Load the templates
$records = $app->db->queryAllRecords("SELECT * FROM dns_template WHERE visible = 'Y'");
$records = $app->db->queryAllRecords("SELECT * FROM dns_template WHERE visible = 'Y' ORDER BY name ASC");
$template_id_option = '';
$n = 0;
foreach($records as $rec){
......
......@@ -64,7 +64,7 @@ $liste["item"][] = array( 'field' => "server_id",
'op' => "like",
'prefix' => "%",
'suffix' => "%",
'datasource' => array ( 'type' => 'CUSTOM',
'datasource'=> array ( 'type' => 'CUSTOM',
'class'=> 'custom_datasource',
'function'=> 'dns_servers'
),
......@@ -90,8 +90,4 @@ $liste["item"][] = array( 'field' => "ns",
'width' => "",
'value' => "");
?>
\ No newline at end of file
......@@ -67,14 +67,4 @@ $liste["item"][] = array( 'field' => "name",
'width' => "",
'value' => "");
?>
\ No newline at end of file
......@@ -46,6 +46,7 @@ $app->auth->check_module_permissions('domain');
$app->uses('listform_actions');
$app->listform_actions->SQLOrderBy = 'ORDER BY domain';
$app->listform_actions->onLoad();
?>
\ No newline at end of file
......@@ -21,6 +21,7 @@ $app->uses('listform_actions');
// Limit the results to alias domains
// $app->listform_actions->SQLExtWhere = "type = 'local'";
$app->listform_actions->SQLOrderBy = 'ORDER BY domain';
$app->listform_actions->onLoad();
......
......@@ -67,6 +67,7 @@ class list_action extends listform_actions {
}
$list = new list_action;
$list->SQLOrderBy = 'ORDER BY database_name';
$list->onLoad();
......
......@@ -68,6 +68,7 @@ class list_action extends listform_actions {
}
$list = new list_action;
$list->SQLOrderBy = 'ORDER BY username';
$list->onLoad();
......
......@@ -49,6 +49,7 @@ $app->uses('listform_actions');
// Limit the results to alias domains
//$app->listform_actions->SQLExtWhere = "type = 'subdomain'";
$app->listform_actions->SQLOrderBy = 'ORDER BY username';
$app->listform_actions->onLoad();
......
......@@ -88,7 +88,7 @@ class list_action extends listform_actions {
$list = new list_action;
$list->SQLExtWhere = "type = 'vhost'";
$list->SQLOrderBy = 'ORDER BY domain';
$list->onLoad();
......
......@@ -48,7 +48,7 @@ $app->uses('listform_actions');
// Limit the results to alias domains
$app->listform_actions->SQLExtWhere = "type = 'alias'";
$app->listform_actions->SQLOrderBy = 'ORDER BY domain';
$app->listform_actions->onLoad();
......
......@@ -53,7 +53,7 @@ class list_action extends listform_actions {
$list = new list_action;
$list->SQLExtWhere = "type = 'vhost'";
$list->SQLOrderBy = 'ORDER BY domain';
$list->onLoad();
?>
\ No newline at end of file
......@@ -59,7 +59,7 @@ class list_action extends listform_actions {
$list = new list_action;
$list->SQLExtWhere = "type = 'vhost'";
$list->SQLOrderBy = 'ORDER BY domain';
$list->onLoad();
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment