From cb5c58878e9f61e8333f28087541ee00896674c2 Mon Sep 17 00:00:00 2001 From: Andreas Huber <anh@fjd.de> Date: Mon, 6 Apr 2020 13:52:25 +0200 Subject: [PATCH] Abgleich mit Labor Wohngeld --- models/common/address-international.json | 28 ++++++++++-------------- models/common/address-national.json | 16 ++++++++++++-- models/common/phone.json | 2 +- 3 files changed, 26 insertions(+), 20 deletions(-) diff --git a/models/common/address-international.json b/models/common/address-international.json index 69bd2b4c..99a35939 100644 --- a/models/common/address-international.json +++ b/models/common/address-international.json @@ -1,21 +1,8 @@ { - "title": "International Address", "type": "object", + "title": "International Address", "description": "Eine internationale Adresse, bestehend aus ein bis fünf Adresszeilen.", - "x-examples": { - "example-1": { - "lines": [ - "760 United Nations Plaza", - "Manhattan, New York City, New York 10017" - ] - }, - "example-2": { - "lines": [ - "Threadneedle Street", - "London EC2R 8AH" - ] - } - }, + "additionalProperties": false, "properties": { "lines": { "type": "array", @@ -29,7 +16,14 @@ }, "country": { "type": "string", - "description": "Staat" + "description": "Staat gemäß Codeliste [https://www.xrepository.de/details/urn:de:bund:destatis:bevoelkerungsstatistik:schluessel:staat](Codeliste Staat aus der Staats- und Gebietssystematik des Statistischen Bundesamtes)", + "minLength": 3, + "maxLength": 3, + "pattern": "^[0-9]{3}$" } - } + }, + "required": [ + "lines", + "country" + ] } \ No newline at end of file diff --git a/models/common/address-national.json b/models/common/address-national.json index a89ec43b..a5b1bf9f 100644 --- a/models/common/address-national.json +++ b/models/common/address-national.json @@ -11,6 +11,7 @@ }, "oneOf": [ { + "additionalProperties": false, "properties": { "street": { "type": "string", @@ -24,6 +25,7 @@ ], "description": "Hausnummer", "maxLength": 9, + "pattern": "^[1-9][0-9]{0,3}(-[1-9][0-9]{0,3})?$", "minimum": 1 }, "house-number-suffix": { @@ -48,9 +50,15 @@ "type": "string", "description": "Adresszusatz" } - } + }, + "required": [ + "street", + "postal-code", + "city" + ] }, { + "additionalProperties": false, "properties": { "post-office-box": { "type": "string", @@ -68,7 +76,11 @@ "description": "Ort", "maxLength": 50 } - } + }, + "required": [ + "postal-code", + "city" + ] } ], "type": "object" diff --git a/models/common/phone.json b/models/common/phone.json index 5638af8e..b9202f1b 100644 --- a/models/common/phone.json +++ b/models/common/phone.json @@ -7,7 +7,7 @@ "number": { "type": "string", "title": "Phone Number", - "description": "Telefonnummer im internationalen Format, z.B. \"+49 89 32168-42\". Muss mit einem Plus beginnen und darf danach außer Ziffern nur Leerzeichen ( ) und Bindestriche (-) enthalten.", + "description": "Telefonnummer gemäß ITU E.123. Es soll das internationalen Format, z.B. \"+49 89 32168-42\" verwendet werden.", "example": "+49 89 32168-42", "maxLength": 23 }, -- GitLab