mirror of
https://github.com/IT4Change/gradido.git
synced 2025-12-13 07:45:54 +00:00
commit
d820caba3f
@ -38,6 +38,7 @@
|
|||||||
"vue-cli-plugin-i18n": "^1.0.1",
|
"vue-cli-plugin-i18n": "^1.0.1",
|
||||||
"vue-clickaway": "^2.2.2",
|
"vue-clickaway": "^2.2.2",
|
||||||
"vue-clipboard2": "^0.3.0",
|
"vue-clipboard2": "^0.3.0",
|
||||||
|
"vue-cookies": "^1.7.4",
|
||||||
"vue-flatpickr-component": "^8.1.2",
|
"vue-flatpickr-component": "^8.1.2",
|
||||||
"vue-good-table": "^2.21.3",
|
"vue-good-table": "^2.21.3",
|
||||||
"vue-i18n": "^8.22.4",
|
"vue-i18n": "^8.22.4",
|
||||||
|
|||||||
54
src/App.vue
54
src/App.vue
@ -2,54 +2,54 @@
|
|||||||
<div id="app" class="font-sans text-gray-800">
|
<div id="app" class="font-sans text-gray-800">
|
||||||
<header class="border-t-4 border-blue-700 bg-white z-10 absolute w-full shadow-md">
|
<header class="border-t-4 border-blue-700 bg-white z-10 absolute w-full shadow-md">
|
||||||
</header>
|
</header>
|
||||||
<div class="bg-gray-100 min-h-screen pt-40 text-lg">
|
<div class="bg-gray-100 min-h-screen pt-40 text-lg">
|
||||||
<div style="text-align:center">
|
|
||||||
|
|
||||||
|
|
||||||
<modal v-if="this.$store.state.modals"/>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<router-view />
|
<router-view />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import Modal from '@/components/Modal'
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'app',
|
name: 'app',
|
||||||
component: {
|
|
||||||
Modal
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
name: '',
|
|
||||||
nameState: null,
|
|
||||||
submittedNames: []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
created () {
|
created () {
|
||||||
if ( this.$store.state.is_auth == false && this.$store.state.is_admin == false) {
|
if (this.$cookies.get('gdd_is_auth') == 'true' && this.$store.state.is_auth == true) {
|
||||||
this.$router.push("/Landing")
|
this.$store.state.user.email = this.$cookies.get('gdd_email')
|
||||||
}
|
|
||||||
},
|
// if ( this.$store.state.is_auth == false && this.$store.state.is_admin == false) {
|
||||||
methods: {
|
// this.$router.push("/Landing")
|
||||||
|
// } else {
|
||||||
|
this.$router.push('/KontoOverview')
|
||||||
|
// }
|
||||||
|
}else {
|
||||||
|
this.$router.push("/Landing")
|
||||||
|
}
|
||||||
|
|
||||||
|
//var user = { id:1, name:'Journal',session:'25j_7Sl6xDq2Kc3ym0fmrSSk2xV2XkUkX' };
|
||||||
|
//this.$cookies.set('user',user);
|
||||||
|
//// print user name
|
||||||
|
//console.log("APP.vue START created get cookie is_auth=>",this.$cookies.get('gdd_is_auth'))
|
||||||
|
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
/*
|
||||||
login() {
|
login() {
|
||||||
console.log("app.vue user login() : " + this.$store.state.is_auth)
|
//console.log("app.vue user login() : " + this.$store.state.is_auth)
|
||||||
this.$store.commit('login')
|
this.$store.commit('login')
|
||||||
//this.$router.push('/KontoOverview')
|
//this.$router.push('/KontoOverview')
|
||||||
},
|
},
|
||||||
loginAsAdmin () {
|
loginAsAdmin () {
|
||||||
console.log("app.vue admin login(): " + this.$store.state.is_admin)
|
// console.log("app.vue admin login(): " + this.$store.state.is_admin)
|
||||||
this.$store.state.modals = true
|
this.$store.state.modals = true
|
||||||
//this.$store.commit('loginAsAdmin')
|
//this.$store.commit('loginAsAdmin')
|
||||||
//this.$router.push('/AdminOverview')
|
//this.$router.push('/AdminOverview')
|
||||||
},
|
},
|
||||||
|
|
||||||
logout(){
|
logout(){
|
||||||
|
// console.log("app.vue user logout() : ")
|
||||||
this.$store.commit('logout')
|
this.$store.commit('logout')
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@ -2,6 +2,7 @@ import Vue from 'vue';
|
|||||||
import DashboardPlugin from './plugins/dashboard-plugin';
|
import DashboardPlugin from './plugins/dashboard-plugin';
|
||||||
import App from './App.vue';
|
import App from './App.vue';
|
||||||
import i18n from './i18n.js';
|
import i18n from './i18n.js';
|
||||||
|
import VueCookies from 'vue-cookies';
|
||||||
|
|
||||||
// store
|
// store
|
||||||
import {store} from './store/store';
|
import {store} from './store/store';
|
||||||
@ -11,7 +12,8 @@ import router from './routes/router';
|
|||||||
|
|
||||||
// plugin setup
|
// plugin setup
|
||||||
Vue.use(DashboardPlugin);
|
Vue.use(DashboardPlugin);
|
||||||
Vue.config.productionTip = false
|
Vue.config.productionTip = false;
|
||||||
|
Vue.use(VueCookies);
|
||||||
|
|
||||||
|
|
||||||
/* eslint-disable no-new */
|
/* eslint-disable no-new */
|
||||||
|
|||||||
@ -31,7 +31,7 @@ import VueQrcodeReader from "vue-qrcode-reader";
|
|||||||
|
|
||||||
import VueGoodTablePlugin from 'vue-good-table';
|
import VueGoodTablePlugin from 'vue-good-table';
|
||||||
// import the styles
|
// import the styles
|
||||||
import 'vue-good-table/dist/vue-good-table.css'
|
import 'vue-good-table/dist/vue-good-table.css';
|
||||||
|
|
||||||
|
|
||||||
Object.keys(rules).forEach(rule => {
|
Object.keys(rules).forEach(rule => {
|
||||||
|
|||||||
@ -28,13 +28,15 @@ router.beforeEach((to, from, next) => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
//console.log("----------------")
|
//console.log("----------------")
|
||||||
console.log("to", to)
|
//("ROUTER.js to", to)
|
||||||
console.log("store.state.is_auth", store.state.is_auth)
|
//console.log("ROUTER.js store.state.is_auth", store.state.is_auth)
|
||||||
// if (store.state.is_auth != true && to.path != "/login" ) {
|
//console.log("ROUTER.js store.commit('isActive')", store.commit('isActive'))
|
||||||
// next()
|
|
||||||
// } else {
|
//if (store.commit('isActive') ) {
|
||||||
// next("/login")
|
// next()
|
||||||
// }
|
//} else {
|
||||||
|
// next("/login")
|
||||||
|
//}
|
||||||
//console.log(from)
|
//console.log(from)
|
||||||
//console.log(next)
|
//console.log(next)
|
||||||
|
|
||||||
|
|||||||
@ -1,5 +1,6 @@
|
|||||||
import DashboardLayout from '@/views/Layout/DashboardLayout.vue'
|
import DashboardLayout from '@/views/Layout/DashboardLayout.vue'
|
||||||
import AuthLayout from '@/views/Pages/AuthLayout.vue'
|
import AuthLayoutGDD from '@/views/Layout/AuthLayout_gdd.vue'
|
||||||
|
import AuthLayout from '@/views/Layout/AuthLayout.vue'
|
||||||
|
|
||||||
import NotFound from '@/views/NotFoundPage.vue'
|
import NotFound from '@/views/NotFoundPage.vue'
|
||||||
|
|
||||||
@ -8,13 +9,18 @@ const routes = [
|
|||||||
{
|
{
|
||||||
path: '/',
|
path: '/',
|
||||||
redirect: 'landing',
|
redirect: 'landing',
|
||||||
component: AuthLayout,
|
component: AuthLayoutGDD,
|
||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
path: '/Landing',
|
path: '/Landing',
|
||||||
name: 'Landing',
|
name: 'Landing',
|
||||||
component: () => import(/* webpackChunkName: "demo" */ '../views/Landing.vue')
|
component: () => import(/* webpackChunkName: "demo" */ '../views/Landing.vue')
|
||||||
}
|
},
|
||||||
|
{
|
||||||
|
path: '/login',
|
||||||
|
name: 'login',
|
||||||
|
component: () => import(/* webpackChunkName: "demo" */ '../views/Pages/Login.vue')
|
||||||
|
},
|
||||||
|
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
@ -36,11 +42,6 @@ const routes = [
|
|||||||
name: 'profile',
|
name: 'profile',
|
||||||
component: () => import(/* webpackChunkName: "demo" */ '../views/Pages/UserProfile.vue')
|
component: () => import(/* webpackChunkName: "demo" */ '../views/Pages/UserProfile.vue')
|
||||||
},
|
},
|
||||||
{
|
|
||||||
path: '/login',
|
|
||||||
name: 'login',
|
|
||||||
component: () => import(/* webpackChunkName: "demo" */ '../views/Pages/Login.vue')
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
path: '/register',
|
path: '/register',
|
||||||
name: 'register',
|
name: 'register',
|
||||||
|
|||||||
@ -1,6 +1,9 @@
|
|||||||
import Vue from 'vue'
|
import Vue from 'vue'
|
||||||
import Vuex from 'vuex'
|
import Vuex from 'vuex'
|
||||||
Vue.use(Vuex)
|
Vue.use(Vuex)
|
||||||
|
import axios from 'axios';
|
||||||
|
import VueCookies from 'vue-cookies';
|
||||||
|
import router from '../routes/router.js';
|
||||||
|
|
||||||
export const store = new Vuex.Store({
|
export const store = new Vuex.Store({
|
||||||
state: {
|
state: {
|
||||||
@ -10,37 +13,78 @@ export const store = new Vuex.Store({
|
|||||||
active: false,
|
active: false,
|
||||||
modals: false,
|
modals: false,
|
||||||
user : {
|
user : {
|
||||||
name:"oger ly",
|
name:"",
|
||||||
email:"test@test.de"
|
email:""
|
||||||
}
|
},
|
||||||
|
dataLogout: {"session_id": -127182}
|
||||||
},
|
},
|
||||||
mutations: {
|
mutations: {
|
||||||
login (state) {
|
isActive(state) {
|
||||||
console.log("store login() user from " + state.is_auth)
|
//("Im Store PRÜFEN PRÜFEN" )
|
||||||
if (state.is_auth) {
|
return true
|
||||||
state.is_auth = false
|
|
||||||
state.active = false
|
|
||||||
} else {
|
|
||||||
state.is_auth = true
|
|
||||||
state.active = true
|
|
||||||
}
|
|
||||||
console.log("store login() user to " + state.is_auth)
|
|
||||||
},
|
},
|
||||||
loginAsAdmin (state) {
|
login (state, logindata) {
|
||||||
console.log("store login admin from" + state.is_admin)
|
//console.log("Im Store LOGIN() start " )
|
||||||
if (state.is_admin) {
|
//console.log("logon state =>", state )
|
||||||
state.is_admin = false
|
//console.log("logon TEST =>", logindata )
|
||||||
state.active = false
|
axios.post("http://localhost/login_api/unsecureLogin", logindata).then((ldata) => {
|
||||||
} else {
|
|
||||||
state.is_admin = true
|
//console.log("Im Store LOGIN() axios then.statusText ", ldata.statusText);
|
||||||
state.active = true
|
if (ldata.statusText === "OK") {
|
||||||
}
|
//console.log("STORE login() from" + state.is_auth)
|
||||||
console.log("store login admin to" + state.is_admin)
|
state.is_auth = true
|
||||||
|
state.active = true
|
||||||
|
$cookies.set('gdd_is_auth','true');
|
||||||
|
$cookies.set('gdd_email',logindata.email);
|
||||||
|
state.user.email = logindata.email
|
||||||
|
|
||||||
|
//console.log("STORE login() to " + state.is_auth)
|
||||||
|
router.push('/KontoOverview')
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
return true
|
||||||
|
}, (error) => {
|
||||||
|
console.log(error);
|
||||||
|
});
|
||||||
|
//console.log("STORE login() from" + state.is_auth)
|
||||||
|
//if (state.is_auth) {
|
||||||
|
// state.is_auth = false
|
||||||
|
// state.active = false
|
||||||
|
//} else {
|
||||||
|
// state.is_auth = true
|
||||||
|
// state.active = true
|
||||||
|
//}
|
||||||
|
// console.log("STORE login() to " + state.is_auth)
|
||||||
},
|
},
|
||||||
|
creatUser( state, formdata) {
|
||||||
|
//console.log("Im Store creatUser() start " )
|
||||||
|
axios.post("http://localhost/login_api/createUser", formdata).then((ldata) => {
|
||||||
|
|
||||||
|
console.log("Im Store creatUser() axios then ", ldata);
|
||||||
|
// this.ldata = ldata.data;
|
||||||
|
return true
|
||||||
|
|
||||||
|
}, (error) => {
|
||||||
|
console.log(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
logout(state){
|
logout(state){
|
||||||
|
axios.post("http://localhost/login_api/logout", this.dataLogout).then((ldata) => {
|
||||||
|
|
||||||
|
//console.log("Im Store logout() axios then ", ldata);
|
||||||
|
// this.ldata = ldata.data;
|
||||||
|
//return true
|
||||||
state.is_auth = false
|
state.is_auth = false
|
||||||
state.is_admin = false
|
state.is_admin = false
|
||||||
state.active = false
|
state.active = false
|
||||||
|
$cookies.set('gdd_is_auth','false');
|
||||||
|
$cookies.remove('gdd_email');
|
||||||
|
router.push('/Landing')
|
||||||
|
}, (error) => {
|
||||||
|
console.log(error);
|
||||||
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
@ -290,7 +290,7 @@
|
|||||||
methods: {
|
methods: {
|
||||||
TransienceList() {
|
TransienceList() {
|
||||||
axios.get("/json-example/admin_transience_list.json").then((d) => {
|
axios.get("/json-example/admin_transience_list.json").then((d) => {
|
||||||
console.log(d);
|
//console.log(d);
|
||||||
this.transiencelist = d.data;
|
this.transiencelist = d.data;
|
||||||
|
|
||||||
}, (error) => {
|
}, (error) => {
|
||||||
@ -299,7 +299,7 @@
|
|||||||
},
|
},
|
||||||
TransactionList() {
|
TransactionList() {
|
||||||
axios.get("/json-example/admin_transaction_list.json").then((d) => {
|
axios.get("/json-example/admin_transaction_list.json").then((d) => {
|
||||||
console.log(d);
|
//console.log(d);
|
||||||
this.transactionlist = d.data;
|
this.transactionlist = d.data;
|
||||||
|
|
||||||
}, (error) => {
|
}, (error) => {
|
||||||
@ -308,7 +308,7 @@
|
|||||||
},
|
},
|
||||||
UserList() {
|
UserList() {
|
||||||
axios.get("/json-example/admin_userlist.json").then((d) => {
|
axios.get("/json-example/admin_userlist.json").then((d) => {
|
||||||
console.log(d);
|
//console.log(d);
|
||||||
this.userlist = d.data;
|
this.userlist = d.data;
|
||||||
|
|
||||||
}, (error) => {
|
}, (error) => {
|
||||||
@ -317,7 +317,7 @@
|
|||||||
},
|
},
|
||||||
CommunityStatistic() {
|
CommunityStatistic() {
|
||||||
axios.get("/json-example/admin_community_statistic.json").then((d) => {
|
axios.get("/json-example/admin_community_statistic.json").then((d) => {
|
||||||
console.log(d);
|
//console.log(d);
|
||||||
this.communitystatistic = d.data;
|
this.communitystatistic = d.data;
|
||||||
|
|
||||||
}, (error) => {
|
}, (error) => {
|
||||||
@ -326,7 +326,7 @@
|
|||||||
},
|
},
|
||||||
ChartsStatistic() {
|
ChartsStatistic() {
|
||||||
axios.get("/json-example/admin_charts_statistic.json").then((d) => {
|
axios.get("/json-example/admin_charts_statistic.json").then((d) => {
|
||||||
console.log(d);
|
//console.log(d);
|
||||||
this.chartsstatistic = d.data;
|
this.chartsstatistic = d.data;
|
||||||
|
|
||||||
}, (error) => {
|
}, (error) => {
|
||||||
@ -335,7 +335,7 @@
|
|||||||
},
|
},
|
||||||
CardStatistic() {
|
CardStatistic() {
|
||||||
axios.get("/json-example/admin_card_statistic.json").then((d) => {
|
axios.get("/json-example/admin_card_statistic.json").then((d) => {
|
||||||
console.log(d);
|
//console.log(d);
|
||||||
this.cardstatistic = d.data;
|
this.cardstatistic = d.data;
|
||||||
|
|
||||||
}, (error) => {
|
}, (error) => {
|
||||||
@ -344,7 +344,7 @@
|
|||||||
},
|
},
|
||||||
StatisticDatas() {
|
StatisticDatas() {
|
||||||
axios.get("/json-example/admin_statisticdatas.json").then((d) => {
|
axios.get("/json-example/admin_statisticdatas.json").then((d) => {
|
||||||
console.log(d);
|
//console.log(d);
|
||||||
this.userdata = d.data;
|
this.userdata = d.data;
|
||||||
|
|
||||||
}, (error) => {
|
}, (error) => {
|
||||||
|
|||||||
@ -4,7 +4,9 @@
|
|||||||
<div class="header bg-gradient-info py-7 py-lg-8 pt-lg-9">
|
<div class="header bg-gradient-info py-7 py-lg-8 pt-lg-9">
|
||||||
<b-container>
|
<b-container>
|
||||||
<div class="header-body text-center mb-7">
|
<div class="header-body text-center mb-7">
|
||||||
<b-row class="justify-content-center">
|
<p class="h1">GRADIDO</p>
|
||||||
|
<p class="h4">Wallet</p>
|
||||||
|
<!-- <b-row class="justify-content-center">
|
||||||
<b-col xl="5" lg="6" md="6" class="px-5">
|
<b-col xl="5" lg="6" md="6" class="px-5">
|
||||||
<h1 class="text-light">Landing Gradido</h1>
|
<h1 class="text-light">Landing Gradido</h1>
|
||||||
<br>
|
<br>
|
||||||
@ -14,7 +16,75 @@
|
|||||||
<br><br>
|
<br><br>
|
||||||
<router-link to="/register" class="font-weight-bold text-white mt-5"> Register</router-link>
|
<router-link to="/register" class="font-weight-bold text-white mt-5"> Register</router-link>
|
||||||
</b-col>
|
</b-col>
|
||||||
|
</b-row> -->
|
||||||
|
<hr>
|
||||||
|
<p class="lead">
|
||||||
|
Anmelden
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<b-row class="justify-content-center">
|
||||||
|
<b-col xl="5" lg="6" md="6" class="px-5">
|
||||||
|
<form @submit.prevent="login">
|
||||||
|
|
||||||
|
<b-row class="form-group">
|
||||||
|
<label for="example-email-input" class="col-md-2 col-form-label form-control-label">Email</label>
|
||||||
|
<b-col md="10">
|
||||||
|
<base-input type="email" autocomplete="username email" placeholder="argon@example.com" v-model="lemail"/>
|
||||||
|
</b-col>
|
||||||
|
</b-row>
|
||||||
|
|
||||||
|
<b-row class="form-group">
|
||||||
|
<label for="example-password-input"
|
||||||
|
class="col-md-2 col-form-label form-control-label">Password</label>
|
||||||
|
<b-col md="10">
|
||||||
|
<base-input type="password" autocomplete="current-password" placeholder="password" v-model="lpwd"/>
|
||||||
|
</b-col>
|
||||||
|
</b-row>
|
||||||
|
|
||||||
|
<b-button block type="submit" >Anmelden</b-button>
|
||||||
|
</form>
|
||||||
|
</b-col>
|
||||||
</b-row>
|
</b-row>
|
||||||
|
|
||||||
|
<hr>
|
||||||
|
<p class="lead">
|
||||||
|
neues Mitglied anlegen
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<b-row class="justify-content-center">
|
||||||
|
<b-col xl="5" lg="6" md="6" class="px-5">
|
||||||
|
<form>
|
||||||
|
<b-row class="form-group">
|
||||||
|
<label class="col-md-2 col-form-label form-control-label">Vorname</label>
|
||||||
|
<b-col md="10">
|
||||||
|
<base-input placeholder="Jon " v-model="rfname"></base-input>
|
||||||
|
</b-col>
|
||||||
|
</b-row>
|
||||||
|
<b-row class="form-group">
|
||||||
|
<label class="col-md-2 col-form-label form-control-label">Nachname</label>
|
||||||
|
<b-col md="10">
|
||||||
|
<base-input placeholder=" Snow" v-model="rlname"></base-input>
|
||||||
|
</b-col>
|
||||||
|
</b-row>
|
||||||
|
<b-row class="form-group">
|
||||||
|
<label for="example-email-input" class="col-md-2 col-form-label form-control-label">Email</label>
|
||||||
|
<b-col md="10">
|
||||||
|
<base-input type="email" autocomplete="username email" placeholder="argon@example.com" v-model="remail"/>
|
||||||
|
</b-col>
|
||||||
|
</b-row>
|
||||||
|
|
||||||
|
<b-row class="form-group">
|
||||||
|
<label for="example-password-input"
|
||||||
|
class="col-md-2 col-form-label form-control-label">Password</label>
|
||||||
|
<b-col md="10">
|
||||||
|
<base-input type="password" autocomplete="current-password" placeholder="password" v-model="rpwd"/>
|
||||||
|
</b-col>
|
||||||
|
</b-row>
|
||||||
|
</form>
|
||||||
|
<b-button block type="submit" @click="creatUser()">Anmelden</b-button>
|
||||||
|
</b-col>
|
||||||
|
</b-row>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</b-container>
|
</b-container>
|
||||||
<div class="separator separator-bottom separator-skew zindex-100">
|
<div class="separator separator-bottom separator-skew zindex-100">
|
||||||
@ -24,32 +94,44 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<!-- Page content -->
|
<!-- Page content -->
|
||||||
<section class="py-6">
|
|
||||||
<b-container >
|
|
||||||
<b-row align-v="center" class="row-grid">
|
|
||||||
<b-col md="6">
|
|
||||||
<b-img src="img/theme/landing-1.png" fluid />
|
|
||||||
</b-col>
|
|
||||||
<b-col md="6">
|
|
||||||
<div class="pr-md-5">
|
|
||||||
<h1 class="text-light"> {{ $t('site.landing1.explore') }}</h1>
|
|
||||||
<p class="text-light">{{ $t('site.landing1.text') }}</p>
|
|
||||||
<router-link to="/user" class="font-weight-bold text-warning mt-5">{{ $t('site.landing1.link') }}</router-link>
|
|
||||||
</div>
|
|
||||||
</b-col>
|
|
||||||
</b-row>
|
|
||||||
</b-container>
|
|
||||||
</section>
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
|
// Components
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'Landing',
|
name: 'Landing',
|
||||||
|
data(){
|
||||||
|
return {
|
||||||
|
lemail: '',
|
||||||
|
lpwd: '',
|
||||||
|
rfname: '',
|
||||||
|
rlname: '',
|
||||||
|
remail: '',
|
||||||
|
rpwd: ''
|
||||||
|
}
|
||||||
|
},
|
||||||
methods: {
|
methods: {
|
||||||
login() {
|
login() {
|
||||||
console.log("app.vue user login() : " + this.$store.state.is_auth)
|
if (this.lemail != '' || this.lpwd != '') {
|
||||||
this.$store.commit('login')
|
//console.log("landingpage login() ")
|
||||||
this.$router.push('/KontoOverview')
|
//console.log("landingpage login() lemail ", this.lemail)
|
||||||
|
//console.log("landingpage login() lpwd ", this.lpwd)
|
||||||
|
this.$store.commit('login', {"email": this.lemail, "password": this.lpwd})
|
||||||
|
}
|
||||||
|
|
||||||
|
//this.$router.push('/KontoOverview')
|
||||||
|
|
||||||
|
},
|
||||||
|
creatUser() {
|
||||||
|
console.log("landingpage creatUser() ")
|
||||||
|
console.log("landingpage login() remail ", this.remail)
|
||||||
|
console.log("landingpage login() rfname ", this.rfname)
|
||||||
|
console.log("landingpage login() rlname ", this.rlname)
|
||||||
|
console.log("landingpage login() rpwd ", this.rpwd)
|
||||||
|
this.$store.commit('creatUser', {"email":this.remail, "first_name":this.rfname, "last_name":this.rlname , "emailType": 2, "password":this.rpwd})
|
||||||
|
//this.$router.push('/KontoOverview')
|
||||||
|
|
||||||
},
|
},
|
||||||
loginAsAdmin () {
|
loginAsAdmin () {
|
||||||
|
|||||||
147
src/views/Layout/AuthLayout_gdd.vue
Normal file
147
src/views/Layout/AuthLayout_gdd.vue
Normal file
@ -0,0 +1,147 @@
|
|||||||
|
<template>
|
||||||
|
<div class="main-content bg-default">
|
||||||
|
|
||||||
|
<template>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="main-content">
|
||||||
|
<router-view></router-view>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<footer class="py-5" id="footer-main">
|
||||||
|
<b-container >
|
||||||
|
<b-row align-v="center" class="justify-content-xl-between">
|
||||||
|
<b-col xl="6">
|
||||||
|
<div class="copyright text-center text-xl-left text-muted">
|
||||||
|
© {{year}} <a href="https://gradido.net/" class="font-weight-bold ml-1" target="_blank">Gradido Wallet</a>
|
||||||
|
</div>
|
||||||
|
</b-col>
|
||||||
|
<b-col xl="6" class="col-xl-6">
|
||||||
|
<b-nav class="nav-footer justify-content-center justify-content-lg-end">
|
||||||
|
<b-nav-item ref="https://www.creative-tim.com" target="_blank">
|
||||||
|
Gradido
|
||||||
|
</b-nav-item>
|
||||||
|
<b-nav-item href="https://www.creative-tim.com/presentation" target="_blank">
|
||||||
|
Impressum
|
||||||
|
</b-nav-item>
|
||||||
|
<b-nav-item href="http://blog.creative-tim.com" target="_blank">
|
||||||
|
Datenschutzerklärung
|
||||||
|
</b-nav-item>
|
||||||
|
<b-nav-item href="https://www.creative-tim.com/license" target="_blank">
|
||||||
|
License
|
||||||
|
</b-nav-item>
|
||||||
|
</b-nav>
|
||||||
|
</b-col>
|
||||||
|
</b-row>
|
||||||
|
</b-container>
|
||||||
|
</footer>
|
||||||
|
</template>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
import { BaseNav } from '@/components';
|
||||||
|
import { ZoomCenterTransition } from 'vue2-transitions';
|
||||||
|
|
||||||
|
export default {
|
||||||
|
components: {
|
||||||
|
BaseNav,
|
||||||
|
ZoomCenterTransition
|
||||||
|
},
|
||||||
|
props: {
|
||||||
|
backgroundColor: {
|
||||||
|
type: String,
|
||||||
|
default: 'black'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
showMenu: false,
|
||||||
|
menuTransitionDuration: 250,
|
||||||
|
pageTransitionDuration: 200,
|
||||||
|
year: new Date().getFullYear(),
|
||||||
|
pageClass: 'login-page'
|
||||||
|
};
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
|
title() {
|
||||||
|
return `${this.$route.name} Page`;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
toggleNavbar() {
|
||||||
|
document.body.classList.toggle('nav-open');
|
||||||
|
this.showMenu = !this.showMenu;
|
||||||
|
},
|
||||||
|
closeMenu() {
|
||||||
|
document.body.classList.remove('nav-open');
|
||||||
|
this.showMenu = false;
|
||||||
|
},
|
||||||
|
setBackgroundColor() {
|
||||||
|
document.body.classList.add('bg-default');
|
||||||
|
},
|
||||||
|
removeBackgroundColor() {
|
||||||
|
document.body.classList.remove('bg-default');
|
||||||
|
},
|
||||||
|
updateBackground() {
|
||||||
|
if (!this.$route.meta.noBodyBackground) {
|
||||||
|
this.setBackgroundColor();
|
||||||
|
} else {
|
||||||
|
this.removeBackgroundColor()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
beforeDestroy() {
|
||||||
|
this.removeBackgroundColor();
|
||||||
|
},
|
||||||
|
beforeRouteUpdate(to, from, next) {
|
||||||
|
// Close the mobile menu first then transition to next page
|
||||||
|
if (this.showMenu) {
|
||||||
|
this.closeMenu();
|
||||||
|
setTimeout(() => {
|
||||||
|
next();
|
||||||
|
}, this.menuTransitionDuration);
|
||||||
|
} else {
|
||||||
|
next();
|
||||||
|
}
|
||||||
|
},
|
||||||
|
watch: {
|
||||||
|
$route: {
|
||||||
|
immediate: true,
|
||||||
|
handler: function () {
|
||||||
|
this.updateBackground()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
<style lang="scss">
|
||||||
|
$scaleSize: 0.8;
|
||||||
|
@keyframes zoomIn8 {
|
||||||
|
from {
|
||||||
|
opacity: 0;
|
||||||
|
transform: scale3d($scaleSize, $scaleSize, $scaleSize);
|
||||||
|
}
|
||||||
|
100% {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.main-content .zoomIn {
|
||||||
|
animation-name: zoomIn8;
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes zoomOut8 {
|
||||||
|
from {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
to {
|
||||||
|
opacity: 0;
|
||||||
|
transform: scale3d($scaleSize, $scaleSize, $scaleSize);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.main-content .zoomOut {
|
||||||
|
animation-name: zoomOut8;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@ -13,28 +13,15 @@
|
|||||||
</sidebar-item>
|
</sidebar-item>
|
||||||
<sidebar-item
|
<sidebar-item
|
||||||
:link="{
|
:link="{
|
||||||
name: 'User Profile',
|
name: 'Profil',
|
||||||
path: '/profile',
|
path: '/profile',
|
||||||
icon: 'ni ni-single-02 text-yellow'
|
icon: 'ni ni-single-02 text-yellow'
|
||||||
}">
|
}">
|
||||||
</sidebar-item>
|
</sidebar-item>
|
||||||
|
<b-nav-item href="#!" @click="logout">
|
||||||
|
<i class="ni ni-palette"></i>
|
||||||
|
<b-nav-text class="p-0">Logout</b-nav-text>
|
||||||
<sidebar-item
|
</b-nav-item>
|
||||||
:link="{
|
|
||||||
name: 'Login',
|
|
||||||
path: '/login',
|
|
||||||
icon: 'ni ni-key-25 text-info'
|
|
||||||
}">
|
|
||||||
</sidebar-item>
|
|
||||||
<sidebar-item
|
|
||||||
:link="{
|
|
||||||
name: 'Register',
|
|
||||||
path: '/register',
|
|
||||||
icon: 'ni ni-circle-08 text-pink'
|
|
||||||
}">
|
|
||||||
</sidebar-item>
|
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<template slot="links-after">
|
<template slot="links-after">
|
||||||
@ -110,7 +97,11 @@
|
|||||||
if (isWindows) {
|
if (isWindows) {
|
||||||
initScrollbar('sidenav');
|
initScrollbar('sidenav');
|
||||||
}
|
}
|
||||||
}
|
},
|
||||||
|
logout(){
|
||||||
|
//console.log("DashboardLayout.vue user logout() : ")
|
||||||
|
this.$store.commit('logout')
|
||||||
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.initScrollbar()
|
this.initScrollbar()
|
||||||
|
|||||||
@ -41,7 +41,7 @@
|
|||||||
<img alt="Image placeholder" src="img/theme/team-4.jpg">
|
<img alt="Image placeholder" src="img/theme/team-4.jpg">
|
||||||
</span>
|
</span>
|
||||||
<b-media-body class="ml-2 d-none d-lg-block">
|
<b-media-body class="ml-2 d-none d-lg-block">
|
||||||
<span class="mb-0 text-sm font-weight-bold">Grad Dido</span>
|
<span class="mb-0 text-sm font-weight-bold">{{this.$store.state.user.email}}</span>
|
||||||
</b-media-body>
|
</b-media-body>
|
||||||
</b-media>
|
</b-media>
|
||||||
</a>
|
</a>
|
||||||
@ -68,7 +68,7 @@
|
|||||||
<span>{{ $t('site.navbar.support') }}</span>
|
<span>{{ $t('site.navbar.support') }}</span>
|
||||||
</b-dropdown-item>
|
</b-dropdown-item>
|
||||||
<div class="dropdown-divider"></div>
|
<div class="dropdown-divider"></div>
|
||||||
<b-dropdown-item href="#!">
|
<b-dropdown-item href="#!" @click="logout">
|
||||||
<i class="ni ni-user-run"></i>
|
<i class="ni ni-user-run"></i>
|
||||||
<span>{{ $t('site.logout') }}</span>
|
<span>{{ $t('site.logout') }}</span>
|
||||||
</b-dropdown-item>
|
</b-dropdown-item>
|
||||||
@ -118,7 +118,11 @@ export default {
|
|||||||
},
|
},
|
||||||
closeDropDown() {
|
closeDropDown() {
|
||||||
this.activeNotifications = false;
|
this.activeNotifications = false;
|
||||||
}
|
},
|
||||||
|
logout(){
|
||||||
|
//console.log("DashboardNavbar.vue user logout() : ")
|
||||||
|
this.$store.commit('logout')
|
||||||
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@ -9,7 +9,7 @@
|
|||||||
<b-container fluid class="d-flex align-items-center">
|
<b-container fluid class="d-flex align-items-center">
|
||||||
<b-row >
|
<b-row >
|
||||||
<b-col lg="7" md="10">
|
<b-col lg="7" md="10">
|
||||||
<h1 class="display-2 text-white">Hello Jesse</h1>
|
<h1 class="display-2 text-white">Hello {{this.$store.state.user.email}}</h1>
|
||||||
<p class="text-white mt-0 mb-5">This is your profile page. You can see the progress you've made with your
|
<p class="text-white mt-0 mb-5">This is your profile page. You can see the progress you've made with your
|
||||||
work and manage your projects or assigned tasks</p>
|
work and manage your projects or assigned tasks</p>
|
||||||
<a href="#!" class="btn btn-info">Edit profile</a>
|
<a href="#!" class="btn btn-info">Edit profile</a>
|
||||||
|
|||||||
@ -38,7 +38,7 @@
|
|||||||
</b-row>
|
</b-row>
|
||||||
<div class="text-center">
|
<div class="text-center">
|
||||||
<h5 class="h3">
|
<h5 class="h3">
|
||||||
Jessica Jones<span class="font-weight-light">, 27</span>
|
{{this.$store.state.user.email}}<span class="font-weight-light"></span>
|
||||||
</h5>
|
</h5>
|
||||||
<div class="h5 font-weight-300">
|
<div class="h5 font-weight-300">
|
||||||
<i class="ni location_pin mr-2"></i>Bucharest, Romania
|
<i class="ni location_pin mr-2"></i>Bucharest, Romania
|
||||||
|
|||||||
@ -52,6 +52,7 @@ import DashboardContent from '../Layout/Content.vue';
|
|||||||
import { FadeTransition } from 'vue2-transitions';
|
import { FadeTransition } from 'vue2-transitions';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
props: [],
|
||||||
components: {
|
components: {
|
||||||
DashboardNavbar,
|
DashboardNavbar,
|
||||||
ContentFooter,
|
ContentFooter,
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user