From ee4a7f9c224f73edd94177d00dbfc39cfc43f341 Mon Sep 17 00:00:00 2001 From: Terran McCanna Date: Tue, 17 Nov 2020 15:58:32 -0500 Subject: [PATCH] OPAC: Added Content Updates This updates the Syndetics section to pull in full content instead of screen-scraping it, and expands the NoveList section by default. Signed-off-by: Terran McCanna --- .../opac/parts/record/addedcontent.tt2 | 154 ++++++++++++++------- .../opac/parts/record/extras.tt2 | 2 +- 2 files changed, 104 insertions(+), 52 deletions(-) diff --git a/Open-ILS/src/templates-bootstrap/opac/parts/record/addedcontent.tt2 b/Open-ILS/src/templates-bootstrap/opac/parts/record/addedcontent.tt2 index 05f640d0b1..8b1c0863da 100755 --- a/Open-ILS/src/templates-bootstrap/opac/parts/record/addedcontent.tt2 +++ b/Open-ILS/src/templates-bootstrap/opac/parts/record/addedcontent.tt2 @@ -1,55 +1,107 @@ -
- -[% - ac_types = { - reviews => l('Reviews'), - anotes => l('Author Notes'), - toc => l('Table of Contents'), - excerpt => l('Excerpt'), - summary => l('Summary') - }; - - selected_type = CGI.param('ac'); - - # For each type of added content, render the link if it's known to have - # content, do not render the link if it's known to not have content. If - # the content status is unknown, render the link, but hide the link via CSS - # if dojo is enabled. If dojo is not enabled, render and display the link. -%] - -
- [% - all_hidden = 1; - FOR type IN ac_types.keys; - tab_class = 'ac_tab'; - SET tab_class = tab_class _ ' ac_tab_selected' IF type == selected_type; - IF ctx.added_content.$type.status != '2'; # no content - all_hidden = 0; - IF ctx.added_content.$type.status == '3' AND want_dojo; # status unknown - tab_class = tab_class _ ' hidden'; - END %] - - [% END; - END; - %] -
+ +[% IF attrs.isbn_clean || attrs.upc || attrs.issn %] + + + +
+ +
+
+ × + +
+
-
- [% - IF selected_type; - content = ctx.added_content.$selected_type.content; - IF content; - content; - ELSE; - l('No Content Available'); - END; - ELSIF all_hidden; - l('No Content Available'); - END; - %]
-
+ +[% END %] \ No newline at end of file diff --git a/Open-ILS/src/templates-bootstrap/opac/parts/record/extras.tt2 b/Open-ILS/src/templates-bootstrap/opac/parts/record/extras.tt2 index b681ab4be1..13fd29871c 100755 --- a/Open-ILS/src/templates-bootstrap/opac/parts/record/extras.tt2 +++ b/Open-ILS/src/templates-bootstrap/opac/parts/record/extras.tt2 @@ -69,7 +69,7 @@ %]
[% - IF tab_is_active(name); + IF tab_is_active(name) OR name == 'awards' OR name == 'addedcontent'; href = mkurl('', {}, ['expand', 'ac']); arrow = arrow_down; ELSE; -- 2.11.0