master
cody 3 months ago
parent 200fdb5c5b
commit d1fdfc36dd

@ -104,7 +104,9 @@ class StatisticsController extends CommonController
})
->with([
"order",
"product",
"product" => function ($query) {
$query->withoutGlobalScope(AdminProjectScope::class);
},
"productItem",
"productParamedicLevel",
"paramedic" => function ($query) {

@ -44,7 +44,9 @@ class OrderItems extends SoftDeletesModel
public function product()
{
return $this->hasOneThrough(Product::class, ProductItems::class, "id", "id", "product_item_id", "product_id")->withTrashedParents();
return $this->hasOneThrough(Product::class, ProductItems::class, "id", "id", "product_item_id", "product_id")
->withoutGlobalScope(\App\Scopes\AdminProjectScope::class)
->withTrashedParents();
}
public function productItem()

Loading…
Cancel
Save