[Koha-bugs] [Bug 32132] Missing budget_period_id in aqbudgets kills lateorders.pl

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Fri Feb 2 09:00:08 CET 2024


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=32132

Emmi Takkinen <emmi.takkinen at koha-suomi.fi> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 Attachment #143988|0                           |1
        is obsolete|                            |

--- Comment #4 from Emmi Takkinen <emmi.takkinen at koha-suomi.fi> ---
Created attachment 161721
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=161721&action=edit
Bug 32132: Do not allow NULL value in column aqbudgets.budget_period_id

If budget_period_id column is set as NULL, "Late orders"
page dies on error 500. Logs read:

Template process failed: undef error - DBIC result _type isn't of the _type
Aqbudget at
/home/koha/Koha/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/lateorders.tt
line 157

This patch makes changes to column aqbudgets.budget_period_id so that it
no longer allows NULL values. This is in line with aqbudgets tables foreign key
"budget_period_id" which has ON DELETE CASCADE clause.

To test:
1. Run prove t/db_dependent/Koha/Acquisition/Fund.t
=> Tests should fail
2. Run updatedatabase.pl and restart services if needed
3. Rerun prove t/db_dependent/Koha/Acquisition/Fund.t
=> Tests should now pass

Sponsored-by: Koha-Suomi Oy

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list