index.js 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  1. import https from '@/plugins/luch-request_0.0.7/request'
  2. export const setManager = data => {
  3. return https.get('/shop-admin/set-manager', data)
  4. }
  5. /** *
  6. * 员工列表
  7. */
  8. export const getStaffList = data => {
  9. return https.get('/shop-admin/list', data)
  10. }
  11. /** *
  12. * 查看员工 b
  13. */
  14. export const getStaffDet = data => {
  15. return https.get('/shop-admin/detail', data)
  16. }
  17. /** *
  18. * 添加员工 b
  19. */
  20. export const addStaff = data => {
  21. return https.post('/shop-admin/prepare-bind', data)
  22. }
  23. /** *
  24. * 修改员工 b
  25. */
  26. export const updateStaff = data => {
  27. return https.post('/shop-admin/update', data)
  28. }
  29. /** *
  30. * 删除员工 b
  31. */
  32. export const delStaff = data => {
  33. return https.get('/shop-admin/delete', data)
  34. }
  35. /** *
  36. * 员工角色--列表 b
  37. */
  38. export const getRoleList = data => {
  39. return https.get('/admin-role/list', data)
  40. }
  41. /** *
  42. * 员工角色--添加 b
  43. */
  44. export const addRole = data => {
  45. return https.post('/admin-role/add', data)
  46. }
  47. /** *
  48. * 员工角色--修改 b
  49. */
  50. export const updateRole = data => {
  51. return https.post('/admin-role/update', data)
  52. }
  53. //员工角色
  54. export const delRole = data => {
  55. return https.get('/admin-role/delete', data)
  56. }
  57. //操作记录
  58. export const getLogList = data => {
  59. return https.get('/admin-log/list', data)
  60. }
  61. //获取员工的验证码
  62. export const getStaffAuthCode = data => {
  63. return https.get('/shop-admin/get-staff-auth-code', data)
  64. }
  65. //添加员工
  66. export const createStaff = data => {
  67. return https.post('/shop-admin/add-staff', data)
  68. }