I have a model with a custom accessor so I get that custom attribute,
class Order extends GSModel{
$appends = [\'orderContents\'];
publ
There's no way to do it in one go, so here's what you need:
$openOrders = Order::open()->has('contents')->get(['id','date','tableName']);
$openOrders->each(function ($order) {
$order->setAppends([]);
});
Alternatively, you may use Laravel's Higher Order Messaging on the last step:
$openOrders->each->setAppends([]);