emReset
Table of Contents
The emReset
service provides methods to reset (="clean") the local database.
Reset
The emReset.reset()
method removes all current user resources, including their database tables and schemas. This is an asynchronous process, so the method returns a then-able promise that can be used to restore the UI, e.g. by routing to another page.
emReset.reset().then(function(){ $state.go('index', {}, {location: 'replace', reload: true}); });
NB Reset is irreversible, all data that have not been uploaded to the server yet will be lost. Thus, when exposing it to the user, you will want to put this function behind a warning/confirmation dialog.
Last modified
5 years ago
Last modified on 07/05/19 08:21:16
Note:
See TracWiki
for help on using the wiki.