Corrected some logic problems...

4 storing:
  - Array in Memory Global state.todos
  - Array temporary filtered arr_todos
  - IndexedDb
  - Database
This commit is contained in:
Paolo Arena
2019-02-15 01:25:44 +01:00
parent 1af2c86067
commit cd0ec40441
11 changed files with 198 additions and 132 deletions

View File

@@ -43,10 +43,10 @@ export default class Home extends Vue {
set conta(valore) {
GlobalStore.actions.setConta(valore)
let my = this.$q.i18n.lang
this.showNotification(String(my))
this.showNotif(String(my))
}
showNotification(message: string, color = 'primary', icon = '') {
showNotif(message: string, color = 'primary', icon = '') {
this.$q.notify({
color,
icon,
@@ -158,15 +158,15 @@ export default class Home extends Vue {
}
askfornotification() {
this.showNotification(this.$t('notification.waitingconfirm'), 'positive', 'notifications')
this.showNotif(this.$t('notification.waitingconfirm'), 'positive', 'notifications')
let mythis = this
Notification.requestPermission(function (result) {
console.log('User Choice', result)
if (result === 'granted') {
mythis.showNotification(mythis.$t('notification.confirmed'), 'positive', 'notifications')
mythis.showNotif(mythis.$t('notification.confirmed'), 'positive', 'notifications')
} else {
mythis.showNotification(mythis.$t('notification.denied'), 'negative', 'notifications')
mythis.showNotif(mythis.$t('notification.denied'), 'negative', 'notifications')
// displayConfirmNotification();
}