Sort gallery media by capture date instead of file name
All checks were successful
Docker / build (release) Successful in 9s

This commit is contained in:
krek0 2026-09-24 12:52:50 +02:00
parent 2f0c426dc1
commit f7415fb5f6
11 changed files with 314 additions and 33 deletions

View file

@ -99,6 +99,8 @@ async function uploadFile(file, galleryID, csrfvalue, ownerID) {
const sendform = new FormData();
sendform.append('csrfmiddlewaretoken', csrfvalue);
sendform.append('file_field', file);
// The capture date is often missing from the metadata but present here.
if (file.lastModified) sendform.append('file_modified', file.lastModified);
sendform.append('gallery', galleryID);
if (ownerID) sendform.append('owner', ownerID);
const start = performance.now();