🔥码云GVP开源项目 12k star Uniapp+ElementUI 功能强大 支持多语言、二开方便! 广告
[TOC] ## 获取员工店面列表 ~~~[api] post:/user/shoplist *int:page=1#页码 *int:limit=10#每页显示个数 string:key=id#排序字段名 string:order=normal#排序方式 <<< success <<< error ~~~ ## 编辑会员获取员工列表 ~~~[api] post:/user/getlist <<< success { "code": 0, "info": "成功", "data":[ { "id": 1, "shop_name": "淘宝店", "userList":[ {"id": 1000, "name": "老板"}, {"id": 1003, "name": "飒飒"}, {"id": 1004, "name": "胡歌"} ] }, { "id": 2, "shop_name": "京东店", "userList":[ {"id": 1001, "name": "李亮"}, {"id": 1002, "name": "王璟珩"} ] }, { "id": 3, "shop_name": "东大街店", "userList":[ {"id": 1008, "name": "梁海鹏"} ] } ] } ~~~ ## 员工二维码 ~~~[api] post:/user/qrcode <<< success <<< error ~~~ ## 员工信息 ~~~[api] post:/user/info *int:id=默认值1000#员工Id <<< success { "code": 0, "info": "成功", "data":{ "id": 1000, "name": "_ADMIN_NAME", "code": "", "token": "", "phone": "_ADMIN_PHONE", "identity": "", "entry_date": "2019-01-01", "leave_date": "2099-01-01", "shop_id": 1, "state": 1, "wechat_user_id": 1, "qrcode_url": "http://localhost/_ALIAS/api/v1/wechat/index?url=/_ALIAS/api/v1/user/bingbyqrcode/uid/1000", "shop_name": "_SHOP_NAME" } } <<< error { "code": 310, "info": "用户不存在", "data": null } { "code": 401, "info":{ "id": "id必须是数字" }, "data": null } ~~~ ## 员工列表 ~~~[api] post:/user/list *int:page=1#页码 *int:limit=10#每页显示个数 *int:shop_id=10#门店id string:key=id#排序字段名 string:order=normal#排序方式 <<< success { "code": 0, "info": "成功", "data":[ { "id": 1000, "name": "_ADMIN_NAME", "code": "", "token": "", "phone": "_ADMIN_PHONE", "identity": "", "entry_date": "2019-01-01", "leave_date": "2099-01-01", "shop_id": 1, "state": 1, "wechat_user_id": 1, "shop_name": "_SHOP_NAME" }, { "id": 1001, "name": "testrui", "code": "", "token": "", "phone": "1820", "identity": "", "entry_date": "2017-09-12", "leave_date": "2099-01-01", "shop_id": 1, "state": 1, "wechat_user_id": 0, "shop_name": "_SHOP_NAME" } ] } <<< error ~~~ ## 添加员工 ~~~[api] post:/user/add *string:name=张三#员工姓名 *string:phone=182xxxxxxxx#联系电话 *string:entry_date=2018-10-22#入职时间 *int:shop_id=1#归属门店 <<< success { "code": 0, "info": "成功", "data":{ "name": "testrui", "phone": "1820", "entry_date": "2017-09-12", "shop_id": "1", "id": "1001" } } <<< error ~~~ ## 编辑员工 ~~~[api] post:/user/edit *int:id=1000#员工Id *string:name=张三#员工姓名 *string:phone=182xxxxxxxx#联系电话 *string:entry_date=2018-10-22#入职时间 *int:shop_id=1#归属门店 *int:state=1#状态 0-离职,1-在职 <<< success { "code": 0, "info": "成功", "data":{ "id": "1001", "name": "testrui", "phone": "1820", "entry_date": "2017-09-12", "shop_id": "1", "state": "0" } } <<< error ~~~ ## 已绑定微信的员工数 ~~~[api] post:/user/bindnum <<< success { "code": 0, "info": "成功", "data":{ "allNum": 2, "bindNum": 1 } } <<< error ~~~ ## 通过手机号绑定前验证是否已绑定过 ~~~[api] post:/user/checkuser <<< success { "code": 0, "info": "成功", "data":0-未绑定,1-已绑定 } <<< error ~~~ ## 绑定手机 ~~~[api] post:/user/bingbyphone *int:phone=182xxxxxxxx#手机号 <<< success { "code": 0, "info": "成功", "data":{ "id": 1001, "wechat_user_id": 1 } } <<< error ~~~ ## 员工解除绑定微信功能 ~~~[api] post:/user/relieve *int:id=1#员工ID <<< success { "code": 0, "info": "成功", "data":{ "id": 1001, "wechat_user_id": 1 } } <<< error ~~~ ## 二维码绑定 ~~~[api] get:/user/bingbyqrcode/uid/1 <<< success { "code": 0, "info": "成功", "data":{ "id": 1001, "wechat_user_id": 1 } } <<< error ~~~ ## 一键重置权限 ~~~[api] post:/user/resetcompetence *int:id=1#0-全部,>0 user_id <<< success <<< error ~~~