socialUser.js 464 B

1234567891011121314151617181920212223242526
  1. import request from "@/utils/request";
  2. // 社交绑定,使用 code 授权码
  3. export function socialBind(type, code, state) {
  4. return request({
  5. url: '/system/social-user/bind',
  6. method: 'post',
  7. data: {
  8. type,
  9. code,
  10. state,
  11. }
  12. })
  13. }
  14. // 取消社交绑定
  15. export function socialUnbind(type, openid) {
  16. return request({
  17. url: '/system/social-user/unbind',
  18. method: 'delete',
  19. data: {
  20. type,
  21. openid
  22. }
  23. })
  24. }