Skip to content

Commit 0f3e266

Browse files
authored
extensions: Support id and name (#327)
* Wrap topic type with object supporting id and name * Update topic_type_GET.json * c * Add status * Add label, priority, stage schemas * Add readme for stage, priority and labels * Add user extension * Fix more * more fixes * Add topic event value wrapper * Update comment event * refactor user * refactor * c * c * Fix event action * Add topic status type * Add id to custom field enumValues * Update README.md * Perhaps * c * c * c
1 parent f4f5035 commit 0f3e266

18 files changed

+271
-181
lines changed

README.md

Lines changed: 130 additions & 105 deletions
Large diffs are not rendered by default.

Schemas/Collaboration/Comment/comment_GET.json

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
},
1313
"author": {
1414
"required": true,
15-
"type": "string"
15+
"$ref": "../../User/user_GET.json"
1616
},
1717
"comment": {
1818
"required": true,
@@ -31,8 +31,7 @@
3131
"null"]
3232
},
3333
"modified_author": {
34-
"type": ["string",
35-
"null"]
34+
"$ref": "../../User/user_GET.json"
3635
},
3736
"authorization": {
3837
"type": "object",

Schemas/Collaboration/Events/comment_event_GET.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
},
1717
"author": {
1818
"required": true,
19-
"type": "string"
19+
"$ref": "../../User/user_GET.json"
2020
},
2121
"actions": {
2222
"type": "array",

Schemas/Collaboration/Events/event_action.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,7 @@
77
"type": "string"
88
},
99
"value": {
10-
"type": ["string",
11-
"null"]
10+
"$ref": "event_action_value.json"
1211
}
1312
}
1413
}
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
{
2+
"title": "event_action",
3+
"type": ["object", "null"],
4+
"properties": {
5+
"id": {
6+
"type": ["string", "null"]
7+
},
8+
"displayValue": {
9+
"type": ["string", "null"]
10+
}
11+
}
12+
}

Schemas/Collaboration/Events/topic_event_GET.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
},
1313
"author": {
1414
"required": true,
15-
"type": "string"
15+
"$ref": "../../User/user_GET.json"
1616
},
1717
"actions": {
1818
"type": "array",
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
{
2+
"title": "extension_item_get",
3+
"type": ["object", "null"],
4+
"properties": {
5+
"id": {
6+
"type": "string",
7+
"required": true
8+
},
9+
"name": {
10+
"type": "string",
11+
"required": true
12+
}
13+
}
14+
}
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
{
2+
"title": "extension_item_set",
3+
"type": ["object", "null"],
4+
"properties": {
5+
"id": {
6+
"type": "string",
7+
"required": true
8+
}
9+
}
10+
}

Schemas/Collaboration/Topic/topic_GET.json

Lines changed: 9 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"title": "topic_GET",
3-
"type": "object",
3+
"type": ["object", "null"],
44
"properties": {
55
"guid": {
66
"required": true,
@@ -11,12 +11,10 @@
1111
"type": "string"
1212
},
1313
"topic_type": {
14-
"type": ["string",
15-
"null"]
14+
"$ref": "extension_item_GET.json"
1615
},
1716
"topic_status": {
18-
"type": ["string",
19-
"null"]
17+
"$ref": "extension_item_GET.json"
2018
},
2119
"reference_links": {
2220
"type": ["array",
@@ -30,8 +28,7 @@
3028
"type": "string"
3129
},
3230
"priority": {
33-
"type": ["string",
34-
"null"]
31+
"$ref": "extension_item_GET.json"
3532
},
3633
"index": {
3734
"type": [
@@ -43,8 +40,7 @@
4340
"type": ["array",
4441
"null"],
4542
"items": {
46-
"type": ["string",
47-
"null"]
43+
"$ref": "extension_item_GET.json"
4844
}
4945
},
5046
"creation_date": {
@@ -53,22 +49,19 @@
5349
},
5450
"creation_author": {
5551
"required": true,
56-
"type": "string"
52+
"$ref": "../../User/user_GET.json"
5753
},
5854
"modified_date": {
5955
"type": "string"
6056
},
6157
"modified_author": {
62-
"type": ["string",
63-
"null"]
58+
"$ref": "../../User/user_GET.json"
6459
},
6560
"assigned_to": {
66-
"type": ["string",
67-
"null"]
61+
"$ref": "../../User/user_GET.json"
6862
},
6963
"stage": {
70-
"type": ["string",
71-
"null"]
64+
"$ref": "extension_item_GET.json"
7265
},
7366
"description": {
7467
"type": ["string",

Schemas/Collaboration/Topic/topic_POST.json

Lines changed: 6 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,10 @@
99
"null"]
1010
},
1111
"topic_type": {
12-
"type": ["string",
13-
"null"]
12+
"$ref": "extension_item_SET.json"
1413
},
1514
"topic_status": {
16-
"type": ["string",
17-
"null"]
15+
"$ref": "extension_item_SET.json"
1816
},
1917
"reference_links": {
2018
"type": ["array",
@@ -28,8 +26,7 @@
2826
"type": "string"
2927
},
3028
"priority": {
31-
"type": ["string",
32-
"null"]
29+
"$ref": "extension_item_SET.json"
3330
},
3431
"index": {
3532
"type": [
@@ -41,17 +38,14 @@
4138
"type": ["array",
4239
"null"],
4340
"items": {
44-
"type": ["string",
45-
"null"]
41+
"$ref": "extension_item_SET.json"
4642
}
4743
},
4844
"assigned_to": {
49-
"type": ["string",
50-
"null"]
45+
"$ref": "extension_item_SET.json"
5146
},
5247
"stage": {
53-
"type": ["string",
54-
"null"]
48+
"$ref": "extension_item_SET.json"
5549
},
5650
"description": {
5751
"type": ["string",

Schemas/Collaboration/Topic/topic_PUT.json

Lines changed: 6 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,10 @@
55
"type": "object",
66
"properties": {
77
"topic_type": {
8-
"type": ["string",
9-
"null"]
8+
"$ref": "extension_item_SET.json"
109
},
1110
"topic_status": {
12-
"type": ["string",
13-
"null"]
11+
"$ref": "extension_item_SET.json"
1412
},
1513
"reference_links": {
1614
"type": ["array",
@@ -24,8 +22,7 @@
2422
"type": "string"
2523
},
2624
"priority": {
27-
"type": ["string",
28-
"null"]
25+
"$ref": "extension_item_SET.json"
2926
},
3027
"index": {
3128
"type": [
@@ -37,17 +34,14 @@
3734
"type": ["array",
3835
"null"],
3936
"items": {
40-
"type": ["string",
41-
"null"]
37+
"$ref": "extension_item_SET.json"
4238
}
4339
},
4440
"assigned_to": {
45-
"type": ["string",
46-
"null"]
41+
"$ref": "extension_item_SET.json"
4742
},
4843
"stage": {
49-
"type": ["string",
50-
"null"]
44+
"$ref": "extension_item_SET.json"
5145
},
5246
"description": {
5347
"type": ["string",

Schemas/Collaboration/Viewpoint/viewpoint_GET.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@
4545
},
4646
"creation_author": {
4747
"required": true,
48-
"type": "string"
48+
"$ref": "../../User/user_GET.json"
4949
},
5050
"authorization": {
5151
"type": "object",

Schemas/Project/custom_field.json

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,14 @@
4040
"value": {
4141
"required": true,
4242
"type": "string"
43+
},
44+
"displayValue": {
45+
"required": true,
46+
"type": "string"
47+
},
48+
"readonly": {
49+
"required": true,
50+
"type": "boolean"
4351
}
4452
}
4553
}

Schemas/Project/extension_item.json

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
{
2+
"title": "extension_item",
3+
"type": ["object", "null"],
4+
"properties": {
5+
"id": {
6+
"type": "string",
7+
"required": true
8+
},
9+
"name": {
10+
"type": "string",
11+
"required": true
12+
}
13+
}
14+
}

Schemas/Project/extensions_GET.json

Lines changed: 12 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -4,56 +4,44 @@
44
"properties": {
55
"topic_type": {
66
"required": true,
7-
"type": ["array",
8-
"null"],
7+
"type": ["array", "null"],
98
"items": {
10-
"type": ["string",
11-
"null"]
9+
"$ref": "extension_item.json"
1210
}
1311
},
1412
"topic_status": {
1513
"required": true,
16-
"type": ["array",
17-
"null"],
14+
"type": ["array", "null"],
1815
"items": {
19-
"type": ["string",
20-
"null"]
16+
"$ref": "topic_status_extension_item.json"
2117
}
2218
},
2319
"topic_label": {
2420
"required": true,
25-
"type": ["array",
26-
"null"],
21+
"type": ["array", "null"],
2722
"items": {
28-
"type": ["string",
29-
"null"]
23+
"$ref": "extension_item.json"
3024
}
3125
},
3226
"priority": {
3327
"required": true,
34-
"type": ["array",
35-
"null"],
28+
"type": ["array", "null"],
3629
"items": {
37-
"type": ["string",
38-
"null"]
30+
"$ref": "extension_item.json"
3931
}
4032
},
4133
"users": {
4234
"required": true,
43-
"type": ["array",
44-
"null"],
35+
"type": ["array", "null"],
4536
"items": {
46-
"type": ["string",
47-
"null"]
37+
"$ref": "user_extension_item.json"
4838
}
4939
},
5040
"stage": {
5141
"required": true,
52-
"type": ["array",
53-
"null"],
42+
"type": ["array", "null"],
5443
"items": {
55-
"type": ["string",
56-
"null"]
44+
"$ref": "extension_item.json"
5745
}
5846
},
5947
"project_actions": {
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
{
2+
"title": "topic_status_extension_item",
3+
"type": ["object", "null"],
4+
"properties": {
5+
"id": {
6+
"type": "string",
7+
"required": true
8+
},
9+
"name": {
10+
"type": "string",
11+
"required": true
12+
},
13+
"status_type": {
14+
"type": "string",
15+
"enum": ["open", "closed"],
16+
"required": true
17+
}
18+
}
19+
}
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{
2+
"title": "user_extension_item",
3+
"type": ["object", "null"],
4+
"properties": {
5+
"id": {
6+
"type": "string",
7+
"required": true
8+
},
9+
"name": {
10+
"type": "string",
11+
"required": false
12+
},
13+
"email": {
14+
"type": "string",
15+
"required": true
16+
}
17+
}
18+
}

0 commit comments

Comments
 (0)