{ "name": "CreditInsurance", "description": "Credit insurance", "base": "VnModel", "options": { "mysql": { "table": "creditInsurance" } }, "properties": { "id": { "id": true, "type": "Number", "description": "Identifier" }, "credit": { "type": "Number" }, "created": { "type": "date", "mysql": { "columnName": "creationDate" } }, "grade": { "type": "Number" } }, "relations": { "classification": { "type": "belongsTo", "model": "CreditClassification", "foreignKey": "creditClassification" } }, "scope": { "include": { "relation": "classification", "scope": { "fields": ["client"], "include": { "relation": "customer", "scope": { "fields": ["name", "salesPersonFk"], "include": { "relation": "salesPerson", "scope": { "fields": "userFk", "include": { "relation": "user", "scope": { "fields": ["name"] } } } } } } } } } }