jinx 1 vuosi sitten
vanhempi
commit
fc176db872
1 muutettua tiedostoa jossa 5 lisäystä ja 2 poistoa
  1. 5 2
      src/components/header/Login.vue

+ 5 - 2
src/components/header/Login.vue

@@ -33,8 +33,8 @@
                         <div class="tips" v-show="errors.message">{{ errors.message }}</div>
                     </div>
                     <div class="links">
-                        <a href="http://test.4dkankan.com/#/login/forget?from=%2F">{{ $t('header.forgetPassword') }}</a>
-                        <a href="http://test.4dkankan.com/#/login/register?from=%2F">{{ $t('header.resigter') }}</a>
+                        <a @click="checkLanguage" href="http://test.4dkankan.com/#/login/forget?from=%2F">{{ $t('header.forgetPassword') }}</a>
+                        <a @click="checkLanguage" href="http://test.4dkankan.com/#/login/register?from=%2F">{{ $t('header.resigter') }}</a>
                     </div>
                 </div>
             </div>
@@ -68,6 +68,9 @@ const getAuth = () => {
         })
         .catch(() => {})
 }
+const checkLanguage = () => {
+    localStorage.setItem('language', getLocale())
+}
 const onLogin = () => {
     errors.value = {}
     if (!username.value) {