{
    "name": "Country",
    "description": "Worldwide countries",
    "base": "VnModel",
    "options": {
        "mysql": {
            "table": "country"
        }
    },
    "properties": {
        "id": {
            "type": "number",
            "id": true,
            "description": "Identifier"
        },
        "name": {
            "type": "string",
            "required": true
        },
        "code": {
            "type": "string"
        },
        "isUeeMember": {
            "type": "boolean"
        },
        "isSocialNameUnique": {
            "type": "boolean"
        },
        "continentFk": {
            "type": "number"
        },
        "hasDailyInvoice": {
            "type": "boolean",
            "description": "Indicates if the autonomy has daily invoice enabled"
        }
    },
    "relations": {
        "currency": {
            "type": "belongsTo",
            "model": "Currency",
            "foreignKey": "currencyFk"
        },
        "continent": {
            "type": "belongsTo",
            "model": "Continent",
            "foreignKey": "continentFk"
        },
        "saySimpleCountry": {
            "type": "hasOne",
            "model": "SaySimpleCountry",
            "foreignKey": "countryFk"
        }
    },
    "acls": [
        {
            "accessType": "READ",
            "principalType": "ROLE",
            "principalId": "$everyone",
            "permission": "ALLOW"
        }
    ]
}