简要描述:
- 获取技师列表
请求URL:
GET/plugin.appointment.frontend.worker.get-workers-by-name
参数:
参数名 | 是否必须 | 类型 | 说明 |
---|---|---|---|
lng | 是 | float | 经度 |
lat | 是 | float | 纬度 |
city_name | 是 | int | 城市名 |
page | 否 | int | 页码 |
pagesize | 否 | int | 默认10条 |
kwd | 否 | string | 技师姓名搜索 |
返回示例:
正确时返回:
{
"result": 1,
"msg": "成功",
"data": {
"total": 6,
"per_page": 4,
"current_page": 1,
"last_page": 2,
"next_page_url": "http://127.0.0.1:88/addons/yun_shop/api.php?page=2",
"prev_page_url": null,
"from": 1,
"to": 4,
"data": [
{
"id": 10,
"uniacid": 8,
"member_u_id": 2591,
"name": "姓名3",
"thumb": "http://127.0.0.1:88/attachment/images/8/2019/12/tg0gx4ocO9cJH9IauxUo6GJ69oL99J.png",
"store_id": 15,
"score": "4.11",
"tags": [
"分类名称1-2"
],
"has_one_store": {
"id": 15,
"store_name": "门店名称2",
"longitude": "114.155593",
"latitude": "22.551731",
"distance": 115.9,
"unit": "km"
},
"worker_projects": [
{
"title": "项目名称1",
"category_id": 17,
"pivot": {
"worker_id": 10,
"project_id": 3,
"created_at": "2019-12-20 09:45:30",
"updated_at": "2019-12-20 09:45:30"
},
"has_one_category": {
"id": 17,
"name": "分类名称1-2"
}
},
{
"title": "项目名称2",
"category_id": 17,
"pivot": {
"worker_id": 10,
"project_id": 4,
"created_at": "2019-12-20 09:45:30",
"updated_at": "2019-12-20 09:45:30"
},
"has_one_category": {
"id": 17,
"name": "分类名称1-2"
}
},
{
"title": "项目名称3",
"category_id": 0,
"pivot": {
"worker_id": 10,
"project_id": 5,
"created_at": "2019-12-20 09:45:30",
"updated_at": "2019-12-20 09:45:30"
},
"has_one_category": null
}
]
}
]
}
}
错误时返回:
返回参数说明:
参数名 | 类型 | 说明 |
---|---|---|
id | int | ID |
member_u_id | int | 用户Uid |
name | string | 姓名 |
thumb | string | 缩略图 |
store_id | int | 门店ID |
score | float | 评分 |
tags | Array | 技师标签 |
has_one_store | obj | 门店信息 |
worker_projects | array | 关联项目 |
worker_projects->title | string | 关联项目名称 |
备注:
- 更多返回错误代码请看首页的错误代码描述