Skip to content
Snippets Groups Projects
Commit a3d4ad59 authored by Felix Blanke's avatar Felix Blanke
Browse files

Disallow additional properties

parent 9e376015
No related branches found
No related tags found
1 merge request!25Feature: Use JSON schema
......@@ -33,7 +33,8 @@
"description": "IDs of all AKs that should be scheduled before this AK"
}
},
"required": ["conflicts", "dependencies"]
"required": ["conflicts", "dependencies"],
"additionalProperties": false
},
"info": {
"type": "object",
......@@ -43,8 +44,10 @@
"description": {"description": "Short description of the AK", "type": "string"},
"reso": {"description": "Whether this AK intends to introduce a resolution", "type": "boolean"}
},
"required": ["name", "head", "description", "reso"]
"required": ["name", "head", "description", "reso"],
"additionalProperties": false
}
},
"required": ["id", "duration", "room_constraints", "time_constraints", "properties", "info"]
"required": ["id", "duration", "room_constraints", "time_constraints", "properties", "info"],
"additionalProperties": false
}
......@@ -33,7 +33,8 @@
]
}
},
"required": ["ak_id", "required", "preference_score"]
"required": ["ak_id", "required", "preference_score"],
"additionalProperties": false
},
"uniqueItems": true
},
......@@ -48,8 +49,10 @@
"info": {
"type": "object",
"properties": {"name": {"description": "Name of the person", "type": "string"}},
"required": ["name"]
"required": ["name"],
"additionalProperties": false
}
},
"required": ["id", "room_constraints", "time_constraints", "info"]
"required": ["id", "room_constraints", "time_constraints", "info"],
"additionalProperties": false
}
......@@ -26,8 +26,10 @@
"properties": {
"name": {"description": "Name of the room", "type": "string"}
},
"required": ["name"]
"required": ["name"],
"additionalProperties": false
}
},
"required": ["id", "capacity", "fulfilled_room_constraints", "time_constraints", "info"]
"required": ["id", "capacity", "fulfilled_room_constraints", "time_constraints", "info"],
"additionalProperties": false
}
\ No newline at end of file
......@@ -41,7 +41,8 @@
"uniqueItems": true
}
},
"required": ["ak_id", "room_id", "timeslot_ids", "participant_ids"]
"required": ["ak_id", "room_id", "timeslot_ids", "participant_ids"],
"additionalProperties": false
},
"uniqueItems": true
}
......
......@@ -4,6 +4,7 @@
"title": "Timeslot",
"type": "object",
"required": ["info", "blocks"],
"additionalProperties": false,
"properties": {
"info": {
"type": "object",
......@@ -19,7 +20,8 @@
}
}
},
"required": ["duration"]
"required": ["duration"],
"additionalProperties": false
},
"blocks": {
"type": "array",
......@@ -41,14 +43,16 @@
"start": {"description": "Start datetime of the timeslot", "type": "string"},
"end": {"description": "End datetime of the timeslot", "type": "string"}
},
"required": ["start", "end"]
"required": ["start", "end"],
"additionalProperties": false
},
"fulfilled_time_constraints": {
"$ref": "/schema/common/constraints.schema.json",
"description": "Time constraints fulfilled by this timeslot"
}
},
"required": ["id", "info", "fulfilled_time_constraints"]
"required": ["id", "info", "fulfilled_time_constraints"],
"additionalProperties": false
}
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment