Apps Community apps Customers Model Person

Model Person

namespace HubletoApp\Customers\Models\Person

List of contact persons existing in the system

Constants

This model does not define constants.

Properties

Property Value
 eloquentClass Eloquent\Contact::Person
 table persons
 lookupSqlValue concat([TABLE].first_name, ' ', [TABLE].last_name)

Properties

Property Value
isJunctionTable FALSE
table persons
lookupSqlValue concat([TABLE].first_name, ' ', [TABLE].last_name)

Data Scructure

Column Title ADIOS Type Length Required
id ID  int TRUE
first_name First Name  varchar TRUE
last_name Last Name  varchar TRUE
is_main Main Contact  boolean FALSE
note Note  text FALSE
date_created Date Created  date TRUE
is_active Active  boolean TRUE
id_company Company  lookup FALSE

Foreign Keys

Column Model Relation OnUpdate OnDelete
id_company Modules\Core\Customers\Models\Company 1:1 Cascade Restrict

Indexes

Only  default indexes are used.

Relations

Relation Type Other parameters
COMPANY BELONGS_TO Company::class, 'id_company'
CONTACTS HAS_MANY Contact::class, 'id_person', 'id'
ADDRESSES HAS_MANY Address::class, 'id_person', 'id'
TAGS HAS_MANY PersonTag::class, 'id_person', 'id'
www.hubleto.com | Found a bug or missing something? Report an issue via GitHub.