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

(-)a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-patron-consent.tt (-24 / +24 lines)
Lines 36-49 Link Here
36
                        <input type="hidden" name="op" value="save"/>
36
                        <input type="hidden" name="op" value="save"/>
37
                        <input type="hidden" name="borrowernumber" value="[% patron.borrowernumber | html %]"/>
37
                        <input type="hidden" name="borrowernumber" value="[% patron.borrowernumber | html %]"/>
38
                        <h1>Your consents</h1>
38
                        <h1>Your consents</h1>
39
                        <br>
40
                        [% FOREACH consent IN consents %]
39
                        [% FOREACH consent IN consents %]
41
                            [% SET consent_type = consent.type %]
40
                            [% SET consent_type = consent.type %]
42
                            [% IF consent_type == 'GDPR_PROCESSING' %]
41
                            [% IF consent_type == 'GDPR_PROCESSING' %]
43
                                <legend><h2>Privacy policy consent</h2></legend>
42
                                <legend><h2>Privacy policy consent</h2></legend>
44
                                <p>Please read the <a target="_blank" href="[% Koha.Preference('PrivacyPolicyURL') | url %]">privacy policy</a>.</p>
43
                                <div class="alert alert-warning">
45
                                <p>In order to keep you logged in, we need your consent to process personal data as specified in the EU General Data Protection Regulation of May 25, 2018. If you would not agree, we will need to <strong>remove</strong> your account within a reasonable time.</p>
44
                                    <p>In order to keep you logged in, we need your consent to process personal data as specified in the privacy policy linked below.</p>
46
                                <p>Do you agree with our processing of your personal data as outlined in the policy?</p>
45
                                    <p>If you choose to withdraw your consent we will <strong>remove your account</strong> within a reasonable time and you should log out now.</p>
46
                                </div>
47
                                <p>I have read the <a target="_blank" href="[% Koha.Preference('PrivacyPolicyURL') | url %]">privacy policy</a> and agree with your processing of my personal data as outlined therein.</p>
47
                            [% ELSIF consent_types.$consent_type %]
48
                            [% ELSIF consent_types.$consent_type %]
48
                                [% SET consent_title = ( consent_types.$consent_type.title.$lang || consent_types.$consent_type.title.en ) %]
49
                                [% SET consent_title = ( consent_types.$consent_type.title.$lang || consent_types.$consent_type.title.en ) %]
49
                                [% SET consent_desc  = ( consent_types.$consent_type.description.$lang || consent_types.$consent_type.description.en )  %]
50
                                [% SET consent_desc  = ( consent_types.$consent_type.description.$lang || consent_types.$consent_type.description.en )  %]
Lines 55-69 Link Here
55
                                <p>Do you agree?</p>
56
                                <p>Do you agree?</p>
56
                            [% END %]
57
                            [% END %]
57
                            <fieldset>
58
                            <fieldset>
58
                                <input type="radio" name="check_[% consent_type | html %]" value="1"> Yes<br>
59
                                [% IF consent.given_on %]
59
                                <input type="radio" name="check_[% consent_type | html %]" value="0"> No
60
                                    <input type="radio" name="check_[% consent_type | html %]" value="1" checked="checked"> Yes<br>
61
                                    <input type="radio" name="check_[% consent_type | html %]" value="0"> No
62
                                [% ELSIF consent.refused_on %]
63
                                    <input type="radio" name="check_[% consent_type | html %]" value="1"> Yes<br>
64
                                    <input type="radio" name="check_[% consent_type | html %]" value="0" checked="checked"> No
65
                                [% ELSE %]
66
                                    <input type="radio" name="check_[% consent_type | html %]" value="1"> Yes<br>
67
                                    <input type="radio" name="check_[% consent_type | html %]" value="0"> No
68
                                [% END %]
69
                                [% IF consent.given_on %]
70
                                    <p class="consent_info"><strong>Your consent was registered on [% consent.given_on | html %].</strong></p>
71
                                [% ELSIF consent.refused_on %]
72
                                    <p class="dissent_info"><strong>We registered that you did not consent on [% consent.refused_on | html %].</strong></p>
73
                                [% END %]
60
                            </fieldset>
74
                            </fieldset>
61
                            [% IF consent.given_on %]
62
                                <p class="consent_info">Your consent was registered on [% consent.given_on | html %].</p>
63
                            [% ELSIF consent.refused_on %]
64
                                <p class="dissent_info">We registered that you did not consent on [% consent.refused_on | html %].</p>
65
                            [% END %]
66
                            <br>
67
                        [% END %]
75
                        [% END %]
68
                        <fieldset class="action">
76
                        <fieldset class="action">
69
                            <input id="saveconsent" type="submit" value="Save" class="btn btn-primary" />
77
                            <input id="saveconsent" type="submit" value="Save" class="btn btn-primary" />
Lines 85-97 Link Here
85
[% BLOCK jsinclude %]
93
[% BLOCK jsinclude %]
86
    <script>
94
    <script>
87
        $(document).ready(function() {
95
        $(document).ready(function() {
88
            [% FOREACH consent IN consents %]
89
                [% IF consent.given_on %]
90
                    $("input[type='radio'][name='check_[% consent.type | html %]'][value='1']").prop('checked',true);
91
                [% ELSIF consent.refused_on %]
92
                    $("input[type='radio'][name='check_[% consent.type | html %]'][value='0']").prop('checked',true);
93
                 [% END %]
94
            [% END %]
95
            // Initially no choice is made or no change, so disable button
96
            // Initially no choice is made or no change, so disable button
96
            $("#saveconsent").prop('disabled', true);
97
            $("#saveconsent").prop('disabled', true);
97
98
Lines 100-110 Link Here
100
                var v = $(this).val();
101
                var v = $(this).val();
101
                // If former registration info present, toggle
102
                // If former registration info present, toggle
102
                if( v == 1 ) {
103
                if( v == 1 ) {
103
                    $(this).parent().siblings('.consent_info').show();
104
                    $(this).siblings('.consent_info').show();
104
                    $(this).parent().siblings('.dissent_info').hide();
105
                    $(this).siblings('.dissent_info').hide();
105
                } else {
106
                } else {
106
                    $(this).parent().siblings('.consent_info').hide();
107
                    $(this).siblings('.consent_info').hide();
107
                    $(this).parent().siblings('.dissent_info').show();
108
                    $(this).siblings('.dissent_info').show();
108
                }
109
                }
109
            });
110
            });
110
        });
111
        });
111
- 

Return to bug 31503