Bugzilla – Attachment 67276 Details for
Bug 12598
New misc/import_borrowers.pl command line tool
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 12598: Re-add bug 18555: Create patron list from patron import
0001-Bug-12598-Re-add-bug-18555-Create-patron-list-from-p.patch (text/plain), 2.17 KB, created by
Colin Campbell
on 2017-09-21 13:22:11 UTC
(
hide
)
Description:
Bug 12598: Re-add bug 18555: Create patron list from patron import
Filename:
MIME Type:
Creator:
Colin Campbell
Created:
2017-09-21 13:22:11 UTC
Size:
2.17 KB
patch
obsolete
>From d12ce1b240ee1d95c987fb01b37b50902dd959d9 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Tue, 22 Aug 2017 13:34:17 -0300 >Subject: [PATCH 1/2] Bug 12598: Re-add bug 18555: Create patron list from > patron import > >Signed-off-by: Colin Campbell <colin.campbell@ptfs-europe.com> >--- > Koha/Patrons/Import.pm | 3 +++ > tools/import_borrowers.pl | 7 +++++++ > 2 files changed, 10 insertions(+) > >diff --git a/Koha/Patrons/Import.pm b/Koha/Patrons/Import.pm >index c785604766..ab73d99048 100644 >--- a/Koha/Patrons/Import.pm >+++ b/Koha/Patrons/Import.pm >@@ -82,6 +82,7 @@ sub import_patrons { > my $alreadyindb = 0; > my $overwritten = 0; > my $invalid = 0; >+ my @imported_borrowers; > my $matchpoint_attr_type = $self->set_attribute_types({ extended => $extended, matchpoint => $matchpoint, }); > > # Use header line to construct key to column map >@@ -320,6 +321,7 @@ sub import_patrons { > } > > $imported++; >+ push @imported_borrowers, $borrowernumber; #for patronlist > push( > @feedback, > { >@@ -350,6 +352,7 @@ sub import_patrons { > overwritten => $overwritten, > already_in_db => $alreadyindb, > invalid => $invalid, >+ imported_borrowers => \@imported_borrowers, > }; > } > >diff --git a/tools/import_borrowers.pl b/tools/import_borrowers.pl >index c49a0bcd91..59168b6fb2 100755 >--- a/tools/import_borrowers.pl >+++ b/tools/import_borrowers.pl >@@ -137,6 +137,13 @@ if ( $uploadborrowers && length($uploadborrowers) > 0 ) { > my $overwritten = $return->{overwritten}; > my $alreadyindb = $return->{already_in_db}; > my $invalid = $return->{invalid}; >+ my $imported_borrowers = $return->{imported_borrowers}; >+ >+ if ( $imported && $createpatronlist ) { >+ my $patronlist = AddPatronList({ name => $patronlistname }); >+ AddPatronsToList({ list => $patronlist, borrowernumbers => $imported_borrowers }); >+ $template->param('patronlistname' => $patronlistname); >+ } > > my $uploadinfo = $input->uploadInfo($uploadborrowers); > foreach ( keys %$uploadinfo ) { >-- >2.13.5 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 12598
:
29807
|
29808
|
29809
|
29939
|
30755
|
30780
|
35557
|
35558
|
35559
|
35560
|
35848
|
35849
|
35850
|
35851
|
35964
|
36684
|
36685
|
36687
|
36688
|
36690
|
36692
|
36693
|
36694
|
36695
|
36696
|
39124
|
39125
|
39126
|
39127
|
39128
|
41790
|
41791
|
41792
|
41793
|
41794
|
44065
|
44066
|
44067
|
44068
|
44069
|
48753
|
48754
|
48755
|
48756
|
48757
|
50693
|
50694
|
50695
|
50696
|
50697
|
50698
|
50699
|
50700
|
50704
|
51122
|
51357
|
51358
|
51359
|
51360
|
51361
|
51362
|
51363
|
51364
|
51365
|
51366
|
51367
|
51368
|
51369
|
51370
|
51371
|
51372
|
52323
|
52324
|
52325
|
52326
|
52327
|
52328
|
52329
|
52330
|
52331
|
52332
|
52333
|
52540
|
64437
|
64438
|
64855
|
65214
|
65215
|
65216
|
65217
|
65218
|
65819
|
65820
|
65821
|
65822
|
65823
|
65824
|
66353
|
66354
|
66355
|
66356
|
66357
|
66358
|
66359
|
66575
|
66576
|
66577
|
66578
|
66579
|
66580
|
66581
|
66582
|
67276
|
67277
|
70265
|
70266
|
71755
|
71756
|
71757
|
71758
|
71759
|
71760
|
71761
|
71762
|
71763
|
71764
|
71765
|
71766