Changeset 34093
- Timestamp:
- 2020-03-22T23:09:20+13:00 (4 years ago)
- Location:
- main/trunk/model-interfaces-dev/heritage-nz/transform
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
main/trunk/model-interfaces-dev/heritage-nz/transform/layouts/header.xsl
r33268 r34093 75 75 <xsl:choose> 76 76 <xsl:when test="not(page/pageRequest[@action='q']) or /page/pageRequest/paramList/param[@name='qs']/@value = '1'"> 77 <form action="{$library_name}/collection/{$collNameChecked}/search/TextQuery" >77 <form action="{$library_name}/collection/{$collNameChecked}/search/TextQuery" onsubmit="return validateQuickSearchForm()"> 78 78 <!-- This parameter says that we have come from the quick search area --> 79 79 <input type="hidden" name="qs" value="1"/> -
main/trunk/model-interfaces-dev/heritage-nz/transform/layouts/main.xsl
r33272 r34093 37 37 </gsf:script> 38 38 39 <gsf:script> 40 function gtag_trigger_download_event(elem,source_file) { 41 gtag('event', 'download_report', { 'event_category' : 'download', 'event_label': source_file }); 42 } 43 44 function gtag_trigger_search_event(query) { 45 gtag('event', 'search', { 'search_term': query }); 46 } 47 48 function validateQuickSearchForm() { 49 var $query = $('#quicksearcharea input[name="s1.query"]'); 50 if ($query.length > 0) { 51 var query = $query.val(); 52 if (query != "" ) { 53 gtag_trigger_search_event(query); 54 return true; 55 } 56 } 57 return false; 58 } 59 60 61 function validateAdvancedSearchForm() { 62 var $query = $('#quicksearcharea input[name="s1.query"]'); 63 64 var $query_term_elems = $('form[name="QueryForm"] input[name="s1.fqv"]'); 65 66 if ($query_term_elems.length > 0) { 67 68 var query_terms = []; 69 $query_term_elems.each(function() { 70 var q = $(this).val(); 71 if (q != "") { 72 query_terms.push(q) 73 } 74 }); 75 76 var query = query_terms.join(' '); 77 if (query != "" ) { 78 gtag_trigger_search_event(query); 79 return true; 80 } 81 } 82 83 return false; 84 } 85 </gsf:script> 86 39 87 <!-- ***** in header.xsl ***** --> 40 88 <xsl:call-template name="create-html-header"/> … … 84 132 85 133 #gs_footer { 134 font-size: 90%; 135 } 136 /* 137 #gs_footer { 86 138 position: absolute; 87 139 bottom: -30px; … … 89 141 width: 99.8%; 90 142 } 91 143 */ 92 144 #quicksearcharea ul { 93 145 margin-top: 10px; -
main/trunk/model-interfaces-dev/heritage-nz/transform/pages/berry.xsl
r33269 r34093 10 10 11 11 <!-- set page title --> 12 <xsl:template name="pageTitle"><a href="{$library_name}/collection/pdf-reports/page/about">Digital Library Home</a><gslib:rightArrow/><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'berry.title')"/></xsl:template> 12 <xsl:template name="pageTitle"><a href="{$library_name}/collection/pdf-reports/page/about">Digital Library Home</a><gslib:rightArrow/><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'favourites.title')"/></xsl:template> 13 14 <!-- optional cgi-params for links to document pages --> 15 <!-- here because collectionConfig.xml defined a template in 16 its *global* section that uses gsf:link, which in turn then 17 generates XSL tags that refer to opt-doc-link-arg --> 18 <!-- not strictly necessary in berry.xsl as currently used 19 in the HeritageDL, which is to access the berryBasket/favouriteBasket 20 without a c=xxx argument, and so doesn't draw in the 21 collectionConfig.xml file, however added here as a catch-all 22 in case this changes in the future and c=xxxx added in --> 23 24 <xsl:variable name="opt-doc-link-args"></xsl:variable> 13 25 14 26 <xsl:template name="customJavascript"> -
main/trunk/model-interfaces-dev/heritage-nz/transform/pages/classifier.xsl
r33271 r34093 44 44 <xsl:comment>Filler needed for div</xsl:comment> 45 45 <xsl:call-template name="viewOptions"/> 46 <xsl:if test="$berryBasketOn or $favourite sBasketOn or ($documentBasketOn and (util:contains(/page/pageRequest/userInformation/@groups, 'administrator') or util:contains(/page/pageRequest/userInformation/@groups, 'all-collections-editor') or util:contains(/page/pageRequest/userInformation/@groups, $thisCollectionEditor)))">46 <xsl:if test="$berryBasketOn or $favouriteBasketOn or ($documentBasketOn and (util:contains(/page/pageRequest/userInformation/@groups, 'administrator') or util:contains(/page/pageRequest/userInformation/@groups, 'all-collections-editor') or util:contains(/page/pageRequest/userInformation/@groups, $thisCollectionEditor)))"> 47 47 <xsl:if test="$berryBasketOn"> 48 48 <!-- show the berry basket if it's turned on --> … … 53 53 </xsl:if> 54 54 55 <xsl:if test="$favourite sBasketOn">55 <xsl:if test="$favouriteBasketOn"> 56 56 <!-- show the favourites 'basket' if it's turned on --> 57 57 <div class="tableOfContentsContainer" style="position:relative; z-index: 2;"> <!-- **** --> -
main/trunk/model-interfaces-dev/heritage-nz/transform/pages/query.xsl
r33271 r34093 22 22 --> 23 23 <!-- **** --> 24 <div id="float-anchor" style="position: absolute; width: 29%; min-width:180px; top: 105px;right:20px; margin: 0 0 10px 20px;">24 <div id="float-anchor" style="position: absolute; width: 29%; min-width:180px; /*top: 105px;*/ right:20px; margin: 0 0 10px 20px;"> 25 25 <xsl:comment>Filler needed for div</xsl:comment> 26 <xsl:call-template name="viewOptions"/>26 <!-- <xsl:call-template name="viewOptions"/>--> 27 27 28 <xsl:if test="$berryBasketOn or $favourite sBasketOn or ($documentBasketOn and (util:contains(/page/pageRequest/userInformation/@groups, 'administrator') or util:contains(/page/pageRequest/userInformation/@groups, 'all-collections-editor') or util:contains(/page/pageRequest/userInformation/@groups, $thisCollectionEditor)))">28 <xsl:if test="$berryBasketOn or $favouriteBasketOn or ($documentBasketOn and (util:contains(/page/pageRequest/userInformation/@groups, 'administrator') or util:contains(/page/pageRequest/userInformation/@groups, 'all-collections-editor') or util:contains(/page/pageRequest/userInformation/@groups, $thisCollectionEditor)))"> 29 29 <div id="rightSidebar" style="margin: 0 0 5px 5px; width: 100%"> 30 30 <!-- … … 46 46 </xsl:if> 47 47 48 <xsl:if test="$favourite sBasketOn">48 <xsl:if test="$favouriteBasketOn"> 49 49 <!-- show the favourites 'basket' if it's turned on --> 50 50 <div class="tableOfContentsContainer" style="position:relative; z-index: 2;"> <!-- **** --> … … 127 127 --> 128 128 <!-- **** --> 129 <div id="facetSelector" style="position: relative; float: right; top: 100px;"> 129 <div id="facetSelector" style="position: relative; float: right; top: 100px;"><b>Refine Your Search:</b> 130 130 <xsl:for-each select="/page/pageResponse/facetList/facet"> 131 131 <xsl:if test="count(count) > 0"> -
main/trunk/model-interfaces-dev/heritage-nz/transform/pages/verify.xsl
r33270 r34093 11 11 <xsl:template name="pageTitle"><a href="{$library_name}/collection/pdf-reports/page/about">Digital Library Home</a><gslib:rightArrow/><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'verify.title')"/></xsl:template> 12 12 13 <!-- optional cgi-params for links to document pages --> 14 <!-- needed here because collectionConfig.xml defined a template in 15 its *global* section that uses gsf:link, which in turn then 16 generates XSL tags that refer to opt-doc-link-arg --> 17 <xsl:variable name="opt-doc-link-args"></xsl:variable> 18 13 19 </xsl:stylesheet>
Note:
See TracChangeset
for help on using the changeset viewer.