Ignore:
Timestamp:
2018-09-13T14:05:59+12:00 (6 years ago)
Author:
kjdon
Message:

params class changed, now returns false by default for shouldsave. so don't need to add any that we don't want saving in the session. turned hard coded strings into static string variables

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone3/src/java/org/greenstone/gsdl3/action/GeneralAction.java

    r28964 r32448  
    2727{
    2828
     29  public static final String CONFIG_CHANGE_NAME_ARG = "configChangeName";
     30  public static final String CONFIG_CHANGE_VALUE_ARG = "configChangeValue";
     31 
    2932    /** process a request */
    3033    public Node process(Node message_node)
     
    4851        HashMap<String, Serializable> params = GSXML.extractParams(cgi_param_list, false);
    4952
    50         if (params.get("configChangeName") != null && params.get("configChangeValue") != null)
    51         {
    52             String optionName = (String) params.get("configChangeName");
    53             String optionValue = (String) params.get("configChangeValue");
     53        if (params.get(CONFIG_CHANGE_NAME_ARG) != null && params.get(CONFIG_CHANGE_VALUE_ARG) != null)
     54        {
     55            String optionName = (String) params.get(CONFIG_CHANGE_NAME_ARG);
     56            String optionValue = (String) params.get(CONFIG_CHANGE_VALUE_ARG);
    5457
    5558            changeConfig(optionName, optionValue);
     
    100103            Element param_list = null;
    101104            // add in the service params - except the ones only used by the action
    102             HashMap service_params = (HashMap) params.get("s1");
     105            HashMap service_params = (HashMap) params.get(GSParams.SERVICE_PREFIX);
    103106            if (service_params != null)
    104107            {
Note: See TracChangeset for help on using the changeset viewer.