2016-11-17 11:56:35 +00:00
|
|
|
{
|
|
|
|
"name": "Client",
|
2017-10-11 13:36:47 +00:00
|
|
|
"base": "VnModel",
|
2017-11-22 11:43:12 +00:00
|
|
|
"options": {
|
|
|
|
"mysql": {
|
2018-01-29 11:37:54 +00:00
|
|
|
"table": "client"
|
2017-11-22 11:43:12 +00:00
|
|
|
}
|
|
|
|
},
|
2016-11-17 11:56:35 +00:00
|
|
|
"properties": {
|
|
|
|
"id": {
|
|
|
|
"type": "Number",
|
|
|
|
"id": true,
|
2017-02-07 16:02:17 +00:00
|
|
|
"description": "Identifier"
|
2016-11-17 11:56:35 +00:00
|
|
|
},
|
|
|
|
"name": {
|
|
|
|
"type": "string",
|
2017-01-12 10:02:22 +00:00
|
|
|
"required": true
|
2017-01-24 11:30:17 +00:00
|
|
|
},
|
2016-11-17 11:56:35 +00:00
|
|
|
"fi": {
|
|
|
|
"type": "string",
|
2017-05-23 12:05:26 +00:00
|
|
|
"description": "Fiscal indentifier"
|
2016-11-17 11:56:35 +00:00
|
|
|
},
|
|
|
|
"socialName": {
|
2018-01-11 21:11:35 +00:00
|
|
|
"type": "string",
|
|
|
|
"required": true
|
2016-11-17 11:56:35 +00:00
|
|
|
},
|
|
|
|
"contact": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2017-01-02 06:28:36 +00:00
|
|
|
"street": {
|
2017-01-09 13:58:44 +00:00
|
|
|
"type": "string"
|
2017-01-02 06:28:36 +00:00
|
|
|
},
|
|
|
|
"city": {
|
2017-01-09 13:58:44 +00:00
|
|
|
"type": "string"
|
2017-01-02 06:28:36 +00:00
|
|
|
},
|
2017-05-09 12:04:44 +00:00
|
|
|
"postcode": {
|
|
|
|
"type": "string"
|
2017-04-28 13:04:29 +00:00
|
|
|
},
|
2016-11-17 11:56:35 +00:00
|
|
|
"email": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
"phone": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2017-01-17 10:26:59 +00:00
|
|
|
"mobile": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2017-11-22 11:43:12 +00:00
|
|
|
"isActive": {
|
2016-11-17 11:56:35 +00:00
|
|
|
"type": "boolean"
|
2016-12-15 15:55:11 +00:00
|
|
|
},
|
2016-11-17 11:56:35 +00:00
|
|
|
"credit": {
|
|
|
|
"type": "Number"
|
|
|
|
},
|
2017-05-09 12:04:44 +00:00
|
|
|
"creditInsurance": {
|
2016-11-17 11:56:35 +00:00
|
|
|
"type": "Number"
|
|
|
|
},
|
|
|
|
"iban": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2017-01-02 06:28:36 +00:00
|
|
|
"dueDay": {
|
|
|
|
"type": "Number"
|
|
|
|
},
|
2017-11-22 07:59:21 +00:00
|
|
|
"isEqualizated": {
|
2016-11-17 11:56:35 +00:00
|
|
|
"type": "boolean",
|
2017-05-10 15:18:25 +00:00
|
|
|
"description": "The client has equalization tax"
|
2016-11-17 11:56:35 +00:00
|
|
|
},
|
2017-11-13 10:47:41 +00:00
|
|
|
"hasToInvoiceByAddress": {
|
|
|
|
"type": "boolean",
|
|
|
|
"description": "The client has to be invoiced by address"
|
|
|
|
},
|
2016-11-17 11:56:35 +00:00
|
|
|
"hasToInvoice": {
|
|
|
|
"type": "boolean",
|
|
|
|
"description": "Global invoicing enabled for the client"
|
|
|
|
},
|
2017-12-05 10:21:48 +00:00
|
|
|
"isToBeMailed": {
|
2016-11-17 11:56:35 +00:00
|
|
|
"type": "boolean",
|
|
|
|
"description": "Send invoices by email"
|
2017-05-05 10:54:47 +00:00
|
|
|
},
|
2017-11-22 11:43:12 +00:00
|
|
|
"hasSepaVnl": {
|
2017-05-09 12:04:44 +00:00
|
|
|
"type": "boolean"
|
|
|
|
},
|
2017-11-22 07:59:21 +00:00
|
|
|
"hasCoreVnl": {
|
2017-05-09 12:04:44 +00:00
|
|
|
"type": "boolean"
|
|
|
|
},
|
2017-11-22 07:59:21 +00:00
|
|
|
"hasCoreVnh": {
|
2017-05-09 12:04:44 +00:00
|
|
|
"type": "boolean"
|
|
|
|
},
|
2017-11-22 11:43:12 +00:00
|
|
|
"isTaxDataChecked":{
|
|
|
|
"type": "boolean"
|
|
|
|
},
|
2017-05-09 12:04:44 +00:00
|
|
|
"eypbc": {
|
|
|
|
"type": "boolean"
|
|
|
|
},
|
|
|
|
"quality": {
|
2017-05-05 10:54:47 +00:00
|
|
|
"type": "Number"
|
|
|
|
},
|
2017-11-22 07:59:21 +00:00
|
|
|
"isVies": {
|
2017-07-03 12:19:47 +00:00
|
|
|
"type": "boolean"
|
2017-05-09 12:04:44 +00:00
|
|
|
},
|
|
|
|
"isRelevant": {
|
|
|
|
"type": "boolean"
|
|
|
|
},
|
|
|
|
"accountingAccount": {
|
|
|
|
"type": "string"
|
2017-05-12 13:21:37 +00:00
|
|
|
},
|
|
|
|
"created": {
|
|
|
|
"type": "date"
|
2016-11-17 11:56:35 +00:00
|
|
|
}
|
2017-01-24 11:30:17 +00:00
|
|
|
},
|
|
|
|
"relations": {
|
2017-05-12 11:36:12 +00:00
|
|
|
"account": {
|
2017-05-12 09:14:55 +00:00
|
|
|
"type": "belongsTo",
|
2017-01-24 11:30:17 +00:00
|
|
|
"model": "Account",
|
|
|
|
"foreignKey": "id"
|
2017-02-21 10:36:43 +00:00
|
|
|
},
|
2017-05-12 11:36:12 +00:00
|
|
|
"payMethod": {
|
2017-05-12 09:14:55 +00:00
|
|
|
"type": "belongsTo",
|
2017-04-28 13:04:29 +00:00
|
|
|
"model": "PayMethod",
|
2017-05-12 09:14:55 +00:00
|
|
|
"foreignKey": "payMethodFk"
|
2017-04-28 13:04:29 +00:00
|
|
|
},
|
2017-05-12 11:36:12 +00:00
|
|
|
"salesPerson": {
|
2017-05-12 09:14:55 +00:00
|
|
|
"type": "belongsTo",
|
2018-01-29 11:37:54 +00:00
|
|
|
"model": "Worker",
|
2017-05-12 09:14:55 +00:00
|
|
|
"foreignKey": "salesPersonFk"
|
|
|
|
},
|
2017-05-12 11:36:12 +00:00
|
|
|
"province":{
|
2017-05-12 09:14:55 +00:00
|
|
|
"type": "belongsTo",
|
|
|
|
"model": "Province",
|
|
|
|
"foreignKey": "provinceFk"
|
|
|
|
},
|
2017-05-12 11:36:12 +00:00
|
|
|
"country":{
|
2017-05-12 09:14:55 +00:00
|
|
|
"type": "belongsTo",
|
|
|
|
"model": "Country",
|
|
|
|
"foreignKey": "countryFk"
|
|
|
|
},
|
2017-05-12 11:36:12 +00:00
|
|
|
"contactChannel":{
|
2017-05-12 09:14:55 +00:00
|
|
|
"type": "belongsTo",
|
|
|
|
"model": "ContactChannel",
|
|
|
|
"foreignKey": "contactChannelFk"
|
2017-04-28 13:04:29 +00:00
|
|
|
},
|
2017-05-12 11:36:12 +00:00
|
|
|
"type": {
|
|
|
|
"type": "belongsTo",
|
|
|
|
"model": "ClientType",
|
|
|
|
"foreignKey": "typeFk"
|
|
|
|
},
|
|
|
|
"addresses": {
|
2017-02-21 10:36:43 +00:00
|
|
|
"type": "hasMany",
|
|
|
|
"model": "Address",
|
2017-05-09 12:04:44 +00:00
|
|
|
"foreignKey": "clientFk"
|
2017-01-24 11:30:17 +00:00
|
|
|
}
|
2017-10-11 13:36:47 +00:00
|
|
|
}
|
2017-05-17 06:19:03 +00:00
|
|
|
}
|