Bugzilla – Attachment 85056 Details for
Bug 22206
Add routes to enable suspension or resumption of holds
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 22206: OpenAPI spec
Bug-22206-OpenAPI-spec.patch (text/plain), 4.55 KB, created by
Martin Renvoize (ashimema)
on 2019-02-13 11:05:11 UTC
(
hide
)
Description:
Bug 22206: OpenAPI spec
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2019-02-13 11:05:11 UTC
Size:
4.55 KB
patch
obsolete
>From 34cb7a0ff685ba896fbe6f04658b795fbfd77520 Mon Sep 17 00:00:00 2001 >From: Tomas Cohen Arazi <tomascohen@theke.io> >Date: Mon, 28 Jan 2019 07:39:27 -0300 >Subject: [PATCH] Bug 22206: OpenAPI spec > >Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> >--- > api/v1/swagger/paths.json | 3 + > api/v1/swagger/paths/holds.json | 132 ++++++++++++++++++++++++++++++++ > 2 files changed, 135 insertions(+) > >diff --git a/api/v1/swagger/paths.json b/api/v1/swagger/paths.json >index 289cd89b2f..c04afaac91 100644 >--- a/api/v1/swagger/paths.json >+++ b/api/v1/swagger/paths.json >@@ -20,6 +20,9 @@ > "/holds/{hold_id}": { > "$ref": "paths/holds.json#/~1holds~1{hold_id}" > }, >+ "/holds/{hold_id}/suspension": { >+ "$ref": "paths/holds.json#/~1holds~1{hold_id}~1suspension" >+ }, > "/patrons": { > "$ref": "paths/patrons.json#/~1patrons" > }, >diff --git a/api/v1/swagger/paths/holds.json b/api/v1/swagger/paths/holds.json >index afeaac44d1..2dea98c53b 100644 >--- a/api/v1/swagger/paths/holds.json >+++ b/api/v1/swagger/paths/holds.json >@@ -386,5 +386,137 @@ > } > } > } >+ }, >+ "/holds/{hold_id}/suspension": { >+ "post": { >+ "x-mojo-to": "Holds#suspend", >+ "operationId": "suspendHold", >+ "tags": ["holds"], >+ "parameters": [{ >+ "$ref": "../parameters.json#/hold_id_pp" >+ }, { >+ "name": "body", >+ "in": "body", >+ "description": "A JSON object containing fields to modify", >+ "required": false, >+ "schema": { >+ "type": "object", >+ "properties": { >+ "expiration_date": { >+ "description": "Date the hold suspension expires", >+ "type": "string", >+ "format": "date" >+ } >+ } >+ } >+ } >+ ], >+ "consumes": ["application/json"], >+ "produces": ["application/json"], >+ "responses": { >+ "201": { >+ "description": "Hold suspended" >+ }, >+ "400": { >+ "description": "Missing or wrong parameters", >+ "schema": { >+ "$ref": "../definitions.json#/error" >+ } >+ }, >+ "401": { >+ "description": "Authentication required", >+ "schema": { >+ "$ref": "../definitions.json#/error" >+ } >+ }, >+ "403": { >+ "description": "Hold not allowed", >+ "schema": { >+ "$ref": "../definitions.json#/error" >+ } >+ }, >+ "404": { >+ "description": "Hold not found", >+ "schema": { >+ "$ref": "../definitions.json#/error" >+ } >+ }, >+ "500": { >+ "description": "Internal server error", >+ "schema": { >+ "$ref": "../definitions.json#/error" >+ } >+ }, >+ "503": { >+ "description": "Under maintenance", >+ "schema": { >+ "$ref": "../definitions.json#/error" >+ } >+ } >+ }, >+ "x-koha-authorization": { >+ "permissions": { >+ "reserveforothers": "1" >+ } >+ } >+ }, >+ "delete": { >+ "x-mojo-to": "Holds#resume", >+ "operationId": "resumeHold", >+ "tags": ["holds"], >+ "parameters": [ >+ { >+ "$ref": "../parameters.json#/hold_id_pp" >+ } >+ ], >+ "consumes": ["application/json"], >+ "produces": ["application/json"], >+ "responses": { >+ "204": { >+ "description": "Hold resumed" >+ }, >+ "400": { >+ "description": "Missing or wrong parameters", >+ "schema": { >+ "$ref": "../definitions.json#/error" >+ } >+ }, >+ "401": { >+ "description": "Authentication required", >+ "schema": { >+ "$ref": "../definitions.json#/error" >+ } >+ }, >+ "403": { >+ "description": "Hold not allowed", >+ "schema": { >+ "$ref": "../definitions.json#/error" >+ } >+ }, >+ "404": { >+ "description": "Hold not found", >+ "schema": { >+ "$ref": "../definitions.json#/error" >+ } >+ }, >+ "500": { >+ "description": "Internal server error", >+ "schema": { >+ "$ref": "../definitions.json#/error" >+ } >+ }, >+ "503": { >+ "description": "Under maintenance", >+ "schema": { >+ "$ref": "../definitions.json#/error" >+ } >+ } >+ }, >+ "x-koha-authorization": { >+ "permissions": { >+ "reserveforothers": "1" >+ } >+ } >+ } > } > } >-- >2.20.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 22206
:
84473
|
84474
|
84475
|
85056
|
85057
|
85058
|
85468
|
85469
|
85470
|
85471
|
85862
|
85864
|
85865
|
85866
|
85867
|
85868