Nextrek
Diff Revisions
635
vs
640
for /Android/SmartCharging/endPoints/repositories/CommentRepository.php
|
@@ -64,7 +64,7 @@ |
64 |
64 |
|
} |
65 |
65 |
|
} |
66 |
66 |
|
|
67 |
|
- |
public function getComments($id_local, $start_index, $length) { |
|
67 |
+ |
public function getComments($id_local, $start_index, $length, $data_order) { |
68 |
68 |
|
/* query SQL da eseguire |
69 |
69 |
|
SELECT id_commento, id_locale, id_user, voto, descrizione, data, img |
70 |
70 |
|
FROM commenti, immagini_commenti |
|
@@ -98,7 +98,8 @@ |
98 |
98 |
|
FROM commenti as c |
99 |
99 |
|
LEFT JOIN immagini_commenti as i ON c.id=i.id_commento |
100 |
100 |
|
LEFT JOIN utente as u ON c.id_user=u.id |
101 |
|
- |
WHERE c.id IN (".implode(",", $comment_id_list).")"; |
|
101 |
+ |
WHERE c.id IN (".implode(",", $comment_id_list).") |
|
102 |
+ |
ORDER BY c.data ".$data_order; |
102 |
103 |
|
|
103 |
104 |
|
//echo "<br/>".$sqlImgs."<br/>"; |
104 |
105 |
|
|