## [获取资源占用信息](#)

**请求URL**

`/api/ebuilder/form/occupy/getOccupyResource` POST

**请求体** application/json

```json
{
	"pageId":"long //页面id",
	"compId":"string //组件id",
	"startTime":"string //开始时间（yyyy-MM-dd HH:mm:ss）",
	"endTime":"string //结束时间（yyyy-MM-dd HH:mm:ss）",
	"config":{
		"objId":"",//表单id
		"resourceField":"",//资源字段id
		"startDateTimeField":"",//开始日期字段id
		"startTimeField":"",//开始时间字段id（如有）
		"endDateTimeField":"",//结束日期字段id
		"endTimeField":""//结束时间字段id（如有）
	},//和pageId、compId择一传递即可
	"resourceIds":"string[] //资源id"
}
```

**请求示例**

```json
{
    "pageId":832603822945058827,
    "compId":"c8a2c20774f34156bd916a30abff7f1a",
    "startTime":"2023-02-22 09:00:00",
    "endTime":"2023-02-22 18:00:00",
    "resourceIds":[832497106005721088,832497032873836545,832496946976284673]
}
```

**返回结果**

```json
{
	"code":"int",
	"msg":"string",
	"status":"boolean",
	"data":[{
		"id":"string //资源id",
		"name":"string //资源名称",
		"used":"boolean //是否已占用"
	}]
}
```

**返回结果示例**

```json
{
    "code": 200,
    "msg": "接口返回成功",
    "status": true,
    "data": [
        {
            "id": "832497106005721088",
            "name": "北京包厢205",
            "used": false
        },
        {
            "id": "832497032873836545",
            "name": "北京包厢204",
            "used": true
        },
        {
            "id": "832496946976284673",
            "name": "北京包厢203",
            "used": false
        }
    ]
}
```
