Bug 14493

Summary: export_borrowers.pl - Export patron attributes
Product: Koha Reporter: Vitor Fernandes <vfernandes>
Component: Command-line UtilitiesAssignee: Jason Etheridge <jason>
Status: Patch doesn't apply --- QA Contact: Testopia <testopia>
Severity: enhancement    
Priority: P5 - low CC: f.demians, jason, jonathan.druart, katrin.fischer, robin, severine.queune
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: Sponsored Patch complexity: Trivial patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Attachments: Export borrowers script
export_borrowers.pl changed to support patron attributes
export_borrowers.pl changed to support patron attributes
Bug 14493: export_borrowers.pl - Export patron attributes
Bug 14493: export_borrowers.pl - Export patron attributes

Description Vitor Fernandes 2015-07-06 11:09:57 UTC
When using the script export_borrowers.pl the patron attributes are not exposed to the CSV.
The idea is to have a field called patron_attributes that exposes all the extended attributes.
Comment 1 Vitor Fernandes 2015-07-06 11:29:58 UTC Comment hidden (obsolete)
Comment 2 Jonathan Druart 2015-07-14 16:27:52 UTC
There is no change with your file and the one in master.
Comment 3 Vitor Fernandes 2015-08-04 12:17:54 UTC Comment hidden (obsolete)
Comment 4 Vitor Fernandes 2015-08-04 12:24:38 UTC
Created attachment 41341 [details] [review]
export_borrowers.pl changed to support patron attributes

Test plan:

- Use export_borrowers.pl to export all patron and all fields
- The patrons extended attributes are not exported
- Apply the patch
- Use export_borrowers.pl with the no fields specified or with the field patron_attributes
- The patrons extended attributes will be exported in one column 

Create by: Vitor Fernandes <vfernandes@keep.pt>
Sponsored by: KEEP SOLUTIONS
Comment 5 Jonathan Druart 2015-08-04 14:07:05 UTC
Is it ready to test?
Don't forget to provide a test plan.
Comment 6 Vitor Fernandes 2015-08-04 14:22:07 UTC
Jonathan,

Yes, is ready to test.
You can check the test plan on the patch commit.
Comment 7 Jonathan Druart 2015-08-04 14:34:15 UTC
(In reply to Vitor Fernandes from comment #6)
> You can check the test plan on the patch commit.

Yes sorry, it's on the bug report but not on the patch! Thanks.
Comment 8 Frédéric Demians 2015-11-11 14:16:35 UTC
Vitor, your patch uses GetBorrowerAttributes which has been moved from C4::Member to C4::Members::Attributes. Could you add this to export_borrowers.pl?

  use C4::Members::Attributes qw(GetBorrowerAttributes);

And add the test plan to the patch itself as suggested by Johnatan?
Comment 9 Jason Etheridge 2018-07-12 19:32:41 UTC
Created attachment 76926 [details] [review]
Bug 14493: export_borrowers.pl - Export patron attributes

Tweaked Vitor's original patch to accomodate changes to the file.

---

export_borrowers.pl changed to support patron attributes

Test plan:

- Use export_borrowers.pl to export all patron and all fields
- The patrons extended attributes are not exported
- Apply the patch
- Use export_borrowers.pl with the no fields specified or with the field patron_attributes
- The patrons extended attributes will be exported in one column

Create by: Vitor Fernandes <vfernandes@keep.pt>
Sponsored by: KEEP SOLUTIONS

Signed-off-by: Jason Etheridge <jason@equinoxinitiative.org>
Comment 10 Maryse Simard 2019-05-10 21:04:41 UTC
Created attachment 89574 [details] [review]
Bug 14493: export_borrowers.pl - Export patron attributes

Tweaked Vitor's original patch to accomodate changes to the file.

Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>
Comment 11 Axelle Aix-Marseille Université 2019-10-01 07:48:34 UTC
We try to test today : this patch doesn't apply on a sandbox (Biblibre n°1)
Comment 12 Séverine Queune 2019-10-02 12:10:50 UTC
Bug 14493 - export_borrowers.pl - Export patron attributes

41341 - export_borrowers.pl changed to support patron attributes
89574 - Bug 14493: export_borrowers.pl - Export patron attributes

Apply? [(y)es, (n)o, (i)nteractive] y
Applying: export_borrowers.pl changed to support patron attributes
Using index info to reconstruct a base tree...
M       misc/export_borrowers.pl
Falling back to patching base and 3-way merge...
Auto-merging misc/export_borrowers.pl
CONFLICT (content): Merge conflict in misc/export_borrowers.pl
Failed to merge in the changes.
Patch failed at 0001 export_borrowers.pl changed to support patron attributes
Comment 13 Katrin Fischer 2022-10-07 23:15:55 UTC
Would be great to see this one rescued!