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

(-)a/C4/Auth.pm (+2 lines)
Lines 336-341 sub get_template_and_user { Link Here
336
            noItemTypeImages             => C4::Context->preference("noItemTypeImages"),
336
            noItemTypeImages             => C4::Context->preference("noItemTypeImages"),
337
            marcflavour                  => C4::Context->preference("marcflavour"),
337
            marcflavour                  => C4::Context->preference("marcflavour"),
338
            persona                      => C4::Context->preference("persona"),
338
            persona                      => C4::Context->preference("persona"),
339
            GoodReadsReviews             => C4::Context->preference("GoodReadsReviews"),
340
            GoodReadsKey                 => C4::Context->preference("GoodReadsKey"),
339
    );
341
    );
340
    if ( $in->{'type'} eq "intranet" ) {
342
    if ( $in->{'type'} eq "intranet" ) {
341
        $template->param(
343
        $template->param(
(-)a/installer/data/mysql/sysprefs.sql (+1 lines)
Lines 423-425 INSERT INTO systempreferences (variable,value,options,explanation,type) VALUES ( Link Here
423
INSERT INTO systempreferences (variable,value,options,explanation,type) VALUES('DisplayIconsXSLT', '1', '', 'If ON, displays the format, audience, and material type icons in XSLT MARC21 results and detail pages.', 'YesNo');
423
INSERT INTO systempreferences (variable,value,options,explanation,type) VALUES('DisplayIconsXSLT', '1', '', 'If ON, displays the format, audience, and material type icons in XSLT MARC21 results and detail pages.', 'YesNo');
424
INSERT INTO systempreferences (variable,value,options,explanation,type) VALUES ('HighlightOwnItemsOnOPAC','0','','If on, and a patron is logged into the OPAC, items from his or her home library will be emphasized and shown first in search results and item details.','YesNo');
424
INSERT INTO systempreferences (variable,value,options,explanation,type) VALUES ('HighlightOwnItemsOnOPAC','0','','If on, and a patron is logged into the OPAC, items from his or her home library will be emphasized and shown first in search results and item details.','YesNo');
425
INSERT INTO systempreferences (variable,value,options,explanation,type) VALUES ('HighlightOwnItemsOnOPACWhich','PatronBranch','PatronBranch|OpacURLBranch','Decides which branch''s items to emphasize. If PatronBranch, emphasize the logged in user''s library''s items. If OpacURLBranch, highlight the items of the Apache var BRANCHCODE defined in Koha''s Apache configuration file.','Choice')
425
INSERT INTO systempreferences (variable,value,options,explanation,type) VALUES ('HighlightOwnItemsOnOPACWhich','PatronBranch','PatronBranch|OpacURLBranch','Decides which branch''s items to emphasize. If PatronBranch, emphasize the logged in user''s library''s items. If OpacURLBranch, highlight the items of the Apache var BRANCHCODE defined in Koha''s Apache configuration file.','Choice')
426
INSERT IGNORE INTO systempreferences (variable,value,explanation,options,type)  VALUES('GoodReadsReviews','0','Show Goodreads Reviews','','YesNo');
(-)a/installer/data/mysql/updatedatabase.pl (+11 lines)
Lines 6499-6504 if ( CheckVersion($DBversion) ) { Link Here
6499
        AND user_permissions.code = 'circulate_remaining_permissions'
6499
        AND user_permissions.code = 'circulate_remaining_permissions'
6500
    });
6500
    });
6501
    print "Upgrade to $DBversion done ( Add circ permission overdues_report )\n";
6501
    print "Upgrade to $DBversion done ( Add circ permission overdues_report )\n";
6502
}
6503
6504
$DBversion = "3.11.00.XXX";
6505
if ( CheckVersion($DBversion) ) {
6506
    $dbh->do(
6507
        qq{
6508
INSERT IGNORE INTO systempreferences (variable,value,explanation,options,type)  VALUES('GoodReadsReviews','0','Show Goodreads Reviews','','YesNo');
6509
        }
6510
    );
6511
    print
6512
"Upgrade to $DBversion done (Bug 9817: Add GoodReads Reviews to OPAC)\n";
6502
    SetVersion($DBversion);
6513
    SetVersion($DBversion);
6503
}
6514
}
6504
6515
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/enhanced_content.pref (+12 lines)
Lines 326-328 Enhanced Content: Link Here
326
                  yes: Enable
326
                  yes: Enable
327
                  no: "Don't enable"
327
                  no: "Don't enable"
328
            - the ability to use Koha Plugins. Note, the plugin system must also be enabled in the Koha configuration file to be fully enabled.
328
            - the ability to use Koha Plugins. Note, the plugin system must also be enabled in the Koha configuration file to be fully enabled.
329
    Good Reads:
330
        -
331
            - Good reads API key
332
            - pref: GoodReadsKey
333
              class: password
334
            - you can get a key from http://www.goodreads.com/api/keys
335
        -
336
            - pref: GoodReadsReviews
337
              choices:
338
                  yes: "Show"
339
                  no: "Don't show"
340
            - a tab in the holdings section in the OPAC for Goodreads reviews
(-)a/koha-tmpl/opac-tmpl/prog/en/includes/goodreadsreviews.inc (+43 lines)
Line 0 Link Here
1
<style>
2
  #goodreads-widget {
3
    font-family: georgia, serif;
4
    padding: 18px 0;
5
    width:565px;
6
  }
7
  #goodreads-widget h1 {
8
    font-weight:normal;
9
    font-size: 16px;
10
    border-bottom: 1px solid #BBB596;
11
    margin-bottom: 0;
12
  }
13
  #goodreads-widget a {
14
    text-decoration: none;
15
    color:#660;
16
  }
17
  iframe{
18
    background-color: #fff;
19
  }
20
  #goodreads-widget a:hover { text-decoration: underline; }
21
  #goodreads-widget a:active {
22
    color:#660;
23
  }
24
  #gr_footer {
25
    width: 100%;
26
    border-top: 1px solid #BBB596;
27
    text-align: right;
28
  }
29
  #goodreads-widget .gr_branding{
30
    color: #382110;
31
    font-size: 11px;
32
    text-decoration: none;
33
    font-family: verdana, arial, helvetica, sans-serif;
34
  }
35
</style>
36
<div id="goodreadreviews">
37
<div id="goodreads-widget">
38
  <div id="gr_header"><h1>Goodreads reviews for [% title |html %]</h1></div>
39
  <iframe id="the_iframe" src="http://www.goodreads.com/api/reviews_widget_iframe?did=4504&format=html&header_text=Goodreads+reviews+for+[% title |uri %]&isbn=[% normalized_isbn %]&links=660&review_back=fff&stars=000&text=000" width="800" height="400" frameborder="0"></iframe>
40
  <div id="gr_footer">
41
  </div>
42
</div>
43
</div>
(-)a/koha-tmpl/opac-tmpl/prog/en/modules/opac-detail.tt (-1 / +9 lines)
Lines 976-981 YAHOO.util.Event.onContentReady("furtherm", function () { Link Here
976
[% IF ( IDreamBooksReviews ) %]
976
[% IF ( IDreamBooksReviews ) %]
977
    <li id='tab_idb_critic_reviews' style="display:none;"><a href='#idb_critic_reviews'>Book reviews by critics ( XXX )</a></li>
977
    <li id='tab_idb_critic_reviews' style="display:none;"><a href='#idb_critic_reviews'>Book reviews by critics ( XXX )</a></li>
978
[% END %]
978
[% END %]
979
980
[% IF GoodReadsReviews %]
981
   <li id="tab_goodreadreviews"><a href="#goodreadreviews">Goodreads Reviews</a></li>
982
[% END %]
983
979
</ul>
984
</ul>
980
985
981
[% IF ( serialcollection ) %]
986
[% IF ( serialcollection ) %]
Lines 1324-1329 YAHOO.util.Event.onContentReady("furtherm", function () { Link Here
1324
</div>
1329
</div>
1325
[% END %]
1330
[% END %]
1326
1331
1332
[% IF GoodReadsReviews %]
1333
    [% INCLUDE 'goodreadsreviews.inc' %]
1334
[% END %]
1335
1327
[% IF ( OPACLocalCoverImages && localimages.size ) %]
1336
[% IF ( OPACLocalCoverImages && localimages.size ) %]
1328
<div id="images">
1337
<div id="images">
1329
<p>Click on an image to view it in the image viewer</p>
1338
<p>Click on an image to view it in the image viewer</p>
1330
- 

Return to bug 9817