CDR basic search query, style and language mods, misc minor style mods.

This commit is contained in:
Nate Jones
2014-06-16 18:12:21 +00:00
parent 067cdf86d4
commit fcc5886339
8 changed files with 198 additions and 245 deletions

View File

@@ -62,6 +62,7 @@
if (!function_exists('check_sql')) {
function check_sql($string) {
$string = str_replace("''", "null", $string);
return trim($string); //remove white space
}
}
@@ -358,21 +359,21 @@
if (!function_exists('th_order_by')) {
//html table header order by
function th_order_by($field_name, $columntitle, $order_by, $order) {
$html = "<th nowrap>&nbsp; &nbsp; ";
function th_order_by($field_name, $columntitle, $order_by, $order, $app_uuid = '') {
if (strlen($app_uuid) > 0) { $app_uuid = "&app_uuid=".$app_uuid; } // accomodate need to pass app_uuid where necessary (inbound/outbound routes lists)
$html = "<th nowrap>";
if (strlen($order_by)==0) {
$html .= "<a href='?order_by=$field_name&order=desc' title='ascending'>$columntitle</a>";
$html .= "<a href='?order_by=$field_name&order=desc".$app_uuid."' title='ascending'>$columntitle</a>";
}
else {
if ($order=="asc") {
$html .= "<a href='?order_by=$field_name&order=desc' title='ascending'>$columntitle</a>";
$html .= "<a href='?order_by=$field_name&order=desc".$app_uuid."' title='ascending'>$columntitle</a>";
}
else {
$html .= "<a href='?order_by=$field_name&order=asc' title='descending'>$columntitle</a>";
$html .= "<a href='?order_by=$field_name&order=asc".$app_uuid."' title='descending'>$columntitle</a>";
}
}
$html .= "&nbsp; &nbsp; </th>";
$html .= "</th>";
return $html;
}
}