Skip to content

Commit 6645a0c

Browse files
authored
Merge branch 'development' into corrects-dredd-hooks
2 parents d1cad56 + e55d841 commit 6645a0c

File tree

3 files changed

+21
-21
lines changed

3 files changed

+21
-21
lines changed

app/api/schema/sessions.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ def validate_date(self, data, original_data):
6565
id = fields.Str(dump_only=True)
6666
title = fields.Str(required=True)
6767
subtitle = fields.Str(allow_none=True)
68-
level = fields.Int(allow_none=True)
68+
level = fields.Str(allow_none=True)
6969
short_abstract = fields.Str(allow_none=True)
7070
long_abstract = fields.Str(allow_none=True)
7171
comments = fields.Str(allow_none=True)

docs/api/api_blueprint.apib

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -11231,7 +11231,7 @@ Create a new session using an event_id and track_id **(Minimum Co-Organizer Acce
1123111231
"attributes": {
1123211232
"title": "Micropython Session",
1123311233
"subtitle": "Title",
11234-
"level": 1,
11234+
"level": "1",
1123511235
"short-abstract": "Short Abstract",
1123611236
"long-abstract": "The Long Abstract",
1123711237
"comments": "Comment",
@@ -11293,7 +11293,7 @@ Create a new session using an event_id and track_id **(Minimum Co-Organizer Acce
1129311293
"attributes": {
1129411294
"title": "Micropython Session",
1129511295
"subtitle": null,
11296-
"level": 1,
11296+
"level": "1",
1129711297
"short-abstract": null,
1129811298
"average-rating": 4.25,
1129911299
"long-abstract": null,
@@ -11381,7 +11381,7 @@ Get a single session. **(Public)**
1138111381
"attributes": {
1138211382
"title": "Micropython Session",
1138311383
"subtitle": null,
11384-
"level": 1,
11384+
"level": "1",
1138511385
"short-abstract": null,
1138611386
"average-rating": 4.25,
1138711387
"long-abstract": null,
@@ -11435,7 +11435,7 @@ Update a single session by `id`. **(Minimum Co-Organizer Access)**
1143511435
"data": {
1143611436
"attributes": {
1143711437
"title": "Micropython Session",
11438-
"level": 1,
11438+
"level": "1",
1143911439
"starts-at": "2017-06-01T10:00:00.500127+00:00",
1144011440
"ends-at": "2017-06-01T11:00:00.500127+00:00",
1144111441
"created-at": "2017-05-01T01:24:47.500127+00:00",
@@ -11485,7 +11485,7 @@ Update a single session by `id`. **(Minimum Co-Organizer Access)**
1148511485
"attributes": {
1148611486
"title": "Micropython Session",
1148711487
"subtitle": null,
11488-
"level": 1,
11488+
"level": "1",
1148911489
"short-abstract": null,
1149011490
"average-rating": 4.25,
1149111491
"long-abstract": null,
@@ -11548,7 +11548,7 @@ Delete a single session. **(Minimum Co-Organizer Access)**
1154811548
+ sort (optional, string, `created-at`) - Sort the resources according to the given attribute in ascending order. Append '-' to sort in descending order.
1154911549
+ filter (optional, string, `[]`) - Filter according to the flask-rest-jsonapi filtering system. Please refer: http://flask-rest-jsonapi.readthedocs.io/en/latest/filtering.html for more.
1155011550

11551-
### List Sessions [GET]
11551+
### List Sessions under an Event [GET]
1155211552

1155311553
+ Request
1155411554

@@ -11615,7 +11615,7 @@ Delete a single session. **(Minimum Co-Organizer Access)**
1161511615
"submitted-at": "2017-05-01T01:24:47.500127+00:00",
1161611616
"comments": "Comment",
1161711617
"video-url": "http://example.com/example",
11618-
"level": 1,
11618+
"level": "1",
1161911619
"deleted-at": null,
1162011620
"starts-at": "2017-06-01T10:00:00.500127+00:00",
1162111621
"is-mail-sent": false,
@@ -11645,7 +11645,7 @@ Delete a single session. **(Minimum Co-Organizer Access)**
1164511645
+ sort (optional, string, `created-at`) - Sort the resources according to the given attribute in ascending order. Append '-' to sort in descending order.
1164611646
+ filter (optional, string, `[]`) - Filter according to the flask-rest-jsonapi filtering system. Please refer: http://flask-rest-jsonapi.readthedocs.io/en/latest/filtering.html for more.
1164711647

11648-
### List Sessions [GET]
11648+
### List Sessions under a Track [GET]
1164911649

1165011650
+ Request
1165111651

@@ -11712,7 +11712,7 @@ Delete a single session. **(Minimum Co-Organizer Access)**
1171211712
"submitted-at": "2017-05-01T01:24:47.500127+00:00",
1171311713
"comments": "Comment",
1171411714
"video-url": "http://example.com/example",
11715-
"level": 1,
11715+
"level": "1",
1171611716
"deleted-at": null,
1171711717
"starts-at": "2017-06-01T10:00:00.500127+00:00",
1171811718
"is-mail-sent": false,
@@ -11742,7 +11742,7 @@ Delete a single session. **(Minimum Co-Organizer Access)**
1174211742
+ sort (optional, string, `created-at`) - Sort the resources according to the given attribute in ascending order. Append '-' to sort in descending order.
1174311743
+ filter (optional, string, `[]`) - Filter according to the flask-rest-jsonapi filtering system. Please refer: http://flask-rest-jsonapi.readthedocs.io/en/latest/filtering.html for more.
1174411744

11745-
### List Sessions [GET]
11745+
### List Sessions under a Session Type [GET]
1174611746

1174711747
+ Request
1174811748

@@ -11809,7 +11809,7 @@ Delete a single session. **(Minimum Co-Organizer Access)**
1180911809
"submitted-at": "2017-05-01T01:24:47.500127+00:00",
1181011810
"comments": "Comment",
1181111811
"video-url": "http://example.com/example",
11812-
"level": 1,
11812+
"level": "1",
1181311813
"deleted-at": null,
1181411814
"starts-at": "2017-06-01T10:00:00.500127+00:00",
1181511815
"is-mail-sent": false,
@@ -11839,7 +11839,7 @@ Delete a single session. **(Minimum Co-Organizer Access)**
1183911839
+ sort (optional, string, `created-at`) - Sort the resources according to the given attribute in ascending order. Append '-' to sort in descending order.
1184011840
+ filter (optional, string, `[]`) - Filter according to the flask-rest-jsonapi filtering system. Please refer: http://flask-rest-jsonapi.readthedocs.io/en/latest/filtering.html for more.
1184111841

11842-
### List Sessions [GET]
11842+
### List Sessions under a Microlocation [GET]
1184311843

1184411844
+ Request
1184511845

@@ -11906,7 +11906,7 @@ Delete a single session. **(Minimum Co-Organizer Access)**
1190611906
"submitted-at": "2017-05-01T01:24:47.500127+00:00",
1190711907
"comments": "Comment",
1190811908
"video-url": "http://example.com/example",
11909-
"level": 1,
11909+
"level": "1",
1191011910
"deleted-at": null,
1191111911
"starts-at": "2017-06-01T10:00:00.500127+00:00",
1191211912
"is-mail-sent": false,
@@ -11936,7 +11936,7 @@ Delete a single session. **(Minimum Co-Organizer Access)**
1193611936
+ sort (optional, string, `created-at`) - Sort the resources according to the given attribute in ascending order. Append '-' to sort in descending order.
1193711937
+ filter (optional, string, `[]`) - Filter according to the flask-rest-jsonapi filtering system. Please refer: http://flask-rest-jsonapi.readthedocs.io/en/latest/filtering.html for more.
1193811938

11939-
### List Sessions [GET]
11939+
### List Sessions under a Speaker [GET]
1194011940

1194111941
+ Request
1194211942

@@ -12003,7 +12003,7 @@ Delete a single session. **(Minimum Co-Organizer Access)**
1200312003
"submitted-at": "2017-05-01T01:24:47.500127+00:00",
1200412004
"comments": "Comment",
1200512005
"video-url": "http://example.com/example",
12006-
"level": 1,
12006+
"level": "1",
1200712007
"deleted-at": null,
1200812008
"starts-at": "2017-06-01T10:00:00.500127+00:00",
1200912009
"is-mail-sent": false,

tests/hook_main.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1068,7 +1068,7 @@ def session_delete(transaction):
10681068
db.session.commit()
10691069

10701070

1071-
@hooks.before("Sessions > List Sessions under an Event > List Sessions")
1071+
@hooks.before("Sessions > List Sessions under an Event > List Sessions under an Event")
10721072
def event_session(transaction):
10731073
"""
10741074
GET /events/1/sessions
@@ -1081,7 +1081,7 @@ def event_session(transaction):
10811081
db.session.commit()
10821082

10831083

1084-
@hooks.before("Sessions > List Sessions under a Track > List Sessions")
1084+
@hooks.before("Sessions > List Sessions under a Track > List Sessions under a Track")
10851085
def track_session(transaction):
10861086
"""
10871087
GET /tracks/1/sessions
@@ -1094,7 +1094,7 @@ def track_session(transaction):
10941094
db.session.commit()
10951095

10961096

1097-
@hooks.before("Sessions > List Sessions under a Session Type > List Sessions")
1097+
@hooks.before("Sessions > List Sessions under a Session Type > List Sessions under a Session Type")
10981098
def session_type_session(transaction):
10991099
"""
11001100
GET /session-types/1/sessions
@@ -1107,7 +1107,7 @@ def session_type_session(transaction):
11071107
db.session.commit()
11081108

11091109

1110-
@hooks.before("Sessions > List Sessions under a Microlocation > List Sessions")
1110+
@hooks.before("Sessions > List Sessions under a Microlocation > List Sessions under a Microlocation")
11111111
def microlocation_session(transaction):
11121112
"""
11131113
GET /microlations/1/sessions
@@ -1120,7 +1120,7 @@ def microlocation_session(transaction):
11201120
db.session.commit()
11211121

11221122

1123-
@hooks.before("Sessions > List Sessions under a Speaker > List Sessions")
1123+
@hooks.before("Sessions > List Sessions under a Speaker > List Sessions under a Speaker")
11241124
def speaker_session(transaction):
11251125
"""
11261126
GET /speakers/1/sessions

0 commit comments

Comments
 (0)