Bug 34572 - Simplify template logic around check-in input form
Summary: Simplify template logic around check-in input form
Status: RESOLVED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Circulation (show other bugs)
Version: Main
Hardware: All All
: P5 - low minor
Assignee: Owen Leonard
QA Contact: Katrin Fischer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-08-18 07:44 UTC by Owen Leonard
Modified: 2023-12-28 20:47 UTC (History)
4 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:
23.11.00,23.05.04,22.11.10
Circulation function:


Attachments
Bug 34572: Simplify template logic around check-in input form (2.73 KB, patch)
2023-08-18 07:51 UTC, Owen Leonard
Details | Diff | Splinter Review
Bug 34572: Simplify template logic around check-in input form (2.79 KB, patch)
2023-08-18 11:22 UTC, PTFS Europe Sandboxes
Details | Diff | Splinter Review
Bug 34572: Simplify template logic around check-in input form (2.84 KB, patch)
2023-08-25 13:00 UTC, Katrin Fischer
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Owen Leonard 2023-08-18 07:44:09 UTC
Fridolin writes in Bug 34289 comment 5:

Since we have now :

[% IF ( exemptfine ) %]
    <input name="barcode" id="barcode" size="14" placeholder="Enter item barcode" class="barcode focus input-warning" type="text" />
[% ELSIF ( dropboxmode ) %]
    <input name="barcode" id="barcode" size="14" placeholder="Enter item barcode" class="barcode focus input-warning" />
[% ELSE %]

There is no difference between those two lines since type="text" is default behavior.

Maybe merge into [% IF ( exemptfine || dropboxmode ) %]
Comment 1 Owen Leonard 2023-08-18 07:51:06 UTC
Created attachment 154589 [details] [review]
Bug 34572: Simplify template logic around check-in input form

This patch makes a minor simplifying change to the check-in template
around how to style the barcode input field in dropbox or fine-exempt
mode.

To test, apply the patch and go to Circulation.

- If necessary, check some items out to patrons so that you have items
  to check in.
- Go to the check-in page and click the icon inside the barcode field to
  expand the panel of options.
- Check the "book drop mode" checkbox. The barcode field should now be
  highlighted yellow.
- Check in an item. When the page redisplays, the barcode field should
  have the same highlighted style.

- If necessary, enable the finesMode system preference.
- On the check-in page, in the panel of options, check the "Forgive
  overdue fines" checkbox. Test checking in again, confirming the same
  style consistency in the barcode field.
Comment 2 PTFS Europe Sandboxes 2023-08-18 11:22:18 UTC
Created attachment 154639 [details] [review]
Bug 34572: Simplify template logic around check-in input form

This patch makes a minor simplifying change to the check-in template
around how to style the barcode input field in dropbox or fine-exempt
mode.

To test, apply the patch and go to Circulation.

- If necessary, check some items out to patrons so that you have items
  to check in.
- Go to the check-in page and click the icon inside the barcode field to
  expand the panel of options.
- Check the "book drop mode" checkbox. The barcode field should now be
  highlighted yellow.
- Check in an item. When the page redisplays, the barcode field should
  have the same highlighted style.

- If necessary, enable the finesMode system preference.
- On the check-in page, in the panel of options, check the "Forgive
  overdue fines" checkbox. Test checking in again, confirming the same
  style consistency in the barcode field.

Signed-off-by: Inkeri <inkeri.hakulinen@helsinki.fi>
Comment 3 Inkeri Hakulinen 2023-08-18 11:23:27 UTC
Seems to work alright.
Comment 4 Katrin Fischer 2023-08-25 13:00:05 UTC
Created attachment 154811 [details] [review]
Bug 34572: Simplify template logic around check-in input form

This patch makes a minor simplifying change to the check-in template
around how to style the barcode input field in dropbox or fine-exempt
mode.

To test, apply the patch and go to Circulation.

- If necessary, check some items out to patrons so that you have items
  to check in.
- Go to the check-in page and click the icon inside the barcode field to
  expand the panel of options.
- Check the "book drop mode" checkbox. The barcode field should now be
  highlighted yellow.
- Check in an item. When the page redisplays, the barcode field should
  have the same highlighted style.

- If necessary, enable the finesMode system preference.
- On the check-in page, in the panel of options, check the "Forgive
  overdue fines" checkbox. Test checking in again, confirming the same
  style consistency in the barcode field.

Signed-off-by: Inkeri <inkeri.hakulinen@helsinki.fi>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 5 Tomás Cohen Arazi (tcohen) 2023-09-12 12:43:40 UTC
Pushed to master for 23.11.

Nice work everyone, thanks!
Comment 6 Fridolin Somers 2023-09-14 18:22:56 UTC
Pushed to 23.05.x for 23.05.04
Comment 7 Matt Blenkinsop 2023-09-15 10:22:06 UTC
Nice work everyone!

Pushed to oldstable for 22.11.x