Jelajahi Sumber

Supply-orders and shipments (wip)

Vijayakrishnan 4 tahun lalu
induk
melakukan
a079d42458
1 mengubah file dengan 2 tambahan dan 0 penghapusan
  1. 2 0
      app/Models/Client.php

+ 2 - 0
app/Models/Client.php

@@ -400,12 +400,14 @@ class Client extends Model
     public function supplyOrders()
     {
         return $this->hasMany(SupplyOrder::class, 'client_id', 'id')
+            ->where('is_cancelled', false)
             ->orderBy('created_at', 'desc');
     }
 
     public function unshippedSupplyOrders()
     {
         return $this->hasMany(SupplyOrder::class, 'client_id', 'id')
+            ->where('is_cancelled', false)
             ->whereNull('shipment_id')
             ->orderBy('created_at', 'desc');
     }