Showing
1 changed file
with
1 additions
and
18 deletions
| ... | @@ -26,20 +26,6 @@ | ... | @@ -26,20 +26,6 @@ |
| 26 | </div> | 26 | </div> |
| 27 | 27 | ||
| 28 | <div> | 28 | <div> |
| 29 | - <label for="email" class="block text-sm font-medium text-gray-700"> | ||
| 30 | - 邮箱 <span class="text-red-500">*</span> | ||
| 31 | - </label> | ||
| 32 | - <input | ||
| 33 | - id="email" | ||
| 34 | - v-model="formData.email" | ||
| 35 | - type="email" | ||
| 36 | - autocomplete="email" | ||
| 37 | - required | ||
| 38 | - 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" | ||
| 39 | - /> | ||
| 40 | - </div> | ||
| 41 | - | ||
| 42 | - <div> | ||
| 43 | <label for="phone" class="block text-sm font-medium text-gray-700"> | 29 | <label for="phone" class="block text-sm font-medium text-gray-700"> |
| 44 | 手机号 | 30 | 手机号 |
| 45 | </label> | 31 | </label> |
| ... | @@ -170,7 +156,6 @@ import { useAuth } from '@/contexts/auth' | ... | @@ -170,7 +156,6 @@ import { useAuth } from '@/contexts/auth' |
| 170 | import { useTitle } from '@vueuse/core'; | 156 | import { useTitle } from '@vueuse/core'; |
| 171 | 157 | ||
| 172 | const $route = useRoute(); | 158 | const $route = useRoute(); |
| 173 | -const $router = useRouter(); | ||
| 174 | useTitle($route.meta.title); | 159 | useTitle($route.meta.title); |
| 175 | 160 | ||
| 176 | const router = useRouter() | 161 | const router = useRouter() |
| ... | @@ -178,7 +163,6 @@ const { login } = useAuth() | ... | @@ -178,7 +163,6 @@ const { login } = useAuth() |
| 178 | 163 | ||
| 179 | const formData = reactive({ | 164 | const formData = reactive({ |
| 180 | name: '', | 165 | name: '', |
| 181 | - email: '', | ||
| 182 | phone: '', | 166 | phone: '', |
| 183 | password: '', | 167 | password: '', |
| 184 | confirmPassword: '', | 168 | confirmPassword: '', |
| ... | @@ -205,7 +189,7 @@ const openPrivacy = () => { | ... | @@ -205,7 +189,7 @@ const openPrivacy = () => { |
| 205 | } | 189 | } |
| 206 | 190 | ||
| 207 | const handleSubmit = async () => { | 191 | const handleSubmit = async () => { |
| 208 | - if (!formData.name || !formData.email || !formData.password) { | 192 | + if (!formData.name || !formData.password) { |
| 209 | error.value = '请填写所有必填字段' | 193 | error.value = '请填写所有必填字段' |
| 210 | return | 194 | return |
| 211 | } | 195 | } |
| ... | @@ -226,7 +210,6 @@ const handleSubmit = async () => { | ... | @@ -226,7 +210,6 @@ const handleSubmit = async () => { |
| 226 | 210 | ||
| 227 | // 使用auth.js中的login函数 | 211 | // 使用auth.js中的login函数 |
| 228 | const success = login({ | 212 | const success = login({ |
| 229 | - email: formData.email, | ||
| 230 | name: formData.name, | 213 | name: formData.name, |
| 231 | avatar: 'https://cdn.ipadbiz.cn/mlaj/images/user-avatar-3.jpg' | 214 | avatar: 'https://cdn.ipadbiz.cn/mlaj/images/user-avatar-3.jpg' |
| 232 | }) | 215 | }) | ... | ... |
-
Please register or login to post a comment