mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-05-24 02:14:21 -04:00
* working on js localizations * remove dependencies * Pad Hashes to at least 10 characters in length * Inject JS translations into front end dynamically * Implement VueJS for Client Edit Page with reactivity * Conditionally hide rows if not enabled (custom_value) * Split client template into smaller components * implementing ui buttons * CRUD cycles of a client * Working on Client CRUD - Integrity constraint issues
53 lines
922 B
PHP
53 lines
922 B
PHP
<?php
|
|
|
|
namespace App\Models;
|
|
|
|
use Hashids\Hashids;
|
|
use Illuminate\Notifications\Notifiable;
|
|
use Illuminate\Contracts\Auth\MustVerifyEmail;
|
|
use Illuminate\Foundation\Auth\User as Authenticatable;
|
|
|
|
|
|
class ClientContact extends Authenticatable
|
|
{
|
|
use Notifiable;
|
|
|
|
protected $guard = 'contact';
|
|
|
|
/**
|
|
* The attributes that are mass assignable.
|
|
*
|
|
* @var array
|
|
*/
|
|
protected $fillable = [
|
|
'first_name',
|
|
'last_name',
|
|
'email',
|
|
'password',
|
|
'phone',
|
|
'custom_value1',
|
|
'custom_value2',
|
|
];
|
|
|
|
/**
|
|
* The attributes that should be hidden for arrays.
|
|
*
|
|
* @var array
|
|
*/
|
|
protected $hidden = [
|
|
'password', 'remember_token',
|
|
];
|
|
|
|
|
|
public function client()
|
|
{
|
|
$this->hasOne(Client::class);
|
|
}
|
|
|
|
public function primary_contact()
|
|
{
|
|
$this->where('is_primary', true);
|
|
}
|
|
|
|
}
|