91 lines
1.9 KiB
JSON
91 lines
1.9 KiB
JSON
{
|
|
"name": "Ticket",
|
|
"base": "VnModel",
|
|
"options": {
|
|
"mysql": {
|
|
"table": "ticket"
|
|
}
|
|
},
|
|
"properties": {
|
|
"id": {
|
|
"id": true,
|
|
"type": "Number",
|
|
"description": "Identifier"
|
|
},
|
|
"shipped": {
|
|
"type": "date",
|
|
"required": true
|
|
},
|
|
"landed": {
|
|
"type": "date"
|
|
},
|
|
"nickname": {
|
|
"type": "String"
|
|
},
|
|
"location": {
|
|
"type": "String"
|
|
},
|
|
"solution": {
|
|
"type": "String"
|
|
},
|
|
"packages": {
|
|
"type": "Number"
|
|
},
|
|
"created": {
|
|
"type": "date"
|
|
}
|
|
},
|
|
"relations": {
|
|
"client": {
|
|
"type": "belongsTo",
|
|
"model": "Client",
|
|
"foreignKey": "clientFk"
|
|
},
|
|
"warehouse": {
|
|
"type": "belongsTo",
|
|
"model": "Warehouse",
|
|
"foreignKey": "warehouseFk"
|
|
},
|
|
"invoiceOut": {
|
|
"type": "belongsTo",
|
|
"model": "InvoiceOut",
|
|
"foreignKey": "refFk"
|
|
},
|
|
"address": {
|
|
"type": "belongsTo",
|
|
"model": "Address",
|
|
"foreignKey": "addressFk"
|
|
},
|
|
"route": {
|
|
"type": "belongsTo",
|
|
"model": "Route",
|
|
"foreignKey": "routeFk"
|
|
},
|
|
"company": {
|
|
"type": "belongsTo",
|
|
"model": "Company",
|
|
"foreignKey": "companyFk"
|
|
},
|
|
"agencyMode": {
|
|
"type": "belongsTo",
|
|
"model": "AgencyMode",
|
|
"foreignKey": "agencyModeFk",
|
|
"required": true
|
|
},
|
|
"packages": {
|
|
"type": "hasMany",
|
|
"model": "TicketPackaging",
|
|
"foreignKey": "ticketFk"
|
|
},
|
|
"tracking": {
|
|
"type": "hasOne",
|
|
"model": "TicketTracking",
|
|
"foreignKey": "ticketFk"
|
|
},
|
|
"notes": {
|
|
"type": "hasMany",
|
|
"model": "TicketObservation",
|
|
"foreignKey": "ticketFk"
|
|
}
|
|
}
|
|
} |