Skip to content
Snippets Groups Projects
Commit c471ac4b authored by SNA's avatar SNA
Browse files

FIX

parent 2e7494d0
No related branches found
No related tags found
No related merge requests found
...@@ -103,14 +103,14 @@ if (isset($whereAttach) && $whereAttach <> '') $where .= $whereAttach; ...@@ -103,14 +103,14 @@ if (isset($whereAttach) && $whereAttach <> '') $where .= $whereAttach;
$order_field = $list->getOrderField(); $order_field = $list->getOrderField();
if (!empty($order_field) && !empty($order)){ if (!empty($order_field) && !empty($order)){
if($_REQUEST['order_field'] == 'identifier'){ if($_REQUEST['order_field'] == 'identifier'){
$orderstr = "order by regexp_replace(identifier, '[^a-zA-Z]', '', 'g') ".$order.", regexp_replace(identifier, '[^0-9]', '', 'g')::int"." ".$order; $orderstr = "order by regexp_replace(identifier, '[^a-zA-Z]', '', 'g') ".$order.", regexp_replace(identifier, '[^0-9]', '', 'g')::bigint"." ".$order;
}else{ }else{
$orderstr = "order by ".$order_field." ".$order; $orderstr = "order by ".$order_field." ".$order;
} }
} else { } else {
$list->setOrder(); $list->setOrder();
$list->setOrderField('identifier'); $list->setOrderField('identifier');
$orderstr = "order by attachment_type asc, regexp_replace(identifier, '[^a-zA-Z]', '', 'g') DESC, regexp_replace(identifier, '[^0-9]', '', 'g')::int DESC"; $orderstr = "order by attachment_type asc, regexp_replace(identifier, '[^a-zA-Z]', '', 'g') DESC, regexp_replace(identifier, '[^0-9]', '', 'g')::bigint DESC";
} }
$parameters = ''; $parameters = '';
...@@ -380,4 +380,4 @@ if (isset($_REQUEST['load'])) { ...@@ -380,4 +380,4 @@ if (isset($_REQUEST['load'])) {
$status = 0; $status = 0;
echo "{status : " . $status . ", content : '" . addslashes($debug.$content) . "', error : '" . addslashes($error) . "'}"; echo "{status : " . $status . ", content : '" . addslashes($debug.$content) . "', error : '" . addslashes($error) . "'}";
} }
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment