Changeset 19940 in main


Ignore:
Timestamp:
03/03/20 10:34:02 (4 weeks ago)
Author:
GarthBraithwaite_STG
Message:

java view - Updated query module java and xslt to use the configuration/measure_name.

Location:
trunk
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/ibisph-view/src/main/webapp/xslt/html/query/module/result/Result.xslt

    r19890 r19940  
    3232        <xsl:param name="Result.dimensions"      select="if($Result.useExternalXML) then $Dimensions/DIMENSIONS else $Result.queryModule/DIMENSIONS"/>
    3333        <xsl:param name="Measures"/>
    34         <xsl:param name="Result.measure"         select="if($Result.useExternalXML) then $Measures/MEASURES/MEASURE[NAME=$Result.queryModule/CONFIGURATIONS/CONFIGURATION/MEASURE_NAME] else $Result.queryModule/MEASURES/MEASURE[NAME=$Result.queryModule/CONFIGURATIONS/CONFIGURATION/MEASURE_NAME]"/>
     34        <xsl:param name="Result.measure"         select="if($Result.useExternalXML) then $Measures/MEASURES/MEASURE[NAME=$Page.configuration/MEASURE_NAME] else $Result.queryModule/MEASURES/MEASURE[NAME=$Page.configuration/MEASURE_NAME]"/>
    3535        <xsl:param name="ValueTypes"/>
    3636        <xsl:param name="Result.valueTypes"      select="if($Result.useExternalXML) then $ValueTypes/VALUE_TYPES else $Result.queryModule/VALUE_TYPES"/>
  • trunk/ibisph/src/main/java/org/ibisph/querymodule/modelmap/AddHTTPRequestParametersToQueryModule.java

    r17255 r19940  
    355355    }
    356356
    357     // Set specified measure name.  If not specified then leave as is - default.
    358     String measureName = null;
    359     if(request != null) {
    360       measureName = request.getParameter("MeasureName");
    361       if(!StrLib.isSomething(measureName)) measureName = request.getParameter("_MeasureName");
    362       if(StrLib.isSomething(measureName)) this.queryModuleService.setRequestMeasureName(queryModule, measureName);
    363     }
    364 
    365     // Do a similar thing for the chart/graph name.
     357    // Set chart name.
    366358    String chartName = null;
    367359    if(request != null) {
  • trunk/ibisph/src/main/java/org/ibisph/querymodule/modelmap/UpdateDisplayOptionsFromHTTPRequest.java

    r15559 r19940  
    5353    Node queryModule = (Node)modelMap.get(this.modelMapKey);
    5454
    55     // Set specified measure name.  If not specified then leave as is - default.
    56     String measureName = request.getParameter(this.measureParameterName);
    57     this.queryModuleService.setRequestMeasureName(queryModule, measureName);
    58 
    59     // Do a similar thing for the chart/graph name.
     55    // Set the chart/graph name.
    6056    String chartName = request.getParameter(this.chartParameterName);
    6157    if(!StrLib.isSomething(chartName)) chartName = request.getParameter("chartName");
  • trunk/ibisph/src/main/java/org/ibisph/querymodule/service/QueryModuleXML.java

    r17645 r19940  
    180180    }
    181181
    182     // set the default measure
    183     String measureName = XMLLib.getText(configuration, "DEFAULT_MEASURE_NAME");
    184     if(!StrLib.isSomething(measureName)) measureName = XMLLib.getText(configuration, "MEASURES/MEASURE[not(NO_DISPLAY_FLAG)][1]/NAME");
    185     setRequestMeasureName(document, measureName);
    186 
    187182    // first check the config's param for a chart name.  If nothing use the
    188183    // default.  If still nothing then try the qm's param.
     
    369364
    370365  /**
    371    * Sets the /QUERY_MODULE/REQUEST/MEASURE_NAME element's value.
    372    * @param queryModule
    373    * @param measureName value to set.
    374    */
    375   public void setRequestMeasureName(Node queryModule, String measureName) {
    376     if(StrLib.isSomething(measureName)) {
    377       XMLLib.setText(
    378         queryModule,
    379         "/QUERY_MODULE/REQUEST",
    380         "MEASURE_NAME",
    381         measureName
    382       );
    383     }
    384   } //-------------------------- End of Method ------------------------------
    385 
    386   /**
    387366   * Gets the /QUERY_MODULE/REQUEST/CHART_NAME element's value.
    388367   * @param queryModule query module document to get text value from.
Note: See TracChangeset for help on using the changeset viewer.