setup wizard funcionality upgrade for v2

This commit is contained in:
Čarodej
2022-02-11 10:05:12 +01:00
parent 3867c9cd67
commit 03730b80c0
33 changed files with 517 additions and 448 deletions

View File

@@ -1,5 +1,5 @@
<template>
<AuthContentWrapper ref="auth" class="h-screen bg-white">
<AuthContentWrapper ref="auth" class="h-screen dark:bg-dark-background bg-white">
<!--Licence Verify-->
<AuthContent name="licence-verify" :visible="true">
<Headline title="Setup Wizard" description="Please set your purchase code before continue to set up your application.">
@@ -49,6 +49,7 @@ export default {
data() {
return {
isLoading: false,
isExtended: undefined,
purchaseCode: '',
}
},
@@ -71,10 +72,20 @@ export default {
.post('/api/setup/purchase-code', {
purchaseCode: this.purchaseCode,
})
.then(() => {
.then((response) => {
// End loading
this.isLoading = false
console.log(response);
if (response.data === 'b6896a44017217c36f4a6fdc56699728') {
this.isExtended = true
localStorage.setItem('license', 'Extended')
} else {
this.isExtended = false
localStorage.setItem('license', 'Regular')
}
localStorage.setItem('purchase_code', this.purchaseCode)
// Redirect to next step