Bug 25549: Add error reporting to plugins-home
authorMartin Renvoize <martin.renvoize@ptfs-europe.com>
Wed, 7 Oct 2020 15:37:06 +0000 (16:37 +0100)
committerJonathan Druart <jonathan.druart@bugs.koha-community.org>
Thu, 22 Oct 2020 08:04:30 +0000 (10:04 +0200)
commit759ff4519961d0c256eb05a4797fb21c3b2c22d9
tree2b521af0bf3115c1c413c32d655b31b439c00176
parent0eae966d257fa2ecc6a6506e2515691e092a701c
Bug 25549: Add error reporting to plugins-home

This patch adds handling for the newly introduced 'errors' option in
GetPlugins and reports erroroneos plugins to the user.

To test:
1 - Enable plugins in the koha-conf
2 - Install the kitchen sink plugin
3 - Your staff client should be orange now :-)
4 - The plugin should display as installed in the table at
    tools/plugins.
5 - edit the plugin module
    /var/lib/koha/kohadev/plugins/Koha/Plugin/Com/ByWaterSolutions/KitchenSink.pm
6 - Add a line to break compilation, like:
    this won't compile
7 - Restart all
8 - Your Koha is not broken, but is no longer orange (The plugin is not
    loading).
9 - The plugin should display as unable to load in the table at
    tools/plugins.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Koha/Plugins.pm
koha-tmpl/intranet-tmpl/prog/en/modules/plugins/plugins-home.tt
plugins/plugins-home.pl