Changeset 26249


Ignore:
Timestamp:
09/25/12 15:40:37 (8 years ago)
Author:
kjdon
Message:

added back in some params that had gone missing

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone3/src/java/org/greenstone/gsdl3/service/AbstractTextSearch.java

    r25765 r26249  
    136136            return true;
    137137        }
    138 
    139         // Get to there then none of the above params matched
     138    else if (name.equals(CASE_PARAM) || name.equals(STEM_PARAM) || name.equals(ACCENT_PARAM)) {
     139      if (param_default == null) {
     140        param_default = BOOLEAN_PARAM_OFF;
     141      }
     142        String[] bool_ops = {"0", "1"};
     143        String[] bool_texts = {getTextString("param.boolean.off", lang),getTextString("param.boolean.on", lang)};
     144        param = GSXML.createParameterDescription(this.doc, name, getTextString("param."+name, lang), GSXML.PARAM_TYPE_BOOLEAN, param_default, bool_ops, bool_texts);
     145        param_list.appendChild(param);
     146        return true;
     147    } else if (name.equals(MATCH_PARAM)) {
     148      if (param_default == null) {
     149        param_default = MATCH_PARAM_SOME;
     150      }
     151     
     152        String[] vals = {MATCH_PARAM_SOME, MATCH_PARAM_ALL };
     153        String[] val_texts = {getTextString("param."+MATCH_PARAM+"."+MATCH_PARAM_SOME, lang), getTextString("param."+MATCH_PARAM+"."+MATCH_PARAM_ALL, lang)};
     154        param = GSXML.createParameterDescription(this.doc, MATCH_PARAM, getTextString("param."+MATCH_PARAM, lang), GSXML.PARAM_TYPE_ENUM_SINGLE, param_default, vals, val_texts);
     155        param_list.appendChild(param);
     156        return true;
     157    }
     158        // Get to here then none of the above params matched
    140159        // => return false so the chain can continue
    141160        return false;
Note: See TracChangeset for help on using the changeset viewer.