个人中心:手机 + 密码登录

This commit is contained in:
YunaiV
2023-12-28 23:14:22 +08:00
parent f0e8ff1f87
commit cbaf3a2512
4 changed files with 27 additions and 95 deletions
+13
View File
@@ -1,6 +1,19 @@
import request from '@/sheep/request';
const AuthUtil = {
// 使用手机 + 密码登录
login: (data) => {
return request({
url: '/app-api/member/auth/login',
method: 'POST',
data,
custom: {
showSuccess: true,
loadingMsg: '登录中',
successMsg: '登录成功',
},
});
},
// 使用手机 + 验证码登录
smsLogin: (data) => {
return request({
+1 -45
View File
@@ -3,38 +3,8 @@ import request2 from '@/sheep/request2';
import $platform from '@/sheep/platform';
export default {
getUnused: () =>
request2({
url: 'promotion/coupon/get-unused-count',
method: 'GET',
custom: {
showLoading: false,
auth: true,
},
}),
// 账号登录
accountLogin: (data) =>
request({
url: '/user/api/user/accountLogin',
method: 'POST',
data,
custom: {
showSuccess: true,
loadingMsg: '登录中',
},
}),
// 绑定、更换手机号
changeMobile: (data) =>
request({
url: '/user/api/user/changeMobile',
method: 'POST',
data,
custom: {
showSuccess: true,
loadingMsg: '验证中',
},
}),
// 添加分享记录
addShareLog: (data) =>
@@ -54,20 +24,6 @@ export default {
params,
}),
},
// 账号登出
logout: (data) =>
request({
url: '/user/api/user/logout',
method: 'POST',
data,
}),
// 账号注销
logoff: (data) =>
request({
url: '/user/api/user/logoff',
method: 'POST',
data,
}),
address: {
default: () =>