Bug 37832 - Rental discount is should be decimal like other similar fields in circulation rules
Summary: Rental discount is should be decimal like other similar fields in circulation...
Status: Pushed to main
Alias: None
Product: Koha
Classification: Unclassified
Component: Circulation (show other bugs)
Version: unspecified
Hardware: All All
: P5 - low enhancement
Assignee: Peter Vashchuk
QA Contact: Lisette Scheer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-09-04 13:45 UTC by Peter Vashchuk
Modified: 2025-01-16 16:42 UTC (History)
4 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
25.05.00
Circulation function:


Attachments
Bug 37832: Fix Rentaldiscount to be decimal like other similar fields (1.79 KB, patch)
2024-09-04 13:47 UTC, Peter Vashchuk
Details | Diff | Splinter Review
Bug 37832: Fix Rentaldiscount to be decimal like other similar fields (1.85 KB, patch)
2024-09-13 19:05 UTC, Olivier Vezina
Details | Diff | Splinter Review
Attachment to Bug 37832 - Rentaldiscount is not required to be decimal like other similar fields in smart-rules.tt (1.91 KB, patch)
2025-01-08 15:12 UTC, Lisette Scheer
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Peter Vashchuk 2024-09-04 13:45:30 UTC

    
Comment 1 Peter Vashchuk 2024-09-04 13:47:02 UTC
Created attachment 171028 [details] [review]
Bug 37832: Fix Rentaldiscount to be decimal like other similar fields

Added decimal input_mode and pattern for "Rental discount (%)" so it functions same way as "Fine amount" or "Overdue fines cap (amount)" rules, allowing user to save decimals only.

1. Go to Circulation and fine rules page and save some gibberish into "Rental discount (%)", see that it allows you to do that.
2. Apply the patch, and try same thing again, this time it should only allow you to save decimal numbers.
Comment 2 Olivier Vezina 2024-09-13 19:05:16 UTC
Created attachment 171495 [details] [review]
Bug 37832: Fix Rentaldiscount to be decimal like other similar fields

Added decimal input_mode and pattern for "Rental discount (%)" so it functions same way as "Fine amount" or "Overdue fines cap (amount)" rules, allowing user to save decimals only.

1. Go to Circulation and fine rules page and save some gibberish into "Rental discount (%)", see that it allows you to do that.
2. Apply the patch, and try same thing again, this time it should only allow you to save decimal numbers.

Signed-off-by: Olivier V <olivier.vezina@inLibro.com>
Comment 3 Lisette Scheer 2025-01-08 15:12:57 UTC
Created attachment 176240 [details] [review]
Attachment to Bug 37832 - Rentaldiscount is not required to be decimal like other similar fields in smart-rules.tt

Bug 37832: Fix Rentaldiscount to be decimal like other similar fields

Added decimal input_mode and pattern for "Rental discount (%)" so it functions same way as "Fine amount" or "Overdue fines cap (amount)" rules, allowing user to save decimals only.

1. Go to Circulation and fine rules page and save some gibberish into "Rental discount (%)", see that it allows you to do that.
2. Apply the patch, and try same thing again, this time it should only allow you to save decimal numbers.

Signed-off-by: Olivier V <olivier.vezina@inLibro.com>
Signed-off-by: Lisette Scheer <lisette@bywatersolutions.com>
Comment 4 Katrin Fischer 2025-01-16 16:42:04 UTC
Pushed for 25.05!

Well done everyone, thank you!