Bug 6964 - 'Add child' function should be dependant on system preference 'borrowerRelationship'
Summary: 'Add child' function should be dependant on system preference 'borrowerRelati...
Alias: None
Product: Koha
Classification: Unclassified
Component: Templates (show other bugs)
Version: master
Hardware: All All
: P5 - low enhancement (vote)
Assignee: Aleksa Vujicic
QA Contact: Marcel de Rooy
Depends on:
Reported: 2011-10-04 13:11 UTC by Katrin Fischer
Modified: 2013-12-05 20:01 UTC (History)
2 users (show)

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

The 'Add Child' button is not shown if 'borrowerRelationship' is empty. System preference description also changed. (10.38 KB, patch)
2012-01-24 00:55 UTC, Aleksa Vujicic
Details | Diff | Splinter Review
[SIGNED-OFF] Bug 6964 - 'Add child' function should be dependant on system preference 'borrowerRelationship' (10.57 KB, patch)
2012-01-24 14:45 UTC, Owen Leonard
Details | Diff | Splinter Review
Followup for typo on borrowernumber (1022 bytes, patch)
2012-02-03 07:54 UTC, Marcel de Rooy
Details | Diff | Splinter Review
Follow-up fixing typo (1022 bytes, patch)
2012-02-03 07: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 Katrin Fischer 2011-10-04 13:11:00 UTC
In academic libraries the features to 'Add childs' is not used and the button in patron account causes confusion.

I suggest to check if the system preference 'borrowerRelationship' is not empty to decide if the button is shown or not. 
The description of the system preference could be amended to say 'Leave empty to deactivate'.
Comment 1 Aleksa Vujicic 2012-01-24 00:55:07 UTC Comment hidden (obsolete)
Comment 2 Owen Leonard 2012-01-24 14:45:58 UTC Comment hidden (obsolete)
Comment 3 Paul Poulain 2012-02-02 10:43:44 UTC
QA comment:
* tiny patch, nothing to say about the code, it's OK
* I think it's an ENH, that could surprise some libraries. Changing the severity & version to have it for 3.8
Comment 4 Marcel de Rooy 2012-02-03 07:47:05 UTC
Note that a follow-up fixed missing comma after total_due:

diff --git a/members/paycollect.pl b/members/paycollect.pl
index cbddc05..e05a5a6 100755
--- a/members/paycollect.pl
+++ b/members/paycollect.pl
@@ -138,6 +138,7 @@ $template->param(
     borrowenumber => $borrowernumber,    # some templates require global
     borrower      => $borrower,
     total         => $total_due
+	activeBorrowerRelationship => (C4::Context->preference('borrowerRelationship') ne ''),

As Paul noted in commit: Seems everybody forgot to test paycollect, as there was a syntax error!
Comment 5 Marcel de Rooy 2012-02-03 07:54:31 UTC Comment hidden (obsolete)
Comment 6 Marcel de Rooy 2012-02-03 07:58:10 UTC
Created attachment 7431 [details] [review]
Follow-up fixing typo

Second try to add attachment..