From f0690c7b1ea690c4afa6eec754958bd83837a5b0 Mon Sep 17 00:00:00 2001 From: domi41 Date: Sun, 6 Sep 2020 05:17:26 +0200 Subject: [PATCH] feat: add a UUID to the proposals Mostly to see if it works. If it does, we should probably add UUIDs everywhere. --- openapi/components/schemas/proposal.yaml | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/openapi/components/schemas/proposal.yaml b/openapi/components/schemas/proposal.yaml index 143e144..0c6888e 100644 --- a/openapi/components/schemas/proposal.yaml +++ b/openapi/components/schemas/proposal.yaml @@ -1,22 +1,30 @@ +# Thing unto which the participants pass judgments. +# Also known as Candidate. type: object properties: id: type: integer - description: A unique identifier. + description: A unique identifier for the proposal, in the poll. readOnly: true example: 4 + uuid: + type: uuid + description: A Universally Unique IDentifier for the proposal. (version 4) + readOnly: true + example: bb788552-727d-470b-827e-d7796248d293 name: type: string description: Unique but short name of the proposal. example: A new school + description: + type: string + description: An optional description of the proposal. (no markup allowed) + example: This school would welcome 500 pupils. ballots: type: array description: The ballots received by this proposal. items: $ref: ./ballot.yaml - description: - type: string - description: An optional description of the proposal - example: This school would welcome 500 pupils. + required: - name