Bladeren bron

updated the sorting order of the conversations view

The sorting order of conversations has been adjusted so that selected messages are no longer brought to the top.

This is more in line with expected behavior from other chat apps
Antonio Fernandez 1 jaar geleden
bovenliggende
commit
94ddcdd065
1 gewijzigde bestanden met toevoegingen van 5 en 2 verwijderingen
  1. 5 2
      messages_contacts.php

+ 5 - 2
messages_contacts.php

@@ -140,12 +140,15 @@
 	$sql .= ") as n\n";
 
 	$sql .= "order by \n";
-	$sql .= "case when (number = :number) then 0 end asc,\n";
+	//uncomment below to have the selected message pop up to the top of the list
+	//$sql .= "case when (number = :number) then 0 end asc,\n";
 	$sql .= "date desc\n";
 
 	$parameters['domain_uuid'] = $domain_uuid;
 	$parameters['user_uuid'] = $_SESSION['user']['user_uuid'];
-	$parameters['number'] = $_SESSION['user']['contact_number'] ?? null;
+
+	//uncomment below to have the selected message pop up to the top of the list
+	//$parameters['number'] = $_SESSION['user']['contact_number'] ?? null;
 //echo "<pre>\n";
 //echo $sql;
 //echo "</pre>\n";