Bug 19012 - Note additional columns that are required during patron import
Summary: Note additional columns that are required during patron import
Status: Pushed to oldstable
Alias: None
Product: Koha
Classification: Unclassified
Component: Tools (show other bugs)
Version: master
Hardware: All All
: P5 - low minor (vote)
Assignee: Nick Clemens
QA Contact: Marcel de Rooy
URL:
Keywords:
: 20671 (view as bug list)
Depends on:
Blocks:
 
Reported: 2017-07-31 16:15 UTC by Nick Clemens
Modified: 2019-08-06 15:09 UTC (History)
8 users (show)

See Also:
Change sponsored?: ---
Patch complexity: String patch
Who signed the patch off:
Text to go in the release notes:
Version(s) released in:
19.11.00,19.05.03


Attachments
Bug 19012 - Note additional columns that are required during patron import (2.92 KB, patch)
2017-07-31 16:17 UTC, Nick Clemens
Details | Diff | Splinter Review
[SIGNED OFF] Bug 19012 - Note additional columns that are required during patron import (2.99 KB, patch)
2017-08-08 21:54 UTC, Katrin Fischer
Details | Diff | Splinter Review
Bug 19012 - Note additional columns that are required during patron import (1.34 KB, patch)
2019-06-07 12:46 UTC, Nick Clemens
Details | Diff | Splinter Review
Really Spare Patron Import. (944 bytes, text/csv)
2019-06-17 23:59 UTC, M. Tompsett
Details
Really realy spare patron import (48 bytes, text/csv)
2019-06-18 10:45 UTC, Nick Clemens
Details
Bug 19012 - Note additional columns that are required during patron import (1.39 KB, patch)
2019-06-20 15:57 UTC, M. Tompsett
Details | Diff | Splinter Review
Bug 19012: Note additional columns that are required during patron import (1.49 KB, patch)
2019-07-05 08:58 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 Nick Clemens 2017-07-31 16:15:32 UTC
We say 'branchcode' and 'categorycode' are required - this is true, but so are surname and cardnumber
Comment 1 Nick Clemens 2017-07-31 16:17:55 UTC
Created attachment 65363 [details] [review]
Bug 19012 - Note additional columns that are required during patron import

This adds surname and cardnumber to the list of required columns on the
import tool screen and help page

To test:
Read the updated notes, verify it is true and understandable
Comment 2 Katrin Fischer 2017-08-08 21:54:40 UTC
Created attachment 65693 [details] [review]
[SIGNED OFF] Bug 19012 - Note additional columns that are required during patron import

This adds surname and cardnumber to the list of required columns on the
import tool screen and help page

To test:
Read the updated notes, verify it is true and understandable

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 3 Jonathan Druart 2017-08-09 17:34:01 UTC
No, they are not mandatory. It's the default value for BorrowerMandatoryField, but can be removed, and others can be added. I guess you will have to parse the pref to display which fields are mandatory.
Comment 4 Katrin Fischer 2017-08-09 18:51:28 UTC
That's interesting, I didn't know that!
Comment 5 Katrin Fischer 2017-08-09 18:52:47 UTC
Hm, in my experience surname and cardnumber were always needed and it seemed to make sense, now I wonder.
Comment 6 Katrin Fischer 2017-08-09 21:17:00 UTC
I'd done some testing and looking at the code, surname is a mandatory hardcoded value:

150: my @criticals = qw(surname branchcode categorycode);    # there probably should be others

Cardnumber in fact isn't!
Comment 7 Nick Clemens 2019-06-07 12:46:47 UTC
Created attachment 90419 [details] [review]
Bug 19012 - Note additional columns that are required during patron import

This adds surname and cardnumber to the list of required columns on the
import tool screen and help page

To test:
Read the updated notes, verify it is true and understandable
Comment 8 Nick Clemens 2019-06-07 12:48:20 UTC
*** Bug 20671 has been marked as a duplicate of this bug. ***
Comment 9 Nick Clemens 2019-06-07 12:49:05 UTC
(In reply to Jonathan Druart from comment #3)
> No, they are not mandatory. It's the default value for
> BorrowerMandatoryField, but can be removed, and others can be added. I guess
> you will have to parse the pref to display which fields are mandatory.

Nope, test it, fields required in the pref are not required for import - that may be its own bug if you wish
Comment 10 M. Tompsett 2019-06-17 23:59:03 UTC
Created attachment 90708 [details]
Really Spare Patron Import.

This is a scary example of what patron import let's you import.
I suspect if you had userid set and empty card number and used userid as the match, it would import too.
Comment 11 M. Tompsett 2019-06-18 00:00:29 UTC
I got away with cardnumber, branch code, and category code. If we are correcting the text to match what it does, then the text is still wrong.

If we are fixing the import and matching the text, then that's still broken.
Comment 12 Nick Clemens 2019-06-18 10:45:05 UTC
Created attachment 90721 [details]
Really realy spare patron import

Remove surname from the file and it fails on missing a critical column
Comment 13 M. Tompsett 2019-06-20 15:57:58 UTC
Created attachment 90856 [details] [review]
Bug 19012 - Note additional columns that are required during patron import

This adds surname and cardnumber to the list of required columns on the
import tool screen and help page

To test:
Read the updated notes, verify it is true and understandable

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Comment 14 Marcel de Rooy 2019-07-05 08:58:00 UTC
Created attachment 91328 [details] [review]
Bug 19012: Note additional columns that are required during patron import

This adds surname and cardnumber to the list of required columns on the
import tool screen and help page

To test:
Read the updated notes, verify it is true and understandable

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Comment 15 Martin Renvoize 2019-07-15 11:21:25 UTC
Nice work!

Pushed to master for 19.11.00
Comment 16 Fridolin SOMERS 2019-07-30 05:34:12 UTC
Pushed to 19.05.x for 19.05.03
Comment 17 Lucas Gass 2019-08-06 15:09:27 UTC
backported to 18.11.x for 18.11.09