consumerm模块完成度90%,完善消费者和商家端数据库表,商品、聊天、订单数据对接好了supabase,和商家端对接了聊天功能,安卓端编译通过了css样式,剩余几个页面在处理函数规范问题
This commit is contained in:
@@ -132,10 +132,7 @@ const handleSubmit = async () => {
|
||||
.page-container {
|
||||
padding: 20px;
|
||||
background-color: #f5f5f5;
|
||||
min-height: 100vh;
|
||||
}
|
||||
|
||||
.form-group {
|
||||
flex: 1;
|
||||
background-color: #fff;
|
||||
border-radius: 8px;
|
||||
padding: 0 15px;
|
||||
|
||||
@@ -133,10 +133,7 @@ const handleSubmit = async () => {
|
||||
.page-container {
|
||||
padding: 20px;
|
||||
background-color: #f5f5f5;
|
||||
min-height: 100vh;
|
||||
}
|
||||
|
||||
.form-group {
|
||||
flex: 1;
|
||||
background-color: #fff;
|
||||
border-radius: 8px;
|
||||
padding: 0 15px;
|
||||
|
||||
@@ -139,14 +139,15 @@
|
||||
.spinner {
|
||||
width: 88rpx;
|
||||
height: 88rpx;
|
||||
border-radius: 50%; /* 如果不支持 50%,可以用 44rpx */
|
||||
border-radius: 44rpx; /* 如果不支持 50%,可以用 44rpx */
|
||||
border-width: 8rpx;
|
||||
border-style: solid;
|
||||
border-color: #f3f4f6;
|
||||
border-top-color: #ff6b6b;
|
||||
/* animation: spin 1s linear infinite; UVUE CSS动画需要特定写法或 transform */
|
||||
transform: rotate(360deg);
|
||||
transition-duration: 1000ms;
|
||||
/* transform: rotate(360deg); */
|
||||
/* transition-duration: 1000ms; */
|
||||
|
||||
/* 简单的无限旋转在原生 CSS 中可能需要写关键帧但 App-UVUE 支持有限,
|
||||
这里暂时保留样式但不指望它自动动起来,或者应该用 loading 组件 */
|
||||
}
|
||||
@@ -178,7 +179,7 @@
|
||||
padding: 24rpx;
|
||||
border-radius: 16rpx;
|
||||
font-size: 28rpx;
|
||||
font-weight: 600;
|
||||
font-weight: 700;
|
||||
}
|
||||
|
||||
.action.primary {
|
||||
@@ -192,6 +193,7 @@
|
||||
background: #ffffff;
|
||||
}
|
||||
|
||||
/*
|
||||
@keyframes spin {
|
||||
from {
|
||||
transform: rotate(0deg);
|
||||
@@ -200,4 +202,5 @@
|
||||
transform: rotate(360deg);
|
||||
}
|
||||
}
|
||||
*/
|
||||
</style>
|
||||
|
||||
@@ -87,10 +87,7 @@ const handleSubmit = async () => {
|
||||
.page-container {
|
||||
padding: 20px;
|
||||
background-color: #f5f5f5;
|
||||
min-height: 100vh;
|
||||
}
|
||||
|
||||
.form-group {
|
||||
flex: 1;
|
||||
background-color: #fff;
|
||||
border-radius: 8px;
|
||||
padding: 0 15px;
|
||||
|
||||
@@ -316,7 +316,7 @@ const handleLogin = async () => {
|
||||
errorCode === 'invalid_credentials') {
|
||||
throw new Error('邮箱或密码错误')
|
||||
} else {
|
||||
throw new Error(errorMsg || '登录失败,请重试')
|
||||
throw new Error(errorMsg != '' ? errorMsg : '登录失败,请重试')
|
||||
}
|
||||
}
|
||||
} else {
|
||||
|
||||
@@ -69,6 +69,7 @@
|
||||
<view class="protocol">
|
||||
<checkbox-group @change="handleProtocolChange">
|
||||
<checkbox
|
||||
class="protocol-checkbox"
|
||||
:checked="protocol"
|
||||
:class="{ 'trembling': inAnimation }"
|
||||
@animationend="inAnimation = false"
|
||||
@@ -241,7 +242,8 @@
|
||||
user = result
|
||||
console.log('✅ result 本身就是 user 对象:', id)
|
||||
} else {
|
||||
console.warn('⚠️ 未找到 user 信息,检查所有字段:', Object.keys(result.toMap() || {}))
|
||||
// console.warn('⚠️ 未找到 user 信息,检查所有字段:', Object.keys(result.toMap() || {}))
|
||||
console.warn('⚠️ 未找到 user 信息,检查所有字段')
|
||||
}
|
||||
}
|
||||
|
||||
@@ -263,7 +265,7 @@
|
||||
if (code === 500 && errorMsg.includes('confirmation email')) {
|
||||
throw new Error('注册失败:邮件服务配置错误,请联系管理员或修改 Supabase 配置(设置 ENABLE_EMAIL_AUTOCONFIRM=true)')
|
||||
} else {
|
||||
throw new Error(errorMsg || '注册失败,请重试')
|
||||
throw new Error(errorMsg != '' ? errorMsg : '注册失败,请重试')
|
||||
}
|
||||
}
|
||||
|
||||
@@ -355,12 +357,12 @@
|
||||
</script>
|
||||
|
||||
<style>
|
||||
page {
|
||||
/* page {
|
||||
background: #F5F5F5;
|
||||
}
|
||||
} */
|
||||
|
||||
.register-wrapper {
|
||||
min-height: 100vh;
|
||||
flex: 1;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
background: #F5F5F5;
|
||||
@@ -389,7 +391,7 @@ page {
|
||||
|
||||
.title {
|
||||
font-size: 40rpx;
|
||||
font-weight: 600;
|
||||
font-weight: 700;
|
||||
color: #333333;
|
||||
text-align: center;
|
||||
margin-bottom: 50rpx;
|
||||
@@ -466,7 +468,7 @@ page {
|
||||
border-radius: 4rpx;
|
||||
color: #FFFFFF;
|
||||
font-size: 32rpx;
|
||||
font-weight: 500;
|
||||
font-weight: 700;
|
||||
box-shadow: 0 4rpx 12rpx rgba(255, 77, 79, 0.3);
|
||||
}
|
||||
|
||||
@@ -501,7 +503,7 @@ page {
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.protocol checkbox {
|
||||
.protocol-checkbox {
|
||||
margin-right: 10rpx;
|
||||
}
|
||||
|
||||
@@ -514,6 +516,7 @@ page {
|
||||
color: var(--view-theme, #FF4D4F);
|
||||
}
|
||||
|
||||
/*
|
||||
.trembling {
|
||||
animation: shake 0.6s;
|
||||
}
|
||||
@@ -523,6 +526,7 @@ page {
|
||||
10%, 30%, 50%, 70%, 90% { transform: translateX(-10rpx); }
|
||||
20%, 40%, 60%, 80% { transform: translateX(10rpx); }
|
||||
}
|
||||
*/
|
||||
|
||||
/* 底部版权 */
|
||||
.footer {
|
||||
|
||||
@@ -46,7 +46,7 @@
|
||||
|
||||
<style>
|
||||
.page {
|
||||
min-height: 100vh;
|
||||
flex: 1;
|
||||
background: #f7f8fa;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
@@ -97,7 +97,6 @@
|
||||
font-weight: 700;
|
||||
color: #111;
|
||||
margin-bottom: 12rpx;
|
||||
display: block;
|
||||
}
|
||||
|
||||
.p {
|
||||
@@ -105,7 +104,6 @@
|
||||
color: rgba(0, 0, 0, 0.65);
|
||||
line-height: 44rpx;
|
||||
margin-bottom: 12rpx;
|
||||
display: block;
|
||||
}
|
||||
|
||||
.divider {
|
||||
@@ -125,7 +123,7 @@
|
||||
background: linear-gradient(135deg, #ff4d4f 0%, #ff7a45 100%);
|
||||
color: #fff;
|
||||
font-size: 30rpx;
|
||||
font-weight: 600;
|
||||
font-weight: 700;
|
||||
box-shadow: 0 16rpx 32rpx rgba(255, 77, 79, 0.24);
|
||||
}
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user