Bugzilla – Attachment 113274 Details for
Bug 26633
Add advanced editor for transfer limits
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 26633: Add API documentation
Bug-26633-Add-API-documentation.patch (text/plain), 2.92 KB, created by
Kyle M Hall (khall)
on 2020-11-06 18:33:03 UTC
(
hide
)
Description:
Bug 26633: Add API documentation
Filename:
MIME Type:
Creator:
Kyle M Hall (khall)
Created:
2020-11-06 18:33:03 UTC
Size:
2.92 KB
patch
obsolete
>From d63a6aa6bb258c06c3a15791ed37e6305d95df3c Mon Sep 17 00:00:00 2001 >From: Kyle M Hall <kyle@bywatersolutions.com> >Date: Fri, 6 Nov 2020 13:15:14 -0500 >Subject: [PATCH] Bug 26633: Add API documentation > >--- > api/v1/swagger/paths/transfer_limits.yaml | 38 +++++++++++++++++++++++ > 1 file changed, 38 insertions(+) > >diff --git a/api/v1/swagger/paths/transfer_limits.yaml b/api/v1/swagger/paths/transfer_limits.yaml >index 3a4f7ecf00..67a8dc1175 100644 >--- a/api/v1/swagger/paths/transfer_limits.yaml >+++ b/api/v1/swagger/paths/transfer_limits.yaml >@@ -3,6 +3,7 @@ > get: > x-mojo-to: TransferLimits#list > operationId: listTransferLimits >+ description: "This resource returns a list of existing transfer limits." > tags: > - transfer > parameters: >@@ -56,6 +57,7 @@ > post: > x-mojo-to: TransferLimits#add > operationId: addTransferLimit >+ description: "This resource accepts a new transfer limit and creates it if it does not already exist." > tags: > - transfer > parameters: >@@ -103,6 +105,7 @@ > delete: > x-mojo-to: TransferLimits#delete > operationId: deleteTransferLimit >+ description: "This resource deletes a transfer limit for the given limit id" > tags: > - transfer > parameters: >@@ -141,6 +144,39 @@ > post: > x-mojo-to: TransferLimits#batch_add > operationId: batchAddTransferLimits >+ description: "This resource batch creates new transfer limits based on the given data. >+ >+ For example, if the paramters `to_library_id: 'BranchA'` and `item_type: 'BOOK'` are passed in >+ new transfer limits for `BOOK`s will be created, with one transfer limit each for all the >+ branches defined in Koha. Given 4 branches, 3 limits would be created: >+ >+ >+ * to_library_id: 'BranchA', from_library_id: 'BranchB', item_type: 'BOOK' >+ >+ * to_library_id: 'BranchA', from_library_id: 'BranchC', item_type: 'BOOK' >+ >+ * to_library_id: 'BranchA', from_library_id: 'BranchD', item_type: 'BOOK' >+ >+ >+ The body of the query would look like >+ ``` >+ { >+ 'to_library_id': 'BranchA', >+ 'item_type': 'BOOK' >+ >+ } >+ ``` >+ >+ >+ As another example, imagine we have an itemtype that is never supposed to be transferred to another library. >+ If we call that itemtype `LOCAL_ONLY` we would need to just pass `item_type: 'LOCAL_ONLY'`, which would create transfer >+ limits for all libraries, meaning those items would never be allowed to transfer to another >+ library. The body of the query would look like >+ ``` >+ { >+ 'item_type': 'LOCAL_ONLY' >+ } >+ ```" > tags: > - transfer > parameters: >@@ -193,6 +229,8 @@ > delete: > x-mojo-to: TransferLimits#batch_delete > operationId: batchDeleteTransferLimits >+ description: 'This endpoint works just like [the POST version](#op-post-transfer_limits-batch), except it deletes transfer in batch >+ rather than creating them.' > tags: > - transfer > parameters: >-- >2.24.1 (Apple Git-126)
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 26633
:
111380
|
111381
|
112327
|
112328
|
112330
|
112437
|
112438
|
112587
|
112778
|
112779
|
112780
|
112781
|
112782
|
112923
|
112924
|
112925
|
112926
|
112927
|
112928
|
112929
|
113053
|
113265
|
113266
|
113267
|
113268
|
113269
|
113270
|
113271
|
113272
|
113273
|
113274
|
113275
|
113676
|
113677
|
113961
|
116612
|
116613
|
116952
|
116953
|
116954
|
116955
|
116956
|
116957
|
116958
|
116959
|
116960
|
116961
|
116962
|
116963
|
116964