@@ -, +, @@
---
C4/Members.pm | 1 -
C4/Reserves.pm | 1 +
Koha/Template/Plugin/Koha.pm | 1 +
.../prog/en/modules/admin/preferences/opac.pref | 7 +++
.../prog/en/modules/admin/preferences/patrons.pref | 6 ++
.../prog/en/modules/members/memberentrygen.tt | 16 ++++++
.../prog/en/modules/members/moremember.tt | 10 ++++
.../bootstrap/en/modules/opac-memberentry.tt | 43 ++++++++++++++++
.../opac-tmpl/bootstrap/en/modules/opac-privacy.tt | 24 ++++++++-
.../opac-tmpl/bootstrap/en/modules/opac-user.tt | 53 ++++++++++++++++++-
members/moremember.pl | 1 +
opac/opac-privacy.pl | 38 +++++++++-----
opac/opac-user.pl | 32 +++++++++---
13 files changed, 204 insertions(+), 29 deletions(-)
--- a/C4/Members.pm
+++ a/C4/Members.pm
@@ -114,7 +114,6 @@ BEGIN {
push @EXPORT, qw(
&ModMember
&changepassword
- &ModPrivacy
);
#Delete data
--- a/C4/Reserves.pm
+++ a/C4/Reserves.pm
@@ -268,6 +268,7 @@ sub GetReserve {
my ($reserve_id) = @_;
my $dbh = C4::Context->dbh;
+
my $query = "SELECT * FROM reserves WHERE reserve_id = ?";
my $sth = $dbh->prepare( $query );
$sth->execute( $reserve_id );
--- a/Koha/Template/Plugin/Koha.pm
+++ a/Koha/Template/Plugin/Koha.pm
@@ -23,6 +23,7 @@ use Encode qw( encode );
use base qw( Template::Plugin );
use C4::Context;
+use Koha::Database;
=pod
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref
+++ a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref
@@ -582,6 +582,13 @@ OPAC:
no: "Don't allow"
- patrons to choose their own privacy settings for their reading history. This requires opacreadinghistory and AnonymousPatron
-
+ - pref: AllowPatronToSetCheckoutsVisibilityForGuarantor
+ default: 0
+ choices:
+ yes: Allow
+ no: "Don't allow"
+ - patrons to choose their own privacy settings for showing the patron's checkouts to the patron's guarantor".
+ -
- Use borrowernumber
- pref: AnonymousPatron
class: integer
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/patrons.pref
+++ a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/patrons.pref
@@ -128,6 +128,12 @@ Patrons:
no: "Don't"
- enable the ability to upload and attach arbitrary files to a borrower record.
-
+ - pref: AllowStaffToSetCheckoutsVisibilityForGuarantor
+ choices:
+ yes: Allow
+ no: "Don't allow"
+ - staff to set the ability for a patron's checkouts to be viewed by linked patrons in the OPAC.
+ -
- Card numbers for patrons must be
- pref: CardnumberLength
- "characters long. The length can be a single number to specify an exact length, a range separated by a comma (i.e., 'Min,Max'), or a maximum with no minimum (i.e., ',Max')."
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt
+++ a/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt
@@ -1,5 +1,6 @@
[% USE Koha %]
[% USE KohaDates %]
+[% USE Koha %]
[% INCLUDE 'doc-head-open.inc' %]
Koha › Patrons › [% IF ( opadd ) %]Add[% ELSIF ( opduplicate ) %]Duplicate[% ELSE %] Modify[% END %] patron [% IF (firstname) %][% firstname %] [% END %][% IF (surname) %][% surname %] [% END %]([%IF ( categoryname ) %][% categoryname %][% ELSE %][% IF ( I ) %]Organization[% END %][% IF ( A ) %]Adult[% END %][% IF ( C ) %]Child[% END %][% IF ( P ) %]Professional[% END %][% IF ( S ) %]Staff[% END %][% END %])
[% INCLUDE 'doc-head-close.inc' %]
@@ -465,6 +466,21 @@
[% END %]
+ [% IF guarantorid && Koha.Preference('AllowStaffToSetCheckoutsVisibilityForGuarantor') %]
+
+
+
+
Allow guarantor of this patron to view this patron's checkouts from the OPAC
+
+ [% END %]
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember.tt
+++ a/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember.tt
@@ -347,6 +347,16 @@ function validate1(date) {
[% IF ( privacy1 ) %]Default[% END %]
[% IF ( privacy2 ) %]Never[% END %]
[% END %]
+
+
+ Show checkouts to guarantor
+ [% IF privacy_guarantor_checkouts %]
+ Yes
+ [% ELSE %]
+ No
+ [% END %]
+