Changeset 26057

Show
Ignore:
Timestamp:
01.08.2012 16:07:03 (7 years ago)
Author:
ak19
Message:

Fixed side-effect bug I accidentally introduced in a previous commit which made the appearance of the FieldSearch? and AdvancedSearch? queries dependent on the presence of TextQuery?, because an index in TextQuery? is called index and indexes in the other 2 types of queries are called fq-something. Fixed this now.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone3/web/interfaces/default/transform/layouts/header.xsl

    r26028 r26057  
    358358    <!-- Search form should only appear if there's a search (query) service AND it has an index.  
    359359         By default, all collections end up with some query service (default is MGPP) even when they have 
    360          no search indexes, which is why the extra test for the presence of an index is necessary. --> 
     360         no search indexes, which is why the extra test for the presence of an index/fq-something is necessary. --> 
    361361    <xsl:template name="quick-search-area"> 
    362         <xsl:if test="/page/pageResponse/collection[@name=$collNameChecked]/serviceList/service[@type='query']/paramList/param[@name='index']"> 
     362        <xsl:if test="/page/pageResponse/collection[@name=$collNameChecked]/serviceList/service[@type='query']/paramList/param[@name='index' or fn:starts-with('fq')]"> 
    363363            <xsl:variable name="subaction" select="/page/pageRequest/@subaction"/> 
    364364            <div id="quicksearcharea"> 
     
    412412                        </span> 
    413413                    </xsl:if> 
    414                     <!-- The submit button --> 
     414                    <!-- The submit button (for TextQuery) --> 
     415                    <xsl:if test="/page/pageResponse/collection[@name=$collNameChecked]/serviceList/service[@name='TextQuery']"> 
    415416                    <input type="submit" id="quickSearchSubmitButton"> 
    416417                        <xsl:attribute name="value"> 
     
    419420                    </input> 
    420421                    <br/> 
     422                    </xsl:if> 
    421423                    <!-- The list of other search types --> 
    422424                    <ul>