important fixes for bibtemplate, featuredcontentslider, result_common.js
authorsenator <lebbeous@esilibrary.com>
Sat, 5 Mar 2011 17:17:14 +0000 (12:17 -0500)
committersenator <lebbeous@esilibrary.com>
Sat, 5 Mar 2011 17:17:14 +0000 (12:17 -0500)
Open-ILS/web/opac/skin/kcls/js/misc.js
Open-ILS/web/opac/skin/kcls/js/result_common.js
Open-ILS/web/opac/skin/kcls/xml/common/js_shared.xml

index 1f9b3fa..9059a17 100644 (file)
@@ -3,15 +3,6 @@ var webCacheKey;
 var userVitalStats;
 
 function opac_init() {
-    featuredcontentslider.init({
-        id: "homebanner",
-        contentsource: ["inline", ""],
-        toc: "markup",
-        nextprev: ["", ""],
-        enablefade: [true, 0.04],
-        onChange: function(previndex, curindex){},
-        autorotate: [true, 3000] //pause time (in milliseconds)
-    });
        var advLink = getId("home_adv_search_link");
        if(advLink) advLink.setAttribute("href", buildOPACLink({page:ADVANCED})); 
        getId("home_myopac_link").setAttribute("href", buildOPACLink({page:MYOPAC}, false, true));
index 7e26da8..bb82f20 100644 (file)
@@ -58,7 +58,9 @@ var recordsCache = [];
 var lowHitCount = 4;
 var isbnList = '';
 var googleBooksLink = true;
-buildOrgSel($('holdsCacheSel'), globalOrgTree, 0);
+attachEvt("common", "init", function() {
+    buildOrgSel($('holdsCacheSel'), globalOrgTree, 0);
+});
 
 var resultFetchAllRecords = false;
 var resultCompiledSearch = null;
index b3d80a4..2be236c 100644 (file)
@@ -142,6 +142,7 @@ dojo.require("dijit.form.FilteringSelect");
 dojo.require("dojo.date.locale");
 dojo.require("dojo.date.stamp");
 dojo.require("dojo.parser");
+dojo.require("openils.BibTemplate");
 dojo.require("openils.widget.FacetSidebar"); // pulls in Searcher and I18N
 dojo.require("dijit.form.CheckBox");
 dojo.require("openils.widget.ProgressDialog");
@@ -184,3 +185,16 @@ try {
         document.getElementById('toptable').style.display = ''; 
     } catch(ee) {}
 }
+<!--#if expr="$OILS_PAGE='index.xml'"-->
+dojo.addOnLoad(function() {
+    featuredcontentslider.init({
+        id: "homebanner",
+        contentsource: ["inline", ""],
+        toc: "markup",
+        nextprev: ["", ""],
+        enablefade: [true, 0.04],
+        onChange: function(previndex, curindex){},
+        autorotate: [true, 3000] //pause time (in milliseconds)
+    });
+});
+<!--#endif-->