Appendix A: Web Templates
These liquid template files can be loaded in a text editor and content copied to the relevant template source field.
Interactive Map
{% codecomponent name:maptaskr_MaptaskrPCF.MtrPCF designHeightOfMap:'80vh' featuresShowMapDownload:'yes' featuresDownloadMapFormat:'pdf' featuresShowScaleBar:'yes' featuresShowExtentControls:'yes' featuresShowLayersSearch:'yes' featuresDefaultTabOpened:'none' preSelectedLayers:'' snapSelectedLayers:'' traceSelectedLayers: ' exclusionarySelectedLayers:'' intersectionSelectedLayers:'' intersectionWarningBuffers:'' intersectionErrorBuffers:'' featuresAutoCollapseTabs:'yes' constrainBoundaries:'' uploadsShowAnnotationControl:'yes' uploadsAnnotationColor:'#b4eb34' uploadsAllowedUploadTypes:'Both' uploadsAllowedProjections:'' showFileCount:'-1' shapeNames:'Boundary' shapeStrokeColors:'' shapeFillColors:'' shapeDashedLine:'' tabsShowSearch:'yes' tabsShowBasemap:'yes' tabsShowMeasurement:'yes' tabsShowDrawUpload:'yes' tabsShowMapLayers:'yes' tabsShowLegend:'yes' tabsShowHelpGuide:'yes' loadShapes:'yes' loadRelatedShapes:'No' loadShapesCustomEndpoint:'' loadRelatedShapesCustomEndpoint:'' numberOfConcurrentIntersectionCalls:'20' %}
Maptaskr Custom Layer Search
Please refer to the appropriate template depending on your installed version of Maptaskr for Power Pages listed below.
v2.2.1.58 & earlier
{% fetchxml layer_query %}
<fetch distinct="false" mapping="logical" output-format="xml-platform" version="1.0">
<entity name="maptaskr_layers">
<attribute name="maptaskr_iscorporate"/>
<attribute name="maptaskr_layername"/>
<attribute name="maptaskr_securitygroupid"/>
<attribute name="maptaskr_layersid"/>
<attribute name="maptaskr_layerurl"/>
<attribute name="maptaskr_layertype"/>
<attribute name="maptaskr_layergroupid"/>
<attribute name="maptaskr_metadata_style"/>
<attribute name="maptaskr_hasauth"/>
<attribute name="createdon"/>
<attribute name="maptaskr_securitylayertype"/>
<attribute name="maptaskr_sharedto"/>
<attribute name="maptaskr_password"/>
<attribute name="maptaskr_securitylayervalue"/>
<attribute name="maptaskr_username"/>
<attribute name="maptaskr_name"/>
<attribute name="maptaskr_arcgisauthapplication"/>
<attribute name="maptaskr_securitylayerkey"/>
<attribute name="maptaskr_zoomtoextent"/>
<attribute name="maptaskr_isforportal"/>
<attribute name="maptaskr_arcgisauthtype"/>
<attribute name="maptaskr_isforauthenticated"/>
<attribute name="maptaskr_sortorder"/>
<attribute name="maptaskr_isforenableexport"/>
<order descending="false" attribute="maptaskr_sortorder"/>
<filter type="and">
<condition attribute="maptaskr_iscorporate" value="1" operator="eq"/>
<condition attribute="maptaskr_isforportal" value="1" operator="eq"/>
</filter>
<link-entity name="maptaskr_layergroup" alias="layerGroup" link-type="inner" to="maptaskr_group_id" from="maptaskr_layergroupid">
<attribute name="maptaskr_name" alias="layer_group_name"/>
<attribute name="maptaskr_layergroupid"/>
</link-entity>
</entity>
</fetch>
{% endfetchxml %}
{ "layers" :
[
{% for result in layer_query.results.entities %}
{
"maptaskr_iscorporate" : "{{ result.maptaskr_iscorporate }}",
"maptaskr_layername" : "{{ result.maptaskr_layername }}",
"maptaskr_securitygroupid" : "{{ result.maptaskr_securitygroupid }}",
"maptaskr_layersid" : "{{ result.maptaskr_layersid }}",
"maptaskr_layerurl" : "{{ result.maptaskr_layerurl }}",
"maptaskr_layertype" : "{{ result.maptaskr_layertype }}",
"maptaskr_layergroupid" : "{{ result.maptaskr_layergroupid }}",
"maptaskr_metadata_style" : "{{ result.maptaskr_metadata_style }}",
"maptaskr_hasauth" : "{{ result.maptaskr_hasauth }}",
"createdon" : "{{ result.createdon }}",
"maptaskr_securitylayertype" : "{{ result.maptaskr_securitylayertype }}",
"maptaskr_sharedto" : "{{ result.maptaskr_sharedto }}",
"maptaskr_password" : "{{ result.maptaskr_password }}",
"maptaskr_securitylayervalue" : "{{ result.maptaskr_securitylayervalue }}",
"maptaskr_username" : "{{ result.maptaskr_username }}",
"maptaskr_name" : "{{ result.maptaskr_name }}",
"maptaskr_arcgisauthapplication" : "{{ result.maptaskr_arcgisauthapplication }}",
"maptaskr_securitylayerkey" : "{{ result.maptaskr_securitylayerkey }}",
"maptaskr_zoomtoextent" : "{{ result.maptaskr_zoomtoextent }}",
"maptaskr_isforportal" : "{{ result.maptaskr_isforportal }}",
"maptaskr_arcgisauthtype" : "{{ result.maptaskr_arcgisauthtype }}",
"maptaskr_isforauthenticated" : "{{ result.maptaskr_isforauthenticated }}",
"maptaskr_sortorder" : "{{ result.maptaskr_sortorder }}",
"maptaskr_isforenableexport" : "{{ result.maptaskr_isforenableexport }}",
"layer_group_name" : "{{ result['layer_group_name'] }}"
}
{% unless forloop.last %},{% endunless %}
{% endfor %}
]
}
v2.2.1.59 - v2.2.1.63
{% fetchxml layer_query %}
<fetch distinct="false" mapping="logical" output-format="xml-platform" version="1.0">
<entity name="maptaskr_layers">
<attribute name="maptaskr_iscorporate"/>
<attribute name="maptaskr_layername"/>
<attribute name="maptaskr_securitygroupid"/>
<attribute name="maptaskr_layersid"/>
<attribute name="maptaskr_layerurl"/>
<attribute name="maptaskr_layertype"/>
<attribute name="maptaskr_layergroupid"/>
<attribute name="maptaskr_metadata_style"/>
<attribute name="maptaskr_hasauth"/>
<attribute name="createdon"/>
<attribute name="maptaskr_securitylayertype"/>
<attribute name="maptaskr_sharedto"/>
<attribute name="maptaskr_password"/>
<attribute name="maptaskr_securitylayervalue"/>
<attribute name="maptaskr_username"/>
<attribute name="maptaskr_name"/>
<attribute name="maptaskr_arcgisauthapplication"/>
<attribute name="maptaskr_securitylayerkey"/>
<attribute name="maptaskr_zoomtoextent"/>
<attribute name="maptaskr_isforportal"/>
<attribute name="maptaskr_statictoken"/>
<attribute name="maptaskr_arcgisauthtype"/>
<attribute name="maptaskr_isforauthenticated"/>
<attribute name="maptaskr_sortorder"/>
<attribute name="maptaskr_isforenableexport"/>
<order descending="false" attribute="maptaskr_sortorder"/>
<filter type="and">
<condition attribute="maptaskr_iscorporate" value="1" operator="eq"/>
<condition attribute="maptaskr_isforportal" value="1" operator="eq"/>
</filter>
<link-entity name="maptaskr_layergroup" alias="layerGroup" link-type="inner" to="maptaskr_group_id" from="maptaskr_layergroupid">
<attribute name="maptaskr_name" alias="layer_group_name"/>
<attribute name="maptaskr_layergroupid"/>
</link-entity>
</entity>
</fetch>
{% endfetchxml %}
{ "layers" :
[
{% for result in layer_query.results.entities %}
{
"maptaskr_iscorporate" : "{{ result.maptaskr_iscorporate }}",
"maptaskr_layername" : "{{ result.maptaskr_layername }}",
"maptaskr_securitygroupid" : "{{ result.maptaskr_securitygroupid }}",
"maptaskr_layersid" : "{{ result.maptaskr_layersid }}",
"maptaskr_layerurl" : "{{ result.maptaskr_layerurl }}",
"maptaskr_layertype" : "{{ result.maptaskr_layertype }}",
"maptaskr_layergroupid" : "{{ result.maptaskr_layergroupid }}",
"maptaskr_metadata_style" : "{{ result.maptaskr_metadata_style }}",
"maptaskr_hasauth" : "{{ result.maptaskr_hasauth }}",
"createdon" : "{{ result.createdon }}",
"maptaskr_securitylayertype" : "{{ result.maptaskr_securitylayertype }}",
"maptaskr_sharedto" : "{{ result.maptaskr_sharedto }}",
"maptaskr_password" : "{{ result.maptaskr_password }}",
"maptaskr_securitylayervalue" : "{{ result.maptaskr_securitylayervalue }}",
"maptaskr_username" : "{{ result.maptaskr_username }}",
"maptaskr_name" : "{{ result.maptaskr_name }}",
"maptaskr_arcgisauthapplication" : "{{ result.maptaskr_arcgisauthapplication }}",
"maptaskr_securitylayerkey" : "{{ result.maptaskr_securitylayerkey }}",
"maptaskr_zoomtoextent" : "{{ result.maptaskr_zoomtoextent }}",
"maptaskr_isforportal" : "{{ result.maptaskr_isforportal }}",
"maptaskr_statictoken" : "{{ result.maptaskr_statictoken }}",
"maptaskr_arcgisauthtype" : "{{ result.maptaskr_arcgisauthtype }}",
"maptaskr_isforauthenticated" : "{{ result.maptaskr_isforauthenticated }}",
"maptaskr_sortorder" : "{{ result.maptaskr_sortorder }}",
"maptaskr_isforenableexport" : "{{ result.maptaskr_isforenableexport }}",
"layer_group_name" : "{{ result['layer_group_name'] }}"
}
{% unless forloop.last %},{% endunless %}
{% endfor %}
]
}
v2.2.1.64 & later
{% fetchxml layer_query %}
<fetch distinct="false" mapping="logical" output-format="xml-platform" version="1.0">
<entity name="maptaskr_layers">
<attribute name="maptaskr_iscorporate" />
<attribute name="maptaskr_layername" />
<attribute name="maptaskr_securitygroupid" />
<attribute name="maptaskr_layersid" />
<attribute name="maptaskr_layerurl" />
<attribute name="maptaskr_layertype" />
<attribute name="maptaskr_layergroupid" />
<attribute name="maptaskr_metadata_style" />
<attribute name="maptaskr_hasauth" />
<attribute name="createdon" />
<attribute name="maptaskr_securitylayertype" />
<attribute name="maptaskr_sharedto" />
<attribute name="maptaskr_password" />
<attribute name="maptaskr_securitylayervalue" />
<attribute name="maptaskr_username" />
<attribute name="maptaskr_name" />
<attribute name="maptaskr_arcgisauthapplication" />
<attribute name="maptaskr_securitylayerkey" />
<attribute name="maptaskr_zoomtoextent" />
<attribute name="maptaskr_isforportal" />
<attribute name="maptaskr_statictoken" />
<attribute name="maptaskr_arcgisauthtype" />
<attribute name="maptaskr_isforauthenticated" />
<attribute name="maptaskr_additionalparameters" />
<attribute name="maptaskr_sortorder" />
<attribute name="maptaskr_isforenableexport" />
<order descending="false" attribute="maptaskr_sortorder" />
<filter type="and">
<condition attribute="maptaskr_iscorporate" value="1" operator="eq" />
<condition attribute="maptaskr_isforportal" value="1" operator="eq" />
</filter>
<link-entity name="maptaskr_layergroup" alias="layerGroup" link-type="inner" to="maptaskr_group_id" from="maptaskr_layergroupid">
<attribute name="maptaskr_name" alias="layer_group_name" />
<attribute name="maptaskr_layergroupid" />
</link-entity>
</entity>
</fetch>
{% endfetchxml %}
{ "layers" :
[
{% for result in layer_query.results.entities %}
{
"maptaskr_iscorporate" : "{{ result.maptaskr_iscorporate }}",
"maptaskr_layername" : "{{ result.maptaskr_layername }}",
"maptaskr_securitygroupid" : "{{ result.maptaskr_securitygroupid }}",
"maptaskr_layersid" : "{{ result.maptaskr_layersid }}",
"maptaskr_layerurl" : "{{ result.maptaskr_layerurl }}",
"maptaskr_layertype" : "{{ result.maptaskr_layertype }}",
"maptaskr_layergroupid" : "{{ result.maptaskr_layergroupid }}",
"maptaskr_metadata_style" : "{{ result.maptaskr_metadata_style }}",
"maptaskr_hasauth" : "{{ result.maptaskr_hasauth }}",
"createdon" : "{{ result.createdon }}",
"maptaskr_securitylayertype" : "{{ result.maptaskr_securitylayertype }}",
"maptaskr_sharedto" : "{{ result.maptaskr_sharedto }}",
"maptaskr_password" : "{{ result.maptaskr_password }}",
"maptaskr_securitylayervalue" : "{{ result.maptaskr_securitylayervalue }}",
"maptaskr_username" : "{{ result.maptaskr_username }}",
"maptaskr_name" : "{{ result.maptaskr_name }}",
"maptaskr_arcgisauthapplication" : "{{ result.maptaskr_arcgisauthapplication }}",
"maptaskr_securitylayerkey" : "{{ result.maptaskr_securitylayerkey }}",
"maptaskr_zoomtoextent" : "{{ result.maptaskr_zoomtoextent }}",
"maptaskr_isforportal" : "{{ result.maptaskr_isforportal }}",
"maptaskr_statictoken" : "{{ result.maptaskr_statictoken }}",
"maptaskr_arcgisauthtype" : "{{ result.maptaskr_arcgisauthtype }}",
"maptaskr_isforauthenticated" : "{{ result.maptaskr_isforauthenticated }}",
"maptaskr_additionalparameters" : "{{ result.maptaskr_additionalparameters }}",
"maptaskr_sortorder" : "{{ result.maptaskr_sortorder }}",
"maptaskr_isforenableexport" : "{{ result.maptaskr_isforenableexport }}",
"layer_group_name" : "{{ result['layer_group_name'] }}"
}
{% unless forloop.last %},{% endunless %}
{% endfor %}
]
}
Maptaskr Lambpet Search
{% assign parentid = request.params['parentid'] | xml_escape %}
{% fetchxml mtr_query %}
<fetch version="1.0" output-format="xml-platform" mapping="logical" distinct="false">
<entity name="maptaskr_lambpet">
<attribute name="maptaskr_lambpetid" />
<attribute name="maptaskr_name" />
<attribute name="createdon" />
<order attribute="maptaskr_name" descending="false" />
<filter type="and">
<condition attribute="maptaskr_parententityid" operator="eq" value="{{parentid}}" />
</filter>
</entity>
</fetch>
{% endfetchxml %}
{ "mtrshape" :
[
{% for result in mtr_query.results.entities %}
{
"mtrobjectid" : {{ result.maptaskr_lambpetid }}
}
{% unless forloop.last %},{% endunless %}
{% endfor %}
]
}
Maptaskr Shape Search
{% assign parentid = request.params['parentid'] | xml_escape %}
{% fetchxml mtr_query%}
<fetch distinct="false" mapping="logical" output-format="xml-platform" version="1.0">
<entity name="annotation">
<attribute name="subject" />
<attribute name="notetext" />
<attribute name="filename" />
<attribute name="documentbody" />
<attribute name="annotationid" />
<attribute name="objectid" />
<order descending="false" attribute="subject" />
<link-entity name="maptaskr_lambpet" alias="af" link-type="inner" to="objectid" from="maptaskr_lambpetid">
<attribute name="maptaskr_lambpetid" />
<filter type="and">
<condition attribute="maptaskr_parententityid" operator="eq" value="{{parentid}}" />
</filter>
</link-entity>
</entity>
</fetch>
{% endfetchxml %}
{ "shapes" :
[
{% for result in mtr_query.results.entities %}
{
"subject" : "{{ result.subject }}",
"notetext" : "{{ result.notetext }}",
"filename" : "{{ result.filename }}",
"documentbody" : "{{ result.documentbody }}",
"annotationid" : "{{ result.annotationid }}",
"documentname" : "{{ result["ag.dwer_name"] }}",
"documenttype" : "{{ result.subject }}",
"lambpetid" : "{{ result.['af.maptaskr_lambpetid'] }}"
}
{% unless forloop.last %},{% endunless %}
{% endfor %}
]
}
Maptaskr Layer Groups
{% fetchxml layer_query %}
<fetch distinct="false" mapping="logical" output-format="xml-platform" version="1.0">
<entity name="maptaskr_layergroup">
<attribute name="maptaskr_name" />
<attribute name="maptaskr_layergroupid" />
<attribute name="maptaskr_group_type" />
<attribute name="createdby" />
<order descending="false" attribute="maptaskr_name" />
</entity>
</fetch>
{% endfetchxml %}
{ "layergroups" :
[
{% for result in layer_query.results.entities %}
{
"maptaskr_name" : "{{ result.maptaskr_name }}",
"maptaskr_layergroupid" : "{{ result.maptaskr_layergroupid }}",
"maptaskr_group_type" : "{{ result.maptaskr_group_type }}",
"_createdby_value" : "{{ result.createdby }}"
}
{% unless forloop.last %},{% endunless %}
{% endfor %}
]
}
Maptaskr Related Shape Search
{% assign parentid = request.params['parentid'] | xml_escape %}
{% assign parent_id_filter = "<value />" %}
{% fetchxml is_account_query %}
<fetch distinct="false" mapping="logical" output-format="xml-platform" version="1.0">
<entity name="account">
<attribute name="accountid" />
<filter type="and">
<condition attribute="accountid" operator="eq" value="{{parentid}}" />
</filter>
</entity>
</fetch>
{% endfetchxml %}
{% fetchxml is_contact_query %}
<fetch distinct="false" mapping="logical" output-format="xml-platform" version="1.0">
<entity name="contact">
<attribute name="contactid" />
<filter type="and">
<condition attribute="contactid" operator="eq" value="{{parentid}}" />
</filter>
</entity>
</fetch>
{% endfetchxml %}
{% assign is_account = false %}
{% for account in is_account_query.results.entities %}
{% assign is_account = true %}
{% endfor %}
{% assign is_contact = false %}
{% for contact in is_contact_query.results.entities %}
{% assign is_contact = true %}
{% endfor %}
{% assign filtered_parent_ids = "" %}
{% if is_account %}
{% fetchxml account_query %}
<fetch distinct="false" mapping="logical" output-format="xml-platform" version="1.0">
<entity name="account">
<attribute name="accountid" />
<filter type="and">
<condition attribute="accountid" operator="neq" value="{{parentid}}" />
</filter>
</entity>
</fetch>
{% endfetchxml %}
{% capture parent_id_filter %}
{% for account in account_query.results.entities %}
<value>{{account.accountid}}</value>
{% endfor %}
{% endcapture %}
{% elsif is_contact %}
{% fetchxml contact_query %}
<fetch distinct="false" mapping="logical" output-format="xml-platform" version="1.0">
<entity name="contact">
<attribute name="contactid" />
<filter>
<condition attribute="contactid" operator="neq" value="{{parentid}}" />
</filter>
</entity>
</fetch>
{% endfetchxml %}
{% capture parent_id_filter %}
{% for contact in contact_query.results.entities %}
<value>{{contact.contactid}}</value>
{% endfor %}
{% endcapture %}
{% endif %}
{% fetchxml mtr_query %}
<fetch distinct="false" mapping="logical" output-format="xml-platform" version="1.0">
<entity name="annotation">
<attribute name="subject" />
<attribute name="notetext" />
<attribute name="filename" />
<attribute name="documentbody" />
<attribute name="annotationid" />
<attribute name="objectid" />
<order descending="false" attribute="subject" />
<link-entity name="maptaskr_lambpet" alias="af" link-type="inner" to="objectid" from="maptaskr_lambpetid">
<attribute name="maptaskr_lambpetid" />
<filter type="and">
<condition attribute="maptaskr_parententityid" operator="in">
{{parent_id_filter}}
</condition>
</filter>
</link-entity>
</entity>
</fetch>
{% endfetchxml %}
{ "shapes" :
[
{% for result in mtr_query.results.entities %}
{
"subject" : "{{ result.subject }}",
"notetext" : "{{ result.notetext }}",
"filename" : "{{ result.filename }}",
"documentbody" : "{{ result.documentbody }}",
"annotationid" : "{{ result.annotationid }}",
"documentname" : "{{ result["ag.dwer_name"] }}",
"documenttype" : "{{ result.subject }}",
"lambpetid" : "{{ result.['af.maptaskr_lambpetid'] }}",
"attributes" : [
"key" : "Name",
"Value" : "{{ result.subject }}"
]
}
{% unless forloop.last %},{% endunless %}
{% endfor %}
]
}
Maptaskr Layer Group Security Search
{% fetchxml layer_query %}
<fetch distinct="false" mapping="logical" output-format="xml-platform" version="1.0">
<entity name="cr092_layertokens">
<attribute name="cr092_name" alias="name" />
<order descending="false" attribute="cr092_name" />
</entity>
</fetch>
{% endfetchxml %}
{ "token":
[
{% for result in layer_query.results.entities %}
{
"token": "{{result.name}}"
}
{% unless forloop.last %},{% endunless %}
{% endfor %}
]
}
Maptaskr Dataverse Layer
{% assign parentid = request.params['parentid'] | xml_escape %}
{% fetchxml account_query %}
<fetch distinct="false" mapping="logical" output-format="xml-platform" version="1.0">
<entity name="account">
<attribute name="accountid" />
<attribute name="address1_longitude" />
<attribute name="address1_latitude" />
<attribute name="name" />
<attribute name="websiteurl" />
<attribute name="telephone1" />
<filter type="and">
<condition attribute="accountid" operator="neq" value="{{parentid}}" />
<condition attribute="address1_latitude" operator="not-null" />
<condition attribute="address1_longitude" operator="not-null" />
</filter>
</entity>
</fetch>
{% endfetchxml %}
{% fetchxml contact_query %}
<fetch distinct="false" mapping="logical" output-format="xml-platform" version="1.0">
<entity name="contact">
<attribute name="contactid" />
<attribute name="address1_longitude" />
<attribute name="address1_latitude" />
<attribute name="lastname" />
<attribute name="websiteurl" />
<attribute name="telephone1" />
<filter>
<condition attribute="contactid" operator="neq" value="{{parentid}}" />
<condition attribute="address1_latitude" operator="not-null" />
<condition attribute="address1_longitude" operator="not-null" />
</filter>
</entity>
</fetch>
{% endfetchxml %}
{ "layers": [
{
"LayerName": "Accounts",
"LayerStrokeColor": "#FF0000",
"LayerFillColor": "#FF0000",
"LayerFeatures": [
{% for account in account_query.results.entities %}
{
"FeatureName": "{{account.accountid}}",
"FeatureGeometry": {
"type": "Point",
"coordinates": [{{account.address1_longitude}},{{account.address1_latitude}}]
},
"FeatureAttributes": [
{"key": "Company Name", "value":"{{account.name}}"},
{"key": "Website", "value":"{{account.websiteurl}}"},
{"key": "Phone Number", "value":"{{account.telephone1}}"}
]
}
{% unless forloop.last %},{% endunless %}
{% endfor %}
]
},
{
"LayerName": "Contacts",
"LayerStrokeColor": "#0000FF",
"LayerFillColor": "#0000FF",
"LayerFeatures": [
{% for contact in contact_query.results.entities %}
{
"FeatureName": "{{contact.contactid}}",
"FeatureGeometry": {
"type": "Point",
"coordinates": [{{contact.address1_longitude}},{{contact.address1_latitude}}]
},
"FeatureAttributes": [
{"key": "Company Name", "value":"{{contact.lastname}}"},
{"key": "Website", "value":"{{contact.websiteurl}}"},
{"key": "Phone Number", "value":"{{contact.telephone1}}"}
]
}
{% unless forloop.last %},{% endunless %}
{% endfor %}
]
}
]
}