You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Thinking ahead to field use, when one is doing repeated observations, having photos and site data saved on device is almost essential, as many sites will be off-network. To accurately repeat photo framing for example, and sometimes transect photos are essential in relocating transects and other observations.
Could the filesystem API be accessed through wq stack? How?
The text was updated successfully, but these errors were encountered:
Site data should be available offline already via the IndexedDB cache - the maps aren't working, but the data is there. I would envision storing photos in the same place (via wq/store.js), in one of two ways:
convert to base64-encoded thumbnails on the server, and add as a read-only field to observations.json. We could then reference the image via e.g. <img src="data:image/jpg,{{base64_data}}">
add some JavaScript that downloads the image as binary data and stores it, in a manner very similar to how photos in the outbox are saved and referenced (as Blob objects).
The filesystem is not easily accessible from websites due to security restrictions. You can get at the filesystem from within a PhoneGap/Cordova app, but I think we should be able to do what we need by storing Blobs and/or base64 images in IndexedDB via wq/store.js. The main benefit of the IndexedDB approach is that it works on the web and within Cordova, so we don't need separate code paths for each case. On the other hand, the FileSystem API might better match user expectations and could make integration with other native apps easier.
(For browsers that don't support IndexedDB, the localForage library that powers wq/store.js will automatically use WebSQL or localStorage, as appropriate).
Would be great to be able to download a few observations into some kind of Stored Observations bin, viewable on the device via the app perhaps with a read-only template, with the ability to attach child observations to them.
Thinking ahead to field use, when one is doing repeated observations, having photos and site data saved on device is almost essential, as many sites will be off-network. To accurately repeat photo framing for example, and sometimes transect photos are essential in relocating transects and other observations.
Could the filesystem API be accessed through wq stack? How?
The text was updated successfully, but these errors were encountered: