Class: IPortalResource

IPortalResource

SuperMap iPortal 资源详情类。

new IPortalResource(portalUrl, resourceInfo)

Usage
import { IPortalResource } from '@supermapgis/iclient-leaflet';

new IPortalResource(portalUrl, resourceInfo);
<script type="text/javascript" src="https://iclient.supermap.io/dist/leaflet/iclient-leaflet.js"></script>
<script>
  new L.supermap.iPortalResource({paramsNames});
  // 弃用的写法
  new SuperMap.iPortalResource(portalUrl, resourceInfo);
</script>
common/iPortal/iPortalResource.js, line 6
Name Type Description
portalUrl string

服务地址。

resourceInfo Object

可选参数。

Name Type Description
authorizeSetting Array 可选

资源的授权信息。

bounds string 可选

资源的坐标范围。

bounds4326 string 可选

资源的坐标范围,转换为 EPSG:4326 坐标系统后的地理范围。

checkStatus string 可选

资源的审核状态,可以是:空,SUCCESSFUL,UNCHECKED,FAILED。

createTime Date 可选

资源的创建时间。

description string 可选

资源描述。

dirId number 可选

资源所在的门户目录的 ID。

epsgCode number 可选

门户资源基于的坐标系的 EPSG 值。

heatLevel number 可选

记录资源的访问量或下载量。

id string 可选

资源存储到 ElasticSearch 中的文档 ID。

name string 可选

资源名称。

personalDirId number 可选

资源所在的个人目录的 ID。

resourceId number 可选

资源表(maps,services等)里的 ID。

resourceSubType string 可选

某类资源的具体子类型。

resourceType ResourceType 可选

资源类型。

serviceRootUrlId number 可选

批量注册服务时,服务根地址的 ID。

tags Array 可选

资源的标签。

thumbnail string 可选

资源的缩略图。

updateTime Date 可选

资源的更新时间。

userName string 可选

搜索的关键词。

sourceJSON Object 可选

提供了门户项目返回的所有信息。

Version:
  • 10.0.1

Extends

IPortalResource -> IPortalServiceBase

Methods

load(){Promise}

common/iPortal/iPortalResource.js, line 74

加载资源信息。

Returns:
Type Description
Promise 返回 Promise 对象。如果成功,Promise 没有返回值,请求返回结果自动填充到该类的属性中;如果失败,Promise 返回值包含错误信息。

inherited request(method, url, param, requestOptions){Promise}

common/iPortal/iPortalServiceBase.js, line 31

子类统一通过该方法发送请求。

Name Type Default Description
method string 'GET' 可选

请求类型。

url string

服务地址。

param Object

请求参数。

requestOptions Object 可选

fetch 请求配置项。

Returns:
Type Description
Promise 返回包含请求结果的 Promise 对象。

update(){Promise}

common/iPortal/iPortalResource.js, line 90

更新资源属性信息。

Returns:
Type Description
Promise 返回包含更新操作状态的 Promise 对象。