|
|
@@ -46,6 +46,23 @@
|
|
|
<v-row justify="center">
|
|
|
<v-btn color="primary" @click="submitLogin">登录/注册</v-btn>
|
|
|
</v-row>
|
|
|
+ <v-snackbar
|
|
|
+ v-model="showMessage"
|
|
|
+ :top="true"
|
|
|
+ :timeout="1000"
|
|
|
+ >
|
|
|
+ {{ message }}
|
|
|
+ <template v-slot:action="{ attrs }">
|
|
|
+ <v-btn
|
|
|
+ color="pink"
|
|
|
+ text
|
|
|
+ v-bind="attrs"
|
|
|
+ @click="showMessage = false"
|
|
|
+ >
|
|
|
+ 关闭
|
|
|
+ </v-btn>
|
|
|
+ </template>
|
|
|
+ </v-snackbar>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
@@ -67,7 +84,9 @@ export default {
|
|
|
password: null,
|
|
|
captchaCode: null,
|
|
|
r: null,
|
|
|
- plat: 'web'
|
|
|
+ plat: 'web',
|
|
|
+ showMessage: false,
|
|
|
+ message: ''
|
|
|
}
|
|
|
}
|
|
|
},
|
|
|
@@ -105,7 +124,8 @@ export default {
|
|
|
getVerifyCode(verifyCodeReq)
|
|
|
.then(res => {
|
|
|
if (res.code === 0) {
|
|
|
- alert(res.msg)
|
|
|
+ this.showMessage = true
|
|
|
+ this.message = '验证码已发送, 请注意查收'
|
|
|
} else {
|
|
|
console.error(res.msg)
|
|
|
}
|