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

(-)a/installer/data/mysql/atomicupdate/bug_17381_SCOMainUserBlock.perl (+9 lines)
Line 0 Link Here
1
$DBversion = 'XXX';  # will be replaced by the RM
2
if( CheckVersion( $DBversion ) ) {
3
4
    $dbh->do("INSERT IGNORE INTO systempreferences (`variable`, `value`, `options`, `explanation`, `type` ) VALUES ('SCOMainUserBlock','','70|10','Add a block of HTML that will display on the self checkout screen','Textarea')" );
5
6
    # Always end with this (adjust the bug info)
7
    SetVersion( $DBversion );
8
    print "Upgrade to $DBversion done (Bug 17381 - Add system preference SCOMainUserBlock)\n";
9
}
(-)a/installer/data/mysql/sysprefs.sql (+1 lines)
Lines 462-467 INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` Link Here
462
('RoutingListAddReserves','1','','If ON the patrons on routing lists are automatically added to holds on the issue.','YesNo'),
462
('RoutingListAddReserves','1','','If ON the patrons on routing lists are automatically added to holds on the issue.','YesNo'),
463
('RoutingListNote','To change this note edit <a href=\"/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=RoutingListNote#jumped\">RoutingListNote</a> system preference.','70|10','Define a note to be shown on all routing lists','Textarea'),
463
('RoutingListNote','To change this note edit <a href=\"/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=RoutingListNote#jumped\">RoutingListNote</a> system preference.','70|10','Define a note to be shown on all routing lists','Textarea'),
464
('RoutingSerials','1',NULL,'If ON, serials routing is enabled','YesNo'),
464
('RoutingSerials','1',NULL,'If ON, serials routing is enabled','YesNo'),
465
('SCOMainUserBlock','','70|10','Add a block of HTML that will display on the self checkout screen','Textarea'),
465
('SCOUserCSS','',NULL,'Add CSS to be included in the SCO module in an embedded <style> tag.','free'),
466
('SCOUserCSS','',NULL,'Add CSS to be included in the SCO module in an embedded <style> tag.','free'),
466
('SCOUserJS','',NULL,'Define custom javascript for inclusion in the SCO module','free'),
467
('SCOUserJS','',NULL,'Define custom javascript for inclusion in the SCO module','free'),
467
('SearchEngine','Zebra','Elasticsearch|Zebra','Search Engine','Choice'),
468
('SearchEngine','Zebra','Elasticsearch|Zebra','Search Engine','Choice'),
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref (+5 lines)
Lines 747-752 Circulation: Link Here
747
              type: textarea
747
              type: textarea
748
              class: code
748
              class: code
749
        -
749
        -
750
            - "Include the following HTML on the the web-based self checkout screen:"
751
            - pref: SCOMainUserBlock
752
              type: textarea
753
              class: code
754
        -
750
            - "Include the following CSS on all pages in the web-based self checkout:"
755
            - "Include the following CSS on all pages in the web-based self checkout:"
751
            - pref: SCOUserCSS
756
            - pref: SCOUserCSS
752
              type: textarea
757
              type: textarea
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/modules/sco/sco-main.tt (-1 / +2 lines)
Lines 290-295 Link Here
290
                                <h3>You currently have nothing checked out.</h3>
290
                                <h3>You currently have nothing checked out.</h3>
291
                            [% END # / IF issues_count %]
291
                            [% END # / IF issues_count %]
292
                        </div> <!-- / #borrowerdetails -->
292
                        </div> <!-- / #borrowerdetails -->
293
                            </div> <!-- / #newcheckout -->
293
                        [% ELSE # IF validuser %]
294
                        [% ELSE # IF validuser %]
294
                            <div class="sco_entry" >
295
                            <div class="sco_entry" >
295
                                <form id="mainform" action="/cgi-bin/koha/sco/sco-main.pl" name="mainform" method="post">
296
                                <form id="mainform" action="/cgi-bin/koha/sco/sco-main.pl" name="mainform" method="post">
Lines 320-326 Link Here
320
                            </div> <!-- / .sco_entry -->
321
                            </div> <!-- / .sco_entry -->
321
                        [% END # / IF validuser %]
322
                        [% END # / IF validuser %]
322
                    [% END # / UNLESS ( hide_main %]
323
                    [% END # / UNLESS ( hide_main %]
323
324
                    [% IF ( SCOMainUserBlock ) %]<div id="scomainuserblock">[% SCOMainUserBlock %]</div>[% END %]
324
                </div> <!-- / .span12 -->
325
                </div> <!-- / .span12 -->
325
            </div> <!-- / .row-fluid -->
326
            </div> <!-- / .row-fluid -->
326
        </div> <!-- / .container-fluid -->
327
        </div> <!-- / .container-fluid -->
(-)a/opac/sco/sco-main.pl (-1 / +1 lines)
Lines 315-320 if ($borrower->{cardnumber}) { Link Here
315
$template->param(
315
$template->param(
316
    SCOUserJS  => C4::Context->preference('SCOUserJS'),
316
    SCOUserJS  => C4::Context->preference('SCOUserJS'),
317
    SCOUserCSS => C4::Context->preference('SCOUserCSS'),
317
    SCOUserCSS => C4::Context->preference('SCOUserCSS'),
318
    SCOMainUserBlock => C4::Context->preference('SCOMainUserBlock'),
318
);
319
);
319
320
320
output_html_with_http_headers $query, $cookie, $template->output, undef, { force_no_caching => 1 };
321
output_html_with_http_headers $query, $cookie, $template->output, undef, { force_no_caching => 1 };
321
- 

Return to bug 17381