### 一、设置界面显示允许设置点赞的表单，获取数据接口

[图片附件未整合: ../../../_assets/865978205600563201/001-3a4b96fab0.png]

**url：/api/bs/ebuilder/form/appRun/MenuSet/getTpaObjAllowList**

**method：GET**

参数：

| 参数 | 类型 | 描述 |
| --- | --- | --- |
| apid | long | 应用id |
| appId | long | 应用id |
| menuType | String | 点赞的菜单类型取likebutton |
| pageNo | long | 当前页 |
| pageSize | long | 每页最大数量 |
| searchName | String | 搜索表单名称 |

### 二、后台点赞设置页面，获取已允许设置点赞的表单

[图片附件未整合: ../../../_assets/865978205600563201/002-97c9fc5d31.png]

**url：/api/ebuilder/form/fs/likeBtn/getObjLikeAllowList**

**method：POST**

参数：

| 参数 | 类型 | 描述 |
| --- | --- | --- |
| pageSize | long | 每页最大数量 |
| pageNo | long | 当前页 |
| appId | long | 应用id |

### 三、点赞设置详情页，获取数据

[图片附件未整合: ../../../_assets/865978205600563201/003-25b270dafe.png]

**url：/api/ebuilder/form/fs/likeBtn/getLikeTpaSetting**

**method：POST**

参数

| 参数 | 类型 | 描述 |
| --- | --- | --- |
| objId | long | 表单id |

返回参数说明：

| 参数名 | 描述 |  |
| --- | --- | --- |
| buttonList | 赞踩按钮信息 |  |
| likeTpaInfoEntity.enableLike | 是否开启点赞总开关 | 0关闭 1开启 |
| likeTpaInfoEntity.enableLikeLimit | 是否开启限制点赞 | 0关闭 1开启 |
| likeTpaInfoEntity.limitLikeNum | 限制点赞数量 |  |
| likeTpaInfoEntity.limitAnno | 提示公告 |  |

返回参数示例：

```json
{
    "code": 200,
    "msg": "200",
    "status": true,
    "data": {
        "buttonList": [
            {
                "id": "865531052467740742",
                "createTime": 1684722153000,
                "updateTime": 1684805391000,
                "creator": "5114673043180004912",
                "tenantKey": "T2K74I3RJO",
                "deleteType": 0,
                "name": "赞",
                "buttonKey": "likeBtn",
                "objId": "865531048155996160",
                "system": 1,
                "buttonType": "LIKEBTN",
                "showPosition": "{"show_form":["rightTop"],"865531052467740684_table":["LineEndDropDown"]}",
                "enable": 0,
                "showOrder": -2032,
                "iconPath": "{"path":"#icon-satisfied-o","style":{"bgColor":"#ffffff","color":"#111111"}}",
                "iconSelectedPath": "{"path":"#icon-satisfied","style":{"bgColor":"","color":"#999"}}",
                "thirdPartyFlag": 0
            },
            {
                "id": "865531052467740744",
                "createTime": 1684722153000,
                "updateTime": 1684805391000,
                "creator": "5114673043180004912",
                "tenantKey": "T2K74I3RJO",
                "deleteType": 0,
                "name": "踩",
                "buttonKey": "disLikeBtn",
                "objId": "865531048155996160",
                "system": 1,
                "buttonType": "LIKEBTN",
                "showPosition": "{"show_form":["rightTop"],"865531052467740684_table":["LineEndDropDown"]}",
                "enable": 0,
                "showOrder": -2031,
                "iconPath": "{"path":"#icon-step-on","style":{"color":"#111111","bgColor":"#ffffff"}}",
                "iconSelectedPath": "{"path":"#icon-step-on-o","style":{"color":"#999","bgColor":""}}",
                "onlyIcon": 0,
                "thirdPartyFlag": 0
            }
        ],
        "likeTpaInfoEntity": {
            "id": "865957903351201793",
            "createTime": 1684821537000,
            "updateTime": 1684825276000,
            "creator": "5114673043180004912",
            "tenantKey": "T2K74I3RJO",
            "deleteType": 0,
            "enableLike": 0,
            "enableLikeLimit": 1,
            "limitLikeNum": 0,
            "objId": "865531048155996160",
			"limitAnno":""
        }
    },
    "fail": false
}
```

### 四、修改限制点赞功能接口

**url：/api/ebuilder/form/fs/likeBtn/updateEnableLimitTpaInfo**

**method：POST**

参数

| 参数名 | 类型 | 描述 |
| --- | --- | --- |
| enableLikeLimit | int | 是否开启限制点赞 0关闭 1开启 |
| limitLikeNum | int | 设置限制点赞数量 0关闭 1开启 |
| limitAnno | String | 限制公告 |

### 五、开启或关闭点赞总开关接口

**url：/api/ebuilder/form/fs/likeBtn/enableLikeTpa**

**method：POST**

参数

| 参数名 | 类型 | 描述 |
| --- | --- | --- |
| objId | long | 表单id |
| isEnableLike | int | 是否开启点赞总开关0关闭 1开启 |

### 六、修改赞踩按钮信息接口

**url：/api/ebuilder/form/fs/button/updateOpened**

**method：POST**

参数

| 参数 | 描述 |  |
| --- | --- | --- |
| id | 按钮id |  |
| customEnable | 开启或关闭 | 0关闭 1开启 |
