View | Details | Raw Unified | Return to bug 31503
Collapse All | Expand All

(-)a/installer/data/mysql/atomicupdate/bug31503.pl (-2 / +7 lines)
Lines 2-8 use Modern::Perl; Link Here
2
2
3
return {
3
return {
4
    bug_number  => 31503,
4
    bug_number  => 31503,
5
    description => "Change patron_consent.type",
5
    description => "Change patron_consent.type, add pref OPACCustomConsentTypes",
6
    up          => sub {
6
    up          => sub {
7
        my ($args) = @_;
7
        my ($args) = @_;
8
        my ( $dbh, $out ) = @$args{qw(dbh out)};
8
        my ( $dbh, $out ) = @$args{qw(dbh out)};
Lines 10-16 return { Link Here
10
        $dbh->do(
10
        $dbh->do(
11
            q{ALTER TABLE `patron_consent` MODIFY `type` tinytext COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT 'consent type, could be custom type'}
11
            q{ALTER TABLE `patron_consent` MODIFY `type` tinytext COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT 'consent type, could be custom type'}
12
        );
12
        );
13
14
        say $out "Changed column 'patron_consent.type'";
13
        say $out "Changed column 'patron_consent.type'";
14
15
        $dbh->do(
16
            q{INSERT IGNORE INTO systempreferences ( `variable`, `value`, `options`, `explanation`, `type` ) VALUES
17
('OPACCustomConsentTypes', '0', NULL, 'If enabled, custom consent types can be registered on account page', 'YesNo')}
18
        );
19
        say $out "Addedd preference 'OPACCustomConsentTypes'";
15
    },
20
    },
16
};
21
};
(-)a/installer/data/mysql/mandatory/sysprefs.sql (+1 lines)
Lines 445-450 INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` Link Here
445
('OpacCloud','0',NULL,'If ON, enables subject cloud on OPAC','YesNo'),
445
('OpacCloud','0',NULL,'If ON, enables subject cloud on OPAC','YesNo'),
446
('OpacAdditionalStylesheet','','','Define an auxiliary stylesheet for OPAC use, to override specified settings from the primary opac.css stylesheet. Enter the filename (if the file is in the server\'s css directory) or a complete URL beginning with http (if the file lives on a remote server).','free'),
446
('OpacAdditionalStylesheet','','','Define an auxiliary stylesheet for OPAC use, to override specified settings from the primary opac.css stylesheet. Enter the filename (if the file is in the server\'s css directory) or a complete URL beginning with http (if the file lives on a remote server).','free'),
447
('OpacCoce','0', NULL, 'If on, enables cover retrieval from the configured Coce server in the OPAC', 'YesNo'),
447
('OpacCoce','0', NULL, 'If on, enables cover retrieval from the configured Coce server in the OPAC', 'YesNo'),
448
('OPACCustomConsentTypes', '0', NULL, 'If enabled, custom consent types can be registered on account page', 'YesNo'),
448
('OPACCustomCoverImages','0',NULL,'If enabled, the custom cover images will be displayed at the OPAC. CustomCoverImagesURL must be defined.','YesNo'),
449
('OPACCustomCoverImages','0',NULL,'If enabled, the custom cover images will be displayed at the OPAC. CustomCoverImagesURL must be defined.','YesNo'),
449
('OPACdefaultSortField','relevance','relevance|popularity|call_number|pubdate|acqdate|title|author','Specify the default field used for sorting','Choice'),
450
('OPACdefaultSortField','relevance','relevance|popularity|call_number|pubdate|acqdate|title|author','Specify the default field used for sorting','Choice'),
450
('OPACdefaultSortOrder','dsc','asc|dsc|za|az','Specify the default sort order','Choice'),
451
('OPACdefaultSortOrder','dsc','asc|dsc|za|az','Specify the default sort order','Choice'),
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref (+9 lines)
Lines 551-556 OPAC: Link Here
551
                  summary: "in user summary box on OPAC homepage (the system preference <em>OPACUserSummary</em> must be enabled)"
551
                  summary: "in user summary box on OPAC homepage (the system preference <em>OPACUserSummary</em> must be enabled)"
552
                  user: "on patron's 'your summary' page"
552
                  user: "on patron's 'your summary' page"
553
            - ". Note that displayed savings may be inaccurate if checkout history is anonymized."
553
            - ". Note that displayed savings may be inaccurate if checkout history is anonymized."
554
        -
555
            - pref: OPACCustomConsentTypes
556
              default: 0
557
              choices:
558
                  1: Allow
559
                  0: "Don't allow"
560
            - "users to register consents for custom (plugin based) consent types on the user account page."
561
            - "<br>Note: The consents tab is also visible when you enabled PrivacyPolicyConsent."
562
554
    OpenURL:
563
    OpenURL:
555
        -
564
        -
556
            - 'Complete URL of OpenURL resolver (starting with <code>http://</code> or <code>https://</code>):'
565
            - 'Complete URL of OpenURL resolver (starting with <code>http://</code> or <code>https://</code>):'
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/usermenu.inc (-2 / +1 lines)
Lines 24-30 Link Here
24
            [% END %]
24
            [% END %]
25
                <a href="/cgi-bin/koha/opac-memberentry.pl">Personal details</a></li>
25
                <a href="/cgi-bin/koha/opac-memberentry.pl">Personal details</a></li>
26
26
27
            [% IF Koha.Preference('PrivacyPolicyConsent') || Koha.Preference('CookieConsent') # remove when extending %]
27
            [% IF Koha.Preference('PrivacyPolicyConsent') || Koha.Preference('CookieConsent') || Koha.Preference('OPACCustomConsentTypes') %]
28
                [% IF consentview %]<li class="active">[% ELSE %]<li>[% END %]
28
                [% IF consentview %]<li class="active">[% ELSE %]<li>[% END %]
29
                    <a href="/cgi-bin/koha/opac-patron-consent.pl">Consents</a>
29
                    <a href="/cgi-bin/koha/opac-patron-consent.pl">Consents</a>
30
                </li>
30
                </li>
31
- 

Return to bug 31503