|
|
@ -146,7 +146,14 @@ |
|
|
</view> |
|
|
</view> |
|
|
|
|
|
|
|
|
<!-- 注册按钮 --> |
|
|
<!-- 注册按钮 --> |
|
|
<button class="register-btn" @click="register">注册</button> |
|
|
|
|
|
|
|
|
<button class="register-btn" @click="register"> |
|
|
|
|
|
<text v-if="!isLoading">注册</text> |
|
|
|
|
|
<image |
|
|
|
|
|
v-else |
|
|
|
|
|
class="icons-rotation" |
|
|
|
|
|
src="../../../static/icons/loading.png" |
|
|
|
|
|
></image> |
|
|
|
|
|
</button> |
|
|
|
|
|
|
|
|
<!-- 或者 --> |
|
|
<!-- 或者 --> |
|
|
<text class="or-text" @click="goToLogin" |
|
|
<text class="or-text" @click="goToLogin" |
|
|
@ -204,6 +211,7 @@ const isCodeBtnDisabled = ref(false); // 添加验证码按钮禁用状态 |
|
|
const checkboxUrl = ref("../../../static/icons/Check-one-false.png"); |
|
|
const checkboxUrl = ref("../../../static/icons/Check-one-false.png"); |
|
|
const verifyCode = ref(""); |
|
|
const verifyCode = ref(""); |
|
|
const account = ref(""); |
|
|
const account = ref(""); |
|
|
|
|
|
const isLoading = ref(false); |
|
|
|
|
|
|
|
|
// 使用从list.js导入的完整国家列表数据 |
|
|
// 使用从list.js导入的完整国家列表数据 |
|
|
const countries = ref( |
|
|
const countries = ref( |
|
|
@ -261,6 +269,7 @@ async function register() { |
|
|
|
|
|
|
|
|
const account = changeAccount(); |
|
|
const account = changeAccount(); |
|
|
const registerType = changeLoginType(); |
|
|
const registerType = changeLoginType(); |
|
|
|
|
|
isLoading.value = true; |
|
|
|
|
|
|
|
|
const res = await registerApi({ |
|
|
const res = await registerApi({ |
|
|
registerType: registerType, |
|
|
registerType: registerType, |
|
|
@ -269,6 +278,8 @@ async function register() { |
|
|
agree: agreed.value, |
|
|
agree: agreed.value, |
|
|
}); |
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
isLoading.value = false; |
|
|
|
|
|
|
|
|
const message = res.message; |
|
|
const message = res.message; |
|
|
if (res.code === 200) { |
|
|
if (res.code === 200) { |
|
|
// 登录成功 |
|
|
// 登录成功 |
|
|
@ -514,7 +525,6 @@ async function sendCode() { |
|
|
}); |
|
|
}); |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 设置按钮为禁用状态 |
|
|
// 设置按钮为禁用状态 |
|
|
isCodeBtnDisabled.value = true; |
|
|
isCodeBtnDisabled.value = true; |
|
|
@ -656,6 +666,23 @@ function handleCancel() { |
|
|
/* margin-right: 10rpx; */ |
|
|
/* margin-right: 10rpx; */ |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.icons-rotation { |
|
|
|
|
|
margin: 20rpx; |
|
|
|
|
|
width: 40rpx; |
|
|
|
|
|
height: 40rpx; |
|
|
|
|
|
/* margin-right: 10rpx; */ |
|
|
|
|
|
animation: rotation 2s linear infinite; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@keyframes rotation { |
|
|
|
|
|
from { |
|
|
|
|
|
transform: rotate(0deg); |
|
|
|
|
|
} |
|
|
|
|
|
to { |
|
|
|
|
|
transform: rotate(360deg); |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
.back-btn, |
|
|
.back-btn, |
|
|
.headphone-btn { |
|
|
.headphone-btn { |
|
|
font-size: 36rpx; |
|
|
font-size: 36rpx; |
|
|
|