Adds B4 Book Log icon and link to KPAC search results page and
authorTerran McCanna <tmccanna@georgialibraries.org>
Tue, 26 May 2015 13:09:27 +0000 (09:09 -0400)
committerChris Sharp <csharp@georgialibraries.org>
Sat, 9 Dec 2017 19:34:09 +0000 (14:34 -0500)
KPAC item details page.

(This is a PINES-only customization.)

Adds B4 Book Log icon to KPAC search results page and
KPAC item details page.

Conflicts:
Open-ILS/src/templates/kpac/parts/record_row.tt2
Open-ILS/src/templates/kpac/record.tt2

Open-ILS/src/templates/kpac/parts/record_row.tt2
Open-ILS/src/templates/kpac/record.tt2
Open-ILS/web/images/kpac/b4only.png [new file with mode: 0644]

index bc2cda7..00e4492 100644 (file)
                                </div>
                        </div>
             [% END %]
+                       <!-- link to add to b4 book log -->
+                       <div class="item_icon_wrapper">
+                               <div class="item_icon">
+                                       <script type="text/javascript">
+                                               var a = escape("[% attrs.title %]");
+                                               var b = escape("[% attrs.author %]");
+                                               var b4link = "http://b4.georgialibraries.org/cat_add.php?title=" + a + "&author=" + b;
+                                               document.write("<a href='" + b4link + "'>");
+                                       </script>
+                                       <img src="[% ctx.media_prefix %]/images/kpac/b4only.png" alt="Add to B4 Book Log" /><br/>
+                                       Add to B4<br/>Book Log</a>
+                               </div>  
+                       </div>  
                    <div class="clear">&nbsp;</div>
            [% END %]
        
index a59705e..e7d0c20 100644 (file)
@@ -4,7 +4,7 @@
     WRAPPER "kpac/parts/subpage.tt2";
     attrs = {marc_xml => ctx.marc_xml};
     PROCESS get_marc_attrs args=attrs;
-    ctx.page_title = attrs.title | html 
+    ctx.page_title = attrs.title | html
 %]
 
 <div class="item_detail_header">
                                        </div>
                 [% END %]
             [% END %]
+                           <!-- link to add to b4 book log -->
+                           <div class="item_icon_wrapper">
+                               <div class="item_icon">
+                                       <script type="text/javascript">
+                                                       var a = escape("[% attrs.title %]");
+                                                       var b = escape("[% attrs.author %]");
+                                                       var b4link = "http://b4.georgialibraries.org/cat_add.php?title=" + a + "&author=" + b;
+                                                       document.write("<a href='" + b4link + "'>");
+                                               </script>
+                                               <img src="[% ctx.media_prefix %]/images/kpac/b4only.png" alt="Add to B4 Book Log" /><br/>
+                                               Add to B4<br/>Book Log</a>
+                                   </div>
+                           </div>
             </div>
         </div>
     </div>
diff --git a/Open-ILS/web/images/kpac/b4only.png b/Open-ILS/web/images/kpac/b4only.png
new file mode 100644 (file)
index 0000000..5ad1d18
Binary files /dev/null and b/Open-ILS/web/images/kpac/b4only.png differ