简要描述:
- 编辑群活码
请求URL:
GET/&route=plugin.group-code.admin.group-code.update
参数:
参数名 | 是否必须 | 类型 | 说明 |
---|---|---|---|
id | 是 | id | 群活码id |
group[code_name] | 是 | string | 群活码名称(20字) |
group[code_guide] | 是 | string | 群活码引导语(20字) |
group[auth_visit] | 是 | int | 访问授权,0关闭,1开启 |
group[join_type] | 是 | int | 进群方式,0默认进群,1标签进群 |
group[explain] | 是 | int | 说明,0关闭,1开启 |
group[explain_content] | 否 | string | 说明内容,说明开启时必填 |
group[customer_service] | 是 | string | 客服二维码 |
group[customer_service_guide] | 是 | string | 客服引导语 |
group[label_banner] | 否 | string | 标签页banner,标签进群时必填 |
group[label_data] | 否 | array | 标签数据:示例["标签1","标签2"],标签进群时必填 |
group[in_number] | 否 | int | 默认参与人数,标签进群时必填 |
code_data | 是 | string | 群二维码数据(json数据) |
code_data参数:
参数名 | 是否必须 | 类型 | 说明 |
---|---|---|---|
id | 否 | int | 群二维码id,当二维码是原有的二维码时必传,否则该二维码将被删除 |
code_url | 是 | string | 群二维码图片地址 |
label | 否 | string | 群标签(进群方式为标签进群时必选) |
expire | 是 | string | 过期时间 |
upper_limit | 是 | int | 扫码上限 |
status | 是 | int | 状态,0关闭,1开启 |
remark | 否 | string | 备注 |
code_data示例:
code_data = "[{"code_url":"https://shop-yunzshop-com.oss-cn-hangzhou.aliyuncs.com/images/1/2020/07/EZNSRr4L9l3lSX9S1efHw3zWNxDnlf.png","upper_limit":300,"label":"标签1","expire":"2020-08-30","remark":""},{"code_url":"https://shop-yunzshop-com.oss-cn-hangzhou.aliyuncs.com/images/1/2020/07/EZNSRr4L9l3lSX9S1efHw3zWNxDnlf.png","upper_limit":300,"label":"标签1","expire":"2020-08-30","remark":""}]"
[{
"code_url": "https://shop-yunzshop-com.oss-cn-hangzhou.aliyuncs.com/images/1/2020/07/EZNSRr4L9l3lSX9S1efHw3zWNxDnlf.png",
"upper_limit": 300,
"label": "标签1",
"expire": "2020-08-30",
"remark": "",
"status": 1
}, {
"code_url": "https://shop-yunzshop-com.oss-cn-hangzhou.aliyuncs.com/images/1/2020/07/EZNSRr4L9l3lSX9S1efHw3zWNxDnlf.png",
"upper_limit": 300,
"label": "标签1",
"expire": "2020-08-30",
"remark": "",
"status": 1
}]
返回参数data.data说明:
参数名 | 是否必须 | 类型 | 说明 |
---|---|---|---|
code_name | 是 | string | 群活码名称 |
auth_visit | 是 | array | 访问授权,0关闭,1开启 |
member_id | 是 | int | 创建者用户id,0为后台创建 |
status | 是 | int | 群活码状态,0关闭,1开启 |
recommend | 是 | int | 推荐,0关闭,1开启 |
cumulative | 是 | int | 累计扫码人数 |
cumulative_new | 是 | int | 累计新会员 |
log_today_count | 是 | int | 今日扫码人数 |
log_new_today_count | 是 | int | 今日新会员人数 |
code_total_count | 是 | int | 二维码总数 |
code_soon_expire_count | 是 | int | 二维码即将过期数量 |
code_expire_count | 是 | int | 二维码已过期总数 |
has_many_code.id | 是 | int | 群二维码id |
has_many_code.group_id | 是 | string | 群活码id |
has_many_code.label | 是 | int | 群二维码标签 |
has_many_code.group_id | 是 | string | 创建群活码用户昵称 |
has_many_code.code_url | 是 | int | 群二维码图片 |
has_many_code.expire | 是 | string | 群二维码过期时间 |
has_many_code.upper_limit | 是 | int | 群二维码扫码上限 |
has_many_code.status | 是 | int | 群二维码状态,0关闭,1开启 |
has_many_code.remark | 是 | string | 群二维码备注 |
返回示例:未传group参数组将会返回群活码数据
正确时返回:
{
"result": 1,
"msg": "保存成功",
"data": []
}
{
"result": 1,
"msg": "ok",
"data": {
"data": {
"id": 9,
"uniacid": 1,
"member_id": 0,
"code_name": "测试群活码",
"code_guide": "12312321",
"auth_visit": 0,
"join_type": 0,
"explain": 0,
"explain_content": "",
"customer_service": "http://shop-yunzshop-com.oss-cn-hangzhou.aliyuncs.com/123123123",
"customer_service_guide": "12321321321",
"label_banner": "",
"label_data": [],
"in_number": 0,
"status": 0,
"recommend": 0,
"created_at": "2020-08-07 10:45:09",
"updated_at": "2020-08-07 10:45:09",
"deleted_at": null,
"has_many_code": [
{
"id": 7,
"uniacid": 1,
"group_id": 9,
"label": "标签1",
"code_url": "https://shop-yunzshop-com.oss-cn-hangzhou.aliyuncs.com/images/1/2020/07/EZNSRr4L9l3lSX9S1efHw3zWNxDnlf.png",
"expire": "2020-08-30 00:00:00",
"upper_limit": 300,
"status": 1,
"remark": "",
"created_at": "2020-08-07 10:45:09",
"updated_at": "2020-08-07 10:45:09"
},
{
"id": 8,
"uniacid": 1,
"group_id": 9,
"label": "标签1",
"code_url": "https://shop-yunzshop-com.oss-cn-hangzhou.aliyuncs.com/images/1/2020/07/EZNSRr4L9l3lSX9S1efHw3zWNxDnlf.png",
"expire": "2020-08-30 00:00:00",
"upper_limit": 300,
"status": 1,
"remark": "",
"created_at": "2020-08-07 10:45:09",
"updated_at": "2020-08-07 10:45:09"
}
]
}
}
}
错误时返回:
{
"result": 0,
"msg": "群活码名称重复",
"data": []
}
{
"result": 0,
"msg": "群活码编辑失败",
"data": []
}