AccountClient.php 360 B

12345678910111213141516171819
  1. <?php
  2. namespace App\Models;
  3. # use Illuminate\Database\Eloquent\Model;
  4. class AccountClient extends Model
  5. {
  6. protected $table = 'account_client';
  7. public function client() {
  8. return $this->hasOne(Client::class, 'id', 'client_id');
  9. }
  10. public function account() {
  11. return $this->hasOne(Account::class, 'id', 'account_id');
  12. }
  13. }