Merge branch 'master' of git.bubblev.org:bubblev/bubble-web into fix/missing-functionalities fix: page reloading stuff fix: login stuff Merge branch 'master' of git.bubblev.org:bubblev/bubble-web into fix/missing-functionalities fix: sign up and payment check stuff fix: launch bubble screen Merge branch 'master' of git.bubblev.org:bubblev/bubble-web into fix/missing-functionalities Merge branch 'master' of git.bubblev.org:bubblev/bubble-web into fix/missing-functionalities fix: refreshing issue feat: implement devices screen Merge branch 'master' of git.bubblev.org:bubblev/bubble-web into fix/missing-functionalities feat: implement new layout Merge branch 'master' of git.bubblev.org:bubblev/bubble-web into fix/missing-functionalities feat: implement new layout fix: header fix: showing error on add ssh modal fix: login by enter key Co-authored-by: Tyler <everdev0923@gmail.com> Reviewed-on: https://git.bubblev.org/bubblev/bubble-web/pulls/64pull/68/head
@@ -2524,6 +2524,11 @@ | |||||
"entities": "^1.1.1" | "entities": "^1.1.1" | ||||
} | } | ||||
}, | }, | ||||
"dom-walk": { | |||||
"version": "0.1.2", | |||||
"resolved": "https://registry.npmjs.org/dom-walk/-/dom-walk-0.1.2.tgz", | |||||
"integrity": "sha512-6QvTW9mrGeIegrFXdtQi9pk7O/nSK6lSdXW2eqUspN5LWD7UTji2Fqw5V2YLjBpHEoU9Xl/eUWNpDeZvoyOv2w==" | |||||
}, | |||||
"domain-browser": { | "domain-browser": { | ||||
"version": "1.2.0", | "version": "1.2.0", | ||||
"resolved": "https://registry.npmjs.org/domain-browser/-/domain-browser-1.2.0.tgz", | "resolved": "https://registry.npmjs.org/domain-browser/-/domain-browser-1.2.0.tgz", | ||||
@@ -3432,6 +3437,15 @@ | |||||
} | } | ||||
} | } | ||||
}, | }, | ||||
"global": { | |||||
"version": "4.4.0", | |||||
"resolved": "https://registry.npmjs.org/global/-/global-4.4.0.tgz", | |||||
"integrity": "sha512-wv/LAoHdRE3BeTGz53FAamhGlPLhlssK45usmGFThIi4XqnBmjKQ16u+RNbP7WvigRZDxUsM0J3gcQ5yicaL0w==", | |||||
"requires": { | |||||
"min-document": "^2.19.0", | |||||
"process": "^0.11.10" | |||||
} | |||||
}, | |||||
"global-modules": { | "global-modules": { | ||||
"version": "2.0.0", | "version": "2.0.0", | ||||
"resolved": "https://registry.npmjs.org/global-modules/-/global-modules-2.0.0.tgz", | "resolved": "https://registry.npmjs.org/global-modules/-/global-modules-2.0.0.tgz", | ||||
@@ -4550,6 +4564,14 @@ | |||||
"mime-db": "1.44.0" | "mime-db": "1.44.0" | ||||
} | } | ||||
}, | }, | ||||
"min-document": { | |||||
"version": "2.19.0", | |||||
"resolved": "https://registry.npmjs.org/min-document/-/min-document-2.19.0.tgz", | |||||
"integrity": "sha1-e9KC4/WELtKVu3SM3Z8f+iyCRoU=", | |||||
"requires": { | |||||
"dom-walk": "^0.1.0" | |||||
} | |||||
}, | |||||
"minimalistic-assert": { | "minimalistic-assert": { | ||||
"version": "1.0.1", | "version": "1.0.1", | ||||
"resolved": "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz", | "resolved": "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz", | ||||
@@ -5504,8 +5526,7 @@ | |||||
"process": { | "process": { | ||||
"version": "0.11.10", | "version": "0.11.10", | ||||
"resolved": "https://registry.npmjs.org/process/-/process-0.11.10.tgz", | "resolved": "https://registry.npmjs.org/process/-/process-0.11.10.tgz", | ||||
"integrity": "sha1-czIwDoQBYb2j5podHZGn1LwW8YI=", | |||||
"dev": true | |||||
"integrity": "sha1-czIwDoQBYb2j5podHZGn1LwW8YI=" | |||||
}, | }, | ||||
"process-nextick-args": { | "process-nextick-args": { | ||||
"version": "2.0.1", | "version": "2.0.1", | ||||
@@ -7665,6 +7686,23 @@ | |||||
"resolved": "https://registry.npmjs.org/vue/-/vue-2.6.10.tgz", | "resolved": "https://registry.npmjs.org/vue/-/vue-2.6.10.tgz", | ||||
"integrity": "sha512-ImThpeNU9HbdZL3utgMCq0oiMzAkt1mcgy3/E6zWC/G6AaQoeuFdsl9nDhTDU3X1R6FK7nsIUuRACVcjI+A2GQ==" | "integrity": "sha512-ImThpeNU9HbdZL3utgMCq0oiMzAkt1mcgy3/E6zWC/G6AaQoeuFdsl9nDhTDU3X1R6FK7nsIUuRACVcjI+A2GQ==" | ||||
}, | }, | ||||
"vue-carousel": { | |||||
"version": "0.18.0", | |||||
"resolved": "https://registry.npmjs.org/vue-carousel/-/vue-carousel-0.18.0.tgz", | |||||
"integrity": "sha512-a2zxh7QJioDxNMguqcuJ7TPbfgK5bGDaAXIia7NWxPAWsEvNE4ZtHgsGu40L5Aha4uyjmNKXvleB14QAXFoKig==", | |||||
"requires": { | |||||
"global": "^4.3.2", | |||||
"regenerator-runtime": "^0.12.1", | |||||
"vue": "^2.5.17" | |||||
}, | |||||
"dependencies": { | |||||
"regenerator-runtime": { | |||||
"version": "0.12.1", | |||||
"resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.12.1.tgz", | |||||
"integrity": "sha512-odxIc1/vDlo4iZcfXqRYFj0vpXFNoGdKMAUieAlFYO6m/nl5e9KR/beGf41z4a1FI+aQgtjhuaSlDxQ0hmkrHg==" | |||||
} | |||||
} | |||||
}, | |||||
"vue-click-outside": { | "vue-click-outside": { | ||||
"version": "1.1.0", | "version": "1.1.0", | ||||
"resolved": "https://registry.npmjs.org/vue-click-outside/-/vue-click-outside-1.1.0.tgz", | "resolved": "https://registry.npmjs.org/vue-click-outside/-/vue-click-outside-1.1.0.tgz", | ||||
@@ -34,26 +34,13 @@ export default { | |||||
}, | }, | ||||
payMethods: null, | payMethods: null, | ||||
hasPaymentMethod: false, | hasPaymentMethod: false, | ||||
isPageAvailable: false, | |||||
}), | }), | ||||
computed: { | computed: { | ||||
...mapState('users', ['policy']), | ...mapState('users', ['policy']), | ||||
...mapState('paymentMethods', ['accountPaymentMethods']), | ...mapState('paymentMethods', ['accountPaymentMethods']), | ||||
...mapState('system', ['configs', 'messages']), | ...mapState('system', ['configs', 'messages']), | ||||
isPageAvailable() { | |||||
console.log('current user', this.currentUser); | |||||
return ( | |||||
!this.currentUser || | |||||
((this.verifiedContacts || | |||||
this.currentUser.admin || | |||||
this.$route.path === '/verifyEmail' || | |||||
this.$route.path === '/me/action') && | |||||
(!this.configs.paymentsEnabled || | |||||
this.hasPaymentMethod === true || | |||||
this.$route.path === '/payment')) | |||||
); | |||||
}, | |||||
}, | }, | ||||
created() { | created() { | ||||
@@ -85,6 +72,16 @@ export default { | |||||
errors: this.errors, | errors: this.errors, | ||||
}); | }); | ||||
} | } | ||||
this.isPageAvailable = | |||||
!this.currentUser || | |||||
this.$route.path === '/me/action' || | |||||
this.$route.path === '/logout' || | |||||
this.$route.path === '/verifyEmail' || | |||||
((this.verifiedContacts || this.currentUser.admin) && | |||||
(!this.configs.paymentsEnabled || | |||||
this.hasPaymentMethod === true || | |||||
this.$route.path === '/payment')); | |||||
}, | }, | ||||
hasVerifiedContact(policy) { | hasVerifiedContact(policy) { | ||||
@@ -122,6 +119,18 @@ export default { | |||||
}, | }, | ||||
watch: { | watch: { | ||||
$route() { | |||||
this.isPageAvailable = | |||||
!this.currentUser || | |||||
this.$route.path === '/me/action' || | |||||
this.$route.path === '/logout' || | |||||
this.$route.path === '/verifyEmail' || | |||||
((this.verifiedContacts || this.currentUser.admin) && | |||||
(!this.configs.paymentsEnabled || | |||||
this.hasPaymentMethod === true || | |||||
this.$route.path === '/payment')); | |||||
}, | |||||
policy(p) { | policy(p) { | ||||
this.verifiedContacts = this.hasVerifiedContact(p); | this.verifiedContacts = this.hasVerifiedContact(p); | ||||
const currentUser = util.currentUser(); | const currentUser = util.currentUser(); | ||||