mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-09-21 00:41:34 +02:00
62e2444a2c
* Fix js dependencies * Breadcrumb implementation * Test for UniqueEmailRule Validation * reduce length of account_key to prevent key too long error * Fixes for travis - reduce user email length * Reduce all unique field lengths to 100 to prevent key overflow * Fix for Bank Model * Prevent a user from registering multiple account with one email address when using multiple databases
29 lines
462 B
PHP
29 lines
462 B
PHP
<?php
|
|
|
|
namespace App\Models;
|
|
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
/**
|
|
* Class Bank.
|
|
*/
|
|
class Bank extends Model
|
|
{
|
|
/**
|
|
* @var bool
|
|
*/
|
|
public $timestamps = false;
|
|
|
|
/**
|
|
* @param $finance
|
|
*
|
|
* @return \App\Libraries\Bank
|
|
*/
|
|
public function getOFXBank($finance)
|
|
{
|
|
$config = json_decode($this->config);
|
|
|
|
return new \App\Libraries\Bank($finance, $config->fid, $config->url, $config->org);
|
|
}
|
|
}
|