Summary: | Impossible to delete line in circulation and fine rules | ||
---|---|---|---|
Product: | Koha | Reporter: | Klas Blomberg <klas.blomberg> |
Component: | System Administration | Assignee: | Emmi Takkinen <emmi.takkinen> |
Status: | RESOLVED FIXED | QA Contact: | Kyle M Hall (khall) <kyle> |
Severity: | normal | ||
Priority: | P5 - low | CC: | arthur.suzuki, emmi.takkinen, gmcharlt, kyle, lucas, wainuiwitikapark |
Version: | Main | ||
Hardware: | All | ||
OS: | All | ||
Change sponsored?: | --- | Patch complexity: | Trivial patch |
Documentation contact: | Documentation submission: | ||
Text to go in the release notes: | Version(s) released in: |
23.05.00,22.11.02,22.05.09, 21.11.16
|
|
Circulation function: | |||
Attachments: |
Bug 30694: Set decreaseloanholds undef when deleting circulation rule
Bug 30694: Set decreaseloanholds undef when deleting circulation rule Bug 30694: Set decreaseloanholds undef when deleting circulation rule |
Description
Klas Blomberg
2022-05-05 14:31:37 UTC
It does appear to behave correctly in current master. Could you maybe verify if it's still an issue in newer versions and add a step by step on how to test? We are facing similar problem on version 21.11, but with "Holds pickup period (day)" field. However in current master the problem field is "Decreased loan period for high holds" as Klas mentioned. To test: 1. Create new circulation rule and fill all fields. 2. Try to delete the rule. => Rule isn't deleted, all fields except "Decreased loan period for high holds" are now empty or have value "Unlimited". 3. Modify rule and set field "Decreased loan period for high holds" empty. 4. Delete the rule. => Rule is deleted successfully. 5. Create new rule, fill all fields expect field "Decreased loan period for high holds". 6. Delete the rule. => Rule is deleted successfully. Also to add to this, logs show no error and browsers console shows no Javascript etc. errors. Created attachment 143891 [details] [review] Bug 30694: Set decreaseloanholds undef when deleting circulation rule When one tries to delete rule with field "Decreased loan period for high holds" filled, delete fails without errors. This happens because rule isn't set in code section handling the delete in smart-rules.pl. To test: 1. Create a new circulation rule and fill all fields. 2. Try to delete the rule. => Rule isn't deleted, all fields except "Decreased loan period for high holds" are now empty or have value "Unlimited". 3. Modify the rule and set field "Decreased loan period for high holds" empty. 4. Delete the rule. => Rule is deleted successfully. 5. Create a new rule, fill all fields expect field "Decreased loan period for high holds". 6. Delete the rule. => Rule is deleted successfully. 7. Apply this patch. 8. Again create a new rule with field "Decreased loan period for high holds" filled. 9. Try to delete the rule. => Rule is deleted successfully. Sponsored-by: Koha-Suomi Oy Another side note, we are using bug 8367 so our problem with field "Holds pickup period (day)" comes from there and has nothing to with this bug. (In reply to Klas Blomberg from comment #0) > If you have entered a value in the column "Decreased loan period for high > holds" for a circulation rule - you can't delete that line. > > The only thing that will happend is that all numerical values are wiped out > - giving today as duedate Confirmed on master. Created attachment 143918 [details] [review] Bug 30694: Set decreaseloanholds undef when deleting circulation rule When one tries to delete rule with field "Decreased loan period for high holds" filled, delete fails without errors. This happens because rule isn't set in code section handling the delete in smart-rules.pl. To test: 1. Create a new circulation rule and fill all fields. 2. Try to delete the rule. => Rule isn't deleted, all fields except "Decreased loan period for high holds" are now empty or have value "Unlimited". 3. Modify the rule and set field "Decreased loan period for high holds" empty. 4. Delete the rule. => Rule is deleted successfully. 5. Create a new rule, fill all fields expect field "Decreased loan period for high holds". 6. Delete the rule. => Rule is deleted successfully. 7. Apply this patch. 8. Again create a new rule with field "Decreased loan period for high holds" filled. 9. Try to delete the rule. => Rule is deleted successfully. Sponsored-by: Koha-Suomi Oy Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Created attachment 144685 [details] [review] Bug 30694: Set decreaseloanholds undef when deleting circulation rule When one tries to delete rule with field "Decreased loan period for high holds" filled, delete fails without errors. This happens because rule isn't set in code section handling the delete in smart-rules.pl. To test: 1. Create a new circulation rule and fill all fields. 2. Try to delete the rule. => Rule isn't deleted, all fields except "Decreased loan period for high holds" are now empty or have value "Unlimited". 3. Modify the rule and set field "Decreased loan period for high holds" empty. 4. Delete the rule. => Rule is deleted successfully. 5. Create a new rule, fill all fields expect field "Decreased loan period for high holds". 6. Delete the rule. => Rule is deleted successfully. 7. Apply this patch. 8. Again create a new rule with field "Decreased loan period for high holds" filled. 9. Try to delete the rule. => Rule is deleted successfully. Sponsored-by: Koha-Suomi Oy Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Pushed to master for 23.05. Nice work everyone, thanks! Nice work, thanks everyone! Pushed to 22.11.x for the next release. Backported to 22.05.x for upcoming 22.05.09 applied to 21.11.x for 21.11.16 Not backported to 21.05.x |