123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899 |
- import request from '@/utils/request'
- // 登录
- export function login(data) {
- return request({
- url: '/api/login',
- method: 'post',
- data
- });
- }
- // 注册
- export function register(data) {
- return request({
- url: '/api/register',
- method: 'post',
- data
- });
- }
- // 验证码
- export function verify(data) {
- // type=register为注册
- // type=login为登录
- return request({
- url: '/api/register/verify',
- method: 'post',
- data
- });
- }
- // 图形验证码
- export function sms_captcha(data) {
- // type=register为注册
- // type=login为登录
- return request({
- url: '/api/sms_captcha',
- method: 'get',
- data
- });
- }
- // 获取图片验证码key
- export function verify_code(data) {
- // type=register为注册
- // type=login为登录
- return request({
- url: '/api/verify_code',
- method: 'get',
- data
- });
- }
- // 获取用户信息
- export function getUserInfo(data) {
- return request({
- url: '/api/userinfo',
- method: 'get',
- data
- });
- }
- // 短信登录
- export function loginMobile(data) {
- return request({
- url: '/api/login/mobile',
- method: 'post',
- data
- });
- }
- // #ifdef APP-PLUS
- // 微信授权登录
- export function loginWx(data) {
- return request({
- url: '/api/wechat/appauth',
- method: 'get',
- data
- });
- }
- // #endif
- //绑定手机号
- export function bangding(data) {
- return request({
- url: '/api/binding',
- method: 'POST',
- data
- });
- }
- /**
- * 获取图片上传加密key
- */
- export function getUpimgKey(data) {
- return request({
- url: '/api/upload/sign',
- method: 'POST',
- data
- });
- }
|