View | Details | Raw Unified | Return to bug 32680
Collapse All | Expand All

(-)a/Koha/Template/Plugin/KohaPlugins.pm (-1 / +52 lines)
Lines 230-233 sub get_plugins_intranet_catalog_biblio_tab { Link Here
230
    return $tabs;
230
    return $tabs;
231
}
231
}
232
232
233
=head3 get_plugins_intranet_cover_images
234
235
[% KohaPlugins. get_plugins_intranet_cover_images %]
236
237
This method collects the output of all plugins for injecting cover images into the intranet template and appends it to the javascript at the bottom of the page.
238
239
=cut
240
241
sub get_plugins_intranet_cover_images {
242
    return q{} unless C4::Context->config("enable_plugins");
243
244
    my $p = Koha::Plugins->new();
245
246
    return q{} unless $p;
247
248
    my @plugins = $p->GetPlugins(
249
        {
250
            method => 'intranet_cover_images',
251
        }
252
    );
253
254
    my @data = map { $_->intranet_cover_images || q{} } @plugins;
255
256
    return join( "\n", @data );
257
}
258
259
=head3 get_plugins_opac_cover_images
260
261
[% KohaPlugins. get_plugins_opac_cover_images %]
262
263
This method collects the output of all plugins for injecting cover images into the opac template and appends it to the javascript at the bottom of the page.
264
265
=cut
266
267
sub get_plugins_opac_cover_images {
268
    return q{} unless C4::Context->config("enable_plugins");
269
270
    my $p = Koha::Plugins->new();
271
272
    return q{} unless $p;
273
274
    my @plugins = $p->GetPlugins(
275
        {
276
            method => 'opac_cover_images',
277
        }
278
    );
279
280
    my @data = map { $_->opac_cover_images || q{} } @plugins;
281
282
    return join( "\n", @data );
283
}
284
233
1;
285
1;
234
- 

Return to bug 32680