Bugzilla – Attachment 61404 Details for
Bug 17309
Renewing and HomeOrHoldingBranch syspref
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 17309 - Renewing and HomeOrHoldingBranch syspref
Bug-17309---Renewing-and-HomeOrHoldingBranch-syspr.patch (text/plain), 2.44 KB, created by
Jonathan Druart
on 2017-03-21 16:47:13 UTC
(
hide
)
Description:
Bug 17309 - Renewing and HomeOrHoldingBranch syspref
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2017-03-21 16:47:13 UTC
Size:
2.44 KB
patch
obsolete
>From b06fbe6f860784e90a5296d67d380c6d1c4eb978 Mon Sep 17 00:00:00 2001 >From: David Kuhn <techservspec@gmail.com> >Date: Wed, 14 Dec 2016 16:02:26 -0800 >Subject: [PATCH] Bug 17309 - Renewing and HomeOrHoldingBranch syspref >MIME-Version: 1.0 >Content-Type: text/plain; charset=UTF-8 >Content-Transfer-Encoding: 8bit > >The AddRenewal subroutine currently uses the circulation rules for the branch >stored in the Issues table (which is the holding branch) when calculating the new due date. > >This patch replaces using the branch from the Issues table with the branch >specified by the HomeOrHoldingBranch syspref. > >To test: >1. Set up 2 branches, Branch1 and Branch2 >2. Set up a loan rule in Branch1 for DVDs with a 21 day loan period and a > 21 day renewal period. >3. Set up a loan rule in Branch2 for DVDs with a 14 day loan period and a > 14 day renewal period. >4. Checkout a DVD belonging to Branch1 while logged into Branch2. It will > receive the correct 21 day loan period. >5. Renewing the same DVD while logged into either Branch1 or Branch2 > will give a 14 day due date, rather than 21 days. >6. Checkout a DVD belonging to Branch2 while logged into Branch1. It will > receive the correct 14 day loan period. >7. Renewing the same DVD while logged into either Branch1 or Branch2 > will give a 21 day due date, rather than 14 days. >8. Apply the patch and repeat steps 4-7. The correct due date should be given > when the item is renewed, regardless of where it is checked out or renewed. > >This update removes reassignment of $branch variable. > >Signed-off-by: Cédric Vita <cedric.vita@dracenie.com> > >Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >--- > C4/Circulation.pm | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >diff --git a/C4/Circulation.pm b/C4/Circulation.pm >index af5acce..d8ba562 100644 >--- a/C4/Circulation.pm >+++ b/C4/Circulation.pm >@@ -2841,7 +2841,7 @@ sub AddRenewal { > $datedue = (C4::Context->preference('RenewalPeriodBase') eq 'date_due') ? > dt_from_string( $issuedata->{date_due} ) : > DateTime->now( time_zone => C4::Context->tz()); >- $datedue = CalcDateDue($datedue, $itemtype, $issuedata->{'branchcode'}, $borrower, 'is a renewal'); >+ $datedue = CalcDateDue($datedue, $itemtype, _GetCircControlBranch($item, $borrower), $borrower, 'is a renewal'); > } > > # Update the issues record to have the new due date, and a new count >-- >2.1.4
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 17309
:
56846
|
58195
|
61399
| 61404