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

(-)a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-suggestions.tt (-4 / +3 lines)
Lines 97-109 Link Here
97
                                        <li>
97
                                        <li>
98
                                            <div title="Copyright or publication year, for example: 2016">
98
                                            <div title="Copyright or publication year, for example: 2016">
99
                                                [% IF ( copyrightdate_required ) %]
99
                                                [% IF ( copyrightdate_required ) %]
100
                                                    <label for="copyrightdate" class="required">Copyright date:</label>
100
                                                    <label for="copyrightdate" class="required">Publication year:</label>
101
                                                    <input type="text" id="copyrightdate" name="copyrightdate" pattern="[12]\d{3}" size="10" maxlength="4" value="[% copyrightdate | html %]" required="required" />
101
                                                    <input type="text" id="copyrightdate" name="copyrightdate" pattern="[12]\d{3}" size="10" maxlength="4" value="[% copyrightdate | html %]" required="required" />
102
                                                <span class="required">Required</span>
102
                                                <span class="required">Required</span>
103
                                                [% ELSE %]
103
                                                [% ELSE %]
104
                                                    <label for="copyrightdate">Copyright date:</label>
104
                                                    <label for="copyrightdate">Publication year:</label>
105
                                                    <input type="text" id="copyrightdate" name="copyrightdate" pattern="[12]\d{3}" size="10" maxlength="4" value="[% copyrightdate | html %]" />
105
                                                    <input type="text" id="copyrightdate" name="copyrightdate" pattern="[12]\d{3}" size="10" maxlength="4" value="[% copyrightdate | html %]" />
106
                                                [% END %]
106
                                                [% END %]
107
                                                <span class="hint">Copyright or publication year, for example: 2016</span>
107
                                            </div>
108
                                            </div>
108
                                        </li>
109
                                        </li>
109
                                        [% UNLESS Koha.Preference( 'OPACSuggestionAutoFill' ) %]
110
                                        [% UNLESS Koha.Preference( 'OPACSuggestionAutoFill' ) %]
Lines 461-468 Link Here
461
[% Asset.js("lib/jquery/plugins/jquery.checkboxes.min.js") | $raw %]
462
[% Asset.js("lib/jquery/plugins/jquery.checkboxes.min.js") | $raw %]
462
[% INCLUDE 'datatables.inc' %]
463
[% INCLUDE 'datatables.inc' %]
463
<script>
464
<script>
464
    var MSG_UNDO_AUTOFILL_SUGGESTION =  _("Undo");
465
    var MSG_SEARCH_GOOGLE_BOOKS = _("Search Google Books");
466
    [% IF ( loggedinusername ) %]
465
    [% IF ( loggedinusername ) %]
467
        function enableCheckboxActions(){
466
        function enableCheckboxActions(){
468
            // Enable/disable controls if checkboxes are checked
467
            // Enable/disable controls if checkboxes are checked
(-)a/koha-tmpl/opac-tmpl/bootstrap/js/autofill.js (-2 / +4 lines)
Lines 27-32 Link Here
27
        self.$elm = $(elm);
27
        self.$elm = $(elm);
28
        self.fields = fields;
28
        self.fields = fields;
29
29
30
        var MSG_UNDO_AUTOFILL_SUGGESTION =  __("Clear form");
31
        var MSG_SEARCH_GOOGLE_BOOKS = __("Search Google Books");
32
30
        /* decorate element as autofiller */
33
        /* decorate element as autofiller */
31
        self.$undo = $('<input type="button" class="btn" style="display:none;margin-left:5px;" value="' + MSG_UNDO_AUTOFILL_SUGGESTION + '" />');
34
        self.$undo = $('<input type="button" class="btn" style="display:none;margin-left:5px;" value="' + MSG_UNDO_AUTOFILL_SUGGESTION + '" />');
32
        self.$fillbtn = $('<input type="button" class="btn" value="' + MSG_SEARCH_GOOGLE_BOOKS + '" />');
35
        self.$fillbtn = $('<input type="button" class="btn" value="' + MSG_SEARCH_GOOGLE_BOOKS + '" />');
Lines 69-75 Link Here
69
                gAPI += '&maxResults=1';
72
                gAPI += '&maxResults=1';
70
                $.getJSON(gAPI, function (response) {
73
                $.getJSON(gAPI, function (response) {
71
                    if(response.totalItems == 0) {
74
                    if(response.totalItems == 0) {
72
                        self.$error.html(_('Sorry, nothing found.'));
75
                        self.$error.html(__('Sorry, nothing found.'));
73
                        self.$error.show();
76
                        self.$error.show();
74
                        return;
77
                        return;
75
                    }
78
                    }
76
- 

Return to bug 14242