{
    "fields": {
        "name": {
            "type": "varchar",
            "required": true,
            "pattern": "$noBadCharacters"
        },
        "description": {
            "type": "text"
        },
        "createdAt": {
            "type": "datetime",
            "readOnly": true
        },
        "modifiedAt": {
            "type": "datetime",
            "readOnly": true
        },
        "createdBy": {
            "type": "link",
            "readOnly": true,
            "view": "views/fields/user"
        },
        "modifiedBy": {
            "type": "link",
            "readOnly": true,
            "view": "views/fields/user"
        },
        "assignedUser": {
            "type": "link",
            "required": false,
            "view": "views/fields/assigned-user"
        },
        "teams": {
            "type": "linkMultiple",
            "view": "views/fields/teams"
        },
        "freigeschalteteNutzer": {
            "type": "link"
        },
        "collaborators": {
            "type": "linkMultiple",
            "view": "views/fields/collaborators",
            "maxCount": 30,
            "fieldManagerParamList": [
                "readOnly",
                "readOnlyAfterCreate",
                "audited",
                "autocompleteOnEmpty",
                "maxCount",
                "inlineEditDisabled",
                "tooltipText"
            ]
        },
        "advowareAktenzeichen": {
            "type": "varchar",
            "required": false,
            "maxLength": 100,
            "tooltip": true,
            "isCustom": true,
            "copyToClipboard": true
        },
        "aktennr": {
            "type": "int",
            "required": false,
            "tooltip": true,
            "isCustom": true
        },
        "advowareLastSync": {
            "type": "datetime",
            "required": false,
            "readOnly": true,
            "tooltip": true,
            "isCustom": true
        },
        "syncStatus": {
            "type": "enum",
            "required": false,
            "options": [
                "clean",
                "unclean",
                "failed"
            ],
            "style": {
                "clean": "success",
                "unclean": "warning",
                "failed": "danger"
            },
            "default": "clean",
            "tooltip": true,
            "isCustom": true
        },
        "gerichtsrubrum": {
            "type": "text",
            "required": false,
            "isCustom": true
        },
        "gegenstandswert": {
            "type": "currency",
            "required": false,
            "default": 0,
            "isCustom": true
        },
        "kuendigungsservice": {
            "type": "bool",
            "required": false,
            "default": false,
            "isCustom": true
        },
        "aussergerichtlicheGebuehren13": {
            "type": "currency",
            "required": false,
            "default": 0,
            "isCustom": true
        },
        "gerichtskosten1Instanz": {
            "type": "currency",
            "required": false,
            "default": 0,
            "isCustom": true
        },
        "anwaltskosten1Instanz": {
            "type": "currency",
            "required": false,
            "default": 0,
            "isCustom": true
        },
        "beendigungsTatbestand": {
            "type": "enum",
            "required": true,
            "options": [
                "Kündigung Vermieter",
                "Kündigung Mieter",
                "Aufhebungsvertrag",
                "Befristung",
                "ZVG Zuschlagsbeschluss"
            ],
            "style": {
                "Kündigung Vermieter": null,
                "Kündigung Mieter": null,
                "Aufhebungsvertrag": null,
                "Befristung": null,
                "ZVG Zuschlagsbeschluss": null
            },
            "default": "Kündigung Vermieter",
            "isCustom": true
        },
        "kuendigungsgrund": {
            "type": "multiEnum",
            "required": false,
            "options": [
                "Mietrückstand",
                "Eigenbedarf",
                "Fehlverhalten",
                "Verwertung",
                "ZVG Eigenbedarf",
                "573a Abs. 1 (nicht mehr als 2 Whng.)",
                "573a Abs. 2 (Einliegerwohnung)",
                "GewerbeOrdentlich"
            ],
            "tooltip": true,
            "isCustom": true
        },
        "kuendigungsgrundDetails": {
            "type": "text",
            "required": false,
            "isCustom": true
        },
        "kuendigungsdatum": {
            "type": "date",
            "required": false,
            "isCustom": true
        },
        "zustelldatum": {
            "type": "date",
            "required": false,
            "isCustom": true
        },
        "kuendigungsfrist": {
            "type": "varchar",
            "required": false,
            "maxLength": 50,
            "isCustom": true
        },
        "beendigungstermin": {
            "type": "date",
            "required": false,
            "isCustom": true
        },
        "status": {
            "type": "enum",
            "required": false,
            "options": [
                "Entwurf",
                "Versendet",
                "Zugestellt",
                "Akzeptiert",
                "Bestritten",
                "Abgewickelt",
                "Zurückgezogen"
            ],
            "default": "Entwurf",
            "isCustom": true
        },
        "zustellart": {
            "type": "enum",
            "required": false,
            "options": [
                "Einschreiben",
                "Persoenlich",
                "Bote",
                "Brief"
            ],
            "isCustom": true
        },
        "sendungsverfolgungsnummer": {
            "type": "varchar",
            "required": false,
            "maxLength": 100,
            "tooltip": true,
            "isCustom": true
        },
        "vorzeitigeRaeumungZulaessig": {
            "type": "enum",
            "required": false,
            "options": [
                "Nein",
                "JaKeinWohnraum257ZPO",
                "JaBesorgnisgrund259ZPO"
            ],
            "default": "Nein",
            "tooltip": true,
            "isCustom": true
        },
        "beschreibungBesorgnisgrund": {
            "type": "text",
            "required": false,
            "tooltip": true,
            "isCustom": true
        },
        "mietrueckstand": {
            "type": "currency",
            "required": false,
            "default": 0,
            "tooltip": true,
            "isCustom": true
        },
        "mietkaution": {
            "type": "currency",
            "required": false,
            "default": 0,
            "tooltip": true,
            "isCustom": true
        },
        "nebenkostenvorauszahlungen": {
            "type": "currency",
            "required": false,
            "default": 0,
            "tooltip": true,
            "isCustom": true
        }
    },
    "links": {
        "createdBy": {
            "type": "belongsTo",
            "entity": "User"
        },
        "modifiedBy": {
            "type": "belongsTo",
            "entity": "User"
        },
        "assignedUser": {
            "type": "belongsTo",
            "entity": "User"
        },
        "teams": {
            "type": "hasMany",
            "entity": "Team",
            "relationName": "entityTeam",
            "layoutRelationshipsDisabled": true
        },
        "meetings": {
            "type": "hasMany",
            "entity": "Meeting",
            "foreign": "parent"
        },
        "calls": {
            "type": "hasMany",
            "entity": "Call",
            "foreign": "parent"
        },
        "tasks": {
            "type": "hasChildren",
            "entity": "Task",
            "foreign": "parent"
        },
        "emails": {
            "type": "hasChildren",
            "entity": "Email",
            "foreign": "parent",
            "layoutRelationshipsDisabled": true
        },
        "vmhMietverhltnises": {
            "type": "hasMany",
            "relationName": "cKuendigungVmhMietverhltnis",
            "foreign": "kndigungen",
            "entity": "CVmhMietverhltnis",
            "audited": false,
            "isCustom": true
        },
        "freigeschalteteNutzer": {
            "type": "belongsTo",
            "foreign": "cKndigungen",
            "entity": "Contact",
            "audited": false,
            "isCustom": true
        },
        "collaborators": {
            "type": "hasMany",
            "entity": "User",
            "relationName": "entityCollaborator",
            "layoutRelationshipsDisabled": true
        },
        "dokumenteskuendigung": {
            "type": "hasMany",
            "relationName": "cDokumenteKuendigung",
            "foreign": "kndigungensdokumente",
            "entity": "CDokumente",
            "audited": false,
            "isCustom": true
        },
        "contactsKuendigung": {
            "type": "hasMany",
            "relationName": "cKuendigungContact",
            "foreign": "cKuendigungContact",
            "entity": "Contact",
            "audited": false,
            "isCustom": true
        },
        "kuendiger": {
            "type": "hasMany",
            "relationName": "cBeteiligteKuendigungKuendiger",
            "foreign": "kndigungenKuendiger",
            "entity": "CBeteiligte",
            "audited": false,
            "isCustom": true
        },
        "gekuendigte": {
            "type": "hasMany",
            "relationName": "cBeteiligteKuendigungGekuendigte",
            "foreign": "kndigungenGekuendigte",
            "entity": "CBeteiligte",
            "audited": false,
            "isCustom": true
        }
    },
    "collection": {
        "orderBy": "createdAt",
        "order": "desc",
        "textFilterFields": [
            "name"
        ],
        "fullTextSearch": false,
        "countDisabled": false
    },
    "indexes": {
        "name": {
            "columns": [
                "name",
                "deleted"
            ]
        },
        "assignedUser": {
            "columns": [
                "assignedUserId",
                "deleted"
            ]
        },
        "createdAt": {
            "columns": [
                "createdAt"
            ]
        },
        "createdAtId": {
            "unique": true,
            "columns": [
                "createdAt",
                "id"
            ]
        },
        "aktennr": {
            "columns": [
                "aktennr"
            ]
        },
        "advowareAktenzeichen": {
            "columns": [
                "advowareAktenzeichen"
            ]
        },
        "status": {
            "columns": [
                "status",
                "deleted"
            ]
        },
        "kuendigungsdatum": {
            "columns": [
                "kuendigungsdatum"
            ]
        },
        "beendigungstermin": {
            "columns": [
                "beendigungstermin"
            ]
        },
        "syncStatus": {
            "columns": [
                "syncStatus",
                "deleted"
            ]
        }
    },
    "optimisticConcurrencyControl": false
}