International-GNSS-Service / SLM

SiteLog Manager
https://igs-slm.rtfd.org
MIT License
9 stars 2 forks source link

Allow update from an upload to use the times specified in the file? #99

Open bckohan opened 2 months ago

bckohan commented 2 months ago

There is a use case where a log's "gold source" is an external system like EPN and the publish of the new log may happen later than the publish of the original log, but its still desirous to have the log times and filenames match.

I think the best approach here, is to allow the Date Prepared to drive the log index time and be updated from a log upload, but retain the current behavior when updating a log through the interface. This can be thought of as - log file uploads treat the uploaded log (and thus wherever it came from) as the gold source and log file edits treat the SLM as the gold source.

This is pretty tricky wrt to the archive index which needs to maintain consistent time order - the original decision to lock this down on the system side was for editing convenience and to remove human error from the indexing workflow.

Another option might be to offer a per-station or per-agency toggle to enable/disable system control over "Date Prepared" and then drive the indexing off Date Prepared instead of now() during publish.