add default slack sharing permissions

This commit is contained in:
dal 2025-07-16 15:14:16 -06:00
parent 8221bca8de
commit e4630b5cd7
No known key found for this signature in database
GPG Key ID: 16F4B0E1E9F61122
4 changed files with 6261 additions and 0 deletions

View File

@ -0,0 +1,2 @@
CREATE TYPE "public"."slack_sharing_permission_enum" AS ENUM('shareWithWorkspace', 'shareWithChannel', 'noSharing');--> statement-breakpoint
ALTER TABLE "slack_integrations" ADD COLUMN "default_sharing_permissions" "slack_sharing_permission_enum" DEFAULT 'shareWithChannel' NOT NULL;

File diff suppressed because it is too large Load Diff

View File

@ -561,6 +561,13 @@
"when": 1752686086591,
"tag": "0079_sloppy_red_skull",
"breakpoints": true
},
{
"idx": 80,
"version": "7",
"when": 1752700439888,
"tag": "0080_famous_emma_frost",
"breakpoints": true
}
]
}

View File

@ -97,6 +97,12 @@ export const slackChatAuthorizationEnum = pgEnum('slack_chat_authorization_enum'
'auto_added',
]);
export const slackSharingPermissionEnum = pgEnum('slack_sharing_permission_enum', [
'shareWithWorkspace',
'shareWithChannel',
'noSharing',
]);
export const apiKeys = pgTable(
'api_keys',
{
@ -1837,6 +1843,11 @@ export const slackIntegrations = pgTable(
.defaultNow()
.notNull(),
deletedAt: timestamp('deleted_at', { withTimezone: true, mode: 'string' }),
// Default Sharing Permissions in Slack
defaultSharingPermissions: slackSharingPermissionEnum('default_sharing_permissions')
.default('shareWithChannel')
.notNull(),
},
(table) => [
foreignKey({