首页 / 浏览问题 / 云GIS / 问题详情
iserver的数据服务查询怎么使用/
6v6
6EXP 2024年05月08日

DataServiceQueryView这个组件如何使用?position设定之后该组件不显示。oneachfeature如何设定?现在点击后弹窗只显示id号,无法显示其他想显示的属性值。

options Object

参数。

Name Type Default Description
getFeatureMode Array.<GetFeatureMode> | GetFeatureMode 可选

查询方式。

position string 'topright' 可选

组件在地图中显示的位置( 'topleft'|'topright'|'bottomleft'|'bottomright' )。

style function 可选

默认图层样式。返回类型:点样式( maker|circleMaker);线和面样式( L.path )。

onEachFeature function 可选

给该元素绑定事件和弹窗。

1个回答

您好,使用方式可以参考示例:https://iclient.supermap.io/examples/leaflet/editor.html#components_dataServiceQuery

设置position能生效,只是它的位置有些问题,您可以获取这个组件的要素进行位置设置;

document.getElementsByClassName("component-container component-servicequery__container leaflet-control")[0]

oneachfeature设置不生效的问题,可以用11.2.0 Beta 版本的iClient,新版本进行了修改http://support.supermap.com.cn/DownloadCenter/DownloadPage.aspx?id=2708

501EXP 2024年05月08日
...