69 lines
1.4 KiB
JSON
69 lines
1.4 KiB
JSON
{
|
|
"name": "InvoiceOut",
|
|
"base": "VnModel",
|
|
"options": {
|
|
"mysql": {
|
|
"table": "invoiceOut"
|
|
}
|
|
},
|
|
"properties": {
|
|
"id": {
|
|
"id": true,
|
|
"type": "Number",
|
|
"description": "Identifier"
|
|
},
|
|
"ref": {
|
|
"type": "String",
|
|
"required": true
|
|
},
|
|
"serial": {
|
|
"type": "String"
|
|
},
|
|
"issued": {
|
|
"type": "date"
|
|
},
|
|
"amount": {
|
|
"type": "Number"
|
|
},
|
|
"created": {
|
|
"type": "date"
|
|
},
|
|
"dued": {
|
|
"type": "date"
|
|
},
|
|
"booked": {
|
|
"type": "date"
|
|
},
|
|
"hasPdf": {
|
|
"type": "Boolean"
|
|
}
|
|
},
|
|
"relations": {
|
|
"client": {
|
|
"type": "belongsTo",
|
|
"model": "Client",
|
|
"foreignKey": "clientFk"
|
|
},
|
|
"company": {
|
|
"type": "belongsTo",
|
|
"model": "Company",
|
|
"foreignKey": "companyFk",
|
|
"required": true
|
|
},
|
|
"supplier": {
|
|
"type": "belongsTo",
|
|
"model": "Supplier",
|
|
"foreignKey": "companyFk",
|
|
"required": true
|
|
},
|
|
"tickets": {
|
|
"type": "hasMany",
|
|
"model": "Ticket",
|
|
"foreignKey": "refFk",
|
|
"primaryKey": "ref"
|
|
}
|
|
}
|
|
}
|
|
|
|
|