added token notifier
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
This commit is contained in:
parent
c2ef9797f8
commit
4d3bdcbb6e
@ -29,6 +29,7 @@ const route = useRoute()
|
||||
|
||||
const isAuthenticated = ref(false)
|
||||
const user = ref('frikandel')
|
||||
const registrationToken = ref('')
|
||||
const auth = ref(null)
|
||||
const userLoaded = ref(false)
|
||||
const userData = ref(null)
|
||||
@ -118,6 +119,7 @@ const setupNotifications = () => {
|
||||
PushNotifications.addListener('registration',
|
||||
(token) => {
|
||||
// alert('Push registration success, token: ' + token.value);
|
||||
registrationToken.value = token
|
||||
}
|
||||
);
|
||||
|
||||
@ -223,5 +225,5 @@ const logDeviceInfo = async () => {
|
||||
|
||||
const ledenlijst = ref([])
|
||||
|
||||
provide('firebase', { db, ledenlijst, isAuthenticated, user, userData, userPersons, auth, userAllPersons, getPersons, calEvents, news })
|
||||
provide('firebase', { db, ledenlijst, isAuthenticated, user, userData, userPersons, auth, userAllPersons, getPersons, calEvents, news, registrationToken })
|
||||
</script>
|
@ -17,6 +17,7 @@
|
||||
<span>Settings</span>
|
||||
<Icon class="ml-auto" size="2em" name="ion:arrow-forward"/>
|
||||
</NuxtLink>
|
||||
{{ registrationToken }}
|
||||
</div>
|
||||
|
||||
</div>
|
||||
@ -27,5 +28,5 @@ definePageMeta({
|
||||
title: 'Home',
|
||||
})
|
||||
|
||||
const { userPersons } = inject('firebase')
|
||||
const { userPersons, registrationToken } = inject('firebase')
|
||||
</script>
|
||||
|
Loading…
Reference in New Issue
Block a user