Bugzilla – Attachment 100144 Details for
Bug 24369
Add ability to set CORS header in Koha
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 24369: Add AccessControlAllowOrigin syspref
Bug-24369-Add-AccessControlAllowOrigin-syspref.patch (text/plain), 2.91 KB, created by
Kyle M Hall (khall)
on 2020-03-04 18:41:17 UTC
(
hide
)
Description:
Bug 24369: Add AccessControlAllowOrigin syspref
Filename:
MIME Type:
Creator:
Kyle M Hall (khall)
Created:
2020-03-04 18:41:17 UTC
Size:
2.91 KB
patch
obsolete
>From b7b5a174eae4a0ba759c300dba88d4f750444257 Mon Sep 17 00:00:00 2001 >From: Tomas Cohen Arazi <tomascohen@theke.io> >Date: Thu, 9 Jan 2020 10:42:43 -0300 >Subject: [PATCH] Bug 24369: Add AccessControlAllowOrigin syspref > >Signed-off-by: Andrew Isherwood <andrew.isherwood@ptfs-europe.com> > >Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> >--- > .../data/mysql/atomicupdate/bug_24369_CORS.perl | 13 +++++++++++++ > installer/data/mysql/sysprefs.sql | 1 + > .../en/modules/admin/preferences/web_services.pref | 6 ++++++ > 3 files changed, 20 insertions(+) > create mode 100644 installer/data/mysql/atomicupdate/bug_24369_CORS.perl > >diff --git a/installer/data/mysql/atomicupdate/bug_24369_CORS.perl b/installer/data/mysql/atomicupdate/bug_24369_CORS.perl >new file mode 100644 >index 0000000000..e74631985c >--- /dev/null >+++ b/installer/data/mysql/atomicupdate/bug_24369_CORS.perl >@@ -0,0 +1,13 @@ >+$DBversion = 'XXX'; # will be replaced by the RM >+if( CheckVersion( $DBversion ) ) { >+ $dbh->do(q{ >+ INSERT IGNORE INTO `systempreferences` >+ (`variable`, `value`, `options`, `explanation`, `type`) >+ VALUES >+ ('AccessControlAllowOrigin', '', NULL, 'Set the Access-Control-Allow-Origin header to the specified value', 'Free'); >+ }); >+ >+ # Always end with this (adjust the bug info) >+ SetVersion( $DBversion ); >+ print "Upgrade to $DBversion done (Bug 24369 - Add CORS support to Koha)\n"; >+} >diff --git a/installer/data/mysql/sysprefs.sql b/installer/data/mysql/sysprefs.sql >index 40f7a4740f..49b6633f08 100644 >--- a/installer/data/mysql/sysprefs.sql >+++ b/installer/data/mysql/sysprefs.sql >@@ -1,4 +1,5 @@ > INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, `type` ) VALUES >+('AccessControlAllowOrigin', '', NULL, 'Set the Access-Control-Allow-Origin header to the specified value', 'Free'), > ('AccountAutoReconcile','0',NULL,'If enabled, patron balances will get reconciled automatically on each transaction.','YesNo'), > ('AcqCreateItem','ordering','ordering|receiving|cataloguing','Define when the item is created : when ordering, when receiving, or in cataloguing module','Choice'), > ('AcqEnableFiles','0',NULL,'If enabled, allows librarians to upload and attach arbitrary files to invoice records.','YesNo'), >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 ae99ace642..4fa34142ce 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: >+ General: >+ - >+ - "Set the Access-Control-Allow-Origin header to" >+ - pref: 'AccessControlAllowOrigin' >+ class: Text >+ - "." > REST API: > - > - pref: RESTBasicAuth >-- >2.21.1 (Apple Git-122.3)
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 24369
:
97092
|
97093
|
97094
|
97298
|
97299
|
97300
| 100144 |
100145
|
100146