Summary: | OVERDUE notice mis-labeled as "Hold Available for Pickup" | ||
---|---|---|---|
Product: | Koha | Reporter: | Barton Chittenden <barton> |
Component: | Notices | Assignee: | Jonathan Druart <jonathan.druart> |
Status: | CLOSED FIXED | QA Contact: | Marcel de Rooy <m.de.rooy> |
Severity: | major | ||
Priority: | P5 - low | CC: | brendan, chris, gwilliams, jonathan.druart, julian.maurice, kyle, m.de.rooy, tmisilo |
Version: | unspecified | ||
Hardware: | All | ||
OS: | All | ||
See Also: |
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=13215 http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11867 |
||
Change sponsored?: | --- | Patch complexity: | Small patch |
Documentation contact: | Documentation submission: | ||
Text to go in the release notes: | Version(s) released in: | ||
Circulation function: | |||
Bug Depends on: | 11867, 16217 | ||
Bug Blocks: | |||
Attachments: |
Bug 12752: FIX letter names in 3.15.00.041
Bug 12752: FIX letter names in 3.15.00.041 Bug 12752: FIX letter names in 3.15.00.041 Bug 12752: FIX letter names in 3.15.00.041 |
Description
Barton Chittenden
2014-08-12 18:41:53 UTC
It's a problem with the database update not setting a variable correctly I think, we ran into this too, but lost sight of it Actually ODUE is Overdue - this notice is new and not needed. I've been deleting it from most installs. Nicole This became an issue at one of our partner consortia; this database row needs to be deleted before it causes more problems: The library had several additional OVERDUE notices: select module, code, branchcode, name, is_html, title, message_transport_type from letter where code='OVERDUE'; +-------------+---------+------------+----------------------------------+---------+--------------------------------+------------------------+ | module | code | branchcode | name | is_html | title | message_transport_type | +-------------+---------+------------+----------------------------------+---------+--------------------------------+------------------------+ | circulation | OVERDUE | | Item Past Due Alert (2nd Notice) | 0 | Library Item(s) Past Due Alert | email | | circulation | OVERDUE | | Printable Hold notice | 0 | Overdue Notice (phone notice) | phone | | circulation | OVERDUE | XYZZY | Item Past Due Alert (2nd Notice) | 0 | Library Item(s) Past Due Alert | email | | circulation | OVERDUE | ABCDEF | Item Past Due Alert | 0 | Library Item(s) Past Due Alert | email | | circulation | OVERDUE | FOOOBARB | Item Past Due Alert (2nd Notice) | 0 | Library Item(s) Past Due Alert | email | +-------------+---------+------------+----------------------------------+---------+--------------------------------+------------------------+ This caused confusion, because a) The OVERDUE/"All libraries" notice with name "Printable Hold notice" did *not* show as a distinct letter on tools/letter.pl b) tools/overduerules.pl shows available letters by 'letter.name', but only the letter code is stored in the overduerules table. This also points the the necessity of adding a primary key to the letters table, as noted in bug 13215. This has certainly been caused by 3.15.00.041 (bug 11867). The structure of the letter table is not ideal, it should be split into 2 tables to normalised it. I don't know how we could fix this issue as a script cannot know what is the correct name of the letter. I think the problem might be here: http://git.koha-community.org/gitweb/?p=koha.git;a=blob;f=installer/data/mysql/updatedatabase.pl;h=6ba8e4d88b90acf6512458ae2448fddc81b15308;hb=5574a2fc4952322219892bcff3ea2525fec41949#l8361 $name is explicitly set for the HOLD messages, but never updates for the other messages later on: 8363 my $name = $dbh->selectcol_arrayref(q| 8364 SELECT name FROM letter WHERE code="HOLD" 8365 |); 8366 $name = $name->[0]; So $name is also used for PREDUE and OVERDUE Maybe we could fix that database update - and then also do a database update looking at the code/module and change accordingly. In 3.22, this seems to have shifted from OVERDUE to PREDUE select * from letter where code = 'PREDUE'\G *************************** 1. row *************************** module: circulation code: PREDUE branchcode: name: Hold Available for Pickup is_html: 0 title: Advance Notice of Item Due (phone notice) content: Your item is due soon message_transport_type: phone 1 row in set (0.00 sec) Created attachment 49990 [details] [review] Bug 12752: FIX letter names in 3.15.00.041 3.15.00.041 was wrong, the name of the letter should not always been the name of the first HOLD notice. PREDUE_PHONE should be updated with the first name of the PREDUE notice, same for OVERDUE_PHONE and OVERDUE (In reply to Katrin Fischer from comment #6) > So $name is also used for PREDUE and OVERDUE > > Maybe we could fix that database update - and then also do a database update > looking at the code/module and change accordingly. Yes indeed! Sorry to have been so slow to provide a fix for that. See also bug 16217 for a global fix. Created attachment 50369 [details] [review] Bug 12752: FIX letter names in 3.15.00.041 3.15.00.041 was wrong, the name of the letter should not always been the name of the first HOLD notice. PREDUE_PHONE should be updated with the first name of the PREDUE notice, same for OVERDUE_PHONE and OVERDUE Signed-off-by: Chris Cormack <chrisc@catalyst.net.z> Created attachment 50520 [details] [review] Bug 12752: FIX letter names in 3.15.00.041 3.15.00.041 was wrong, the name of the letter should not always been the name of the first HOLD notice. PREDUE_PHONE should be updated with the first name of the PREDUE notice, same for OVERDUE_PHONE and OVERDUE Signed-off-by: Chris Cormack <chrisc@catalyst.net.z> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> QA: Looking at this one now. Created attachment 50879 [details] [review] Bug 12752: FIX letter names in 3.15.00.041 3.15.00.041 was wrong, the name of the letter should not always been the name of the first HOLD notice. PREDUE_PHONE should be updated with the first name of the PREDUE notice, same for OVERDUE_PHONE and OVERDUE Signed-off-by: Chris Cormack <chrisc@catalyst.net.z> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Pushed to Master - Should be in the May 2016 Release. Thanks! Patch pushed to 3.22.x, will be in 3.22.7 Pushed to 3.20.x will be in 3.20.11 |