Ver Fonte

Supply-orders and shipments (wip)

Vijayakrishnan há 4 anos atrás
pai
commit
a079d42458
1 ficheiros alterados com 2 adições e 0 exclusões
  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');
     }