mirror of
https://github.com/xCyanGrizzly/DragonsStash.git
synced 2026-07-22 23:12:02 +00:00
feat(db): add fetchEnabled flag to TopicProgress
Additive Postgres migration (default true) that backs the per-topic fetch enable/disable toggle. Existing rows backfill to enabled, so current behaviour is unchanged. Migration applied to the live DB via CI prisma migrate deploy (deferred, per environment). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,5 @@
|
|||||||
|
-- AlterTable: per-topic user-controlled fetch toggle (forum channels)
|
||||||
|
-- Additive, safe default (true) so existing rows backfill to "enabled" and
|
||||||
|
-- current behaviour is unchanged. Disabling is non-destructive.
|
||||||
|
ALTER TABLE "topic_progress"
|
||||||
|
ADD COLUMN "fetchEnabled" BOOLEAN NOT NULL DEFAULT true;
|
||||||
@@ -597,6 +597,11 @@ model TopicProgress {
|
|||||||
accountChannelMapId String
|
accountChannelMapId String
|
||||||
topicId BigInt
|
topicId BigInt
|
||||||
topicName String?
|
topicName String?
|
||||||
|
/// User-controlled fetch toggle. When false, the worker skips this topic
|
||||||
|
/// (no scanning, no fetching/transfer). Defaults true so every existing and
|
||||||
|
/// newly-discovered topic is fetched unless explicitly disabled. Disabling
|
||||||
|
/// is non-destructive — already-fetched packages are kept.
|
||||||
|
fetchEnabled Boolean @default(true)
|
||||||
lastProcessedMessageId BigInt?
|
lastProcessedMessageId BigInt?
|
||||||
/// When this topic was last scanned (any reason). Used by recency-skip.
|
/// When this topic was last scanned (any reason). Used by recency-skip.
|
||||||
lastScannedAt DateTime?
|
lastScannedAt DateTime?
|
||||||
|
|||||||
Reference in New Issue
Block a user