Repository navigation
Trash for deleted forms and responses, fresh dashboard, in-app Android updates - #13
Merged
Merged
Conversation
…t away Trash (Settings → Trash, admins) - Deleting a form or responses now copies them to a new TrashItem table (form + responses + access list, or one response) and then deletes them as before, so no existing query had to change - Restore puts a form back with its responses and access; a response can be restored once its form exists. A form whose link/port/domain was taken meanwhile gets new ones - Delete forever / Empty Trash; anything older than 30 days is removed every hour. Uploaded files stay until an item leaves the Trash - Included in system backups (older backups still restore) - Delete dialogs now say items go to the Trash; Arabic and Tamil text added Dashboard - experimental.staleTimes.dynamic = 0: links no longer reuse a page seen in the last 30 s, so a form created in the builder shows on the dashboard without a reload
- Once a day on start (and on demand) the app asks GitHub for the latest release; if it is newer and has FormCraft.apk, it offers Update / Later - Update downloads the APK with a notification and opens Android's installer; the first time Android asks to allow "Install unknown apps" for FormCraft - "Check for updates" via a long-press app-icon shortcut and a link under the connect screen, which now also shows the app version - New permission: REQUEST_INSTALL_PACKAGES (nothing installs without a tap) - README: how updates work and how to publish one (same signing key)
- Finds an existing installation before anything else: the FormCraft container's compose folder, then this folder, ./formcraft, ~/formcraft, /root/formcraft, /opt/formcraft, /srv/formcraft. Before, running the one-liner from another folder started a second, fresh install - Update refreshes the compose files (old ones kept as *.bak; git checkouts keep theirs), pulls, restarts, removes the replaced image, waits for health - Says whether it updated or was already the newest version
This was referenced Nov 19, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changed
Dashboard shows new forms right away
experimental.staleTimes.dynamic = 0innext.config.mjs. Next.js 14 re-used a page seen in the last 30 s on link navigation, so a form created in the builder was missing from the dashboard until a reload. Every page here is live data, so navigations now always ask the server (the branded loading screen covers the wait).Trash (Settings → Trash, admins)
TrashItemtable. Deleting a form or responses first copies them there as JSON (a form with its responses and access list, or one response), then deletes them as before. No existing query had to learn about "deleted" rows.backfillLinks). A response can be restored only when its form exists; the UI says to restore the form first.startTrashPurgeinlib/startup.ts). Uploaded files stay on disk until an item leaves the Trash; deleting a form for good also removes its trashed responses.trashItemtable). Older backups without it still restore.Android app updates itself
AppUpdater.java: once a day on start (and on demand) it reads the latest GitHub release; if the tag is newer than the installed version and the release hasFormCraft.apk, it offers Update / Later, downloads with DownloadManager and opens the installer via FileProvider. First time, Android asks to allow "Install unknown apps".REQUEST_INSTALL_PACKAGES. README documents how to publish an update.Testing
tsc --noEmitpasses; APK builds (mobile\scripts\build-apk.ps1).FormCraft.apkto offer an update.Notes for review
TrashItemmodel only (no changes to existing tables). The Docker entrypoint'sprisma db pushcreates it on start.