Files
freeplanet/src/classes/routinestd.ts
Paolo Arena 818a7a4289 - dialog confirm delete item
- fix: context-menu (right click) declared only once and using twice using:
  @click.native="$refs.popover.$refs.popup.show()"
2019-01-29 23:13:28 +01:00

19 lines
392 B
TypeScript

export async function askConfirm($q: any, mytitle, mytext, ok, cancel) {
try {
return await $q.dialog({
title: mytitle,
message: mytext,
ok: ok,
cancel: cancel
}).then((ris) => {
return true
// this.$q.notify('Agreed!')
}).catch(() => {
return false
// this.$q.notify('Disagreed...')
})
} catch (e) {
return false
}
}