-
Notifications
You must be signed in to change notification settings - Fork 0
/
App.vue
90 lines (82 loc) · 2.98 KB
/
App.vue
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
/* eslint-disable */
/*global google*/
<template>
<v-app>
<template><div>
<v-app-bar>
<v-btn link icon to="/">
<v-icon>mdi-qrcode-scan</v-icon>
</v-btn>
<img src="ecodiya.png" height="50"/>
<v-layout v-if="$firebase.auth().currentUser" justify-end style="padding-top:6px">
<v-chip v-if="$store.state.user.bonus" link to="/rating" text-color="orange" color="transparent">
<v-icon color="orange" small>mdi-star-face</v-icon>
{{$store.state.user.bonus}}
</v-chip>
<v-chip v-if="$store.state.user.tokens" link to="/wallet" text-color="#07C01A" color="transparent">
<v-icon color="#07C01A" small>mdi-currency-usd-circle-outline</v-icon>
<span id="topTokens">{{$store.state.user.tokens}}</span>
</v-chip>
<v-chip color="transparent">
<v-icon color="orange">mdi-bell-plus</v-icon>
<span>1</span>
</v-chip>
<v-btn link icon to="/profile" small>
<v-avatar right size="32px">
<v-img id="topAvatar" v-show="$store.state.user.avatar" v-bind:src="$store.state.user.avatar"></v-img>
<v-icon v-show="!$store.state.user.avatar" color="green">mdi-account-circle</v-icon>
</v-avatar>
</v-btn>
</v-layout>
</v-app-bar>
</div>
</template>
<v-content style="margin-bottom:60px">
<router-view class="view"></router-view>
</v-content>
<v-bottom-navigation v-if="$firebase.auth().currentUser" app grow fixed color="orange">
<v-btn value="qr" link icon to="/qr" small>
<v-icon>mdi-qrcode-scan</v-icon>
</v-btn>
<v-btn value="rating" link icon to="/rating" small>
<v-icon>mdi-podium-gold</v-icon>
</v-btn>
<v-btn value="wallet" link icon to="/wallet" small>
<v-icon>mdi-currency-usd-circle-outline</v-icon>
</v-btn>
<v-btn value="find" link icon to="/find" small>
<v-icon>mdi-map-marker-radius</v-icon>
</v-btn>
<v-btn value="ads" link icon to="/ads" small>
<v-icon>mdi-plus-box-outline</v-icon>
</v-btn>
</v-bottom-navigation>
</v-app>
</template>
<script>
//import Wallet from './components/wallet.vue';
//import Profile from './components/profile.vue';
export default {
name: 'App',
data: () => ({
publicPath: process.env.BASE_URL,
bottomNav: false,
appUser:false
}),
methods:{
goProfile(){
window.location.href="/#/profile";
}
}
/*async created() {
let ref = this;
if(ref.$firebase.auth().currentUser){
await ref.$store.state.db.collection('users').doc(ref.$firebase.auth().currentUser.uid).get().then(
doc=>{
ref.appUser = doc.data();
}
);
}
},*/
};
</script>