Przeglądaj źródła

Transmissions order by

Vijayakrishnan 2 lat temu
rodzic
commit
e1e8865fa7
1 zmienionych plików z 4 dodań i 2 usunięć
  1. 4 2
      app/Models/CareMonth.php

+ 4 - 2
app/Models/CareMonth.php

@@ -300,12 +300,14 @@ class CareMonth extends Model
     public function rtmMskTransmissions() {
         return $this->hasMany(ClientRtmTransmission::class, 'care_month_id', 'id')
             ->where('msk_or_lung', 'MSK')
-            ->orderBy('effective_date', 'DESC');
+            ->orderBy('effective_date', 'DESC')
+            ->orderBy('created_at', 'DESC');
     }
 
     public function rtmLungTransmissions() {
         return $this->hasMany(ClientRtmTransmission::class, 'care_month_id', 'id')
             ->where('msk_or_lung', 'LUNG')
-            ->orderBy('effective_date', 'DESC');
+            ->orderBy('effective_date', 'DESC')
+            ->orderBy('created_at', 'DESC');
     }
 }