walletservice/app/Models/UserBankAccount.php

61 lines
1.1 KiB
PHP
Executable File

<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Model;
use App\Models\User;
use App\Models\Operator;
class UserBankAccount extends Model
{
protected $table = 'user_bank_accounts';
public $timestamps = false;
protected $fillable = [
'id_user',
'id_operator',
'account_number',
'iban',
'swift_code',
'account_type',
'balance',
'status',
'reason',
'lastname',
'firstname',
'marital_name',
'nationality',
'birth_date',
'birth_country',
'birth_city',
'father_firstname',
'father_lastname',
'mother_firstname',
'mother_lastname',
'marital_status',
'profession',
'sector_activity',
'subsector_activity',
'tax_number',
'employee_number',
'position',
'employer_name',
'employer_address',
'created_at',
'updated_at'
];
public function user()
{
return $this->belongsTo(User::class);
}
public function bank()
{
return $this->belongsTo(Operator::class);
}
}