Changeset 25315 in main


Ignore:
Timestamp:
06/03/22 18:30:48 (4 weeks ago)
Author:
GarthBraithwaite_STG
Message:

trunk - cleaned out and updated misc todos and unused java code. Changed ibis 30 to 31. Added .string #{commonContentBasePath.string to be explicit. Changed content options css to wrap and simpler left flex for responsive. Changed L.layersets from jq ajax to std fetch. Removed unused cat index and library pages from view. Removed geo selection map from community pages.

Location:
trunk
Files:
2 added
8 deleted
39 edited

Legend:

Unmodified
Added
Removed
  • trunk/ibisph-admin/src/main/webapp/WEB-INF/config/spring/SiteSpecific.xml

    r23219 r25315  
    153153
    154154                                <!-- if wanting prop file in the webapps dir then
    155                                         1) uncomment the below refed bean (above).
     155                                        1) uncomment the refed bean (above).
    156156                                        2) uncomment the ref to the bean (below).
    157                                 <value>#{siteSpecificWebappsRootURL}/nmepht-view.properties</value>
     157                                <value>#{siteSpecificWebappsRootURL}/ibisph-admin.properties</value>
    158158                                -->
    159159
    160                                 <value>file:../ibisph-admin.properties</value>
    161160                                <value>file:${user.home}/ibisph-admin.properties</value>
    162161                        </list>
  • trunk/ibisph-admin/src/main/webapp/WEB-INF/config/spring/indicator.xml

    r22944 r25315  
    5959                        filename. 
    6060                </description>
    61                 <constructor-arg value="#{commonContentBasePath}xml/indicator/profile/preview/"/>
     61                <constructor-arg value="#{commonContentBasePath.string}xml/indicator/profile/preview/"/>
    6262        </bean>
    6363        <bean id="indicatorPreviewXMLBasePathURL" class="org.springframework.beans.factory.config.MethodInvokingFactoryBean">
  • trunk/ibisph-admin/src/main/webapp/WEB-INF/config/spring/publish.xml

    r23426 r25315  
    2323        <!--  R E S O U R C E S  -->
    2424        <bean id="publishIndicatorProfileBasePath" class="org.ibisph.model.StringHolder">
    25                 <constructor-arg value="#{commonContentBasePath}xml/indicator/profile/"/>
     25                <constructor-arg value="#{commonContentBasePath.string}xml/indicator/profile/"/>
    2626        </bean>
    2727        <bean id="publishIndicatorProfileBasePathURL" class="org.springframework.beans.factory.config.MethodInvokingFactoryBean">
  • trunk/ibisph-admin/src/main/webapp/WEB-INF/jsp/dimension/value/detail.jsp

    r23356 r25315  
    55
    66<%--
    7 GARTH TODO: Need to make sure that period dim values are numeric.  At this point
     7TODO: Need to make sure that period dim values are numeric.  At this point
    88the dimension is not passed in as part of the model so can't test if period dim. 
    99When dimension is added to the model then the start point code below can be
  • trunk/ibisph-admin/src/main/webapp/WEB-INF/jsp/indicator/view/dimensions.jsp

    r23343 r25315  
    116116<c:if test="${userDetails.admin}"><a title="Edit dimension: ${indicatorView.periodDimensionName}" href="javascript:requestPage('edit/dimension/detail/${indicatorView.periodDimensionName}.html');"></c:if>
    117117                                        ${indicatorView.periodDimensionName}
    118 <%-- GARTH TODO: need a dimension map or jsp tag to loop the dims to show name instead of only the title.
     118<%-- TODO: need a dimension map or jsp tag to loop the dims to show name instead
     119        of only the title.
    119120                                        ${dimensions[indicatorView.periodDimensionName].title}
    120121--%>
  • trunk/ibisph-admin/src/main/webapp/WEB-INF/jsp/value_type/_help.jsp

    r24423 r25315  
    131131        is typically a Kendo.toString pattern.  This field is named more generic
    132132        (i.e. not named "kendo format pattern") so that other javascript libs could
    133         be implemented. 
     133        be implemented.  If being used in a Kendo template the # character MUST be
     134        escaped as this is a reserved character for Kendo templates.
    134135</c:set>
    135136
  • trunk/ibisph-view/src/main/webapp/WEB-INF/config/spring/SiteSpecific.xml

    r24942 r25315  
    127127                                <entry key="/indicator/index/Set.html"                  value-ref="indicatorIndicatorSetIndexController"/>
    128128                                <entry key="/indicator/index/Table.html"                value-ref="indicatorTableIndexController"/>
    129                                 <entry key="/indicator/index/Categorized.html"  value-ref="indicatorCategorizedIndexController"/>
    130129                                <entry key="/indicator/index/Demographic.html"  value-ref="indicatorDemographicIndexController"/>
    131130
  • trunk/ibisph-view/src/main/webapp/WEB-INF/config/spring/indicator.xml

    r23665 r25315  
    2626                        uses a URL.
    2727                </description>
    28                 <constructor-arg value="#{commonPublishedXMLBasePath}#{indicatorProfilePath}preview/"/>
     28                <constructor-arg value="#{commonPublishedXMLBasePath.string}#{indicatorProfilePath.string}preview/"/>
    2929        </bean>
    3030        <bean id="indicatorPreviewXMLBasePathURL" class="org.springframework.beans.factory.config.MethodInvokingFactoryBean">
     
    181181                </property>
    182182                <property name="view" ref="indicatorIndicatorSetIndexView"/>
    183         </bean>
    184 
    185         <bean id="indicatorCategorizedIndexController" parent="commonModelMapListController">
    186                 <property name="modelMapList">
    187                         <list>
    188                                 <bean class="org.ibisph.modelmap.ModelFromFilePathAndNameService"
    189                                         parent="commonXMLServiceModelMapProperties"
    190                                 >
    191                                         <property name="getModelService" ref="commonPublishedDocumentModelService"/>
    192                                         <property name="filePathAndName" value="indicator/CategorizedSelection.xml"/>
    193                                 </bean>
    194                                 <ref bean="indicatorPublishedIndicatorsModelMap"/>
    195                         </list>
    196                 </property>
    197                 <property name="view" ref="indicatorCategorizedIndexView"/>
    198183        </bean>
    199184
     
    360345                <property name="XSLTPathAndFilename" value="html/indicator/index/table/TablePage.xslt"/>
    361346        </bean>
    362         <bean id="indicatorCategorizedIndexView" parent="commonXSLTTransformationView">
    363                 <property name="XSLTPathAndFilename" value="html/indicator/index/categorized/CategorizedPage.xslt"/>
    364         </bean>
    365347
    366348        <bean id="indicatorSummaryView" parent="commonXSLTTransformationView">
  • trunk/ibisph-view/src/main/webapp/css/ContentOptions.css

    r24697 r25315  
    5959{
    6060        margin:                         0.5em auto 0.2em auto;
    61         flex-wrap:                      nowrap;
     61        flex-wrap:                      wrap;
     62/*
    6263        justify-content:        center;
     64*/
    6365}
    64 .ContentOptions .Container.Buttons button
     66.ContentOptions .Container.Buttons button,
     67.ContentOptions .Container.Buttons .Filler
    6568{
    66         flex:                           1 1 0px;
    67         max-width:                      250px;
     69        margin:                         5px;
     70    width:                              200px;
     71        max-width:                      250px;
     72        flex-basis:             200px;
     73        flex-grow:                      1;
     74        justify-content:        normal;
    6875}
    6976       
  • trunk/ibisph-view/src/main/webapp/css/DataViz.css

    r25122 r25315  
    22 * Used for charts and map sections.
    33 *~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
    4 
    5 
    6 /*
    7 GARTH TODO: NEED TO HAVE MIN-WIDTH SET FOR CONTAINER FOR DIFFERENT LAYOUT SIZES
    8 */
    9 
    10 
    114
    125/* This is needed because embed requires the width property to be set.  If done
  • trunk/ibisph-view/src/main/webapp/css/_layout.css

    r22850 r25315  
    112112
    113113
    114 /* GARTH TODO: needed for table but messes error jsp's div element */
    115114.FullWidth #content
    116115{
  • trunk/ibisph-view/src/main/webapp/js/L.Control.Choropleth.js

    r24408 r25315  
    173173
    174174                // register the choro geojson on data loaded handler so that when the
    175                 // data is avail after the ajax call and the values array is loaded that
     175                // data is avail after the async call and the values array is loaded that
    176176                // the geostats can be invoked.
    177177                choroplethLayer.on("dataloaded", this.onDataAvailable, this);
  • trunk/ibisph-view/src/main/webapp/js/L.GeoJSON.Interactive.Choropleth.js

    r24408 r25315  
    311311        } //~~~~~~~~~~~~~~~~~~~~~~~~~~~ End of Method  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    312312
    313 
    314 
    315         // Gets the geojson, stringifies it and dumps into a new window.  This is a
    316         // crude mechanism called when a user clicks the choro layer download link.
    317         /* NOT USED - FUNC INLINE in the sets control object.  Left just in case...
    318         ,showGeoJSONWindow: function()
    319         {
    320                 var newWindow = window.open("", "_blank", "GeoJSON",  "menubar=yes, toolbar=yes, scrollbars=yes, resizable=yes");
    321                 newWindow.document.write( JSON.stringify(this.toGeoJSON()) );
    322         } //~~~~~~~~~~~~~~~~~~~~~~~~~~~ End of Function ~~~~~~~~~~~~~~~~~~~~~~~~~~~
    323 */
    324 
    325313});
  • trunk/ibisph-view/src/main/webapp/js/L.GeoJSON.Interactive.js

    r24408 r25315  
    198198        // callback which supplies the data and in turn calls the call back that
    199199        // sets the layer's feature/property selection values.
    200         // Called via successful ajax load (L.Control.LayerSets.loadLayerGeoJSON). 
     200        // Called via successful async/fetch/ajax load (L.Control.LayerSets.loadLayerGeoJSON). 
    201201        ,addData: function(geojson)
    202202        {
  • trunk/ibisph-view/src/main/webapp/js/L.LayerSets.js

    r24942 r25315  
    259259
    260260
    261         // Localizes adding the ajax overlay geojson layer.  At some future point this
    262         // code could be replaced with a leaflet plugin that handles ajax - just to
    263         // remove the jquery dependency.
    264         ,loadLayerGeoJSON: function(layer)
     261        // Localizes adding the async overlay geojson layer.  Previous versions used
     262        // jquery  ajax.  Now uses standard fetch to remove the jquery dependency.
     263        ,loadLayerGeoJSON: async function(layer)
    265264        {
    266265                console.debug("L.LayerSets.loadLayerGeoJSON - Loading leaflet ID: " + layer.id + ", layer.title: " + layer.title);
    267                 if(" " < layer.url)
    268                 {
    269                         // http://api.jquery.com/jquery.ajax/
    270                         $.ajax
    271                         (
    272                                 {
    273                                         url: layer.url
    274                                         ,type: "GET"
    275                                         ,dataType: "json"
    276                                         ,geoJSONLayer: layer
    277                                         ,success: function(geoJSONData, textStatus, jqXHR)
    278                                         {
    279                                                 console.debug
    280                                                 (
    281                                                         "L.LayerSets.loadLayerGeoJSON -  AJAX load.  Will call geoJSON layer's 'addData'.  Status: " + textStatus
    282                                                         + ", Leaflet ID: " + this.geoJSONLayer._leaflet_id
    283                                                         + ", title: " + this.geoJSONLayer.title
    284                                                 );
    285                                                 this.geoJSONLayer.addData(geoJSONData);
    286                                         }
    287                                         ,error: function(jqXHR, textStatus, errorThrown)
    288                                         {
    289                                                 console.log("L.LayerSets.loadLayerGeoJSON - FAILED (" + textStatus + "): " + errorThrown + ", URL: " + layer.url + ", Leaflet ID: " + layer.id + ", GeoID: " + layer.geoID + ", title: " + layer.title);
    290                                         }
    291                                 }
     266                if(" " > layer.url) console.error("Missing layer URL - leaflet ID: " + layer.id + ", layer.title: " + layer.title);
     267
     268                try
     269                {
     270                        var response = await fetch(layer.url);
     271                        if(!response.ok) throw new Error("Bad Server Response: "+response.status + ": " + response.statusText);
     272
     273                        var geoJSON = await response.json();
     274                        layer.addData(geoJSON);
     275                }
     276                catch(error)
     277                {
     278                        console.error("Error loading geojson layer. URL: " + layer.url
     279                                + ", Leaflet ID: " + layer.id
     280                                + ", GeoID: " + layer.geoID
     281                                + ", title: " + layer.title
     282                                + ", Error: " + error
    292283                        );
    293284                }
  • trunk/ibisph-view/src/main/webapp/xslt/_ibis-user.xslt

    r23577 r25315  
    8989        >
    9090                <xsl:param name="authority" ibis:doc="AUTHORITY to be tested for."/>
    91 <!-- GARTH TODO: MenuSelectionsList.xslt line 266 XSLT error ISSUE?????
    92         changed sequence to value-of and cookie to strict and seems to have settled down
    93         but put seq back in as it shouldn't make any diff nor should strict
    94 -->
     91                <!-- NOTE: MenuSelectionsList.xslt line 266 XSLT error ISSUE?????
     92                        changed sequence to value-of and cookie to strict and seems to have settled down
     93                        but put seq back in as it shouldn't make any diff nor should strict
     94                -->
    9595                <xsl:sequence select="not(exists($authority)) or exists($ibis.userAuthorities[AUTHORITY = $authority])"/>
    9696        </xsl:function>
     
    9999
    100100<!-- ============================= End of File ============================= -->
    101 
  • trunk/ibisph-view/src/main/webapp/xslt/html/DataViz.xslt

    r24942 r25315  
    122122                <xsl:param name="valueAttributes"/>
    123123
    124 <figure class="DataViz Grid ScrollableContainer" xxxxstyle=" resize: both; overflow: auto;">
     124                <figure class="DataViz Grid ScrollableContainer">
    125125                        <xsl:if test="0 != string-length($title)"><h3><xsl:value-of select="$title"/></h3></xsl:if>
    126126                        <div id="{$containerID}"></div>
     
    131131                </figure>
    132132
    133                 <!-- GARTH TODO: needed for PDF export - needs dejavue fonts installed to work.
     133                <!-- LEFT for future ref.  This is used for PDF export.  Kendo PDFs req
     134                         dejavue fonts installed to work.
    134135                        <script type="x/kendo-template" id="page-template">
    135136                          <div class="page-template">
     
    332333                ,<xsl:call-template name="Kendo.requestGridJSON">
    333334                        <xsl:with-param name="kendoDataSourceJavascriptVariableName" select="$externalDataVizKendoDataSourceReference"/>
    334 <!-- not needed unless using KendoLeafletDataViz.getGridDataSourceViewItems
    335                         <xsl:with-param name="dataVizObjectName" select="$dataVizObjectName"/>
    336 -->
    337335                        <xsl:with-param name="measure"          select="$measure"/>
    338336                        <xsl:with-param name="measureTitle" select="$measureTitle"/>
     
    357355                </xsl:call-template>
    358356                ,<xsl:call-template name="Kendo.requestChartJSON">
    359 <xsl:with-param name="kendoDataSourceJavascriptVariableName" select="$externalDataVizKendoDataSourceReference"/>
     357                        <xsl:with-param name="kendoDataSourceJavascriptVariableName" select="$externalDataVizKendoDataSourceReference"/>
    360358                        <xsl:with-param name="title"         select="$chartTitle"/>
    361359                        <xsl:with-param name="seriesTitle"   select="$recordDimensionFields/RECORD_DIMENSION_FIELD[DIMENSION_USAGE='series']/TITLE"/>
  • trunk/ibisph-view/src/main/webapp/xslt/html/HTMLContentPage.xslt

    r24942 r25315  
    263263
    264264        <xsl:template match="ibis:baseRequestPath" mode="ibis.copy"
    265                 ibis:doc="Provides access to the base req path for things like js ajax reqs."
     265                ibis:doc="Provides access to the base req path for any path that needs
     266                        explicit/absolute request paths.  This is really not needed as the
     267                        page base path applies.
     268                "
    266269        ><xsl:value-of select="$ibis.baseRequestPath"/></xsl:template>
    267270
     
    280283                                <xsl:with-param name="description"  select="@description"/>
    281284                        </xsl:call-template>
    282 <!--
    283                         <input id="{$controlName}" type="checkbox" checked="checked"
    284                                 name="{$controlName}" class="Control"
    285                         />
    286                         <label for="{$controlName}" title="Show/hide alerts"
    287                                 class="FontIcon" font-icon="{$fontIcon} &#xe403;"
    288                         />
    289                        
    290                         id="{@containerID}"
    291 -->
     285
    292286                        <div class="Container">
    293287                                <div class="Content">
  • trunk/ibisph-view/src/main/webapp/xslt/html/Page.xslt

    r24942 r25315  
    444444        </xsl:template>
    445445
    446 
    447 
    448         <xsl:template name="Page.insertAJAXContent"
    449                 ibis:doc="
    450 GARTH TODO: This is temp code.  Needs to be verified and clean out console etc.
    451                         Provides a way to get AJAX content into a page.
    452                         1) The main use case is to get HTML_CONTENT to look like it's part of
    453                                 the IP's views.  This use case is for UT EPHT wants some
    454                                 HTML_CONTENT page to show up as a dataless *view*.  The page will
    455                                 have to be 100% crafted as HTML_CONTENT and does not provide/allow
    456                                 any IP or IPV type data field processing etc - all or nothing. 
    457 
    458                         2) Alternate IP view that looks like it's part of the IP's views.
    459                                 This tries to provide a work around for adopters that want IPs
    460                                 to contain views of different value type e.g. Rates and Counts
    461                                 to be contained within the same *IP view* set.  This works IF:
    462                                 A) The *Rates* and *Counts* IP data is duplicated,
    463                                 B) The map is turned off from the view being referenced.
    464                                 Note that this sometimes doesn't work for maps because the map
    465                                 layers are AJAX and this surrogate content is also ajax of the
    466                                 entire page body.
    467 
    468                         NOTES:
    469                                 Tried IFRAME and EMBED.  If entire page then get header, footer,
    470                                 nav etc.  If limited to the section.Sections container element
    471                                 then have issues with css and script.  Also needed script to auto
    472                                 size the height.  See 9/19/2017 commit for temp IP Interactive.xslt
    473                                 code tried.
    474 
    475                                 Can't easily include outside content.  It's easily done IF we
    476                                 don't have the security headers enabled - which then raises lots
    477                                 of flags when the site is scanned for security vulnerabilities.
    478                 "
    479         >
    480                 <xsl:param name="sourceContentRequestURL"/>
    481                 <xsl:param name="sourceContentJQuerySelector" select="'section.Sections'"/>
    482                 <xsl:param name="destContentJQuerySelector"   select="'section.Sections'"/>
    483 
    484                 <script>
    485                         $.ajax({
    486                                 url: "<xsl:value-of select="$sourceContentRequestURL"/>"
    487                                 ,type: "GET"
    488                                 ,success: function(data)
    489                                 {
    490                 console.log("<xsl:value-of select="$sourceContentJQuerySelector"/>");
    491                 console.log("<xsl:value-of select="$destContentJQuerySelector"/>");
    492                 console.log($(data).find("main section:first").html());
    493                 console.log($(data).find("<xsl:value-of select="$destContentJQuerySelector"/>").html());
    494                                         $("<xsl:value-of select="$destContentJQuerySelector"/>").html( $(data).find("<xsl:value-of select="$sourceContentJQuerySelector"/>").html() );
    495                                 }
    496                         });
    497                 </script>
    498         </xsl:template>
    499 
    500446</xsl:stylesheet>
    501447<!-- ============================= End of File ============================= -->
  • trunk/ibisph-view/src/main/webapp/xslt/html/community/Page.xslt

    r25064 r25315  
    140140
    141141
    142 <!-- GARTH TODO: Is this needed/wanted ??? -->
    143142        <xsl:template name="Page.specificCSS">
    144143                <link rel="stylesheet" type="text/css" href="css/Community.css"/>
    145144        </xsl:template>
    146145
    147 
    148 <!-- GARTH TODO: Used to have a selection map on the index pages.  This currently
    149         isn't used so either remove or implement???
    150 -->
    151         <xsl:template name="Page.specificScript"
    152                 ibis:doc="Provides the javascript selection changes and selection map."
    153         >
    154                 <script type="text/javascript" src="js/InputSelections.js"/>
    155                 <script type="text/javascript">
    156                         var dimensionName = "<xsl:value-of select="$Page.communityName"/>";
    157 
    158                         var $jqueryLeaflet;
    159 
    160                         window.inputSelections = new InputSelections();         // all input elements on the page.
    161 
    162                         $(document).ready(function()
    163                         {
    164                                 if(location.href.indexOf("PrinterFriendly") == -1)
    165                                 {
    166                                         window.inputSelections.registerOnChange();
    167                                 }
    168 
    169                                 window.selectionMapDialog =
    170                                         $("#selectionMapDialog").kendoWindow({
    171                                                 title: "<xsl:value-of select="$Page.communityDimensionTitle"/> Selection Map"
    172                                                 ,visible: false
    173                                                 ,width: "90%"
    174                                                 ,resizable: true
    175                                                 ,modal: true
    176                                         }).data("kendoWindow");
    177 
    178                                 var leafletMapConstructorJSON = $.extend
    179                                         (true, {}
    180                                                 ,<xsl:call-template name="LeafletMap.baseJSON"/>
    181                                                 ,<xsl:call-template name="LeafletMap.namedConfigurationJSON">
    182                                                         <xsl:with-param name="configurationName" select="'Selection'"/>
    183                                                 </xsl:call-template>
    184                                                 ,<xsl:call-template name="LeafletMap.requestJSON">
    185                                                         <xsl:with-param name="mapType" select="'selection'"/>
    186 <xsl:with-param name="selectionLayerSetLayerKeys" select="$Page.communityName"/>                <!-- Page.communityDimension/NAME can't simply use dim name as this needs to be a node -->
    187                                                         <xsl:with-param name="selectionLayerSetSelectionType" select="'single'"/>
    188                                                 </xsl:call-template>
    189                                         );
    190                         });
    191 
    192 
    193                         function showMap()
    194                         {
    195                                 window.selectionMapDialog.center().open();
    196                                 $jqueryLeaflet.map.invalidateSize();
    197                                 L.Control.LayerSets.prototype.htmlSelectionsToMapSelections("GeoProxy", "dimensionValue", $jqueryLeaflet.map, dimensionName);
    198                         } //~~~~~~~~~~~~~~~~~~~~ End of Function ~~~~~~~~~~~~~~~~~~~
    199 
    200 
    201                         function resetForm()
    202                         {
    203                                 document.form.reset();
    204                         } //~~~~~~~~~~~~~~~~~~~~~~~~~~~~ End of Function ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    205 
    206 
    207                         // according to: http://www.hunlock.com/blogs/Mastering_The_Back_Button_With_Javascript
    208                         // having a window.onbeforeunload tells the browser to NOT cache the
    209                         // page so that the back button doesn't impact cleared non selected
    210                         // query selection values.  On the modern browsers that were tested
    211                         // this never was an issue as modern browsers pick up the "post"
    212                         // and understand to reset the page as it was prior to submitting.
    213 //                      window.onbeforeunload = function() {}
    214 
    215                         // <![CDATA[
    216                         // ]]>
    217                 </script>
    218         </xsl:template>
    219 
    220 
    221 <!-- GARTH TODO: Not used as of 8/2020
    222 Same type of code exists in the QM SectionSelections.xslt
    223         <xsl:template name="Page.selectionMap">
    224                 <input type="button" value=" Show Selection Map " onclick="showMap();"/>
    225 
    226                 <div id="selectionMapDialog" class="DialogWindow">
    227                         <div class="Content">
    228                                 <xsl:call-template name="DataViz.mapContainer"/>
    229                         </div>
    230                         <button type="button" title="Sets the selected geographical values."
    231                                 onclick="L.Control.LayerSets.prototype.mapSelectionsToHTMLSelections($jqueryLeaflet.map, 'GeoProxy', 'dimensionValue'); window.selectionMapDialog.close()"
    232                         >OK</button>
    233                         <button type="button" title="Closes map selection without updating selections."
    234                                 onclick="window.selectionMapDialog.close()"
    235                         >Cancel</button>
    236                 </div>
    237                 <xsl:call-template name="DataViz.selectionMapJavaScript"/>
    238         </xsl:template>
    239  -->
    240146
    241147        <xsl:template name="Page.contentOptions">
     
    276182                                        <td><label for="dimensionValue"><xsl:value-of select="$Page.communityDimensionTitle"/>:</label></td>
    277183                                        <td>
    278 <!--
    279                                                 <xsl:if test="0 != string-length($Page.previousDimensionValue/TITLE)">
    280                                                         <a href="javascript:requestSamePageDifferentDimensionValue('{normalize-space($Page.previousDimensionValue/text()[1])}')"
    281                                                                 title="show previous community value"
    282                                                         >&lt;&lt; Show <xsl:value-of select="$Page.previousDimensionValue/TITLE"/></a>
    283                                                 </xsl:if>
    284 -->
    285184                                                <select name="dimensionValue" id="dimensionValue"
    286185                                                        onchange="location=this.options[this.selectedIndex].getAttribute('href');"
     
    309208                                                        </xsl:for-each>
    310209                                                </select>
    311 <!--
    312                                                 <xsl:if test="0 != string-length($Page.nextDimensionValue/TITLE)">
    313                                                         <a href="javascript:requestSamePageDifferentDimensionValue('{ibis:getValueText($Page.nextDimensionValue/text()[1])}')"
    314                                                                 title="show next community value"
    315                                                         >Show <xsl:value-of select="$Page.nextDimensionValue/TITLE"/> &gt;&gt;</a>
    316                                                 </xsl:if>
    317 -->
    318210                                        </td>
    319211                                </tr>
     
    328220                                                        onchange="location=this.options[this.selectedIndex].getAttribute('href');">
    329221                                                >
    330 <!--
    331                                                         <option value="">All</option>
    332 -->
    333222                                                        <xsl:for-each select="$Page.communityIndicatorSet">
    334223                                                                <xsl:sort select="SORT_ORDER" data-type="number" order="ascending"/>
     
    357246                                        </td>
    358247                                </tr>
    359                         </xsl:if>
    360 
    361 <!-- GARTH TODO: turned off until quick facts can be better defined
    362                         <xsl:if test="('facts' != $communityReportType) and exists($Page.communityProfile/FACTS_PAGE_FLAG)">
    363                                 <tr>
    364                                         <td><label><xsl:value-of select="$Page.communityDimensionTitle"/> Information:</label></td>
    365                                         <td>
    366                                                 <a title="Show this communities quick facts page."
    367                                                         href="{$communityBaseRequestPath}facts/{$Page.communityName}/{$Page.communityValue}.html"
    368                                                         ><xsl:value-of select="$Page.communityDimensionValue/TITLE"/>'s Quick Facts</a>
    369                                         </td>
    370                                 </tr>
    371                         </xsl:if>
    372 -->
     248                                </xsl:if>
    373249                        </table>
    374250                </div>
  • trunk/ibisph-view/src/main/webapp/xslt/html/community/facts/Page.xslt

    r23487 r25315  
    126126
    127127
    128         <xsl:template match="ibis:CencusTable" mode="ibis.copy">
     128        <xsl:template match="ibis:CensusTable" mode="ibis.copy">
    129129                https://www.census.gov/quickfacts/fact/table/daviscountyutah,US/PST045219
    130130                https://www.census.gov/quickfacts/fact/csv/daviscountyutah,US/PST045219
  • trunk/ibisph-view/src/main/webapp/xslt/html/indicator/profile/ContentBlocks.xslt

    r24942 r25315  
    1919        <ibis:doc>
    2020                <name>html/indicator/profile/ContentBlocks</name>
    21                 <summary>Provides AJAX IP and IPV data fields and interactive script blocks</summary>
     21                <summary>Provides async (AJAX) IP and IPV data fields and interactive script blocks</summary>
    2222                <description>
    2323                        Provides access to IP/IPV scripts and data fields.
  • trunk/ibisph-view/src/main/webapp/xslt/html/indicator/profile/Page.xslt

    r22957 r25315  
    214214        </xsl:template>
    215215
     216
     217        <xsl:template name="Page.insertAsyncContent"
     218                ibis:doc="
     219                        Provides a way to get async AJAX type content into a page.  Typically
     220                        the IP View's EXTERNAL_CONTENT struct.
     221
     222                        NOTES:
     223                                If implemented at the page level and HTML_CONTENT page implements
     224                                a custom tag then this could be used to insert external content.
     225                                However, most external content has it's own way to incorp into
     226                                a full control HTML_CONTENT type pages.  Examples are iframe,
     227                                embed, and js impls.  This template was placed within the main
     228                                Page.xslt but was moved here because the EXTERANL use case is
     229                                the only one that really makes sense.
     230
     231                                Tried IFRAME and EMBED.  If entire page then get header, footer,
     232                                nav etc.  If limited to the section.Sections container element
     233                                then have issues with css and script.  Also needed script to auto
     234                                size the height.  See 9/19/2017 commit for temp IP Interactive.xslt
     235                                code tried.
     236
     237                                Can't easily include outside content.  It's easily done IF we
     238                                don't have the security headers enabled - which then raises lots
     239                                of flags when the site is scanned for security vulnerabilities.
     240
     241                                See: https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API/Using_Fetch
     242                "
     243        >
     244                <xsl:param name="sourceContentRequestURL"/>
     245                <xsl:param name="sourceContentCSSSelector" select="'section.Sections'"/>
     246                <xsl:param name="destContentCSSSelector"   select="'section.Sections'"/>
     247
     248                <script>
     249                        fetch("<xsl:value-of select="$sourceContentRequestURL"/>")
     250                                .then(response =>
     251                                                {
     252                                                        if(!response.ok) throw new Error("Page.insertAsyncContent - Bad Server Response: "+response.status + ": " + response.statusText);
     253
     254                                                        var text = response.text();
     255                                                        var parser = new DOMParser();
     256                                                        var htmlDocument = parser.parseFromString(text, 'text/html');
     257                                                        const html = htmlDocument.querySelectorAll("<xsl:value-of select="$sourceContentCSSSelector"/>");
     258                                                        return(html);
     259                                                }
     260                                        )
     261                                        .then(html =>
     262                                                {
     263                                                        const destElement = document.querySelectorAll("<xsl:value-of select="$destContentCSSSelector"/>");
     264                                                        if(!destElement) throw new Error("Page.insertAsyncContent - Bad Destination Element: <xsl:value-of select="$destContentCSSSelector"/>");
     265                                                        destElement.innerHTML(html);
     266                                                }
     267                                        )
     268                                .catch(error => { console.error(error); })
     269                        ;
     270                </script>
     271        </xsl:template>
     272
     273
    216274</xsl:stylesheet>
    217275<!-- ============================= End of File ============================= -->
  • trunk/ibisph-view/src/main/webapp/xslt/html/indicator/profile/summary/Page.xslt

    r24942 r25315  
    4141                        <xsl:with-param name="pageType" select="'summary'"/>
    4242                </xsl:call-template>
    43 
    44 
    45                 <!-- DataViz: loop for all views
    46 GARTH TODO: When this is scrutinized/decided upon need to account for external
    47 viz's etc.
    48                 -->
    49 
    5043
    5144                <xsl:if test="exists($indicator/INDICATOR_VIEWS/INDICATOR_VIEW/NAME)">
     
    10093                                        </xsl:call-template>
    10194                                </xsl:if>
    102 
    10395
    10496                                <script>
  • trunk/ibisph-view/src/main/webapp/xslt/html/indicator/profile/view/Page.xslt

    r25200 r25315  
    4141                </xsl:if>
    4242
    43                 <!-- if external content of any sort e.g. complete replacement or section. -->
     43                <!-- if external content of any type e.g. complete replacement or section. -->
    4444                <xsl:if test="(0 != string-length($Indicator.indicatorView/EXTERNAL_CONTENT_URL))">
    45                         <xsl:call-template name="Page.insertAJAXContent">
    46                                 <xsl:with-param name="sourceContentRequestURL"     select="$Indicator.indicatorView/EXTERNAL_CONTENT_URL"/>
    47                                 <xsl:with-param name="sourceContentJQuerySelector" select="$Indicator.indicatorView/EXTERNAL_CONTENT_SELECTOR"/>
    48                                 <xsl:with-param name="destContentJQuerySelector"
     45                        <xsl:call-template name="Page.insertAsyncContent">
     46                                <xsl:with-param name="sourceContentRequestURL"  select="$Indicator.indicatorView/EXTERNAL_CONTENT_URL"/>
     47                                <xsl:with-param name="sourceContentCSSSelector" select="$Indicator.indicatorView/EXTERNAL_CONTENT_SELECTOR"/>
     48                                <xsl:with-param name="destContentCSSSelector"
    4949                                        select="if(0 != string-length($Indicator.indicatorView/EXTERNAL_CONTENT_DEST_SELECTOR))
    5050                                                then $Indicator.indicatorView/EXTERNAL_CONTENT_DEST_SELECTOR
  • trunk/ibisph-view/src/main/webapp/xslt/html/query/module/QueryModule.xslt

    r25010 r25315  
    4747        <xsl:param name="QueryModule.valueAttributes" select="$ValueAttributes/VALUE_ATTRIBUTES"/>
    4848
    49 <!-- GARTH TODO: At some point need to get ZW to update IBISQ to NOT return the
     49<!-- TODO: At some point need to get ZW to update IBISQ to NOT return the
    5050        VALUE sub element OR have JAVA code that handles this when it checks and
    5151        adds a PERIOD DIMENSION.
  • trunk/ibisph-view/src/main/webapp/xslt/html/query/module/result/ContentBlocks.xslt

    r23115 r25315  
    1919        <ibis:doc>
    2020                <name>html/query/module/result/ContentBlocks</name>
    21                 <summary>Provides AJAX QM data fields and interactive script blocks</summary>
     21                <summary>Provides async (ajax or fetch) QM data fields and interactive script blocks</summary>
    2222                <description>
    2323                        Provides access to QM DataViz scripts and data fields.
  • trunk/ibisph-view/src/main/webapp/xslt/html/query/module/result/DataViz.xslt

    r24432 r25315  
    1616                        the QM dataviz xslt code needed for the results page and the QM
    1717                        content blocks XSLT. 
    18 
    19                         GARTH TODO: version 3.x could simplify this with the very similar IP
    20                         code.
    2118                </description>
    2219        </ibis:doc>
     
    149146                        <xsl:with-param name="showLabelColumn"          select="exists($datasetRecords/RECORD[0 != string-length(LABEL)])"/>
    150147                        <xsl:with-param name="datasetRecordTotalValues" select="$datasetRecordTotalValues"/>
    151 <!-- never show this...
     148<!-- adopters said never show this...
    152149                        <xsl:with-param name="showNoteColumn"           select="exists($indicatorViewDatasetRecords/RECORD[0 != string-length(NOTE)])"/>
    153150                        <xsl:with-param name="baseExportFilename" select="concat(ibis:getNormalizedText($queryModule/TITLE), '-', ibis:getNormalizedText($queryConfiguration/TITLE))"/>
     
    155152                        <xsl:with-param name="baseExportFilename" select="concat($queryModule/TITLE, '-', $queryConfiguration/TITLE)"/>
    156153                </xsl:call-template>
    157 
    158 <!-- Other script that is needed on the page for things to work:
    159 
    160         Have to init the object.  Do this onload to be safe.
    161         $(document).ready(function()
    162         {
    163                 <xsl:value-of select="$dataVizObjectName"/>.init();
    164         });
    165 
    166         -OR- for AJAX content block requests:
    167         <xsl:value-of select="$DataVizJavascriptName"/>.init();
    168 
    169 
    170         Resize that is specific to this chart:
    171         <xsl:if test="$showChart">
    172         $(window).resize(function () {
    173                 <xsl:value-of select="$dataVizObjectName"/>.resizeKendoChart();
    174         });
    175         </xsl:if>
    176 
    177         -OR- This jquery version will cover ALL charts:
    178         $(window).resize( function() {
    179                 $(".k-chart").each( function(i,v)
    180                 {
    181                         var kendoChart = $(this).data("kendoChart");
    182                         if(kendoChart) kendoChart.resize();
    183                 })
    184         });
    185 -->
    186154        </xsl:template>
    187155
     
    218186                                SORT_ORDER or use position(). 
    219187                               
    220                                 GARTH TODO: Future coding to use the USAGE VALUES/VALUE/SORT_ORDER:
     188                                TODO: Future coding to use the USAGE VALUES/VALUE/SORT_ORDER:
    221189                                NOTE 2: Not sure SORT_ORDER is even being picked up at this
    222190                                point.  The Interactive.xslt RECORD_DIMENSION_FIELD doesn't
  • trunk/ibisph-view/src/main/webapp/xslt/html/query/module/result/Page.xslt

    r24014 r25315  
    267267                                        </xsl:if>
    268268                                </xsl:if>
     269
     270                                <span class="Filler"/>
    269271                        </div>
    270272                </div>
  • trunk/ibisph-view/src/main/webapp/xslt/html/topic/HTMLContentPage.xslt

    r24245 r25315  
    2121                        So left in the XML files for now for maximum flexibility.
    2222
    23 GARTH TODO: If lois wants all pages to scroll then implement XSLT version...
     23                        TODO: If lois/adopters want all pages to scroll then implement XSLT version...
    2424                        This is currently done via each XML file including:
    2525                        HTML_CLASS]Topic[/HTML_CLASS]
     
    108108
    109109
    110         <xsl:template match="(ibis:AjaxContent | ibis:CencusTable)[1]" mode="ibis.copy">
    111                 put in the ajax js
     110        <xsl:template match="(ibis:AjaxContent | ibis:CensusTable)[1]" mode="ibis.copy">
     111                Stubbed out template where could a cencus table etc.
    112112        </xsl:template>
     113
    113114
    114115        <xsl:template match="(ibis:IndicatorChart | ibis:IndicatorMap | ibis:QueryModuleXYZ)[1]" mode="ibis.copy">
     
    118119
    119120
    120         <xsl:template match="ibis:CencusTable" mode="ibis.copy">
     121        <xsl:template match="ibis:CensusTable" mode="ibis.copy">
    121122                https://www.census.gov/quickfacts/fact/table/daviscountyutah,US/PST045219
    122123                https://www.census.gov/quickfacts/fact/csv/daviscountyutah,US/PST045219
  • trunk/ibisph-view/src/main/webapp/xslt/json/Dataset.xslt

    r24432 r25315  
    8181
    8282
    83 <!-- GARTH TODO: COMPARISON VALUES HARD CODED USE ComparisonValues.xslt ???????? -->
     83<!-- TODO: COMPARISON COLORS HARD CODED - should impl in ComparisonValues.xslt ???????? -->
    8484<xsl:if test="('0' = $recordDimensionFields/RECORD_DIMENSION_FIELD[DIMENSION_USAGE='series']/DIMENSION_VALUES_COUNT) and exists($datasetRecord/DIMENSIONS/DIMENSION[NAME = 'State' and VALUE = 'NM'])">
    8585,"valueColor":"<xsl:value-of select="'#51C6D2'"/>"
  • trunk/ibisph-view/src/main/webapp/xslt/json/Kendo.xslt

    r25164 r25315  
    110110                        access to the full object graph of the database object you are referencing. It ends up this is the way you want
    111111                        to do most all of MVC so you can use DataAnnotations and put your heavy lifting in the models. I hope I have
    112                         helped, Kendo has some quirks but I have been very happy with it on some really large high profile projects             
     112                        helped, Kendo has some quirks but I have been very happy with it on some really large high profile projects.
     113
     114                        See prior 5/2022 commits for notes on formatting values and leaflet
     115                        intigation.
    113116                "
    114117        >
     
    164167<xsl:text>{</xsl:text>
    165168        "data":  <xsl:value-of select="$datasetRecordsJSONJavascriptVariableName"/>
    166 
    167 <!-- GARTH TODO:
    168         GeoStats = execute first thing on load before creating chart or map.
    169         sets the datasource's PEER GROUP field
    170         uses the determinent values to set each PEER GROUP's TITLE e.g. legend value
    171        
    172         Need to have the map's classes used if map is specified because they likely
    173         could have different groupings per map.  NM only has HLS, (2) static Ranks
    174        
    175         EPHT only has HLS and jenks
    176        
    177                 ,"PERCENTAGE-WORKS": ",##0.0'%'"
    178                 ,"Garth": "$###,##0"
    179 -->
    180169        ,"formatPattern":
    181170        {
     
    185174                </xsl:for-each>
    186175        }
    187 <!-- probably should do this as a prototype on the data source option?
    188  
    189         ,"getFormattedNumber": function(number, patternName)
    190         {
    191                 var name    = patternName ? patternName : "measure";
    192                 var pattern = this.options.formatPattern[name];
    193                 if(pattern) return(this.toString(number, pattern);
    194 console.error('~~~~~~~~~kendo .getFormattedValue no pattern match.  number: " +number+ ", patternName: " +patternName+ ", lookup name: " +name);
    195                 return(number);
    196         }
    197 -->
    198 
    199176        ,"schema":
    200177        {
     
    432409
    433410<!--
    434         CONFIG that should be put in a kendo grid type json file.
     411        CONFIG that should be put in a kendo grid type json file. 
     412        Typically _BaseGrid.json etc.  See HI or NM json file  for impls.
    435413        IMPORTANT NOTES: The grid and column resizing is influenced by the
    436414        column widths that are set via kendo parameters, the config settings
     
    549527                var gridContainerWidth = parseInt(window.getComputedStyle(this.element[0]).width, 10);
    550528                var tableWidth         = parseInt(window.getComputedStyle(this.element[0].querySelector("table")).width, 10);
    551 console.log("gridContainerWidth: ", gridContainerWidth, ", tableWidth: ", tableWidth, "totalColumnsWidth: ", totalColumnsWidth);
    552529
    553530                // If the table width is wider than the container width and if the expand
     
    619596
    620597                <!--
    621                         Did have code to dynamically craft - too complex and error prone.
    622                         PLUS XSLT format pattern is not 100% with the kendo pattern...
    623                         Template must be used because axis ticks are dynamically, chart
    624                         script generated. 
     598                        Template must be used to format because axis tick mark values are
     599                        dynamically generated by the kendo chart script and a template is
     600                        what is used to format said values. 
     601
     602                        Prior versions had code to try and craft the template - too complex
     603                        and error prone.  Neither JAVA or XSLT format patterns are 100% with
     604                        the kendo pattern.  Nor are the generic international JS patterns. 
     605                        Also, by default the db JAVA format pattern field was renamed to
     606                        JAVASCRIPT which means that the JS format pattern in the DB and
     607                        then put into the published XML.  As such those javascript field
     608                        patterns will not be right and that's why not used below - because
     609                        it was causing adopters issues and they didn't have time to update.
     610
     611                        NOTE: # MUST be escaped because it is part of the template expression.
    625612                -->
    626 
    627613                <xsl:param name="valueAxisTemplate">
    628614                        <xsl:choose>
    629 <!--
    630         NOTE: no # is acceptable unless escaped because it is part of the template expression.
    631         <JAVASCRIPT_FORMAT_PATTERN>,0.0\"%\"</JAVASCRIPT_FORMAT_PATTERN>
    632         <JAVASCRIPT_FORMAT_PATTERN>,0.0\\'%\\'</JAVASCRIPT_FORMAT_PATTERN>
    633         <JAVASCRIPT_FORMAT_PATTERN>,0.0\\&apos;%\\&apos;</JAVASCRIPT_FORMAT_PATTERN>
    634 
    635         CODE: IF want to use the XSLT format pattern - note removal of #.
    636                                                                                                                    #=kendo.toString(value, "<xsl:sequence select="translate(replace($measureValueType/JAVASCRIPT_FORMAT_PATTERN, '#', ''), '''', '\&quot;')")#
    637         <xsl:when test="$measureValueType/XSLT_FORMAT_PATTERN">#=kendo.toString(value, '<xsl:sequence select="translate(replace($measureValueType/JAVASCRIPT_FORMAT_PATTERN, '#', ''), '''', '\&quot;\')"/>')#</xsl:when>
    638         <xsl:when test="$measureValueType/XSLT_FORMAT_PATTERN">#=kendo.toString(value, '<xsl:sequence select="translate(replace($measureValueType/JAVASCRIPT_FORMAT_PATTERN, '#', ''), '''', '\&quot;\')"/>')#</xsl:when>
    639         <xsl:when test="$measureValueType/JAVASCRIPT_FORMAT_PATTERN">#=kendo.toString(value, '<xsl:sequence select="$measureValueType/JAVASCRIPT_FORMAT_PATTERN"/>')#</xsl:when>
    640 -->
    641                                 <xsl:when test="$measureValueType/JAVASCRIPT_FORMAT_PATTERN">#=kendo.toString(value, '<xsl:sequence select="$measureValueType/JAVASCRIPT_FORMAT_PATTERN"/>')#</xsl:when>
    642615                                <xsl:when test="contains($valueTitle, 'Percent')">#=kendo.toString(value, '0.0')#%</xsl:when>
    643616                                <xsl:when test="contains($valueTitle, 'Number') or contains($valueTitle, 'Count')">#=kendo.toString(value, ',0')#</xsl:when>
     
    645618                        </xsl:choose>
    646619                </xsl:param>
    647 <!--
    648 <xsl:message select="'VAT: ', $valueAxisTemplate"/>
    649 <xsl:message select="'MVT: ', $measureValueType"/>
    650 <xsl:message select="'VT: ', $ValueTypes"/>
    651 -->
    652620
    653621<xsl:text>{</xsl:text>
     
    657625                "text": "<xsl:value-of select="$title"/>"
    658626        }<xsl:text/>
    659         <!-- Kendo seems to handle automatically e.g. pie shows it multi series charts
    660         show it and single series charts do not.
    661         ,legend: { visible: <xsl:value-of select="$includeDatasetSeries"/> }
    662         -->
    663 
    664627        <!-- Use series.categoryField instead of categoryAxis.field. This merges
    665628                categories from all series data.  Also, should NOT use field: "YearAllTitle
     
    679642                        "categoryField": "<xsl:value-of select="$categoryFieldName"/>Title"<xsl:text/>
    680643                        ,"colorField": "valueColor"
    681 //,"noteTextField": "Label"
    682644                        <!-- group by sort order but title via series name - kendo ticket 946525 -->
    683645                <xsl:if test="$includeDatasetSeries">
     
    707669                        ,"labels":
    708670                        {
    709                                 <!--
    710 GARTH TODO: CHECK INTO THESE FORMAT PATTERNS???  Maybe we have a js format pattern instead of
    711 JAVA_FP.  Ticket keeps it generic so could be used with js international FP or kendo's.
    712                                 //format: "XXX {0:n00}" //Custom Formatter like '00##' "<xsl:value-of select="$valueTitle"/>"
    713                                 // template: kendo.template("Year: #: value #") //Custom Formatter like '00##' "<xsl:value-of select="$valueTitle"/>"
    714                                 //template: "Garth: #=value# End"
    715                                 //,format: "p"
    716                                 //template: "GGG {kendo.toString(value, '#')}"
    717                                 // works: template: '#= kendo.toString(value, "n0") #'
    718                                 // # doesn't appear to work.
    719                                 // works: template: '#= kendo.toString(value, ",0.0")#%'
    720                                 // doesn't error but doesn't do anything either: format: 'C'
    721                                 // <XSLT_FORMAT_PATTERN>#0.00</XSLT_FORMAT_PATTERN>
    722                                 // this works but again any "#" breaks it.    template: '${kendo.toString(value,",0")}'
    723                                 // % inside mults by 100 and adds the %:      template: '${kendo.toString(value,",0%")}'
    724                                 http://docs.telerik.com/kendo-ui/framework/globalization/numberformatting       
    725                                         Kendo docs say that # works but it blows things up no matter
    726                                         how quoted.  The format config doesn't do anything.
    727                                 -->
    728671                                "template": "<xsl:value-of select="$valueAxisTemplate"/>"
    729672                        }
     
    745688        ,"chartArea": {"width": <xsl:value-of select="$width"/>}
    746689        </xsl:if>
    747 <!--
    748         ,"jpg":
    749         {
    750                 "fileName": "<xsl:value-of select="$baseExportFilename"/>.jpg"
    751         }
    752 config settings for the saveAsPDF call.  DNA for saveAs callback...
    753         ,"pdf":
    754         {
    755                 "fileName": "<xsl:value-of select="$baseExportFilename"/>.pdf"
    756                 ,"proxyURL": "https://demos.telerik.com/kendo-ui/service/export"
    757                 ,"paperSize": "auto"
    758                 ,"margin": { left: "1cm", top: "1cm", right: "1cm", bottom: "1cm" }
    759         }
    760 -->
    761690<xsl:text>}</xsl:text>
    762691        </xsl:template>
  • trunk/ibisph-view/src/main/webapp/xslt/json/LeafletMap.xslt

    r24448 r25315  
    3737        <xsl:param name="LeafletMap.baseJSONFilename" select="'_Base.json'"/>
    3838
    39         <xsl:param name="LeafletMap.ajaxGeoJSONMapLayersFilePath" select="'contentfile/json/geo/'"
    40                 ibis:doc="Path injected into the ajax call to get map layer geojson files."
     39        <xsl:param name="LeafletMap.geoJSONBaseRequestPath" select="'contentfile/json/geo/'"
     40                ibis:doc="Request base path that can is passed into the async get geo json
     41                        layer call.
     42
     43                        IMPORTANT NOTE: MUST use a 'contentfile' http request or other http
     44                        request from some server for ajax/fetch to work.  If not a server
     45                        request the call will fail (i.e. file:// type urls do not work).
     46                "
    4147        />
    4248        <xsl:param name="LeafletMap.geoJSONIDPropertyName" select="'GeoID'"
     
    128134
    129135                <xsl:param name="legendTitle"     select="'Count'" ibis:doc="Legend's value title - typically the measure title"/>
    130 
    131 <!-- GARTH TODO: maybe pass in a measureValueFormatter object
    132 measureValueFormatter.toString(number);
    133 Then could simply inject a function that uses the kendo.toString or kendo.number etc.???
    134 
    135 the format is only needed
    136 -->
    137136
    138137{       // Start of Choropleth JSON
     
    168167                                        {
    169168                                                "title": "<xsl:value-of select="ibis:getDimensionTitle($geoDimension)"/>"               <!-- layer title layer title - County, Region -->
    170                                                 ,"url": "<xsl:value-of select="concat($LeafletMap.ajaxGeoJSONMapLayersFilePath, $geoDimensionName, '.json')"/>"
     169                                                ,"url": "<xsl:value-of select="concat($LeafletMap.geoJSONBaseRequestPath, $geoDimensionName, '.json')"/>"
    171170                                                ,"show": true
    172171                                                ,"options":
     
    221220</xsl:stylesheet>
    222221<!-- ============================= End of File ============================= -->
    223 
  • trunk/ibisph/ant/build.properties

    r11347 r25315  
    11# Basic properties for the IBIS-PH Builds.
    2 app.version =3.0.0
     2app.version =3.1.0
    33
    44# used to control jvm version
  • trunk/ibisph/ant/build.xml

    r18447 r25315  
    2121        <!-- Default global file directories for this script -->
    2222        <property name="app.name"         value="ibisph"/>
    23         <property name="app.version"      value="3.0.0"/>       <!-- build.properties -->
     23        <property name="app.version"      value="3.1.0"/>       <!-- build.properties -->
    2424        <property name="jar.name"         value="${app.name}-${app.version}.jar"/>
    2525
  • trunk/ibisph/src/main/java/org/ibisph/indicatorprofile/service/IndicatorDataBeanToXML.java

    r25199 r25315  
    9797    XMLLib.addNode(document, getRelationsNode(indicator));
    9898    XMLLib.addNode(document, getIndicatorViewsNode(indicator));
    99 /* Table removed from the db 2022. 
    100  * TODO: should completely remove at some point but leaving in for now as some
    101  * future version might come to want it.
    102  * Commented out for now to avoid the table not found sql exception.
    103     XMLLib.addNode(document, getLinksNode(indicator));
    104 */
    10599
    106100    Node initiativesNode = initiativeDataBeanToXMLService.getInitiativesNode(indicator);
  • trunk/ibisph/src/main/java/org/ibisph/model/StringHolder.java

    r4072 r25315  
    55/**
    66 * Simple property place holder so that the Spring property overrides can be
    7  * used to inject common string values.
     7 * used to inject common string values.  Can't simply extend string as java
     8 * lang String is final.
     9 *
     10 * Spring Bean Note: When referencing a StringHolder object as part of an
     11 * expression where the string holder bean object is a subset of the full string
     12 * value then the .string call is not needed because the expression handler
     13 * appears to use the object's toString when building the value (StringBuffer?). 
     14 * Otherwise .string is always needed to get the value. 
     15 * example when needed: value="#{someStringHolder.string}"
     16 * example not needed:  value="#{someStringHolder}-hello"
    817 *
    918 * @author Garth Braithwaite, STG
  • trunk/ibisph/src/main/java/org/ibisph/querymodule/service/QueryModuleRequestNameValuePairs.java

    r21972 r25315  
    183183      String name = XMLLib.getText(node, "NAME");
    184184
    185 //    TODO: Version 3.x needs to do away with _ param names/value.  This
    186 //    is a kludge and complicates both java and ui code.  Needs to be a
    187 //    configuration criteria flag to NOT show group by etc.
     185      // TODO: Version 3.x needs to do away with _ param names/value.  This
     186      // is a kludge and complicates both java and ui code.  Needs to be a
     187      // configuration criteria flag to NOT show group by etc.
    188188      if(!name.startsWith(this.controlParameterPrefix)) {
    189189        String value = this.queryModuleService.getParameterValue(node);
     
    284284    // for custom user defined/entered dynamic entries e.g. Year9.
    285285
    286 // GARTH TODO: previous versions of this code had this at the end for some reason???  There's not checking or dependence so not sure why???
    287 // This code does NOT check if the selected is the proxy and actual is associated.
    288 // it also does not reference the dim DYNAMIC_VALUE_FLAG which it should???
    289 // maybe it should only set if proxy and dynamic????
     286    // TODO: previous versions of this code had this at the end for some reason??? 
     287    // There's not checking or dependence so not sure why???  This code does NOT
     288    // check if the selected is the proxy and actual is associated.  It also
     289    // does not reference the dim DYNAMIC_VALUE_FLAG which it should???
     290    // Maybe it should only set if proxy and dynamic????
    290291    if(StrLib.isSomething(selectedCategoryGroupBy) && !selectedCategoryGroupBy.equals(actualCategoryGroupBy)) _addDelimitedNameValuePair(null, selectedCategoryGroupBy, actualCategoryGroupBy, false, null, nameValuePairs, urlCharacterEncoding);
    291292    if(StrLib.isSomething(selectedSeriesGroupBy)   && !selectedSeriesGroupBy.equals(actualSeriesGroupBy))     _addDelimitedNameValuePair(null, selectedSeriesGroupBy,   actualSeriesGroupBy,   false, null, nameValuePairs, urlCharacterEncoding);
  • trunk/ibisph/src/main/java/org/ibisph/web/HTTPRequestParametersToContainerElementService.java

    r21145 r25315  
    9898      if(StrLib.isSomething(entry.httpRequestParameterName)) {
    9999        httpParamValue = request.getParameterValues(entry.httpRequestParameterName);
    100         if(httpParamValue != null) {
     100        if(null != httpParamValue) {
    101101       
    102102          elementToAdd = XMLLib.newNode(entry.xmlElementName);
    103 //GARTH TODO: if multiple values then need to add a container and the list...
    104 if(httpParamValue.length > 1) {
    105 }
     103
     104          //TODO: if multiple values then need to add a container and the list...
     105          if(httpParamValue.length > 1) {
     106            logger.error(
     107                "Multiple HTTP param values found but are not handled.  Param Name: "
     108                + entry.httpRequestParameterName
     109                + ", number of values: " + httpParamValue.length
     110                + ", requested URL: " + request.getRequestURL()
     111              );
     112          }
    106113
    107114          String text = httpParamValue[0];
Note: See TracChangeset for help on using the changeset viewer.