From 23016487fef6d15a82b6e86a34416c7f5e94aa79 Mon Sep 17 00:00:00 2001 From: nineven Date: Thu, 4 Feb 2021 10:46:58 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- fir_client/src/components/FirLogin.vue | 6 ++++-- fir_ser/api/views/login.py | 2 ++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/fir_client/src/components/FirLogin.vue b/fir_client/src/components/FirLogin.vue index 5cec09a..2629982 100644 --- a/fir_client/src/components/FirLogin.vue +++ b/fir_client/src/components/FirLogin.vue @@ -62,7 +62,7 @@ 登录 - + 注册 @@ -92,7 +92,8 @@ activeName: 'username', allow_ways: {}, rutitle: '', - rctitle: '' + rctitle: '', + register_enable: false, } }, @@ -220,6 +221,7 @@ if (data.code === 1000) { this.cptch = data.data; this.allow_ways = data.data.login_type; + this.register_enable = data.data.register_enable; this.set_rtitle(); this.set_activename(); } else { diff --git a/fir_ser/api/views/login.py b/fir_ser/api/views/login.py index 87bed04..dceb109 100644 --- a/fir_ser/api/views/login.py +++ b/fir_ser/api/views/login.py @@ -232,6 +232,8 @@ class LoginView(APIView): if LOGIN.get("captcha"): response.data = get_captcha() response.data['login_type'] = get_login_type() + allow_f = REGISTER.get("enable") + response.data['register_enable'] = allow_f return Response(response.dict)