|
1 | 1 | from django.conf import settings
|
2 | 2 | from django.utils.translation import gettext_lazy as _
|
3 | 3 |
|
4 |
| -description = _( |
| 4 | +DESCRIPTION = _( |
5 | 5 | """
|
6 | 6 | **Warning: Difference between `PUT` and `PATCH`**
|
7 | 7 |
|
|
16 | 16 | leaving other fields unchanged.
|
17 | 17 | """
|
18 | 18 | )
|
19 |
| -partijen_description = _( |
| 19 | +PARTIJ_IDENTIFICATOR_DESCRIPTION_CREATE = _( |
| 20 | + """ |
| 21 | +**Warnings:** |
| 22 | +
|
| 23 | +Handles `partijIdentificatoren` creation with atomicity guarantees. |
| 24 | +
|
| 25 | +- If the `UUID` is provided in the `PartijIdentificator` object, |
| 26 | +the endpoint will treat it as an update operation for the existing `PartijIdentificator`, |
| 27 | +applying the provided data and linking the parent `Partij` to the new one created. |
| 28 | +- If the `UUID` is **not** specified, the system will create a new |
| 29 | +`PartijIdentificator` instance respecting all uniqueness constraints. |
| 30 | + """ |
| 31 | +) |
| 32 | + |
| 33 | +PARTIJ_IDENTIFICATOR_DESCRIPTION_UPDATE = _( |
| 34 | + """ |
| 35 | +**Warnings:** |
| 36 | +
|
| 37 | +Handles `partijIdentificatoren` updates with atomicity guarantees. |
| 38 | +
|
| 39 | +- If the `UUID` is provided in the `PartijIdentificator` object, |
| 40 | +the system will update the specified instance with the new data. |
| 41 | +- If the `UUID` is **not** specified, the system will `DELETE` all `PartijIdentificator` |
| 42 | +objects related to the parent and `CREATE` new ones with the new passed data. |
| 43 | + """ |
| 44 | +) |
| 45 | + |
| 46 | +PARTIJEN_DESCRIPTION = _( |
20 | 47 | """
|
21 | 48 | **Atomicity in Partij and PartijIdentificator**
|
22 | 49 |
|
|
27 | 54 |
|
28 | 55 | For `POST`, `PATCH`, and `PUT` requests for `Partij`,
|
29 | 56 | it is possible to send a list of `PartijIdentificator` objects.
|
30 |
| -
|
31 |
| -**Warnings:** |
32 |
| -
|
33 |
| -- In all requests, `PartijIdentificator` objects should not contain the **UUID** |
34 |
| -of the parent `Partij`, because it is automatically assigned. |
35 |
| -- `POST` request: |
36 |
| - - If the **UUID** is provided in the `PartijIdentificator` object, |
37 |
| - the endpoint will treat it as an update operation for the existing `PartijIdentificator`, |
38 |
| - applying the provided data and linking the parent `Partij` to the new one created. |
39 |
| - - If the **UUID** is **not** specified, the system will create a new |
40 |
| - `PartijIdentificator` instance respecting all uniqueness constraints. |
41 |
| -- `PATCH` or `PUT` requests: |
42 |
| - - If the **UUID** is provided in the `PartijIdentificator` object, |
43 |
| - the system will update the specified instance with the new data. |
44 |
| - - If the **UUID** is **not** specified, the system will `DELETE` all `PartijIdentificator` |
45 |
| - objects related to the parent and `CREATE` new ones with the passed data. |
46 | 57 | """
|
47 | 58 | )
|
48 | 59 |
|
| 60 | + |
49 | 61 | custom_settings = {
|
50 | 62 | "TITLE": "klantinteracties",
|
51 |
| - "DESCRIPTION": description, |
| 63 | + "DESCRIPTION": DESCRIPTION, |
52 | 64 | "VERSION": settings.KLANTINTERACTIES_API_VERSION,
|
53 | 65 | "SERVERS": [{"url": "/klantinteracties/api/v1"}],
|
54 | 66 | "TAGS": [
|
|
63 | 75 | {"name": "klanten contacten"},
|
64 | 76 | {"name": "onderwerpobjecten"},
|
65 | 77 | {"name": "partij-identificatoren"},
|
66 |
| - {"name": "partijen", "description": partijen_description}, |
| 78 | + {"name": "partijen", "description": PARTIJEN_DESCRIPTION}, |
67 | 79 | {"name": "rekeningnummers"},
|
68 | 80 | {"name": "vertegenwoordigingen"},
|
69 | 81 | ],
|
|
0 commit comments