Bug 19539 - Editing rules that contain 'Unlimited' values produces invalid data
Summary: Editing rules that contain 'Unlimited' values produces invalid data
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Templates (show other bugs)
Version: Main
Hardware: All All
: P5 - low major (vote)
Assignee: Tomás Cohen Arazi
QA Contact: Testopia
URL:
Keywords:
Depends on: 18857
Blocks: 15486
  Show dependency treegraph
 
Reported: 2017-10-27 14:10 UTC by Tomás Cohen Arazi
Modified: 2019-06-27 09:24 UTC (History)
2 users (show)

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


Attachments
Bug 19539: Fix column index shift in cirulation rules (1.79 KB, patch)
2017-10-27 14:16 UTC, Tomás Cohen Arazi
Details | Diff | Splinter Review
Bug 19539: Fix column index shift in cirulation rules (1.85 KB, patch)
2017-10-27 19:46 UTC, David Bourgault
Details | Diff | Splinter Review
Bug 19539: Fix column index shift in cirulation rules (1.93 KB, patch)
2017-10-30 14:15 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 19539: (follow-up) Fix column index shift in cirulation rules (2.03 KB, patch)
2017-10-30 14:15 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 19539: Fix column index shift in cirulation rules (1.98 KB, patch)
2017-11-01 14:45 UTC, Kyle M Hall
Details | Diff | Splinter Review
Bug 19539: (follow-up) Fix column index shift in cirulation rules (2.08 KB, patch)
2017-11-01 14:45 UTC, Kyle M Hall
Details | Diff | Splinter Review
Bug 19539: (follow-up) Fix column index shift in cirulation rules (1.90 KB, patch)
2017-11-01 16:11 UTC, Jonathan Druart
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Tomás Cohen Arazi 2017-10-27 14:10:54 UTC
Steps to reproduce:
- On the Circulation and fine rules page
- Empty the value of 'Current on-site checkouts allowed' and save
- Notice 'Unlimited' shows on the saved rule.
- Click edit
=> FAIL: the 'Unlimited' string displays intead of the empty string.

This was introduced by bug 18857
Comment 1 Tomás Cohen Arazi 2017-10-27 14:16:04 UTC
Created attachment 68719 [details] [review]
Bug 19539: Fix column index shift in cirulation rules

This patch fixes an index shift introduced by bug 18857 when it introduced
a new column.

To test:
- On the Circulation and fine rules page
- Empty the value of 'Current on-site checkouts allowed' and save
- Notice 'Unlimited' shows on the saved rule.
- Click edit
=> FAIL: the 'Unlimited' string displays instead of the empty string on the editing row.
- Apply this patch
- Re-open the circ rules page
- Click edit
=> SUCCESS: An empty string fills the 'Unlimited' fields
- Sign off :-D
Comment 2 David Bourgault 2017-10-27 19:46:43 UTC
Created attachment 68789 [details] [review]
Bug 19539: Fix column index shift in cirulation rules

This patch fixes an index shift introduced by bug 18857 when it introduced
a new column.

To test:
- On the Circulation and fine rules page
- Empty the value of 'Current on-site checkouts allowed' and save
- Notice 'Unlimited' shows on the saved rule.
- Click edit
=> FAIL: the 'Unlimited' string displays instead of the empty string on the editing row.
- Apply this patch
- Re-open the circ rules page
- Click edit
=> SUCCESS: An empty string fills the 'Unlimited' fields
- Sign off :-D

Signed-off-by: David Bourgault <david.bourgault@inlibro.com>
Comment 3 Jonathan Druart 2017-10-30 14:15:42 UTC
Created attachment 68846 [details] [review]
Bug 19539: Fix column index shift in cirulation rules

This patch fixes an index shift introduced by bug 18857 when it introduced
a new column.

To test:
- On the Circulation and fine rules page
- Empty the value of 'Current on-site checkouts allowed' and save
- Notice 'Unlimited' shows on the saved rule.
- Click edit
=> FAIL: the 'Unlimited' string displays instead of the empty string on the editing row.
- Apply this patch
- Re-open the circ rules page
- Click edit
=> SUCCESS: An empty string fills the 'Unlimited' fields
- Sign off :-D

Signed-off-by: David Bourgault <david.bourgault@inlibro.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 4 Jonathan Druart 2017-10-30 14:15:46 UTC
Created attachment 68847 [details] [review]
Bug 19539: (follow-up) Fix column index shift in cirulation rules

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 5 Kyle M Hall 2017-11-01 14:45:49 UTC
Created attachment 68879 [details] [review]
Bug 19539: Fix column index shift in cirulation rules

This patch fixes an index shift introduced by bug 18857 when it introduced
a new column.

To test:
- On the Circulation and fine rules page
- Empty the value of 'Current on-site checkouts allowed' and save
- Notice 'Unlimited' shows on the saved rule.
- Click edit
=> FAIL: the 'Unlimited' string displays instead of the empty string on the editing row.
- Apply this patch
- Re-open the circ rules page
- Click edit
=> SUCCESS: An empty string fills the 'Unlimited' fields
- Sign off :-D

Signed-off-by: David Bourgault <david.bourgault@inlibro.com>

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

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Comment 6 Kyle M Hall 2017-11-01 14:45:55 UTC
Created attachment 68880 [details] [review]
Bug 19539: (follow-up) Fix column index shift in cirulation rules

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

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Comment 7 Jonathan Druart 2017-11-01 16:11:16 UTC
Created attachment 68883 [details] [review]
Bug 19539: (follow-up) Fix column index shift in cirulation rules

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

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Comment 8 Jonathan Druart 2017-11-01 16:15:31 UTC
Pushed to master for 17.11, thanks to everybody involved!
Comment 9 Fridolin Somers 2017-11-20 13:36:07 UTC
Bug 18857 not in 17.05.x