AgentWithdrawal.php 720 B

123456789101112131415
  1. <?php
  2. namespace App\Models\Agent;
  3. use App\Models\BaseModel;
  4. class AgentWithdrawal extends BaseModel
  5. {
  6. protected $table = 'agent_withdrawals';
  7. protected $fillable = ['order_no', 'request_key', 'agent_id', 'account_id', 'account_type', 'account_snapshot', 'amount', 'fee', 'actual_amount', 'status', 'remark', 'audit_remark', 'audit_admin_id', 'audited_at', 'paid_at'];
  8. protected $hidden = ['request_key'];
  9. protected $casts = ['agent_id' => 'integer', 'amount' => 'decimal:4', 'fee' => 'decimal:4', 'actual_amount' => 'decimal:4', 'account_snapshot' => 'array', 'audited_at' => 'datetime', 'paid_at' => 'datetime'];
  10. public function agent()
  11. {
  12. return $this->belongsTo(Agent::class);
  13. }
  14. }