Bugzilla – Attachment 67604 Details for
Bug 19278
Add a configurable default page size for endpoints
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 19278: Add RESTdefaultPageSize syspref
Bug-19278-Add-RESTdefaultPageSize-syspref.patch (text/plain), 3.09 KB, created by
Tomás Cohen Arazi (tcohen)
on 2017-10-04 13:46:45 UTC
(
hide
)
Description:
Bug 19278: Add RESTdefaultPageSize syspref
Filename:
MIME Type:
Creator:
Tomás Cohen Arazi (tcohen)
Created:
2017-10-04 13:46:45 UTC
Size:
3.09 KB
patch
obsolete
>From e332cae834605dba1291eb36cd21ac7fdf37a1f4 Mon Sep 17 00:00:00 2001 >From: Tomas Cohen Arazi <tomascohen@theke.io> >Date: Fri, 8 Sep 2017 12:18:21 -0300 >Subject: [PATCH] Bug 19278: Add RESTdefaultPageSize syspref > >--- > .../data/mysql/atomicupdate/bug_19196_pagination_plugin.perl | 11 +++++++++++ > installer/data/mysql/sysprefs.sql | 1 + > .../prog/en/modules/admin/preferences/web_services.pref | 6 ++++++ > 3 files changed, 18 insertions(+) > create mode 100644 installer/data/mysql/atomicupdate/bug_19196_pagination_plugin.perl > >diff --git a/installer/data/mysql/atomicupdate/bug_19196_pagination_plugin.perl b/installer/data/mysql/atomicupdate/bug_19196_pagination_plugin.perl >new file mode 100644 >index 0000000..57beb2d >--- /dev/null >+++ b/installer/data/mysql/atomicupdate/bug_19196_pagination_plugin.perl >@@ -0,0 +1,11 @@ >+$DBversion = 'XXX'; >+if( CheckVersion( $DBversion ) ) { >+ $dbh->do(q{ >+ INSERT IGNORE INTO systempreferences ( `variable`, `value`, `options`, `explanation`, `type` ) >+ VALUES >+ ('RESTdefaultPageSize','20','','Set the default number of results returned by the REST API endpoints','Integer') >+ }); >+ >+ SetVersion( $DBversion ); >+ print "Upgrade to $DBversion done (Bug 19278: Add a configurable default page size for REST endpoints)\n"; >+} >diff --git a/installer/data/mysql/sysprefs.sql b/installer/data/mysql/sysprefs.sql >index bc08b5a..ede6d66 100644 >--- a/installer/data/mysql/sysprefs.sql >+++ b/installer/data/mysql/sysprefs.sql >@@ -453,6 +453,7 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` > ('ReservesControlBranch','PatronLibrary','ItemHomeLibrary|PatronLibrary','Branch checked for members reservations rights','Choice'), > ('ReservesMaxPickUpDelay','7','','Define the Maximum delay to pick up an item on hold','Integer'), > ('ReservesNeedReturns','1','','If ON, a hold placed on an item available in this library must be checked-in, otherwise, a hold on a specific item, that is in the library & available is considered available','YesNo'), >+('RESTdefaultPageSize','20','','Default page size for endpoints listing objects','Integer'), > ('RestrictedPageLocalIPs','',NULL,'Beginning of IP addresses considered as local (comma separated ex: "127.0.0,127.0.2")','Free'), > ('RestrictedPageContent','',NULL,'HTML content of the restricted page','TextArea'), > ('RestrictedPageTitle','',NULL,'Title of the restricted page (breadcrumb and header)','Free'), >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/web_services.pref b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/web_services.pref >index b52fdc6..82f7501 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/web_services.pref >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/web_services.pref >@@ -1,4 +1,10 @@ > Web services: >+ REST API: >+ - >+ - "Set the default number of results returned by the REST API endpoints to" >+ - pref: "RESTdefaultPageSize" >+ class: integer >+ - "per page" > OAI-PMH: > - > - pref: OAI-PMH >-- >2.7.4
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 19278
:
66994
|
66995
|
66996
|
67341
|
67604
|
67605
|
67606
|
67607
|
67700
|
67701
|
67702
|
67703
|
67790
|
67791
|
67792
|
67793
|
69365
|
69366
|
69367
|
69368
|
69704