Closed offtherailz closed 8 years ago
This should allow to add the detail window if the feature info response have the proper format. Here an example of how ftl for geoserver should be :
<#list features as feature> <table class="featureInfo" style="margin-left: 10px;"> <caption class="featureInfo">${type.name}</caption> <tr> <th class="title">Attribute</th> <th class="title">Value</th> </tr> <#assign odd = false> <#list feature.attributes as attribute> <#if !attribute.isGeometry> <#if odd> <tr class="odd"> <#else> <tr> </#if> <#assign odd = !odd> <#if attribute.name == "codprov"> <#if attribute.value != ""> <#assign codprov = attribute.value /> <th >codprov</th><td><a id="data-ms-hook" href="javascript:void(0)" onclick="app.infoHook('topp:am_com_multipart',{CQL_FILTER: 'codprov=\'${codprov}\'',paramnames:'codcom,codprov,nome',sortAttribute:'nome'})" >${attribute.value} - DETTAGLIO</a></td> </#if> </#if> <#if attribute.name == "nome"> <#if attribute.value != ""> <#assign nome = attribute.value /> <th >nome</th><td>${attribute.value}</td> </#if> </#if> </tr> </#if> </#list> </tr> </table> <hr /> </#list> <br/>
project specific call should look like this
<#if attribute.name == "idgis"> <#assign idgis = attribute.value /> [...] app.infoHook('sde_postgis:t_dss_report',{CQL_FILTER: "id_tubo='FCON0000EB00D506'",sortAttribute:'distanza_opera_rete', paramnames:'id_tubo,denom_opera_rete,distanza_opera_rete,stato_nodo,gestore_nodo,opera_rete_fgn,stato,potenzialità_autorizzata,criticità_idraulica_1,criticità_idraulica_2,criticità_rete_fgn,criticità_potenzialità,criticità_deroga,criticità_blocco,stato_num'})
This should allow to add the detail window if the feature info response have the proper format. Here an example of how ftl for geoserver should be :
project specific call should look like this