equipment/mouvements/movement.schema.json

42 lines
1.1 KiB
JSON
Raw Normal View History

{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": ["movement"]
},
"direction" : {
"description": "Entrée ou sortie",
"type": "string",
"enum": ["entrée", "sortie"]
},
"inputNature": {
"description": "Nature de l'entrée",
2023-10-26 10:04:45 +02:00
"type": ["null", "string"]
},
"outputNature": {
"description": "Nature de la sortie",
2023-10-26 10:04:45 +02:00
"type": ["null", "string"]
},
"amount": {
"description": "Quantité ajoutée ou retirée",
"type": "integer",
"minimum": 1
},
"equipment": {
"type": "string"
},
"date" : {
"description": "Date de l'opération",
"type": "string",
"format": "date"
},
"comment": {
"description": "Commentaire additionnel",
"type": ["null", "string"]
}
},
"required": ["type", "direction", "amount", "equipment", "date", "comment"]
}