@@ -29,11 +29,11 @@ my ($PluginDir) = grep { -f $_ . "/Koha/Plugin/EDS.pm" } @pluginsdir;
2929$PluginDir = $PluginDir .' /Koha/Plugin/EDS' ;
3030
3131# ################ DO NOT TOUCH - CONTROLLED BY build.py
32- our $MAJOR_VERSION = " 20.11 " ;
33- our $SUB_VERSION = " 009 " ;
32+ our $MAJOR_VERSION = " 21.05 " ;
33+ our $SUB_VERSION = " 001 " ;
3434our $VERSION = $MAJOR_VERSION . " " . $SUB_VERSION ;
3535our $SHA_ADD = " https://widgets.ebscohost.com/prod/api/koha/sha/1711.json" ;
36- our $DATE_UPDATE = ' 2021-08-02 ' ;
36+ our $DATE_UPDATE = ' 2021-08-17 ' ;
3737# #####################################################
3838
3939# # Here is our metadata, some keys are required, some are optional
@@ -110,6 +110,7 @@ sub configure {
110110 defaultparams => $self -> retrieve_data(' defaultparams' ),
111111 autocomplete_mode => $self -> retrieve_data(' autocomplete_mode' ),
112112 autocomplete => $self -> retrieve_data(' autocomplete' ),
113+ PLUGIN_HTTP_PATH => $self -> get_plugin_http_path(),
113114
114115
115116 );
@@ -175,7 +176,8 @@ sub update_EDSScript_js {
175176 autocomplete => ($cgi -> param(' autocomplete' )?$cgi -> param(' autocomplete' ):" -" ),
176177 authtoken => $cgi -> param(' authtoken' ),
177178 lastedsinfoupdate => $cgi -> param(' lastedsinfoupdate' ),
178- edsinfo => quotemeta ($self -> retrieve_data(' edsinfo' ))
179+ edsinfo => quotemeta ($self -> retrieve_data(' edsinfo' )),
180+ PLUGIN_HTTP_PATH => $self -> get_plugin_http_path(),
179181 };
180182 # my $pluginsdir = C4::Context->config('pluginsdir');
181183 # my @pluginsdir = ref($pluginsdir) eq 'ARRAY' ? @$pluginsdir : $pluginsdir;
@@ -185,8 +187,9 @@ sub update_EDSScript_js {
185187 # push @plugindirs, $plugindir
186188 # }
187189 my $template = Template-> new({
188- INCLUDE_PATH => $PluginDir ,
189- OUTPUT_PATH => $PluginDir
190+ INCLUDE_PATH => $PluginDir ,
191+ OUTPUT_PATH => $PluginDir ,
192+ PLUGIN_HTTP_PATH => $self -> get_plugin_http_path(),
190193 });
191194 $template -> process(' js/EDSScript.tt' ,$vars , ' js/EDSScript.js' );
192195 $template -> process(' opac/templates/eds-methods.tt' ,$vars , ' opac/eds-methods.pl' );
@@ -244,7 +247,7 @@ sub opac_js {
244247 <script>
245248 var defaultSearch="| . $default_search . q| ";
246249 </script>
247- <script src="/plugin/Koha/Plugin/EDS /js/EDSScript.js">
250+ <script src="| . $self -> get_plugin_http_path() . q| /js/EDSScript.js">
248251 </script>
249252 | ;
250253}
@@ -372,6 +375,7 @@ sub SetupTool {
372375 customjs => \@customJSContent ,
373376 jsstate => $customJS ,
374377 plugin_dir => $PluginDir ,
378+ PLUGIN_HTTP_PATH => $self -> get_plugin_http_path(),
375379
376380 );
377381
0 commit comments