| 1234567891011121314151617181920212223242526272829303132333435 |
- <?php
- namespace App\Http\Resources;
- use Carbon\Carbon;
- use Illuminate\Http\Request;
- use Illuminate\Http\Resources\Json\JsonResource;
- use App\Models\UnitFinancial;
- class UnitFinancialResource extends JsonResource
- {
- public function toArray(Request $request): array
- {
- return [
- 'id' => $this->id,
- 'unit_id' => $this->unit_id,
- 'tax_regime' => $this->tax_regime,
- 'bank' => $this->bank,
- 'agency' => $this->agency,
- 'account' => $this->account,
- 'account_type' => $this->account_type,
- 'account_holder' => $this->account_holder,
- 'pix_key' => $this->pix_key,
- 'billing_method' => $this->billing_method,
- 'due_date' => $this->due_date,
- 'financial_email' => $this->financial_email,
- 'group' => $this->group,
- 'maintenance_fee' => $this->maintenance_fee,
- 'marketing_fund' => $this->marketing_fund,
- 'tbr' => $this->tbr,
- 'created_at' => Carbon::parse($this->created_at)->format('Y-m-d H:i:s'),
- 'updated_at' => Carbon::parse($this->updated_at)->format('Y-m-d H:i:s'),
- ];
- }
- }
|