- Converting all to Typescript

- Installing 1.0.0.beta Quasar Upgrade
   - (Part 1 - Upgrade Components)
This commit is contained in:
Paolo Arena
2019-03-11 19:21:10 +01:00
parent bb3be0ec16
commit 74ecc4f278
46 changed files with 5986 additions and 0 deletions

View File

@@ -0,0 +1,24 @@
import indexdb from './indexdb'
import { GlobalStore } from "../store/Modules";
export default async (context, cmd, table, data = null, id = '') => {
const descr = data !== null ? data.descr : ''
// console.log('globalroutines', cmd, table, descr, id)
return await indexdb(context, cmd, table, data, id)
.then(ris => {
setTimeout(function () {
GlobalStore.state.connData.uploading_indexeddb = 0
GlobalStore.state.connData.downloading_indexeddb = 0
}, 1000)
return ris
}
).catch(err => {
setTimeout(function () {
GlobalStore.state.connData.uploading_indexeddb = (GlobalStore.state.connData.uploading_indexeddb === 1) ? -1 : GlobalStore.state.connData.uploading_indexeddb
GlobalStore.state.connData.downloading_indexeddb = (GlobalStore.state.connData.downloading_indexeddb === 1) ? -1 : GlobalStore.state.connData.downloading_indexeddb
}, 1000)
console.log('ERROR INDEXEDDB: ', err)
})
}