diff --git a/src/App.vue b/src/App.vue
index 988b560..a50e4b7 100644
--- a/src/App.vue
+++ b/src/App.vue
@@ -94,8 +94,8 @@
-
diff --git a/src/components/login/mfa/MFA.vue b/src/components/login/mfa/MFA.vue
index 3b3a3b7..0d1a374 100644
--- a/src/components/login/mfa/MFA.vue
+++ b/src/components/login/mfa/MFA.vue
@@ -17,17 +17,10 @@ export default {
computed: {
...mapGetters('mainStore', ['getAuthToken']),
isTwoFactorEnabled() {
- // const authToken = this.getAuthToken;
- const payload = localStorage.getItem('user') //this.parseJwt({ token: authToken });
+ const payload = localStorage.getItem('user')
if (payload) {
return JSON.parse(payload)
}
- // if (payload) {
- // this.setAuthenticatorType = payload.authenticatorType
- // if (payload.isTwoFactorAuthenticated) {
- // return payload.isTwoFactorAuthenticated
- // }
- // }
return {};
}
},
@@ -46,18 +39,6 @@ export default {
},
methods: {
...mapMutations('mainStore', 'setSelectedAppId'),
- parseJwt: (payload) => {
- const { token } = payload;
- if (!token) throw new Error('JWT token must be provided')
-
- var base64Url = token.split('.')[1];
- var base64 = base64Url.replace(/-/g, '+').replace(/_/g, '/');
- var jsonPayload = decodeURIComponent(window.atob(base64).split('').map(function (c) {
- return '%' + ('00' + c.charCodeAt(0).toString(16)).slice(-2);
- }).join(''));
-
- return JSON.parse(jsonPayload);
- },
}
}
diff --git a/src/components/login/mfa/SetupMfa.vue b/src/components/login/mfa/SetupMfa.vue
index f307318..a9911c9 100644
--- a/src/components/login/mfa/SetupMfa.vue
+++ b/src/components/login/mfa/SetupMfa.vue
@@ -3,65 +3,61 @@
-
Setup Authenticator as an MFA method
-
-
-
- -
-
-
+
Setup Authenticator as a MFA method
+
+
+ -
+
+
+
+
+ Download/Use any authenticator application like Google Authenticator or Okta Authenticator
+ on your mobile device.
+
+
+
+
-
- Download/Use any authenticator application like Google Authenticator or Okta Authenticator
- on your mobile device.
-
-
-
-
-
-
-
+
+
+ -
+
+
+
+
+ On your mobile device tap the "+" icon then select "Scan QR Code" to scan the QR code
+ below
+
+
+
+
-
-
-
-
-
-
- On your mobile device tap the "+" icon then select "Scan QR Code" to scan the QR code below
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Once the QR code has been scanned, enter the 6-digit code generated by the application.
-
-
+
+
-
+
+
+
+
+ Once the QR code has been scanned, enter the 6-digit code generated by the application.
+
+
+ {{ error }}
+
+
+
Skip
diff --git a/src/views/SettingConfig.vue b/src/views/SettingConfig.vue
index 26095a1..51a2f12 100644
--- a/src/views/SettingConfig.vue
+++ b/src/views/SettingConfig.vue
@@ -3,29 +3,43 @@
-
+
+
+ Multi Factor
Authentication (MFA)
-
-
-
-
- -->
+
+
+
MFA Enabled
+
+ -
+
+ Type: {{ isTwoFactorEnabled.authenticators[0].type }}
+
+
+
+
+
+
+
+
+
+
+
Members &
@@ -69,7 +83,10 @@
import TeamMembers from '../components/teams/TeamMembers.vue';
import MyInvitions from '../components/teams/MyInvitions.vue'
import AdminTeams from '../components/teams/AdminTeams.vue';
-import { mapMutations } from "vuex";
+import { mapMutations, mapGetters } from "vuex";
+// import MfaPage from '../components/login/mfa/MFA.vue'
+
+import SetupMFA from '../components/login/mfa/SetupMfa.vue';
// import MyProfile from '../components/teams/MyProfile.vue'
export default {
@@ -78,7 +95,18 @@ export default {
TeamMembers,
AdminTeams,
MyInvitions,
- // MyProfile
+ SetupMFA
+ // MyProfile,
+ },
+ computed: {
+ ...mapGetters('mainStore', ['getAuthToken']),
+ isTwoFactorEnabled() {
+ const payload = localStorage.getItem('user')
+ if (payload) {
+ return JSON.parse(payload)
+ }
+ return {};
+ }
},
data() {
return {