Open codyswanner opened 1 month ago
Django will almost certainly not be able to access that information directly on the system -- the browser is sandboxed for good reasons. Not sure if that metadata can be passed/requested on upload... I'm skeptical, but this would be very cool if it is possible.
Something that will certainly be available is the timestamp of the upload to the app. Django may be tracking this already and I just need to ask for it, but even if not, it wouldn't be hard to add a field on the Image model for this. That said, I'm torn between the question of "is this useful" and the idea that if it's going to be useful, it needs to be a little more sophisticated than a string of digits indicating a time of upload. Does SQL have a date class that can be used for queries? Does Django? If it's possible to chunk images up by month (or year, or day, depending on the case) then that could be very useful, but it would require SQL or Django to have enough awareness of the system to query by it.
This needs more investigation.
When images are uploaded, is it possible to get information from the uploading device about created date and last-modified date?
If no, does Django have a way of accessing local last-modified information to sort images that way, after being uploaded?