mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-08-01 01:29:31 +08:00
feat: shared link list (#14200)
#### PR Dependency Tree * **PR #14200** 👈 This tree was auto-generated by [Charcoal](https://github.com/danerwilliams/charcoal) <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit ## Release Notes * **New Features** * Added a "Shared Links" panel to workspace management, enabling admins to view all published documents within a workspace * Added publication date tracking for published documents, now displayed alongside shared links * **Chores** * Removed deprecated `publicPages` field; use `publicDocs` instead <sub>✏️ Tip: You can customize this high-level summary in your review settings.</sub> <!-- end of auto-generated comment: release notes by coderabbit.ai -->
This commit is contained in:
+12
@@ -0,0 +1,12 @@
|
||||
-- Add published_at to workspace_pages to track when a doc was shared
|
||||
ALTER TABLE "workspace_pages"
|
||||
ADD COLUMN IF NOT EXISTS "published_at" TIMESTAMPTZ(3);
|
||||
|
||||
-- Backfill existing public docs using the snapshot updated_at
|
||||
UPDATE "workspace_pages" wp
|
||||
SET "published_at" = s."updated_at"
|
||||
FROM "snapshots" s
|
||||
WHERE wp."workspace_id" = s."workspace_id"
|
||||
AND wp."page_id" = s."guid"
|
||||
AND wp."public" = TRUE
|
||||
AND wp."published_at" IS NULL;
|
||||
Reference in New Issue
Block a user