<?php
namespace App\Models;
use App\Models\Concerns\BelongsToMerchant;
use Illuminate\Database\Eloquent\Model;
class Payout extends Model {
 use BelongsToMerchant;protected $fillable=['public_id','merchant_id','environment','asset_id','to_address','amount_atomic','fee_atomic','status','idempotency_key','provider_transfer_id','tx_hash','two_factor_confirmed_at','screening_status','screening_result','approved_at','approved_by','provider_idempotency_key','broadcast_started_at','broadcast_at','completed_at','failed_at','failure_reason','reservation_ledger_transaction_id','settlement_ledger_transaction_id','release_ledger_transaction_id'];protected function casts():array{return ['screening_result'=>'array','two_factor_confirmed_at'=>'datetime','approved_at'=>'datetime','broadcast_started_at'=>'datetime','broadcast_at'=>'datetime','completed_at'=>'datetime','failed_at'=>'datetime'];}public function asset(){return $this->belongsTo(Asset::class);}public function merchant(){return $this->belongsTo(Merchant::class);}public function approvals(){return $this->hasMany(PayoutApproval::class);}}
