Compare commits

..

No commits in common. "master" and "main-zjh" have entirely different histories.

4 changed files with 144 additions and 146 deletions

5
.env
View File

@ -11,8 +11,13 @@ SHOPRO_BASE_URL = https://zysc.fjptzykj.com
# 后端接口 - 测试环境(通过 process.env.NODE_ENV = development
SHOPRO_DEV_BASE_URL = https://zysc.fjptzykj.com
<<<<<<< Updated upstream
#SHOPRO_DEV_BASE_URL = http://192.168.10.36:6127
#SHOPRO_DEV_BASE_URL = http://192.168.10.29:6127
=======
#SHOPRO_DEV_BASE_URL = http://127.0.0.1:48080
#SHOPRO_DEV_BASE_URL = http://192.168.10.5:6127
>>>>>>> Stashed changes
#SHOPRO_DEV_BASE_URL = http://192.168.1.12:6127
#SHOPRO_DEV_BASE_URL = http://192.168.10.75:6127
#SHOPRO_DEV_BASE_URL = http://192.168.1.9:6127

View File

@ -222,8 +222,7 @@
.userMessage {
color: gray;
line-height: 1.2;
max-height: 3.6em;
max-height: 80rpx;
overflow-y: hidden;
}
}

View File

@ -1,148 +1,132 @@
import request from '@/sheep/request';
const AuthUtil = {
// 使用手机 + 密码登录
login: (data) => {
return request({
url: '/member/auth/login',
method: 'POST',
data,
custom: {
showSuccess: true,
loadingMsg: '登录中',
successMsg: '登录成功',
},
});
},
// 使用手机 + 验证码登录
smsLogin: (data) => {
return request({
url: '/member/auth/sms-login',
method: 'POST',
data,
custom: {
showSuccess: true,
loadingMsg: '登录中',
successMsg: '登录成功',
},
});
},
// 发送手机验证码
sendSmsCode: (mobile, scene) => {
return request({
url: '/member/auth/send-sms-code',
method: 'POST',
data: {
mobile,
scene,
},
custom: {
loadingMsg: '发送中',
showSuccess: true,
successMsg: '发送成功',
},
});
},
// 登出系统
logout: () => {
return request({
url: '/member/auth/logout',
method: 'POST',
});
},
// 刷新令牌
refreshToken: (refreshToken) => {
return request({
url: '/member/auth/refresh-token',
method: 'POST',
params: {
refreshToken,
},
custom: {
loading: false, // 不用加载中
showError: false, // 不展示错误提示
},
});
},
// 社交授权的跳转
socialAuthRedirect: (type, redirectUri) => {
return request({
url: '/member/auth/social-auth-redirect',
method: 'GET',
params: {
type,
redirectUri,
},
custom: {
showSuccess: true,
loadingMsg: '登陆中',
},
});
},
// 社交快捷登录
socialLogin: (type, code, state) => {
return request({
url: '/member/auth/social-login',
method: 'POST',
data: {
type,
code,
state,
},
custom: {
showSuccess: true,
loadingMsg: '登陆中',
},
});
},
// 查询
checkLogin: (type, code, state) => {
return request({
url: '/member/auth/checkLogin',
method: 'POST',
data: {
type,
code,
state,
},
custom: {
showSuccess: true,
// loadingMsg: '查询中',
},
});
},
// 微信小程序的一键登录
weixinMiniAppLogin: (phoneCode, loginCode, state) => {
return request({
url: '/member/auth/weixin-mini-app-login',
method: 'POST',
data: {
phoneCode,
loginCode,
state,
},
custom: {
showSuccess: true,
loadingMsg: '登陆中',
successMsg: '登录成功',
},
});
},
// 创建微信 JS SDK 初始化所需的签名
createWeixinMpJsapiSignature: (url) => {
return request({
url: '/member/auth/create-weixin-jsapi-signature',
method: 'POST',
params: {
url,
},
custom: {
showError: false,
showLoading: false,
},
});
},
//
// 使用手机 + 密码登录
login: (data) => {
return request({
url: '/member/auth/login',
method: 'POST',
data,
custom: {
showSuccess: true,
loadingMsg: '登录中',
successMsg: '登录成功',
},
});
},
// 使用手机 + 验证码登录
smsLogin: (data) => {
return request({
url: '/member/auth/sms-login',
method: 'POST',
data,
custom: {
showSuccess: true,
loadingMsg: '登录中',
successMsg: '登录成功',
},
});
},
// 发送手机验证码
sendSmsCode: (mobile, scene) => {
return request({
url: '/member/auth/send-sms-code',
method: 'POST',
data: {
mobile,
scene,
},
custom: {
loadingMsg: '发送中',
showSuccess: true,
successMsg: '发送成功',
},
});
},
// 登出系统
logout: () => {
return request({
url: '/member/auth/logout',
method: 'POST',
});
},
// 刷新令牌
refreshToken: (refreshToken) => {
return request({
url: '/member/auth/refresh-token',
method: 'POST',
params: {
refreshToken,
},
custom: {
loading: false, // 不用加载中
showError: false, // 不展示错误提示
},
});
},
// 社交授权的跳转
socialAuthRedirect: (type, redirectUri) => {
return request({
url: '/member/auth/social-auth-redirect',
method: 'GET',
params: {
type,
redirectUri,
},
custom: {
showSuccess: true,
loadingMsg: '登陆中',
},
});
},
// 社交快捷登录
socialLogin: (type, code, state) => {
return request({
url: '/member/auth/social-login',
method: 'POST',
data: {
type,
code,
state,
},
custom: {
showSuccess: true,
loadingMsg: '登陆中',
},
});
},
// 微信小程序的一键登录
weixinMiniAppLogin: (phoneCode, loginCode, state) => {
return request({
url: '/member/auth/weixin-mini-app-login',
method: 'POST',
data: {
phoneCode,
loginCode,
state,
},
custom: {
showSuccess: true,
loadingMsg: '登陆中',
successMsg: '登录成功',
},
});
},
// 创建微信 JS SDK 初始化所需的签名
createWeixinMpJsapiSignature: (url) => {
return request({
url: '/member/auth/create-weixin-jsapi-signature',
method: 'POST',
params: {
url,
},
custom: {
showError: false,
showLoading: false,
},
});
},
//
};
export default AuthUtil;
export default AuthUtil;

View File

@ -53,11 +53,17 @@
</view> -->
<view class="newList">
<view class="new_menu" v-for="(arr, index) in menuList" :key="index">
<<<<<<< Updated upstream
<view v-for="(item, index) in arr" :key="index" class="new_items"
:style="[{ width: `${100 * (1 / data.column)}%`}]" @tap="sheep.$router.go(item.url)">
<view class="menu-box ss-flex ss-flex-col ss-col-center ss-row-center">
=======
<view v-for="(item, index) in arr" :key="index"
class="new_items"
:style="[{ width: `${100 * (1 / data.column)}%`}]">
<view class="menu-box ss-flex ss-flex-col ss-col-center ss-row-center"
@tap="sheep.$router.go(item.url)" v-if="item.title !== '平台客服' || (item.title === '平台客服' && userInfo.idKefu)">
>>>>>>> Stashed changes
<view v-if="item.badge.show" class="tag-box">
{{ item.badge.text }}
</view>
@ -211,7 +217,11 @@
//
const menuList = computed(() => splitData(props.data.list, props.data.row * props.data.column));
<<<<<<< Updated upstream
console.log('这是菜单', menuList)
=======
console.log("menulist",props.data.list);
>>>>>>> Stashed changes
const swiperHeight = computed(
() => props.data.row * (props.data.layout === 'iconText' ? 200 : 180),
);
@ -398,4 +408,4 @@
}
}
}
</style>
</style>