Bug 19453 - Client side validation broken for "Fund" select
Summary: Client side validation broken for "Fund" select
Status: Pushed to Master
Alias: None
Product: Koha
Classification: Unclassified
Component: Acquisitions (show other bugs)
Version: master
Hardware: All All
: P5 - low normal (vote)
Assignee: David Gustafsson
QA Contact: Marcel de Rooy
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-10-12 11:54 UTC by David Gustafsson
Modified: 2017-10-13 17:02 UTC (History)
1 user (show)

See Also:
Change sponsored?: ---
Patch complexity: Trivial patch
Bot Control: ---
When did the bot last check this:
Who signed the patch off:
Text to go in the release notes:


Attachments
Incorrect jQuery selector for fund drop down validation (1.29 KB, patch)
2017-10-12 12:11 UTC, David Gustafsson
Details | Diff | Splinter Review
Incorrect jQuery selector for fund drop down validation (1.33 KB, patch)
2017-10-12 12:29 UTC, Owen Leonard
Details | Diff | Splinter Review
Bug 19453: Incorrect jQuery selector for fund drop down validation (1.38 KB, patch)
2017-10-13 08:49 UTC, Marcel de Rooy
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description David Gustafsson 2017-10-12 11:54:32 UTC
This might be a regression, or perhaps it has never worked, but the js-validation for the "Fund" select uses the selector [name="fund_code"] when the element is named "fund_id", correcting the selector fixes this.
Comment 1 David Gustafsson 2017-10-12 12:11:28 UTC
Created attachment 67996 [details] [review]
Incorrect jQuery selector for fund drop down validation

Steps to reproduce:
1. Create a new basket
2. Choose "Add to masket"
3. Choose "From a staged file"
4. Select a file
5. Save without selecting a fund

Expected results: A validation error should be shown, and form submit
halted.

Actual results: No validation error is shown and form submits.
Comment 2 Owen Leonard 2017-10-12 12:29:04 UTC
Created attachment 67997 [details] [review]
Incorrect jQuery selector for fund drop down validation

Steps to reproduce:
1. Create a new basket
2. Choose "Add to masket"
3. Choose "From a staged file"
4. Select a file
5. Save without selecting a fund

Expected results: A validation error should be shown, and form submit
halted.

Actual results: No validation error is shown and form submits.

https://bugs.koha-community.org/show_bug.cgi?id=19453

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Comment 3 Marcel de Rooy 2017-10-13 08:49:24 UTC
Created attachment 68052 [details] [review]
Bug 19453: Incorrect jQuery selector for fund drop down validation

Steps to reproduce:
1. Create a new basket
2. Choose "Add to masket"
3. Choose "From a staged file"
4. Select a file
5. Save without selecting a fund

Expected results: A validation error should be shown, and form submit
halted.

Actual results: No validation error is shown and form submits.

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Comment 4 Marcel de Rooy 2017-10-13 08:50:04 UTC
David: Please add Bug [number]: to future patches. Thanks
Comment 5 Jonathan Druart 2017-10-13 17:02:10 UTC
Pushed to master for 17.11, thanks to everybody involved!