[mod]
This commit is contained in:
parent
720c8a6623
commit
0ce00bc9f2
1 changed files with 138 additions and 9 deletions
|
@ -29,16 +29,36 @@
|
||||||
"name": "id"
|
"name": "id"
|
||||||
},
|
},
|
||||||
"data_fields": [
|
"data_fields": [
|
||||||
|
{
|
||||||
|
"name": "name",
|
||||||
|
"type": "string_medium",
|
||||||
|
"nullable": false
|
||||||
|
}
|
||||||
],
|
],
|
||||||
"constraints": [
|
"constraints": [
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "events",
|
"name": "local_resources",
|
||||||
"key_field": {
|
"key_field": {
|
||||||
"name": "id"
|
"name": "id"
|
||||||
},
|
},
|
||||||
"data_fields": [
|
"data_fields": [
|
||||||
|
],
|
||||||
|
"constraints": [
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "local_resource_events",
|
||||||
|
"key_field": {
|
||||||
|
"name": "id"
|
||||||
|
},
|
||||||
|
"data_fields": [
|
||||||
|
{
|
||||||
|
"name": "local_resource_id",
|
||||||
|
"type": "integer",
|
||||||
|
"nullable": false
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "name",
|
"name": "name",
|
||||||
"type": "string_medium",
|
"type": "string_medium",
|
||||||
|
@ -65,6 +85,58 @@
|
||||||
"nullable": true
|
"nullable": true
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
"constraints": [
|
||||||
|
{
|
||||||
|
"kind": "foreign_key",
|
||||||
|
"parameters": {
|
||||||
|
"fields": ["local_resource_id"],
|
||||||
|
"reference": {
|
||||||
|
"name": "local_resources",
|
||||||
|
"fields": ["id"]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "caldav_resources",
|
||||||
|
"key_field": {
|
||||||
|
"name": "id"
|
||||||
|
},
|
||||||
|
"data_fields": [
|
||||||
|
{
|
||||||
|
"name": "url",
|
||||||
|
"type": "string_medium",
|
||||||
|
"nullable": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "read_only",
|
||||||
|
"type": "boolean",
|
||||||
|
"nullable": false
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"constraints": [
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "resources",
|
||||||
|
"key_field": {
|
||||||
|
"name": "id"
|
||||||
|
},
|
||||||
|
"data_fields": [
|
||||||
|
{
|
||||||
|
"name": "kind",
|
||||||
|
"type": "string_short",
|
||||||
|
"nullable": false,
|
||||||
|
"description": "»local« | »caldav«"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "sub_id",
|
||||||
|
"type": "integer",
|
||||||
|
"nullable": false,
|
||||||
|
"description": "local_resources.id | caldav_resources.id"
|
||||||
|
}
|
||||||
|
],
|
||||||
"constraints": [
|
"constraints": [
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
@ -80,22 +152,79 @@
|
||||||
"nullable": false
|
"nullable": false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "private",
|
"name": "public",
|
||||||
"type": "boolean",
|
"type": "boolean",
|
||||||
"nullable": false
|
"nullable": false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "kind",
|
"name": "resource_id",
|
||||||
"type": "string_short",
|
"type": "integer",
|
||||||
"nullable": false
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "data",
|
|
||||||
"type": "string_long",
|
|
||||||
"nullable": false
|
"nullable": false
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"constraints": [
|
"constraints": [
|
||||||
|
{
|
||||||
|
"kind": "foreign_key",
|
||||||
|
"parameters": {
|
||||||
|
"fields": ["resource_id"],
|
||||||
|
"reference": {
|
||||||
|
"name": "resources",
|
||||||
|
"fields": ["id"]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "calendar_members",
|
||||||
|
"key_field": {
|
||||||
|
"name": "id"
|
||||||
|
},
|
||||||
|
"data_fields": [
|
||||||
|
{
|
||||||
|
"name": "calendar_id",
|
||||||
|
"type": "integer",
|
||||||
|
"nullable": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "user_id",
|
||||||
|
"type": "integer",
|
||||||
|
"nullable": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "role",
|
||||||
|
"type": "string_medium",
|
||||||
|
"nullable": false,
|
||||||
|
"description": "»admin« | »editor« | »viewer«"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"constraints": [
|
||||||
|
{
|
||||||
|
"kind": "foreign_key",
|
||||||
|
"parameters": {
|
||||||
|
"fields": ["calendar_id"],
|
||||||
|
"reference": {
|
||||||
|
"name": "calendars",
|
||||||
|
"fields": ["id"]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"kind": "foreign_key",
|
||||||
|
"parameters": {
|
||||||
|
"fields": ["user_id"],
|
||||||
|
"reference": {
|
||||||
|
"name": "users",
|
||||||
|
"fields": ["id"]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"kind": "unique",
|
||||||
|
"parameters": {
|
||||||
|
"fields": ["calendar_id","user_id"]
|
||||||
|
}
|
||||||
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
Loading…
Add table
Reference in a new issue