diff --git a/app/Http/Resources/CompanyResource.php b/app/Http/Resources/CompanyResource.php index d6972ab5..8e109e1c 100644 --- a/app/Http/Resources/CompanyResource.php +++ b/app/Http/Resources/CompanyResource.php @@ -62,7 +62,7 @@ class CompanyResource extends JsonResource $segment = SegmentConstant::where('reference', SegmentConstants::SUPPLIER_CURRENCIES)->where('detail->id', $this->id)->first(); return $segment ? CurrencyResource::collection(Currency::whereIn('id', $segment->detail->currencies)->get()) : []; }), - 'wallets' => $this->banks, + 'wallets' => $this->wallets, 'wallet' => new WalletResource($this->wallets()->first()), 'created_at' => $this->created_at->format('d-m-Y') ]; diff --git a/app/Models/Wallet.php b/app/Models/Wallet.php index 29c3ddc9..8c3114fd 100644 --- a/app/Models/Wallet.php +++ b/app/Models/Wallet.php @@ -21,10 +21,6 @@ class Wallet extends AbstractModel implements Transactionable { return $this->morphTo(); } - public function company(): BelongsTo - { - return $this->BelongsTo(Company::class, 'owner_id', 'id'); - } /** * @return morphMany