|
@@ -29,8 +29,8 @@
|
|
|
<a-form-item>
|
|
|
<JcRange
|
|
|
:status="status"
|
|
|
- :successFun="onSuccess()"
|
|
|
- :errorFun="onError()"
|
|
|
+ @successFun="onSuccess()"
|
|
|
+ @errorFun="onError()"
|
|
|
></JcRange>
|
|
|
</a-form-item>
|
|
|
|
|
@@ -38,7 +38,7 @@
|
|
|
<a-button
|
|
|
type="primary"
|
|
|
html-type="submit"
|
|
|
- :disabled="form.username === '' || form.password === ''"
|
|
|
+ :disabled="form.username === '' || form.password === ''||status==false"
|
|
|
>
|
|
|
登录
|
|
|
</a-button>
|
|
@@ -61,7 +61,6 @@ import { useRouter } from 'vue-router'
|
|
|
import { UserOutlined, LockOutlined } from '@ant-design/icons-vue'
|
|
|
|
|
|
import JcRange from './JcRange.vue'
|
|
|
-// import { ElMessage } from 'element-plus'
|
|
|
|
|
|
export default {
|
|
|
name: 'Login',
|
|
@@ -126,17 +125,8 @@ export default {
|
|
|
},
|
|
|
|
|
|
async handleSubmit() {
|
|
|
- await this.login(this.form)
|
|
|
+ await this.login(this.form)
|
|
|
await this.$router.push(this.handleRoute())
|
|
|
- // if (this.status) {
|
|
|
- // await this.login(this.form)
|
|
|
- // await this.$router.push(this.handleRoute())
|
|
|
- // } else {
|
|
|
- // ElMessage({
|
|
|
- // message: '请先滑块验证',
|
|
|
- // type: 'warning',
|
|
|
- // })
|
|
|
- // }
|
|
|
},
|
|
|
},
|
|
|
}
|