Commit bf7963ac authored by Alex Ne's avatar Alex Ne

Двойная сортировка

parent 8657c792
...@@ -293,7 +293,11 @@ class PDO { ...@@ -293,7 +293,11 @@ class PDO {
$whete_obj = new PDOWhereConstructor($where); $whete_obj = new PDOWhereConstructor($where);
$SQL .= $whete_obj->get_sql(); $SQL .= $whete_obj->get_sql();
if (is_array($order)) { if (is_array($order)) {
$SQL .= " ORDER BY `{$order[0]}` {$order[1]}"; if (count($order) == 2) {
$SQL .= " ORDER BY `{$order[0]}` {$order[1]}";
} else if (count($order) == 4) {
$SQL .= " ORDER BY `{$order[0]}` {$order[1]},`{$order[2]}` {$order[3]}";
}
} }
if (is_integer($limit)) { if (is_integer($limit)) {
......
Markdown is supported
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