Add ability to disconnect Slack channel from compliance page
Users could connect a Slack channel to their compliance page but had no way to remove or change the connection afterward. This adds a disconnect button with a confirmation dialog next to connected Slack channels. - GraphQL: deleteSlackConnection mutation with resolver - Frontend: Disconnect button using useMutation with @deleteEdge Signed-off-by: Sacha Al Himdani <sacha@getprobo.com>
This commit is contained in:
@@ -2077,12 +2077,14 @@ type Organization implements Node {
|
||||
permission(action: String!): Boolean! @goField(forceResolver: true)
|
||||
}
|
||||
|
||||
type SlackConnection {
|
||||
type SlackConnection implements Node {
|
||||
id: ID!
|
||||
channel: String
|
||||
channelId: String
|
||||
createdAt: Datetime!
|
||||
updatedAt: Datetime!
|
||||
|
||||
permission(action: String!): Boolean! @goField(forceResolver: true)
|
||||
}
|
||||
|
||||
type SlackConnectionConnection {
|
||||
@@ -3944,6 +3946,10 @@ type Mutation {
|
||||
deleteCustomDomain(
|
||||
input: DeleteCustomDomainInput!
|
||||
): DeleteCustomDomainPayload!
|
||||
# Slack Connection mutations
|
||||
deleteSlackConnection(
|
||||
input: DeleteSlackConnectionInput!
|
||||
): DeleteSlackConnectionPayload!
|
||||
}
|
||||
|
||||
# Input Types
|
||||
@@ -6096,6 +6102,14 @@ type DeleteCustomDomainPayload {
|
||||
deletedCustomDomainId: ID!
|
||||
}
|
||||
|
||||
input DeleteSlackConnectionInput {
|
||||
slackConnectionId: ID!
|
||||
}
|
||||
|
||||
type DeleteSlackConnectionPayload {
|
||||
deletedSlackConnectionId: ID!
|
||||
}
|
||||
|
||||
# Electronic Signature
|
||||
|
||||
enum ElectronicSignatureStatus
|
||||
|
||||
Reference in New Issue
Block a user