Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Hooke
/
mlaj
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
hookehuyr
2025-03-26 00:53:33 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
c06740a7df2d3669dbfa1f63fff805df8e231615
c06740a7
1 parent
48d5c045
refactor(auth): 移除注册页面的邮箱字段
简化注册表单,移除不再使用的邮箱字段及其相关逻辑
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 additions
and
18 deletions
src/views/auth/RegisterPage.vue
src/views/auth/RegisterPage.vue
View file @
c06740a
...
...
@@ -26,20 +26,6 @@
</div>
<div>
<label for="email" class="block text-sm font-medium text-gray-700">
邮箱 <span class="text-red-500">*</span>
</label>
<input
id="email"
v-model="formData.email"
type="email"
autocomplete="email"
required
class="mt-1 block w-full px-3 py-2 border border-gray-300 rounded-md shadow-sm focus:outline-none focus:ring-green-500 focus:border-green-500"
/>
</div>
<div>
<label for="phone" class="block text-sm font-medium text-gray-700">
手机号
</label>
...
...
@@ -170,7 +156,6 @@ import { useAuth } from '@/contexts/auth'
import { useTitle } from '@vueuse/core';
const $route = useRoute();
const $router = useRouter();
useTitle($route.meta.title);
const router = useRouter()
...
...
@@ -178,7 +163,6 @@ const { login } = useAuth()
const formData = reactive({
name: '',
email: '',
phone: '',
password: '',
confirmPassword: '',
...
...
@@ -205,7 +189,7 @@ const openPrivacy = () => {
}
const handleSubmit = async () => {
if (!formData.name || !formData.
email || !formData.
password) {
if (!formData.name || !formData.password) {
error.value = '请填写所有必填字段'
return
}
...
...
@@ -226,7 +210,6 @@ const handleSubmit = async () => {
// 使用auth.js中的login函数
const success = login({
email: formData.email,
name: formData.name,
avatar: 'https://cdn.ipadbiz.cn/mlaj/images/user-avatar-3.jpg'
})
...
...
Please
register
or
login
to post a comment