invoiceninja/app/Models/BankAccount.php

42 lines
729 B
PHP
Raw Normal View History

2017-01-30 21:40:43 +02:00
<?php
namespace App\Models;
2016-01-20 01:07:31 +02:00
use Illuminate\Database\Eloquent\SoftDeletes;
/**
2017-01-30 21:40:43 +02:00
* Class BankAccount.
*/
2016-01-20 01:07:31 +02:00
class BankAccount extends EntityModel
{
use SoftDeletes;
/**
* @var array
*/
2016-01-20 01:07:31 +02:00
protected $dates = ['deleted_at'];
/**
* @return mixed
*/
2016-01-20 01:07:31 +02:00
public function getEntityType()
{
return ENTITY_BANK_ACCOUNT;
}
/**
* @return \Illuminate\Database\Eloquent\Relations\BelongsTo
*/
2016-01-20 01:07:31 +02:00
public function bank()
{
return $this->belongsTo('App\Models\Bank');
}
/**
* @return \Illuminate\Database\Eloquent\Relations\HasMany
*/
2016-01-26 22:22:33 +02:00
public function bank_subaccounts()
{
return $this->hasMany('App\Models\BankSubaccount');
}
2016-01-20 01:07:31 +02:00
}