Bugzilla – Attachment 155067 Details for
Bug 34617
Patron expiration dates not updated during import when there is no dateexpiry column in the file
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 34617: Preserve calculated expiration dates if set to update on import whether column included or not
Bug-34617-Preserve-calculated-expiration-dates-if-.patch (text/plain), 1.69 KB, created by
Marcel de Rooy
on 2023-09-01 08:26:50 UTC
(
hide
)
Description:
Bug 34617: Preserve calculated expiration dates if set to update on import whether column included or not
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2023-09-01 08:26:50 UTC
Size:
1.69 KB
patch
obsolete
>From e6bed9ea965bc3c8dfa61f322929402c33ea2841 Mon Sep 17 00:00:00 2001 >From: Nick Clemens <nick@bywatersolutions.com> >Date: Fri, 25 Aug 2023 14:51:28 +0000 >Subject: [PATCH] Bug 34617: Preserve calculated expiration dates if set to > update on import whether column included or not >Content-Type: text/plain; charset=utf-8 > >To test: >1 - Setup a csv with column headers: > surname firstname branchcode categorycode cardnumber dateenrolled >2 - add values > Acosta Edna CPL PT 23529001000463 02/01/2013 >3 - Set PT catgeory enrollement period to a specific date in the future >4 - Import the file and overwrite patrons and update dateexpiration >5 - Check Edna, note her date is not correct >6 - Apply patch >7 - Repeat >8 - Expiration date is now set as expected > >Signed-off-by: David Nind <david@davidnind.com> > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >--- > Koha/Patrons/Import.pm | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > >diff --git a/Koha/Patrons/Import.pm b/Koha/Patrons/Import.pm >index 3ba184d1e2..73d5355149 100644 >--- a/Koha/Patrons/Import.pm >+++ b/Koha/Patrons/Import.pm >@@ -279,7 +279,8 @@ sub import_patrons { > # FIXME : You cannot update a field with a perl-evaluated false value using the defaults. > > # The password is always encrypted, skip it unless we are forcing overwrite! >- next if $col eq 'password' && !$overwrite_passwords; >+ next if $col eq 'password' && !$overwrite_passwords; >+ next if $col eq 'dateexpiry' && $update_dateexpiry; > > unless ( exists( $csvkeycol{$col} ) || $defaults->{$col} ) { > $borrower{$col} = $member->{$col} if ( $member->{$col} ); >-- >2.30.2
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 34617
:
154816
|
154817
|
154867
|
154868
|
155066
| 155067