Closed drfaustusfade closed 3 years ago
@fakhrihawari could you please also test this out
cluster lists (or other heavy lists) will be stored on async browser db, with localforage,
that implementation is still using virtual ngmLists data service, but with an underlying store with localforage that is pulled on browser reload, added service ngmLocalDBLists.loadLists ( update:
For now the 'lists' data and 'organization'data store in browser db perfectly For this what scenario i should use to test it further?
alright, thank you, just to double-check that everything is fine
main functionality summary: on each reload ngmLocalDB loadVirtualDB service will run load data into ngmLists from localdb, ngmLocalDB.isVirtualDBLoaded promise could be used to route resolve ngmClusterLists.areListsFetched function can be used to get promise for route resolve, or ngmClusterLists.areListsLoading function to check if list loading flag is on ngmLocalDB is wrapper service for localforage ngmLocalDBLists is module facade for ngmLocalDB if specific functionality for a module is needed ngmLocalDB functions could have virtual, fetch flags to indicate is ngmLists should be set and if data should be returned with bind it is possible to set to scope with loadItem to load into ngmLists if not on it also setItem, getItem, removeItem, keys, clear all functions return promises
updated DEV and PROD
Use localforage (indexdb) as db for lists to overcome 5 MB local storage limit
https://github.com/drfaustusfade/ngm-reportHub/pull/37