Main Koha release repository https://koha-community.org
Find a file
Tomas Cohen Arazi 4b3657b3d6 Bug 26470: Store the item before calling the after action hook
This patch makes Koha::Item->store call $self->SUPER::store before
calling the hook, so things like the itemnumber (AUTO_INCREMENT field)
are available to the plugin hook.

It does so by storing the output on a temporary variable, to keep the
current behaviour of just returning the output from SUPER::store.

To test:
1. Apply the regression tests patch
2. Run:
   $ kshell
  k$ prove t/db_dependent/Koha/Plugins/Biblio_and_Items_plugin_hooks.t \
           t/db_dependent/Koha/Item.t \
           t/db_dependent/Koha/Items.t
=> FAIL: the hooks tests fail. Item.t hasn't been altered so should pass
3. Apply this patch
4. Repeat 2.
=> SUCCESS: Tests pass! Item.t as well! (i.e. no behaviour change)
5. Sign off :-D

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2020-09-18 10:38:01 +02:00
acqui Bug 23682: Fix use Koha::Plugins::Handler statements 2020-09-03 15:00:48 +02:00
admin Bug 23816: Add minimum password length and require strong password overrides by category 2020-09-09 15:39:52 +02:00
api Bug 26271: Add null to the list of accepted account_line data types 2020-09-03 14:18:23 +02:00
authorities
basket
C4 Bug 26384: Fix executable flags 2020-09-11 09:56:56 +02:00
catalogue
cataloguing Bug 26384: Fix executable flags 2020-09-11 09:56:56 +02:00
circ Bug 24663: Remove authnotrequired if set to 0 2020-09-03 10:40:35 +02:00
clubs
course_reserves Bug 24663: Remove authnotrequired if set to 0 2020-09-03 10:40:35 +02:00
debian Bug 25541: (QA follow-up) Default to disabled + Correct message 2020-09-03 14:18:23 +02:00
docs
errors Bug 24545: Fix license statements 2020-02-24 13:31:26 +00:00
etc Bug 25541: (QA follow-up) Default to disabled + Correct message 2020-09-03 14:18:23 +02:00
ill
installer Bug 26007: (QA follow-up) Fix English yml file 2020-09-11 09:56:56 +02:00
Koha Bug 26470: Store the item before calling the after action hook 2020-09-18 10:38:01 +02:00
koha-tmpl Bug 20168: Compiled CSS - RTL files 2020-09-18 10:32:15 +02:00
labels Bug 24663: Remove authnotrequired if set to 0 2020-09-03 10:40:35 +02:00
members Bug 23816: Add minimum password length and require strong password overrides by category 2020-09-09 15:39:52 +02:00
misc Bug 26407: fix query in 'title exists' in search_for_data_inconsistencies.pl 2020-09-18 10:37:56 +02:00
offline_circ Bug 24663: Remove authnotrequired if set to 0 2020-09-03 10:40:35 +02:00
opac Bug 23816: Add minimum password length and require strong password overrides by category 2020-09-09 15:39:52 +02:00
patron_lists
patroncards
plugins
pos Bug 24663: Remove authnotrequired if set to 0 2020-09-03 10:40:35 +02:00
reports Bug 17801: Use issuedate for limits in Most Circulated Items 2020-09-03 14:18:23 +02:00
reserve
reviews
rotating_collections Bug 24663: Remove authnotrequired if set to 0 2020-09-03 10:40:35 +02:00
serials
services
skel
suggestion
svc
t Bug 26470: Regression tests 2020-09-18 10:38:01 +02:00
tags Bug 24663: Remove authnotrequired if set to 0 2020-09-03 10:40:35 +02:00
tmp/modified_authorities
tools Bug 24663: Fix one missing occurrence 2020-09-09 15:39:51 +02:00
virtualshelves Bug 24663: Remove authnotrequired if set to 0 2020-09-03 10:40:35 +02:00
xt Bug 26384: (QA follow-up) Fix two exceptions 2020-09-11 09:56:56 +02:00
.editorconfig
.eslintrc.json
.gitignore
.htaccess
.mailmap Bug 26394: Update .mailmap 2020-09-11 09:56:56 +02:00
.perlcriticrc
.scss-lint.yml Bug 21237: Clean up staff client SCSS 2018-08-24 16:23:25 +00:00
about.pl
changelanguage.pl
cpanfile
fix-perl-path.PL Bug 21395: Make perlcritic happy 2020-06-29 12:37:02 +02:00
gulpfile.js Bug 20168: (follow-up) Add automatic creation of RTL CSS 2020-09-09 14:13:09 +02:00
help.pl
INSTALL Bug 17626: Remove existing install instructions and link to the wiki pages instead 2016-11-22 11:29:07 +00:00
Koha.pm Bug 23816: DBRev 20.06.00.037 2020-09-09 15:39:52 +02:00
koha_perl_deps.pl
kohaversion.pl Bug 26384: Fix executable flags 2020-09-11 09:56:56 +02:00
LICENSE Bug 9440 - update Koha's LICENSE file from GPL2 to GPL3 2013-02-12 08:52:10 -05:00
mainpage.pl Bug 24663: Remove authnotrequired if set to 0 2020-09-03 10:40:35 +02:00
Makefile.PL Bug 26265: Add missing xt dir 2020-08-24 12:30:53 +02:00
MANIFEST.SKIP
package.json Bug 20168: (follow-up) Add automatic creation of RTL CSS 2020-09-09 14:13:09 +02:00
README Bug 9440 - update Koha's LICENSE file from GPL2 to GPL3 2013-02-12 08:52:10 -05:00
README.md Bug 15465: Fix typo in bugs.k-c.org 2017-05-26 11:45:31 -03:00
README.robots Bug 6411 add another example to README.robots 2011-07-05 14:48:05 +12:00
rewrite-config.PL
yarn.lock Bug 20168: (follow-up) Add automatic creation of RTL CSS 2020-09-09 14:13:09 +02:00

Koha is a free software integrated library system (ILS).

Koha is distributed under the GNU GPL version 3 or later.

Note: This is a synced mirror of the official Koha repo.

Note: Koha does not accept pull requests from git hosting sites.

Note: This project has its own bug tracker, to report a bug or submit a patch visit http://bugs.koha-community.org.

For guidelines on submitting patches for Koha please visit https://wiki.koha-community.org/wiki/SubmitingAPatch

The developers handbook can be found at https://wiki.koha-community.org/wiki/Developer_handbook

http://koha-community.org/

Koha Logo