2019-03-26 15:46:08 +11:00
|
|
|
<?php
|
2019-05-11 13:32:07 +10:00
|
|
|
/**
|
|
|
|
|
* Invoice Ninja (https://invoiceninja.com)
|
|
|
|
|
*
|
|
|
|
|
* @link https://github.com/invoiceninja/invoiceninja source repository
|
|
|
|
|
*
|
2020-01-07 11:13:47 +11:00
|
|
|
* @copyright Copyright (c) 2020. Invoice Ninja LLC (https://invoiceninja.com)
|
2019-05-11 13:32:07 +10:00
|
|
|
*
|
|
|
|
|
* @license https://opensource.org/licenses/AAL
|
|
|
|
|
*/
|
2019-03-26 15:46:08 +11:00
|
|
|
|
|
|
|
|
namespace App\Models;
|
|
|
|
|
|
2020-04-09 20:48:04 +10:00
|
|
|
use App\Models\Filterable;
|
2019-03-26 15:46:08 +11:00
|
|
|
use Illuminate\Database\Eloquent\Model;
|
2020-02-27 10:32:44 +11:00
|
|
|
use Illuminate\Database\Eloquent\SoftDeletes;
|
2019-03-26 15:46:08 +11:00
|
|
|
|
2020-04-09 20:48:04 +10:00
|
|
|
class CompanyToken extends BaseModel
|
2019-03-26 15:46:08 +11:00
|
|
|
{
|
2020-02-27 10:32:44 +11:00
|
|
|
use SoftDeletes;
|
2020-04-09 20:48:04 +10:00
|
|
|
use Filterable;
|
|
|
|
|
|
|
|
|
|
protected $fillable = [
|
|
|
|
|
'name'
|
2019-03-27 08:17:28 +11:00
|
|
|
];
|
2019-03-26 15:46:08 +11:00
|
|
|
|
2019-04-25 20:21:07 +10:00
|
|
|
protected $with = [
|
|
|
|
|
];
|
|
|
|
|
|
2019-03-26 15:46:08 +11:00
|
|
|
public function account()
|
|
|
|
|
{
|
|
|
|
|
return $this->belongsTo(Account::class);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public function user()
|
|
|
|
|
{
|
2019-12-31 08:59:12 +11:00
|
|
|
return $this->belongsTo(User::class);
|
2019-03-26 15:46:08 +11:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public function company()
|
|
|
|
|
{
|
2019-12-31 08:59:12 +11:00
|
|
|
return $this->belongsTo(Company::class);
|
2019-03-26 15:46:08 +11:00
|
|
|
}
|
|
|
|
|
}
|