diff --git a/front/src/App.tsx b/front/src/App.tsx index 3d8dd82dd2c..6287f28d8ae 100644 --- a/front/src/App.tsx +++ b/front/src/App.tsx @@ -18,6 +18,8 @@ import { Opportunities } from '~/pages/opportunities/Opportunities'; import { People } from '~/pages/people/People'; import { SettingsProfile } from '~/pages/settings/SettingsProfile'; +import { CompanyShow } from './pages/companies/CompanyShow'; + /** * AuthRoutes is used to allow transitions between auth pages with framer-motion. */ @@ -60,6 +62,7 @@ export function App() { } /> } /> } /> + } /> } /> ; }; +export type ClientConfig = { + __typename?: 'ClientConfig'; + display_google_login: Scalars['Boolean']; + prefill_login_with_seed: Scalars['Boolean']; +}; + export type Comment = { __typename?: 'Comment'; author: User; @@ -129,18 +136,24 @@ export type CommentScalarWhereInput = { export type CommentThread = { __typename?: 'CommentThread'; + authorId?: Maybe; + body?: Maybe; commentThreadTargets?: Maybe>; comments?: Maybe>; createdAt: Scalars['DateTime']; id: Scalars['ID']; + title?: Maybe; updatedAt: Scalars['DateTime']; }; export type CommentThreadCreateInput = { + authorId?: InputMaybe; + body?: InputMaybe; commentThreadTargets?: InputMaybe; comments?: InputMaybe; createdAt?: InputMaybe; id?: InputMaybe; + title?: InputMaybe; updatedAt?: InputMaybe; }; @@ -149,10 +162,13 @@ export type CommentThreadCreateNestedOneWithoutCommentsInput = { }; export type CommentThreadOrderByWithRelationInput = { + authorId?: InputMaybe; + body?: InputMaybe; commentThreadTargets?: InputMaybe; comments?: InputMaybe; createdAt?: InputMaybe; id?: InputMaybe; + title?: InputMaybe; updatedAt?: InputMaybe; }; @@ -162,9 +178,12 @@ export type CommentThreadRelationFilter = { }; export enum CommentThreadScalarFieldEnum { + AuthorId = 'authorId', + Body = 'body', CreatedAt = 'createdAt', DeletedAt = 'deletedAt', Id = 'id', + Title = 'title', UpdatedAt = 'updatedAt', WorkspaceId = 'workspaceId' } @@ -296,10 +315,13 @@ export type CommentThreadTargetWhereUniqueInput = { }; export type CommentThreadUpdateInput = { + authorId?: InputMaybe; + body?: InputMaybe; commentThreadTargets?: InputMaybe; comments?: InputMaybe; createdAt?: InputMaybe; id?: InputMaybe; + title?: InputMaybe; updatedAt?: InputMaybe; }; @@ -307,10 +329,13 @@ export type CommentThreadWhereInput = { AND?: InputMaybe>; NOT?: InputMaybe>; OR?: InputMaybe>; + authorId?: InputMaybe; + body?: InputMaybe; commentThreadTargets?: InputMaybe; comments?: InputMaybe; createdAt?: InputMaybe; id?: InputMaybe; + title?: InputMaybe; updatedAt?: InputMaybe; }; @@ -647,6 +672,10 @@ export type EnumPipelineProgressableTypeFilter = { notIn?: InputMaybe>; }; +export enum FileFolder { + ProfilePicture = 'ProfilePicture' +} + export type IntNullableFilter = { equals?: InputMaybe; gt?: InputMaybe; @@ -697,6 +726,8 @@ export type Mutation = { updateOneCompany?: Maybe; updateOnePerson?: Maybe; updateOnePipelineProgress?: Maybe; + uploadFile: Scalars['String']; + uploadImage: Scalars['String']; verify: Verify; }; @@ -787,6 +818,18 @@ export type MutationUpdateOnePipelineProgressArgs = { }; +export type MutationUploadFileArgs = { + file: Scalars['Upload']; + fileFolder?: InputMaybe; +}; + + +export type MutationUploadImageArgs = { + file: Scalars['Upload']; + fileFolder?: InputMaybe; +}; + + export type MutationVerifyArgs = { loginToken: Scalars['String']; }; @@ -1230,6 +1273,7 @@ export type PipelineWhereUniqueInput = { export type Query = { __typename?: 'Query'; + clientConfig: ClientConfig; findManyCommentThreads: Array; findManyCompany: Array; findManyPerson: Array; @@ -1237,6 +1281,7 @@ export type Query = { findManyPipelineProgress: Array; findManyPipelineStage: Array; findManyUser: Array; + findUniqueCompany: Company; }; @@ -1309,6 +1354,11 @@ export type QueryFindManyUserArgs = { where?: InputMaybe; }; + +export type QueryFindUniqueCompanyArgs = { + id: Scalars['String']; +}; + export enum QueryMode { Default = 'default', Insensitive = 'insensitive' @@ -1392,7 +1442,6 @@ export type UserCreateWithoutCommentsInput = { companies?: InputMaybe; createdAt?: InputMaybe; disabled?: InputMaybe; - displayName?: InputMaybe; email: Scalars['String']; emailVerified?: InputMaybe; firstName: Scalars['String']; @@ -1411,7 +1460,6 @@ export type UserOrderByWithRelationInput = { companies?: InputMaybe; createdAt?: InputMaybe; disabled?: InputMaybe; - displayName?: InputMaybe; email?: InputMaybe; emailVerified?: InputMaybe; firstName?: InputMaybe; @@ -1434,7 +1482,6 @@ export enum UserScalarFieldEnum { CreatedAt = 'createdAt', DeletedAt = 'deletedAt', Disabled = 'disabled', - DisplayName = 'displayName', Email = 'email', EmailVerified = 'emailVerified', FirstName = 'firstName', @@ -1465,7 +1512,6 @@ export type UserUpdateWithoutCommentsInput = { companies?: InputMaybe; createdAt?: InputMaybe; disabled?: InputMaybe; - displayName?: InputMaybe; email?: InputMaybe; emailVerified?: InputMaybe; firstName?: InputMaybe; @@ -1492,7 +1538,6 @@ export type UserWhereInput = { companies?: InputMaybe; createdAt?: InputMaybe; disabled?: InputMaybe; - displayName?: InputMaybe; email?: InputMaybe; emailVerified?: InputMaybe; firstName?: InputMaybe; @@ -1552,6 +1597,11 @@ export type CreateEventMutationVariables = Exact<{ export type CreateEventMutation = { __typename?: 'Mutation', createEvent: { __typename?: 'Analytics', success: boolean } }; +export type GetClientConfigQueryVariables = Exact<{ [key: string]: never; }>; + + +export type GetClientConfigQuery = { __typename?: 'Query', clientConfig: { __typename?: 'ClientConfig', display_google_login: boolean, prefill_login_with_seed: boolean } }; + export type ChallengeMutationVariables = Exact<{ email: Scalars['String']; password: Scalars['String']; @@ -1565,7 +1615,7 @@ export type VerifyMutationVariables = Exact<{ }>; -export type VerifyMutation = { __typename?: 'Mutation', verify: { __typename?: 'Verify', user: { __typename?: 'User', id: string, email: string, displayName: string, workspaceMember?: { __typename?: 'WorkspaceMember', id: string, workspace: { __typename?: 'Workspace', id: string, domainName: string, displayName: string, logo?: string | null } } | null }, tokens: { __typename?: 'AuthTokenPair', accessToken: { __typename?: 'AuthToken', token: string, expiresAt: string }, refreshToken: { __typename?: 'AuthToken', token: string, expiresAt: string } } } }; +export type VerifyMutation = { __typename?: 'Mutation', verify: { __typename?: 'Verify', user: { __typename?: 'User', id: string, email: string, displayName: string, firstName: string, lastName: string, workspaceMember?: { __typename?: 'WorkspaceMember', id: string, workspace: { __typename?: 'Workspace', id: string, domainName: string, displayName: string, logo?: string | null } } | null }, tokens: { __typename?: 'AuthTokenPair', accessToken: { __typename?: 'AuthToken', token: string, expiresAt: string }, refreshToken: { __typename?: 'AuthToken', token: string, expiresAt: string } } } }; export type RenewTokenMutationVariables = Exact<{ refreshToken: Scalars['String']; @@ -1590,7 +1640,6 @@ export type CreateCommentThreadWithCommentMutationVariables = Exact<{ commentText: Scalars['String']; authorId: Scalars['String']; createdAt: Scalars['DateTime']; - commentId: Scalars['String']; commentThreadTargetArray: Array | CommentThreadTargetCreateManyCommentThreadInput; }>; @@ -1603,7 +1652,7 @@ export type GetCommentThreadsByTargetsQueryVariables = Exact<{ }>; -export type GetCommentThreadsByTargetsQuery = { __typename?: 'Query', findManyCommentThreads: Array<{ __typename?: 'CommentThread', id: string, comments?: Array<{ __typename?: 'Comment', id: string, body: string, createdAt: string, updatedAt: string, author: { __typename?: 'User', id: string, displayName: string, firstName: string, lastName: string, avatarUrl?: string | null } }> | null, commentThreadTargets?: Array<{ __typename?: 'CommentThreadTarget', id: string, commentableId: string, commentableType: CommentableType }> | null }> }; +export type GetCommentThreadsByTargetsQuery = { __typename?: 'Query', findManyCommentThreads: Array<{ __typename?: 'CommentThread', id: string, title?: string | null, body?: string | null, authorId?: string | null, comments?: Array<{ __typename?: 'Comment', id: string, body: string, createdAt: string, updatedAt: string, author: { __typename?: 'User', id: string, displayName: string, firstName: string, lastName: string, avatarUrl?: string | null } }> | null, commentThreadTargets?: Array<{ __typename?: 'CommentThreadTarget', id: string, commentableId: string, commentableType: CommentableType }> | null }> }; export type GetCommentThreadQueryVariables = Exact<{ commentThreadId: Scalars['String']; @@ -1646,6 +1695,13 @@ export type GetCompaniesQueryVariables = Exact<{ export type GetCompaniesQuery = { __typename?: 'Query', companies: Array<{ __typename?: 'Company', id: string, domainName: string, name: string, createdAt: string, address: string, employees?: number | null, _commentCount: number, accountOwner?: { __typename?: 'User', id: string, email: string, displayName: string, firstName: string, lastName: string } | null }> }; +export type GetCompanyQueryVariables = Exact<{ + id: Scalars['String']; +}>; + + +export type GetCompanyQuery = { __typename?: 'Query', findUniqueCompany: { __typename?: 'Company', id: string, domainName: string, name: string, createdAt: string, address: string, employees?: number | null, _commentCount: number, accountOwner?: { __typename?: 'User', id: string, email: string, displayName: string } | null } }; + export type UpdateCompanyMutationVariables = Exact<{ id?: InputMaybe; name?: InputMaybe; @@ -1678,39 +1734,6 @@ export type DeleteCompaniesMutationVariables = Exact<{ export type DeleteCompaniesMutation = { __typename?: 'Mutation', deleteManyCompany: { __typename?: 'AffectedRows', count: number } }; -export type GetPipelinesQueryVariables = Exact<{ - where?: InputMaybe; -}>; - - -export type GetPipelinesQuery = { __typename?: 'Query', findManyPipeline: Array<{ __typename?: 'Pipeline', id: string, name: string, pipelineProgressableType: PipelineProgressableType, pipelineStages?: Array<{ __typename?: 'PipelineStage', id: string, name: string, color: string, pipelineProgresses?: Array<{ __typename?: 'PipelineProgress', id: string, progressableType: PipelineProgressableType, progressableId: string }> | null }> | null }> }; - -export type UpdateOnePipelineProgressMutationVariables = Exact<{ - id?: InputMaybe; - pipelineStageId?: InputMaybe; -}>; - - -export type UpdateOnePipelineProgressMutation = { __typename?: 'Mutation', updateOnePipelineProgress?: { __typename?: 'PipelineProgress', id: string } | null }; - -export type CreateOnePipelineProgressMutationVariables = Exact<{ - uuid: Scalars['String']; - entityType: PipelineProgressableType; - entityId: Scalars['String']; - pipelineId: Scalars['String']; - pipelineStageId: Scalars['String']; -}>; - - -export type CreateOnePipelineProgressMutation = { __typename?: 'Mutation', createOnePipelineProgress: { __typename?: 'PipelineProgress', id: string } }; - -export type DeleteManyPipelineProgressMutationVariables = Exact<{ - ids?: InputMaybe | Scalars['String']>; -}>; - - -export type DeleteManyPipelineProgressMutation = { __typename?: 'Mutation', deleteManyPipelineProgress: { __typename?: 'AffectedRows', count: number } }; - export type GetPeopleQueryVariables = Exact<{ orderBy?: InputMaybe | PersonOrderByWithRelationInput>; where?: InputMaybe; @@ -1754,6 +1777,39 @@ export type DeletePeopleMutationVariables = Exact<{ export type DeletePeopleMutation = { __typename?: 'Mutation', deleteManyPerson: { __typename?: 'AffectedRows', count: number } }; +export type GetPipelinesQueryVariables = Exact<{ + where?: InputMaybe; +}>; + + +export type GetPipelinesQuery = { __typename?: 'Query', findManyPipeline: Array<{ __typename?: 'Pipeline', id: string, name: string, pipelineProgressableType: PipelineProgressableType, pipelineStages?: Array<{ __typename?: 'PipelineStage', id: string, name: string, color: string, pipelineProgresses?: Array<{ __typename?: 'PipelineProgress', id: string, progressableType: PipelineProgressableType, progressableId: string }> | null }> | null }> }; + +export type UpdateOnePipelineProgressMutationVariables = Exact<{ + id?: InputMaybe; + pipelineStageId?: InputMaybe; +}>; + + +export type UpdateOnePipelineProgressMutation = { __typename?: 'Mutation', updateOnePipelineProgress?: { __typename?: 'PipelineProgress', id: string } | null }; + +export type CreateOnePipelineProgressMutationVariables = Exact<{ + uuid: Scalars['String']; + entityType: PipelineProgressableType; + entityId: Scalars['String']; + pipelineId: Scalars['String']; + pipelineStageId: Scalars['String']; +}>; + + +export type CreateOnePipelineProgressMutation = { __typename?: 'Mutation', createOnePipelineProgress: { __typename?: 'PipelineProgress', id: string } }; + +export type DeleteManyPipelineProgressMutationVariables = Exact<{ + ids?: InputMaybe | Scalars['String']>; +}>; + + +export type DeleteManyPipelineProgressMutation = { __typename?: 'Mutation', deleteManyPipelineProgress: { __typename?: 'AffectedRows', count: number } }; + export type SearchPeopleQueryVariables = Exact<{ where?: InputMaybe; limit?: InputMaybe; @@ -1798,15 +1854,6 @@ export type GetUsersQueryVariables = Exact<{ [key: string]: never; }>; export type GetUsersQuery = { __typename?: 'Query', findManyUser: Array<{ __typename?: 'User', id: string, email: string, displayName: string, firstName: string, lastName: string }> }; -export type GetClientConfigQuery = { - __typename?: 'Query'; - clientConfig: { - __typename?: 'ClientConfig'; - display_google_login: boolean; - prefill_login_with_seed: boolean; - }; -}; -export type GetClientConfigQueryVariables = {}; export const CreateEventDocument = gql` mutation CreateEvent($type: String!, $data: JSON!) { @@ -1842,6 +1889,41 @@ export function useCreateEventMutation(baseOptions?: Apollo.MutationHookOptions< export type CreateEventMutationHookResult = ReturnType; export type CreateEventMutationResult = Apollo.MutationResult; export type CreateEventMutationOptions = Apollo.BaseMutationOptions; +export const GetClientConfigDocument = gql` + query GetClientConfig { + clientConfig { + display_google_login + prefill_login_with_seed + } +} + `; + +/** + * __useGetClientConfigQuery__ + * + * To run a query within a React component, call `useGetClientConfigQuery` and pass it any options that fit your needs. + * When your component renders, `useGetClientConfigQuery` returns an object from Apollo Client that contains loading, error, and data properties + * you can use to render your UI. + * + * @param baseOptions options that will be passed into the query, supported options are listed on: https://www.apollographql.com/docs/react/api/react-hooks/#options; + * + * @example + * const { data, loading, error } = useGetClientConfigQuery({ + * variables: { + * }, + * }); + */ +export function useGetClientConfigQuery(baseOptions?: Apollo.QueryHookOptions) { + const options = {...defaultOptions, ...baseOptions} + return Apollo.useQuery(GetClientConfigDocument, options); + } +export function useGetClientConfigLazyQuery(baseOptions?: Apollo.LazyQueryHookOptions) { + const options = {...defaultOptions, ...baseOptions} + return Apollo.useLazyQuery(GetClientConfigDocument, options); + } +export type GetClientConfigQueryHookResult = ReturnType; +export type GetClientConfigLazyQueryHookResult = ReturnType; +export type GetClientConfigQueryResult = Apollo.QueryResult; export const ChallengeDocument = gql` mutation Challenge($email: String!, $password: String!) { challenge(email: $email, password: $password) { @@ -1886,6 +1968,8 @@ export const VerifyDocument = gql` id email displayName + firstName + lastName workspaceMember { id workspace { @@ -2027,9 +2111,9 @@ export type CreateCommentMutationHookResult = ReturnType; export type CreateCommentMutationOptions = Apollo.BaseMutationOptions; export const CreateCommentThreadWithCommentDocument = gql` - mutation CreateCommentThreadWithComment($commentThreadId: String!, $commentText: String!, $authorId: String!, $createdAt: DateTime!, $commentId: String!, $commentThreadTargetArray: [CommentThreadTargetCreateManyCommentThreadInput!]!) { + mutation CreateCommentThreadWithComment($commentThreadId: String!, $commentText: String!, $authorId: String!, $createdAt: DateTime!, $commentThreadTargetArray: [CommentThreadTargetCreateManyCommentThreadInput!]!) { createOneCommentThread( - data: {id: $commentThreadId, createdAt: $createdAt, updatedAt: $createdAt, comments: {createMany: {data: {authorId: $authorId, id: $commentId, createdAt: $createdAt, body: $commentText}}}, commentThreadTargets: {createMany: {data: $commentThreadTargetArray, skipDuplicates: true}}} + data: {id: $commentThreadId, createdAt: $createdAt, updatedAt: $createdAt, authorId: $authorId, body: $commentText, commentThreadTargets: {createMany: {data: $commentThreadTargetArray, skipDuplicates: true}}} ) { id createdAt @@ -2073,7 +2157,6 @@ export type CreateCommentThreadWithCommentMutationFn = Apollo.MutationFunction; export type GetCompaniesLazyQueryHookResult = ReturnType; export type GetCompaniesQueryResult = Apollo.QueryResult; +export const GetCompanyDocument = gql` + query GetCompany($id: String!) { + findUniqueCompany(id: $id) { + id + domainName + name + createdAt + address + employees + _commentCount + accountOwner { + id + email + displayName + } + } +} + `; + +/** + * __useGetCompanyQuery__ + * + * To run a query within a React component, call `useGetCompanyQuery` and pass it any options that fit your needs. + * When your component renders, `useGetCompanyQuery` returns an object from Apollo Client that contains loading, error, and data properties + * you can use to render your UI. + * + * @param baseOptions options that will be passed into the query, supported options are listed on: https://www.apollographql.com/docs/react/api/react-hooks/#options; + * + * @example + * const { data, loading, error } = useGetCompanyQuery({ + * variables: { + * id: // value for 'id' + * }, + * }); + */ +export function useGetCompanyQuery(baseOptions: Apollo.QueryHookOptions) { + const options = {...defaultOptions, ...baseOptions} + return Apollo.useQuery(GetCompanyDocument, options); + } +export function useGetCompanyLazyQuery(baseOptions?: Apollo.LazyQueryHookOptions) { + const options = {...defaultOptions, ...baseOptions} + return Apollo.useLazyQuery(GetCompanyDocument, options); + } +export type GetCompanyQueryHookResult = ReturnType; +export type GetCompanyLazyQueryHookResult = ReturnType; +export type GetCompanyQueryResult = Apollo.QueryResult; export const UpdateCompanyDocument = gql` mutation UpdateCompany($id: String, $name: String, $domainName: String, $accountOwnerId: String, $createdAt: DateTime, $address: String, $employees: Int) { updateOneCompany( @@ -2503,162 +2635,6 @@ export function useDeleteCompaniesMutation(baseOptions?: Apollo.MutationHookOpti export type DeleteCompaniesMutationHookResult = ReturnType; export type DeleteCompaniesMutationResult = Apollo.MutationResult; export type DeleteCompaniesMutationOptions = Apollo.BaseMutationOptions; -export const GetPipelinesDocument = gql` - query GetPipelines($where: PipelineWhereInput) { - findManyPipeline(where: $where) { - id - name - pipelineProgressableType - pipelineStages { - id - name - color - pipelineProgresses { - id - progressableType - progressableId - } - } - } -} - `; - -/** - * __useGetPipelinesQuery__ - * - * To run a query within a React component, call `useGetPipelinesQuery` and pass it any options that fit your needs. - * When your component renders, `useGetPipelinesQuery` returns an object from Apollo Client that contains loading, error, and data properties - * you can use to render your UI. - * - * @param baseOptions options that will be passed into the query, supported options are listed on: https://www.apollographql.com/docs/react/api/react-hooks/#options; - * - * @example - * const { data, loading, error } = useGetPipelinesQuery({ - * variables: { - * where: // value for 'where' - * }, - * }); - */ -export function useGetPipelinesQuery(baseOptions?: Apollo.QueryHookOptions) { - const options = {...defaultOptions, ...baseOptions} - return Apollo.useQuery(GetPipelinesDocument, options); - } -export function useGetPipelinesLazyQuery(baseOptions?: Apollo.LazyQueryHookOptions) { - const options = {...defaultOptions, ...baseOptions} - return Apollo.useLazyQuery(GetPipelinesDocument, options); - } -export type GetPipelinesQueryHookResult = ReturnType; -export type GetPipelinesLazyQueryHookResult = ReturnType; -export type GetPipelinesQueryResult = Apollo.QueryResult; -export const UpdateOnePipelineProgressDocument = gql` - mutation UpdateOnePipelineProgress($id: String, $pipelineStageId: String) { - updateOnePipelineProgress( - where: {id: $id} - data: {pipelineStage: {connect: {id: $pipelineStageId}}} - ) { - id - } -} - `; -export type UpdateOnePipelineProgressMutationFn = Apollo.MutationFunction; - -/** - * __useUpdateOnePipelineProgressMutation__ - * - * To run a mutation, you first call `useUpdateOnePipelineProgressMutation` within a React component and pass it any options that fit your needs. - * When your component renders, `useUpdateOnePipelineProgressMutation` returns a tuple that includes: - * - A mutate function that you can call at any time to execute the mutation - * - An object with fields that represent the current status of the mutation's execution - * - * @param baseOptions options that will be passed into the mutation, supported options are listed on: https://www.apollographql.com/docs/react/api/react-hooks/#options-2; - * - * @example - * const [updateOnePipelineProgressMutation, { data, loading, error }] = useUpdateOnePipelineProgressMutation({ - * variables: { - * id: // value for 'id' - * pipelineStageId: // value for 'pipelineStageId' - * }, - * }); - */ -export function useUpdateOnePipelineProgressMutation(baseOptions?: Apollo.MutationHookOptions) { - const options = {...defaultOptions, ...baseOptions} - return Apollo.useMutation(UpdateOnePipelineProgressDocument, options); - } -export type UpdateOnePipelineProgressMutationHookResult = ReturnType; -export type UpdateOnePipelineProgressMutationResult = Apollo.MutationResult; -export type UpdateOnePipelineProgressMutationOptions = Apollo.BaseMutationOptions; -export const CreateOnePipelineProgressDocument = gql` - mutation CreateOnePipelineProgress($uuid: String!, $entityType: PipelineProgressableType!, $entityId: String!, $pipelineId: String!, $pipelineStageId: String!) { - createOnePipelineProgress( - data: {id: $uuid, progressableType: $entityType, progressableId: $entityId, pipeline: {connect: {id: $pipelineId}}, pipelineStage: {connect: {id: $pipelineStageId}}} - ) { - id - } -} - `; -export type CreateOnePipelineProgressMutationFn = Apollo.MutationFunction; - -/** - * __useCreateOnePipelineProgressMutation__ - * - * To run a mutation, you first call `useCreateOnePipelineProgressMutation` within a React component and pass it any options that fit your needs. - * When your component renders, `useCreateOnePipelineProgressMutation` returns a tuple that includes: - * - A mutate function that you can call at any time to execute the mutation - * - An object with fields that represent the current status of the mutation's execution - * - * @param baseOptions options that will be passed into the mutation, supported options are listed on: https://www.apollographql.com/docs/react/api/react-hooks/#options-2; - * - * @example - * const [createOnePipelineProgressMutation, { data, loading, error }] = useCreateOnePipelineProgressMutation({ - * variables: { - * uuid: // value for 'uuid' - * entityType: // value for 'entityType' - * entityId: // value for 'entityId' - * pipelineId: // value for 'pipelineId' - * pipelineStageId: // value for 'pipelineStageId' - * }, - * }); - */ -export function useCreateOnePipelineProgressMutation(baseOptions?: Apollo.MutationHookOptions) { - const options = {...defaultOptions, ...baseOptions} - return Apollo.useMutation(CreateOnePipelineProgressDocument, options); - } -export type CreateOnePipelineProgressMutationHookResult = ReturnType; -export type CreateOnePipelineProgressMutationResult = Apollo.MutationResult; -export type CreateOnePipelineProgressMutationOptions = Apollo.BaseMutationOptions; -export const DeleteManyPipelineProgressDocument = gql` - mutation DeleteManyPipelineProgress($ids: [String!]) { - deleteManyPipelineProgress(where: {id: {in: $ids}}) { - count - } -} - `; -export type DeleteManyPipelineProgressMutationFn = Apollo.MutationFunction; - -/** - * __useDeleteManyPipelineProgressMutation__ - * - * To run a mutation, you first call `useDeleteManyPipelineProgressMutation` within a React component and pass it any options that fit your needs. - * When your component renders, `useDeleteManyPipelineProgressMutation` returns a tuple that includes: - * - A mutate function that you can call at any time to execute the mutation - * - An object with fields that represent the current status of the mutation's execution - * - * @param baseOptions options that will be passed into the mutation, supported options are listed on: https://www.apollographql.com/docs/react/api/react-hooks/#options-2; - * - * @example - * const [deleteManyPipelineProgressMutation, { data, loading, error }] = useDeleteManyPipelineProgressMutation({ - * variables: { - * ids: // value for 'ids' - * }, - * }); - */ -export function useDeleteManyPipelineProgressMutation(baseOptions?: Apollo.MutationHookOptions) { - const options = {...defaultOptions, ...baseOptions} - return Apollo.useMutation(DeleteManyPipelineProgressDocument, options); - } -export type DeleteManyPipelineProgressMutationHookResult = ReturnType; -export type DeleteManyPipelineProgressMutationResult = Apollo.MutationResult; -export type DeleteManyPipelineProgressMutationOptions = Apollo.BaseMutationOptions; export const GetPeopleDocument = gql` query GetPeople($orderBy: [PersonOrderByWithRelationInput!], $where: PersonWhereInput, $limit: Int) { people: findManyPerson(orderBy: $orderBy, where: $where, take: $limit) { @@ -2847,6 +2823,162 @@ export function useDeletePeopleMutation(baseOptions?: Apollo.MutationHookOptions export type DeletePeopleMutationHookResult = ReturnType; export type DeletePeopleMutationResult = Apollo.MutationResult; export type DeletePeopleMutationOptions = Apollo.BaseMutationOptions; +export const GetPipelinesDocument = gql` + query GetPipelines($where: PipelineWhereInput) { + findManyPipeline(where: $where) { + id + name + pipelineProgressableType + pipelineStages { + id + name + color + pipelineProgresses { + id + progressableType + progressableId + } + } + } +} + `; + +/** + * __useGetPipelinesQuery__ + * + * To run a query within a React component, call `useGetPipelinesQuery` and pass it any options that fit your needs. + * When your component renders, `useGetPipelinesQuery` returns an object from Apollo Client that contains loading, error, and data properties + * you can use to render your UI. + * + * @param baseOptions options that will be passed into the query, supported options are listed on: https://www.apollographql.com/docs/react/api/react-hooks/#options; + * + * @example + * const { data, loading, error } = useGetPipelinesQuery({ + * variables: { + * where: // value for 'where' + * }, + * }); + */ +export function useGetPipelinesQuery(baseOptions?: Apollo.QueryHookOptions) { + const options = {...defaultOptions, ...baseOptions} + return Apollo.useQuery(GetPipelinesDocument, options); + } +export function useGetPipelinesLazyQuery(baseOptions?: Apollo.LazyQueryHookOptions) { + const options = {...defaultOptions, ...baseOptions} + return Apollo.useLazyQuery(GetPipelinesDocument, options); + } +export type GetPipelinesQueryHookResult = ReturnType; +export type GetPipelinesLazyQueryHookResult = ReturnType; +export type GetPipelinesQueryResult = Apollo.QueryResult; +export const UpdateOnePipelineProgressDocument = gql` + mutation UpdateOnePipelineProgress($id: String, $pipelineStageId: String) { + updateOnePipelineProgress( + where: {id: $id} + data: {pipelineStage: {connect: {id: $pipelineStageId}}} + ) { + id + } +} + `; +export type UpdateOnePipelineProgressMutationFn = Apollo.MutationFunction; + +/** + * __useUpdateOnePipelineProgressMutation__ + * + * To run a mutation, you first call `useUpdateOnePipelineProgressMutation` within a React component and pass it any options that fit your needs. + * When your component renders, `useUpdateOnePipelineProgressMutation` returns a tuple that includes: + * - A mutate function that you can call at any time to execute the mutation + * - An object with fields that represent the current status of the mutation's execution + * + * @param baseOptions options that will be passed into the mutation, supported options are listed on: https://www.apollographql.com/docs/react/api/react-hooks/#options-2; + * + * @example + * const [updateOnePipelineProgressMutation, { data, loading, error }] = useUpdateOnePipelineProgressMutation({ + * variables: { + * id: // value for 'id' + * pipelineStageId: // value for 'pipelineStageId' + * }, + * }); + */ +export function useUpdateOnePipelineProgressMutation(baseOptions?: Apollo.MutationHookOptions) { + const options = {...defaultOptions, ...baseOptions} + return Apollo.useMutation(UpdateOnePipelineProgressDocument, options); + } +export type UpdateOnePipelineProgressMutationHookResult = ReturnType; +export type UpdateOnePipelineProgressMutationResult = Apollo.MutationResult; +export type UpdateOnePipelineProgressMutationOptions = Apollo.BaseMutationOptions; +export const CreateOnePipelineProgressDocument = gql` + mutation CreateOnePipelineProgress($uuid: String!, $entityType: PipelineProgressableType!, $entityId: String!, $pipelineId: String!, $pipelineStageId: String!) { + createOnePipelineProgress( + data: {id: $uuid, progressableType: $entityType, progressableId: $entityId, pipeline: {connect: {id: $pipelineId}}, pipelineStage: {connect: {id: $pipelineStageId}}} + ) { + id + } +} + `; +export type CreateOnePipelineProgressMutationFn = Apollo.MutationFunction; + +/** + * __useCreateOnePipelineProgressMutation__ + * + * To run a mutation, you first call `useCreateOnePipelineProgressMutation` within a React component and pass it any options that fit your needs. + * When your component renders, `useCreateOnePipelineProgressMutation` returns a tuple that includes: + * - A mutate function that you can call at any time to execute the mutation + * - An object with fields that represent the current status of the mutation's execution + * + * @param baseOptions options that will be passed into the mutation, supported options are listed on: https://www.apollographql.com/docs/react/api/react-hooks/#options-2; + * + * @example + * const [createOnePipelineProgressMutation, { data, loading, error }] = useCreateOnePipelineProgressMutation({ + * variables: { + * uuid: // value for 'uuid' + * entityType: // value for 'entityType' + * entityId: // value for 'entityId' + * pipelineId: // value for 'pipelineId' + * pipelineStageId: // value for 'pipelineStageId' + * }, + * }); + */ +export function useCreateOnePipelineProgressMutation(baseOptions?: Apollo.MutationHookOptions) { + const options = {...defaultOptions, ...baseOptions} + return Apollo.useMutation(CreateOnePipelineProgressDocument, options); + } +export type CreateOnePipelineProgressMutationHookResult = ReturnType; +export type CreateOnePipelineProgressMutationResult = Apollo.MutationResult; +export type CreateOnePipelineProgressMutationOptions = Apollo.BaseMutationOptions; +export const DeleteManyPipelineProgressDocument = gql` + mutation DeleteManyPipelineProgress($ids: [String!]) { + deleteManyPipelineProgress(where: {id: {in: $ids}}) { + count + } +} + `; +export type DeleteManyPipelineProgressMutationFn = Apollo.MutationFunction; + +/** + * __useDeleteManyPipelineProgressMutation__ + * + * To run a mutation, you first call `useDeleteManyPipelineProgressMutation` within a React component and pass it any options that fit your needs. + * When your component renders, `useDeleteManyPipelineProgressMutation` returns a tuple that includes: + * - A mutate function that you can call at any time to execute the mutation + * - An object with fields that represent the current status of the mutation's execution + * + * @param baseOptions options that will be passed into the mutation, supported options are listed on: https://www.apollographql.com/docs/react/api/react-hooks/#options-2; + * + * @example + * const [deleteManyPipelineProgressMutation, { data, loading, error }] = useDeleteManyPipelineProgressMutation({ + * variables: { + * ids: // value for 'ids' + * }, + * }); + */ +export function useDeleteManyPipelineProgressMutation(baseOptions?: Apollo.MutationHookOptions) { + const options = {...defaultOptions, ...baseOptions} + return Apollo.useMutation(DeleteManyPipelineProgressDocument, options); + } +export type DeleteManyPipelineProgressMutationHookResult = ReturnType; +export type DeleteManyPipelineProgressMutationResult = Apollo.MutationResult; +export type DeleteManyPipelineProgressMutationOptions = Apollo.BaseMutationOptions; export const SearchPeopleDocument = gql` query SearchPeople($where: PersonWhereInput, $limit: Int, $orderBy: [PersonOrderByWithRelationInput!]) { searchResults: findManyPerson(where: $where, take: $limit, orderBy: $orderBy) { @@ -3089,39 +3221,4 @@ export function useGetUsersLazyQuery(baseOptions?: Apollo.LazyQueryHookOptions; export type GetUsersLazyQueryHookResult = ReturnType; -export type GetUsersQueryResult = Apollo.QueryResult; - -export const GET_CLIENT_CONFIG = gql` - query GetClientConfig { - clientConfig { - display_google_login - prefill_login_with_seed - } - } -`; - -export function useGetClientConfigQuery( - baseOptions?: Apollo.QueryHookOptions< - GetClientConfigQuery, - GetClientConfigQueryVariables - >, -) { - const options = { ...defaultOptions, ...baseOptions }; - return Apollo.useQuery( - GET_CLIENT_CONFIG, - options, - ); -} - -export function useGetClientConfigLazyQuery( - baseOptions?: Apollo.LazyQueryHookOptions< - GetClientConfigQuery, - GetClientConfigQueryVariables - >, -) { - const options = { ...defaultOptions, ...baseOptions }; - return Apollo.useLazyQuery< - GetClientConfigQuery, - GetClientConfigQueryVariables - >(GET_CLIENT_CONFIG, options); -} \ No newline at end of file +export type GetUsersQueryResult = Apollo.QueryResult; \ No newline at end of file diff --git a/front/src/modules/comments/components/CommentThreadCreateMode.tsx b/front/src/modules/comments/components/CommentThreadCreateMode.tsx index 98ba4c611a4..787f96382ee 100644 --- a/front/src/modules/comments/components/CommentThreadCreateMode.tsx +++ b/front/src/modules/comments/components/CommentThreadCreateMode.tsx @@ -91,7 +91,6 @@ export function CommentThreadCreateMode() { createCommentThreadWithComment({ variables: { authorId: currentUser.id, - commentId: v4(), commentText: commentText, commentThreadId: v4(), createdAt: new Date().toISOString(), diff --git a/front/src/modules/comments/components/CommentThreadRelationPicker.tsx b/front/src/modules/comments/components/CommentThreadRelationPicker.tsx index 66ad701e9e3..704375d24b5 100644 --- a/front/src/modules/comments/components/CommentThreadRelationPicker.tsx +++ b/front/src/modules/comments/components/CommentThreadRelationPicker.tsx @@ -216,6 +216,7 @@ export function CommentThreadRelationPicker({ commentThread }: OwnProps) { entity.entityType === CommentableType.Company ? ( diff --git a/front/src/modules/comments/components/RightDrawerCreateCommentThread.tsx b/front/src/modules/comments/components/RightDrawerCreateCommentThread.tsx index d099851a487..f1bfd3c5664 100644 --- a/front/src/modules/comments/components/RightDrawerCreateCommentThread.tsx +++ b/front/src/modules/comments/components/RightDrawerCreateCommentThread.tsx @@ -7,7 +7,7 @@ import { CommentThreadCreateMode } from './CommentThreadCreateMode'; export function RightDrawerCreateCommentThread() { return ( - + diff --git a/front/src/modules/comments/components/ShowPageComments.tsx b/front/src/modules/comments/components/ShowPageComments.tsx new file mode 100644 index 00000000000..eac1e19f8e9 --- /dev/null +++ b/front/src/modules/comments/components/ShowPageComments.tsx @@ -0,0 +1,65 @@ +import styled from '@emotion/styled'; + +import { CommentThreadForDrawer } from '@/comments/types/CommentThreadForDrawer'; +import { RightDrawerBody } from '@/ui/layout/right-drawer/components/RightDrawerBody'; +import { RightDrawerPage } from '@/ui/layout/right-drawer/components/RightDrawerPage'; +import { + SortOrder, + useGetCommentThreadsByTargetsQuery, +} from '~/generated/graphql'; + +import { CommentableEntity } from '../types/CommentableEntity'; + +import { CommentThread } from './CommentThread'; + +const StyledTopBar = styled.div` + align-items: center; + border-bottom: 1px solid ${({ theme }) => theme.border.color.light}; + color: ${({ theme }) => theme.font.color.secondary}; + display: flex; + flex-direction: row; + font-size: 13px; + justify-content: space-between; + min-height: 40px; + padding-left: 8px; + padding-right: 8px; +`; + +const StyledTopBarTitle = styled.div` + align-items: center; + font-weight: 500; + margin-right: ${({ theme }) => theme.spacing(1)}; +`; + +export function ShowPageComments({ + commentableEntity, +}: { + commentableEntity?: CommentableEntity; +}) { + const { data: queryResult } = useGetCommentThreadsByTargetsQuery({ + variables: { + commentThreadTargetIds: commentableEntity ? [commentableEntity.id] : [], + orderBy: [ + { + createdAt: SortOrder.Desc, + }, + ], + }, + }); + + const commentThreads: CommentThreadForDrawer[] = + queryResult?.findManyCommentThreads ?? []; + + return ( + + + Timeline + + + {commentThreads.map((commentThread) => ( + + ))} + + + ); +} diff --git a/front/src/modules/comments/services/create.ts b/front/src/modules/comments/services/create.ts index 83b721ab811..88b7b1029d7 100644 --- a/front/src/modules/comments/services/create.ts +++ b/front/src/modules/comments/services/create.ts @@ -38,7 +38,6 @@ export const CREATE_COMMENT_THREAD_WITH_COMMENT = gql` $commentText: String! $authorId: String! $createdAt: DateTime! - $commentId: String! $commentThreadTargetArray: [CommentThreadTargetCreateManyCommentThreadInput!]! ) { createOneCommentThread( @@ -46,16 +45,8 @@ export const CREATE_COMMENT_THREAD_WITH_COMMENT = gql` id: $commentThreadId createdAt: $createdAt updatedAt: $createdAt - comments: { - createMany: { - data: { - authorId: $authorId - id: $commentId - createdAt: $createdAt - body: $commentText - } - } - } + authorId: $authorId + body: $commentText commentThreadTargets: { createMany: { data: $commentThreadTargetArray, skipDuplicates: true } } diff --git a/front/src/modules/comments/services/select.ts b/front/src/modules/comments/services/select.ts index 694d1b15591..5653d3ca124 100644 --- a/front/src/modules/comments/services/select.ts +++ b/front/src/modules/comments/services/select.ts @@ -14,6 +14,9 @@ export const GET_COMMENT_THREADS_BY_TARGETS = gql` } ) { id + title + body + authorId comments { id body diff --git a/front/src/modules/companies/components/CompanyChip.tsx b/front/src/modules/companies/components/CompanyChip.tsx index a0f6a389cc6..9ae05d56efe 100644 --- a/front/src/modules/companies/components/CompanyChip.tsx +++ b/front/src/modules/companies/components/CompanyChip.tsx @@ -1,13 +1,15 @@ +import { Link } from 'react-router-dom'; import styled from '@emotion/styled'; import { Avatar } from '@/users/components/Avatar'; export type CompanyChipPropsType = { + id: string; name: string; picture?: string; }; -const StyledContainer = styled.span` +const StyledContainer = styled(Link)` align-items: center; background-color: ${({ theme }) => theme.background.tertiary}; border-radius: ${({ theme }) => theme.spacing(1)}; @@ -16,9 +18,10 @@ const StyledContainer = styled.span` gap: ${({ theme }) => theme.spacing(1)}; height: calc(20px - 2 * ${({ theme }) => theme.spacing(1)}); overflow: hidden; - padding: ${({ theme }) => theme.spacing(1)}; + text-decoration: none; + user-select: none; :hover { @@ -38,9 +41,9 @@ const StyledName = styled.span` white-space: nowrap; `; -function CompanyChip({ name, picture }: CompanyChipPropsType) { +function CompanyChip({ id, name, picture }: CompanyChipPropsType) { return ( - + {picture && ( { updateCompany({ variables: { diff --git a/front/src/modules/companies/components/__stories__/CompanyChip.stories.tsx b/front/src/modules/companies/components/__stories__/CompanyChip.stories.tsx index 0d5439a0a8d..6f5a50feff4 100644 --- a/front/src/modules/companies/components/__stories__/CompanyChip.stories.tsx +++ b/front/src/modules/companies/components/__stories__/CompanyChip.stories.tsx @@ -33,7 +33,8 @@ export const SmallName: Story = { render: getRenderWrapperForComponent( , @@ -44,6 +45,7 @@ export const BigName: Story = { render: getRenderWrapperForComponent( diff --git a/front/src/modules/companies/services/index.ts b/front/src/modules/companies/services/index.ts index 18c6c2f7dd7..41161a6b18a 100644 --- a/front/src/modules/companies/services/index.ts +++ b/front/src/modules/companies/services/index.ts @@ -1,2 +1,3 @@ export * from './select'; +export * from './show'; export * from './update'; diff --git a/front/src/modules/companies/services/show.ts b/front/src/modules/companies/services/show.ts new file mode 100644 index 00000000000..1370b760b83 --- /dev/null +++ b/front/src/modules/companies/services/show.ts @@ -0,0 +1,26 @@ +import { gql } from '@apollo/client'; + +import { useGetCompanyQuery } from '~/generated/graphql'; + +export const GET_COMPANY = gql` + query GetCompany($id: String!) { + findUniqueCompany(id: $id) { + id + domainName + name + createdAt + address + employees + _commentCount + accountOwner { + id + email + displayName + } + } + } +`; + +export function useCompanyQuery(id: string) { + return useGetCompanyQuery({ variables: { id } }); +} diff --git a/front/src/modules/people/components/PeopleCompanyCell.tsx b/front/src/modules/people/components/PeopleCompanyCell.tsx index 6b34efba714..c55625831f6 100644 --- a/front/src/modules/people/components/PeopleCompanyCell.tsx +++ b/front/src/modules/people/components/PeopleCompanyCell.tsx @@ -28,6 +28,7 @@ export function PeopleCompanyCell({ people }: OwnProps) { } nonEditModeContent={ diff --git a/front/src/modules/ui/components/editable-cell/types/EditableChip.tsx b/front/src/modules/ui/components/editable-cell/types/EditableChip.tsx index 3c228b28016..70341cf78c6 100644 --- a/front/src/modules/ui/components/editable-cell/types/EditableChip.tsx +++ b/front/src/modules/ui/components/editable-cell/types/EditableChip.tsx @@ -6,12 +6,14 @@ import { textInputStyle } from '@/ui/themes/effects'; import { EditableCell } from '../EditableCell'; export type EditableChipProps = { + id: string; placeholder?: string; value: string; picture: string; changeHandler: (updated: string) => void; editModeHorizontalAlign?: 'left' | 'right'; ChipComponent: ComponentType<{ + id: string; name: string; picture: string; isOverlapped?: boolean; @@ -40,6 +42,7 @@ const RightContainer = styled.div` `; function EditableChip({ + id, value, placeholder, changeHandler, @@ -74,7 +77,7 @@ function EditableChip({ } nonEditModeContent={ - + {rightEndContents && rightEndContents.length > 0 && diff --git a/front/src/modules/ui/components/property-box/PropertyBox.tsx b/front/src/modules/ui/components/property-box/PropertyBox.tsx new file mode 100644 index 00000000000..87d675f26f7 --- /dev/null +++ b/front/src/modules/ui/components/property-box/PropertyBox.tsx @@ -0,0 +1,32 @@ +import styled from '@emotion/styled'; + +const StyledCompanyPropertyBox = styled.div` + align-items: flex-start; + align-self: stretch; + display: flex; + flex-direction: column; + gap: 8px; + padding: 0px 12px; +`; + +const StyledCompanyPropertyBoxContainer = styled.div` + align-items: flex-start; + align-self: stretch; + background: ${({ theme }) => theme.background.secondary}; + border: 1px solid ${({ theme }) => theme.border.color.medium}; + border-radius: 4px; + display: flex; + flex-direction: column; + gap: 2px; + padding: 4px 12px; +`; + +export function PropertyBox({ children }: { children: JSX.Element }) { + return ( + + + {children} + + + ); +} diff --git a/front/src/modules/ui/components/property-box/PropertyBoxItem.tsx b/front/src/modules/ui/components/property-box/PropertyBoxItem.tsx new file mode 100644 index 00000000000..1cbcb2ab391 --- /dev/null +++ b/front/src/modules/ui/components/property-box/PropertyBoxItem.tsx @@ -0,0 +1,73 @@ +import { ReactNode } from 'react'; +import styled from '@emotion/styled'; + +const StyledPropertyBoxItem = styled.div` + align-items: flex-start; + align-self: stretch; + display: flex; + gap: 4px; +`; + +const StyledIconContainer = styled.div` + align-items: center; + display: flex; + gap: 4px; + min-height: 32px; + + svg { + align-items: center; + color: ${({ theme }) => theme.font.color.tertiary}; + display: flex; + gap: 10px; + height: 16px; + justify-content: center; + width: 16px; + } +`; + +const StyledLabelContainer = styled.div` + align-content: flex-start; + align-items: center; + color: ${({ theme }) => theme.font.color.primary}; + display: flex; + flex: 1 0 0; + flex-wrap: wrap; + gap: 4px; + padding: 6px; + + div { + display: flex; + height: 20px; + padding: 0px 4px; + align-items: center; + gap: 4px; + } + + a { + color: ${({ theme }) => theme.font.color.primary}; + } +`; + +export function PropertyBoxItem({ + icon, + label, + value, + link, +}: { + icon: ReactNode; + label?: string; + value: string; + link?: string; +}) { + return ( + + + {icon} + {label} + + + {link ? {value} : <>{value}>} + + + ); +} diff --git a/front/src/modules/ui/icons/index.ts b/front/src/modules/ui/icons/index.ts index 94af123f820..e580d2e4c00 100644 --- a/front/src/modules/ui/icons/index.ts +++ b/front/src/modules/ui/icons/index.ts @@ -30,3 +30,4 @@ export { IconArrowUpRight } from '@tabler/icons-react'; export { IconBrandGoogle } from '@tabler/icons-react'; export { IconUpload } from '@tabler/icons-react'; export { IconFileUpload } from '@tabler/icons-react'; +export { IconChevronsRight } from '@tabler/icons-react'; diff --git a/front/src/modules/ui/layout/containers/ContentContainer.tsx b/front/src/modules/ui/layout/containers/ContentContainer.tsx index 4cbb3a0f0d6..304db8a6c10 100644 --- a/front/src/modules/ui/layout/containers/ContentContainer.tsx +++ b/front/src/modules/ui/layout/containers/ContentContainer.tsx @@ -30,13 +30,7 @@ type LeftContainerProps = { const LeftContainer = styled.div` display: flex; position: relative; - width: calc( - 100% - - ${(props) => - props.isRightDrawerOpen - ? `${props.theme.rightDrawerWidth} - ${props.theme.spacing(2)}` - : '0px'} - ); + width: 100%; `; export function ContentContainer({ children, topMargin }: OwnProps) { diff --git a/front/src/modules/ui/layout/right-drawer/components/RightDrawer.tsx b/front/src/modules/ui/layout/right-drawer/components/RightDrawer.tsx index 78292cff5c7..b358776b41a 100644 --- a/front/src/modules/ui/layout/right-drawer/components/RightDrawer.tsx +++ b/front/src/modules/ui/layout/right-drawer/components/RightDrawer.tsx @@ -11,17 +11,40 @@ import { rightDrawerPageState } from '../states/rightDrawerPageState'; import { RightDrawerRouter } from './RightDrawerRouter'; +const ClickableBackground = styled.div` + backdrop-filter: blur(1px); + height: 100%; + left: 0; + position: fixed; + top: 0; + width: 100%; + z-index: 9999; +`; + +const StyledContainer = styled.div` + background: white; + height: 100%; + overflow-x: hidden; + position: fixed; + right: 0; + top: 0; + transition: width 0.5s; + width: ${({ theme }) => theme.rightDrawerWidth}; + z-index: 10000; +`; const StyledRightDrawer = styled.div` display: flex; flex-direction: row; - width: ${({ theme }) => theme.rightDrawerWidth}; + width: 100%; `; export function RightDrawer() { const [, setCaptureHotkeyTypeInFocus] = useRecoilState( captureHotkeyTypeInFocusState, ); - const [isRightDrawerOpen] = useRecoilState(isRightDrawerOpenState); + const [isRightDrawerOpen, setIsRightDrawerOpen] = useRecoilState( + isRightDrawerOpenState, + ); const [rightDrawerPage] = useRecoilState(rightDrawerPageState); useEffect(() => { setCaptureHotkeyTypeInFocus(isRightDrawerOpen); @@ -31,10 +54,15 @@ export function RightDrawer() { } return ( - - - - - + <> + setIsRightDrawerOpen(false)} /> + + + + + + + + > ); } diff --git a/front/src/modules/ui/layout/right-drawer/components/RightDrawerTopBar.tsx b/front/src/modules/ui/layout/right-drawer/components/RightDrawerTopBar.tsx index 2eb4ea65067..b89dede43a2 100644 --- a/front/src/modules/ui/layout/right-drawer/components/RightDrawerTopBar.tsx +++ b/front/src/modules/ui/layout/right-drawer/components/RightDrawerTopBar.tsx @@ -1,5 +1,7 @@ import styled from '@emotion/styled'; +import { Button } from '@/ui/components/buttons/Button'; + import { RightDrawerTopBarCloseButton } from './RightDrawerTopBarCloseButton'; const StyledRightDrawerTopBar = styled.div` @@ -28,8 +30,9 @@ export function RightDrawerTopBar({ }) { return ( - {title} + {title} + ); } diff --git a/front/src/modules/ui/layout/right-drawer/components/RightDrawerTopBarCloseButton.tsx b/front/src/modules/ui/layout/right-drawer/components/RightDrawerTopBarCloseButton.tsx index 68e063892f9..b45dc82495e 100644 --- a/front/src/modules/ui/layout/right-drawer/components/RightDrawerTopBarCloseButton.tsx +++ b/front/src/modules/ui/layout/right-drawer/components/RightDrawerTopBarCloseButton.tsx @@ -1,7 +1,7 @@ import styled from '@emotion/styled'; import { useRecoilState } from 'recoil'; -import { IconPlus } from '@/ui/icons/index'; +import { IconChevronsRight } from '@/ui/icons/index'; import { isRightDrawerOpenState } from '../states/isRightDrawerOpenState'; @@ -24,7 +24,6 @@ const StyledButton = styled.button` } svg { color: ${({ theme }) => theme.font.color.tertiary}; - transform: rotate(45deg); } `; @@ -37,7 +36,7 @@ export function RightDrawerTopBarCloseButton() { return ( - + ); } diff --git a/front/src/modules/ui/themes/themes.ts b/front/src/modules/ui/themes/themes.ts index c969d37ee65..22eb1eb5b39 100644 --- a/front/src/modules/ui/themes/themes.ts +++ b/front/src/modules/ui/themes/themes.ts @@ -18,7 +18,7 @@ const common = { horizontalCellMargin: '8px', checkboxColumnWidth: '32px', }, - rightDrawerWidth: '300px', + rightDrawerWidth: '500px', clickableElementBackgroundTransition: 'background 0.1s ease', lastLayerZIndex: 2147483647, }; diff --git a/front/src/modules/users/components/Avatar.tsx b/front/src/modules/users/components/Avatar.tsx index aa125f557d3..66dd69b5672 100644 --- a/front/src/modules/users/components/Avatar.tsx +++ b/front/src/modules/users/components/Avatar.tsx @@ -16,8 +16,10 @@ export const StyledAvatar = styled.div>` !isNonEmptyString(props.avatarUrl) ? props.theme.background.tertiary : 'none'}; - background-image: url(${(props) => - isNonEmptyString(props.avatarUrl) ? props.avatarUrl : 'none'}); + ${(props) => + isNonEmptyString(props.avatarUrl) + ? `background-image: url(${props.avatarUrl});` + : ''} background-size: cover; border-radius: ${(props) => (props.type === 'rounded' ? '50%' : '2px')}; color: ${({ theme }) => theme.font.color.primary}; diff --git a/front/src/pages/companies/CompanyShow.tsx b/front/src/pages/companies/CompanyShow.tsx new file mode 100644 index 00000000000..3a8edf85369 --- /dev/null +++ b/front/src/pages/companies/CompanyShow.tsx @@ -0,0 +1,202 @@ +import { ReactNode } from 'react'; +import { useParams } from 'react-router-dom'; +import { Tooltip } from 'react-tooltip'; +import { useTheme } from '@emotion/react'; +import styled from '@emotion/styled'; + +import { ShowPageComments } from '@/comments/components/ShowPageComments'; +import { useCompanyQuery } from '@/companies/services'; +import { PropertyBox } from '@/ui/components/property-box/PropertyBox'; +import { PropertyBoxItem } from '@/ui/components/property-box/PropertyBoxItem'; +import { IconBuildingSkyscraper, IconLink, IconMap } from '@/ui/icons/index'; +import { WithTopBarContainer } from '@/ui/layout/containers/WithTopBarContainer'; +import { + beautifyExactDate, + beautifyPastDateRelativeToNow, +} from '@/utils/datetime/date-utils'; +import { getLogoUrlFromDomainName } from '@/utils/utils'; +import { CommentableType } from '~/generated/graphql'; + +const StyledCompanyContainer = styled.div` + align-items: center; + align-self: stretch; + background: ${({ theme }) => theme.background.primary}; + border: 1px solid ${({ theme }) => theme.border.color.medium}; + border-radius: 8px; + display: flex; + flex: 1 0 0; +`; + +const StyledLeftPanelContainer = styled.div` + align-items: flex-start; + align-self: stretch; + background: ${({ theme }) => theme.background.secondary}; + border-radius: 8px; + border-right: 1px solid ${({ theme }) => theme.border.color.light}; + padding: 0px ${({ theme }) => theme.spacing(3)}; + width: 320px; +`; + +const StyledRightPanelContainer = styled.div` + align-items: flex-start; + align-self: stretch; + display: flex; + flex: 1 0 0; + flex-direction: column; + justify-content: center; +`; + +export function CompanyShow() { + const companyId = useParams().companyId ?? ''; + + const { data } = useCompanyQuery(companyId); + const company = data?.findUniqueCompany; + + const theme = useTheme(); + + return ( + } + > + + + + + <> + } + value={company?.domainName ?? ''} + link={ + company?.domainName ? 'https://' + company?.domainName : '' + } + /> + } + value={company?.address ? company?.address : 'No address'} + /> + > + + + + + + + + ); +} + +/////////////////////////////////////////////////////////////// +/////////////////////////////////////////////////////////////// +/////////////////////////////////////////////////////////////// +/////////////////////////////////////////////////////////////// +/////////////////////////////////////////////////////////////// + +const StyledShowTopLeftImageContainer = styled.div` + align-items: center; + align-self: stretch; + display: flex; + flex-direction: column; + gap: 8px; + justify-content: center; + padding: ${({ theme }) => theme.spacing(6)} ${({ theme }) => theme.spacing(3)} + ${({ theme }) => theme.spacing(3)} ${({ theme }) => theme.spacing(3)}; +`; + +const StyledShowTopLeftImageInsideContainer = styled.div` + align-items: center; + display: flex; + flex-direction: column; + gap: 12px; + + img { + border-radius: 4px; + height: 40px; + width: 40px; + } + + div { + align-items: center; + display: flex; + flex-direction: column; + gap: 4px; + } +`; + +const StyledDate = styled.div` + color: ${({ theme }) => theme.font.color.tertiary}; +`; + +const StyledTitle = styled.div` + color: ${({ theme }) => theme.font.color.primary}; + font-size: 20px; + font-style: normal; + font-weight: 600; + line-height: 120%; +`; + +const StyledTooltip = styled(Tooltip)` + background-color: ${({ theme }) => theme.background.primary}; + + box-shadow: 0px 2px 4px 3px + ${({ theme }) => theme.background.transparent.light}; + + box-shadow: 2px 4px 16px 6px + ${({ theme }) => theme.background.transparent.light}; + + color: ${({ theme }) => theme.font.color.primary}; + + opacity: 1; + padding: 8px; +`; + +export function TopLeftHeaderOnShowPage({ + logo, + title, + date, +}: { + logo: string; + title: string; + date: string; +}) { + if (!date) { + return null; + } + const beautifiedCreatedAt = beautifyPastDateRelativeToNow(date); + const exactCreatedAt = beautifyExactDate(date); + + return ( + + + + + {title} + + Added {beautifiedCreatedAt} ago + + + + + + ); +} + +/////////////////////////////////////////////////////////////// +/////////////////////////////////////////////////////////////// +/////////////////////////////////////////////////////////////// +/////////////////////////////////////////////////////////////// +/////////////////////////////////////////////////////////////// diff --git a/server/src/core/@generated/comment-thread-target/create-many-comment-thread-target.args.ts b/server/src/core/@generated/comment-thread-target/create-many-comment-thread-target.args.ts index c2b72c0f208..409492ba519 100644 --- a/server/src/core/@generated/comment-thread-target/create-many-comment-thread-target.args.ts +++ b/server/src/core/@generated/comment-thread-target/create-many-comment-thread-target.args.ts @@ -9,8 +9,8 @@ export class CreateManyCommentThreadTargetArgs { @Field(() => [CommentThreadTargetCreateManyInput], {nullable:false}) @Type(() => CommentThreadTargetCreateManyInput) - @ValidateNested({each: true}) @Type(() => CommentThreadTargetCreateManyInput) + @ValidateNested({each: true}) data!: Array; @Field(() => Boolean, {nullable:true}) diff --git a/server/src/core/@generated/comment-thread-target/create-one-comment-thread-target.args.ts b/server/src/core/@generated/comment-thread-target/create-one-comment-thread-target.args.ts index 0e5ebee0511..d029ed70b45 100644 --- a/server/src/core/@generated/comment-thread-target/create-one-comment-thread-target.args.ts +++ b/server/src/core/@generated/comment-thread-target/create-one-comment-thread-target.args.ts @@ -9,7 +9,7 @@ export class CreateOneCommentThreadTargetArgs { @Field(() => CommentThreadTargetCreateInput, {nullable:false}) @Type(() => CommentThreadTargetCreateInput) - @ValidateNested({each: true}) @Type(() => CommentThreadTargetCreateInput) + @ValidateNested({each: true}) data!: CommentThreadTargetCreateInput; } diff --git a/server/src/core/@generated/comment-thread-target/update-many-comment-thread-target.args.ts b/server/src/core/@generated/comment-thread-target/update-many-comment-thread-target.args.ts index f2ac964981a..1865abdba4f 100644 --- a/server/src/core/@generated/comment-thread-target/update-many-comment-thread-target.args.ts +++ b/server/src/core/@generated/comment-thread-target/update-many-comment-thread-target.args.ts @@ -10,8 +10,8 @@ export class UpdateManyCommentThreadTargetArgs { @Field(() => CommentThreadTargetUpdateManyMutationInput, {nullable:false}) @Type(() => CommentThreadTargetUpdateManyMutationInput) - @ValidateNested({each: true}) @Type(() => CommentThreadTargetUpdateManyMutationInput) + @ValidateNested({each: true}) data!: CommentThreadTargetUpdateManyMutationInput; @Field(() => CommentThreadTargetWhereInput, {nullable:true}) diff --git a/server/src/core/@generated/comment-thread-target/update-one-comment-thread-target.args.ts b/server/src/core/@generated/comment-thread-target/update-one-comment-thread-target.args.ts index 7f083a66a8c..3d08745b3a6 100644 --- a/server/src/core/@generated/comment-thread-target/update-one-comment-thread-target.args.ts +++ b/server/src/core/@generated/comment-thread-target/update-one-comment-thread-target.args.ts @@ -10,8 +10,8 @@ export class UpdateOneCommentThreadTargetArgs { @Field(() => CommentThreadTargetUpdateInput, {nullable:false}) @Type(() => CommentThreadTargetUpdateInput) - @ValidateNested({each: true}) @Type(() => CommentThreadTargetUpdateInput) + @ValidateNested({each: true}) data!: CommentThreadTargetUpdateInput; @Field(() => CommentThreadTargetWhereUniqueInput, {nullable:false}) diff --git a/server/src/core/@generated/comment-thread/comment-thread-count-aggregate.input.ts b/server/src/core/@generated/comment-thread/comment-thread-count-aggregate.input.ts index 805d3a008fb..fa89ef4788e 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-count-aggregate.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-count-aggregate.input.ts @@ -11,6 +11,15 @@ export class CommentThreadCountAggregateInput { @HideField() workspaceId?: true; + @Field(() => Boolean, {nullable:true}) + authorId?: true; + + @Field(() => Boolean, {nullable:true}) + body?: true; + + @Field(() => Boolean, {nullable:true}) + title?: true; + @HideField() deletedAt?: true; diff --git a/server/src/core/@generated/comment-thread/comment-thread-count-aggregate.output.ts b/server/src/core/@generated/comment-thread/comment-thread-count-aggregate.output.ts index 26b41017512..ec5a1ea96c3 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-count-aggregate.output.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-count-aggregate.output.ts @@ -12,6 +12,15 @@ export class CommentThreadCountAggregate { @HideField() workspaceId!: number; + @Field(() => Int, {nullable:false}) + authorId!: number; + + @Field(() => Int, {nullable:false}) + body!: number; + + @Field(() => Int, {nullable:false}) + title!: number; + @HideField() deletedAt!: number; diff --git a/server/src/core/@generated/comment-thread/comment-thread-count-order-by-aggregate.input.ts b/server/src/core/@generated/comment-thread/comment-thread-count-order-by-aggregate.input.ts index 38f1f20d721..e062ece4e7a 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-count-order-by-aggregate.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-count-order-by-aggregate.input.ts @@ -12,6 +12,15 @@ export class CommentThreadCountOrderByAggregateInput { @HideField() workspaceId?: keyof typeof SortOrder; + @Field(() => SortOrder, {nullable:true}) + authorId?: keyof typeof SortOrder; + + @Field(() => SortOrder, {nullable:true}) + body?: keyof typeof SortOrder; + + @Field(() => SortOrder, {nullable:true}) + title?: keyof typeof SortOrder; + @HideField() deletedAt?: keyof typeof SortOrder; diff --git a/server/src/core/@generated/comment-thread/comment-thread-create-many-workspace.input.ts b/server/src/core/@generated/comment-thread/comment-thread-create-many-workspace.input.ts index df6c79416af..641cb4fe351 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-create-many-workspace.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-create-many-workspace.input.ts @@ -11,6 +11,15 @@ export class CommentThreadCreateManyWorkspaceInput { @Validator.IsOptional() id?: string; + @Field(() => String, {nullable:true}) + authorId?: string; + + @Field(() => String, {nullable:true}) + body?: string; + + @Field(() => String, {nullable:true}) + title?: string; + @HideField() deletedAt?: Date | string; diff --git a/server/src/core/@generated/comment-thread/comment-thread-create-many.input.ts b/server/src/core/@generated/comment-thread/comment-thread-create-many.input.ts index 776b619362c..37ae8307609 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-create-many.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-create-many.input.ts @@ -14,6 +14,15 @@ export class CommentThreadCreateManyInput { @HideField() workspaceId!: string; + @Field(() => String, {nullable:true}) + authorId?: string; + + @Field(() => String, {nullable:true}) + body?: string; + + @Field(() => String, {nullable:true}) + title?: string; + @HideField() deletedAt?: Date | string; diff --git a/server/src/core/@generated/comment-thread/comment-thread-create-without-comment-thread-targets.input.ts b/server/src/core/@generated/comment-thread/comment-thread-create-without-comment-thread-targets.input.ts index 6a41f970ea2..e0f0ba200f4 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-create-without-comment-thread-targets.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-create-without-comment-thread-targets.input.ts @@ -13,6 +13,15 @@ export class CommentThreadCreateWithoutCommentThreadTargetsInput { @Validator.IsOptional() id?: string; + @Field(() => String, {nullable:true}) + authorId?: string; + + @Field(() => String, {nullable:true}) + body?: string; + + @Field(() => String, {nullable:true}) + title?: string; + @HideField() deletedAt?: Date | string; diff --git a/server/src/core/@generated/comment-thread/comment-thread-create-without-comments.input.ts b/server/src/core/@generated/comment-thread/comment-thread-create-without-comments.input.ts index da829a51e85..376f768ae7f 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-create-without-comments.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-create-without-comments.input.ts @@ -13,6 +13,15 @@ export class CommentThreadCreateWithoutCommentsInput { @Validator.IsOptional() id?: string; + @Field(() => String, {nullable:true}) + authorId?: string; + + @Field(() => String, {nullable:true}) + body?: string; + + @Field(() => String, {nullable:true}) + title?: string; + @HideField() deletedAt?: Date | string; diff --git a/server/src/core/@generated/comment-thread/comment-thread-create-without-workspace.input.ts b/server/src/core/@generated/comment-thread/comment-thread-create-without-workspace.input.ts index 0b4a74ad6e2..fe3dd520a2e 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-create-without-workspace.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-create-without-workspace.input.ts @@ -13,6 +13,15 @@ export class CommentThreadCreateWithoutWorkspaceInput { @Validator.IsOptional() id?: string; + @Field(() => String, {nullable:true}) + authorId?: string; + + @Field(() => String, {nullable:true}) + body?: string; + + @Field(() => String, {nullable:true}) + title?: string; + @HideField() deletedAt?: Date | string; diff --git a/server/src/core/@generated/comment-thread/comment-thread-create.input.ts b/server/src/core/@generated/comment-thread/comment-thread-create.input.ts index ef2d51dc063..0414667a518 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-create.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-create.input.ts @@ -14,6 +14,15 @@ export class CommentThreadCreateInput { @Validator.IsOptional() id?: string; + @Field(() => String, {nullable:true}) + authorId?: string; + + @Field(() => String, {nullable:true}) + body?: string; + + @Field(() => String, {nullable:true}) + title?: string; + @HideField() deletedAt?: Date | string; diff --git a/server/src/core/@generated/comment-thread/comment-thread-group-by.output.ts b/server/src/core/@generated/comment-thread/comment-thread-group-by.output.ts index 885b78d14b9..bb5604163a6 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-group-by.output.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-group-by.output.ts @@ -17,6 +17,15 @@ export class CommentThreadGroupBy { @HideField() workspaceId!: string; + @Field(() => String, {nullable:true}) + authorId?: string; + + @Field(() => String, {nullable:true}) + body?: string; + + @Field(() => String, {nullable:true}) + title?: string; + @HideField() deletedAt?: Date | string; diff --git a/server/src/core/@generated/comment-thread/comment-thread-max-aggregate.input.ts b/server/src/core/@generated/comment-thread/comment-thread-max-aggregate.input.ts index 0a22e60e52a..19110d060c8 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-max-aggregate.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-max-aggregate.input.ts @@ -11,6 +11,15 @@ export class CommentThreadMaxAggregateInput { @HideField() workspaceId?: true; + @Field(() => Boolean, {nullable:true}) + authorId?: true; + + @Field(() => Boolean, {nullable:true}) + body?: true; + + @Field(() => Boolean, {nullable:true}) + title?: true; + @HideField() deletedAt?: true; diff --git a/server/src/core/@generated/comment-thread/comment-thread-max-aggregate.output.ts b/server/src/core/@generated/comment-thread/comment-thread-max-aggregate.output.ts index e76278c67a9..792e77c5af0 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-max-aggregate.output.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-max-aggregate.output.ts @@ -14,6 +14,15 @@ export class CommentThreadMaxAggregate { @HideField() workspaceId?: string; + @Field(() => String, {nullable:true}) + authorId?: string; + + @Field(() => String, {nullable:true}) + body?: string; + + @Field(() => String, {nullable:true}) + title?: string; + @HideField() deletedAt?: Date | string; diff --git a/server/src/core/@generated/comment-thread/comment-thread-max-order-by-aggregate.input.ts b/server/src/core/@generated/comment-thread/comment-thread-max-order-by-aggregate.input.ts index 77e00888aad..a0904e021d1 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-max-order-by-aggregate.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-max-order-by-aggregate.input.ts @@ -12,6 +12,15 @@ export class CommentThreadMaxOrderByAggregateInput { @HideField() workspaceId?: keyof typeof SortOrder; + @Field(() => SortOrder, {nullable:true}) + authorId?: keyof typeof SortOrder; + + @Field(() => SortOrder, {nullable:true}) + body?: keyof typeof SortOrder; + + @Field(() => SortOrder, {nullable:true}) + title?: keyof typeof SortOrder; + @HideField() deletedAt?: keyof typeof SortOrder; diff --git a/server/src/core/@generated/comment-thread/comment-thread-min-aggregate.input.ts b/server/src/core/@generated/comment-thread/comment-thread-min-aggregate.input.ts index 1e45c444c57..07e64e5a3eb 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-min-aggregate.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-min-aggregate.input.ts @@ -11,6 +11,15 @@ export class CommentThreadMinAggregateInput { @HideField() workspaceId?: true; + @Field(() => Boolean, {nullable:true}) + authorId?: true; + + @Field(() => Boolean, {nullable:true}) + body?: true; + + @Field(() => Boolean, {nullable:true}) + title?: true; + @HideField() deletedAt?: true; diff --git a/server/src/core/@generated/comment-thread/comment-thread-min-aggregate.output.ts b/server/src/core/@generated/comment-thread/comment-thread-min-aggregate.output.ts index 7f891925749..943fde8fc3e 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-min-aggregate.output.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-min-aggregate.output.ts @@ -14,6 +14,15 @@ export class CommentThreadMinAggregate { @HideField() workspaceId?: string; + @Field(() => String, {nullable:true}) + authorId?: string; + + @Field(() => String, {nullable:true}) + body?: string; + + @Field(() => String, {nullable:true}) + title?: string; + @HideField() deletedAt?: Date | string; diff --git a/server/src/core/@generated/comment-thread/comment-thread-min-order-by-aggregate.input.ts b/server/src/core/@generated/comment-thread/comment-thread-min-order-by-aggregate.input.ts index ffccd07a07c..4157c790bf6 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-min-order-by-aggregate.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-min-order-by-aggregate.input.ts @@ -12,6 +12,15 @@ export class CommentThreadMinOrderByAggregateInput { @HideField() workspaceId?: keyof typeof SortOrder; + @Field(() => SortOrder, {nullable:true}) + authorId?: keyof typeof SortOrder; + + @Field(() => SortOrder, {nullable:true}) + body?: keyof typeof SortOrder; + + @Field(() => SortOrder, {nullable:true}) + title?: keyof typeof SortOrder; + @HideField() deletedAt?: keyof typeof SortOrder; diff --git a/server/src/core/@generated/comment-thread/comment-thread-order-by-with-aggregation.input.ts b/server/src/core/@generated/comment-thread/comment-thread-order-by-with-aggregation.input.ts index 691a37d8ec3..8b14f681154 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-order-by-with-aggregation.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-order-by-with-aggregation.input.ts @@ -15,6 +15,15 @@ export class CommentThreadOrderByWithAggregationInput { @HideField() workspaceId?: keyof typeof SortOrder; + @Field(() => SortOrder, {nullable:true}) + authorId?: keyof typeof SortOrder; + + @Field(() => SortOrder, {nullable:true}) + body?: keyof typeof SortOrder; + + @Field(() => SortOrder, {nullable:true}) + title?: keyof typeof SortOrder; + @HideField() deletedAt?: keyof typeof SortOrder; diff --git a/server/src/core/@generated/comment-thread/comment-thread-order-by-with-relation.input.ts b/server/src/core/@generated/comment-thread/comment-thread-order-by-with-relation.input.ts index 820b616f151..40a2059e65d 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-order-by-with-relation.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-order-by-with-relation.input.ts @@ -15,6 +15,15 @@ export class CommentThreadOrderByWithRelationInput { @HideField() workspaceId?: keyof typeof SortOrder; + @Field(() => SortOrder, {nullable:true}) + authorId?: keyof typeof SortOrder; + + @Field(() => SortOrder, {nullable:true}) + body?: keyof typeof SortOrder; + + @Field(() => SortOrder, {nullable:true}) + title?: keyof typeof SortOrder; + @HideField() deletedAt?: keyof typeof SortOrder; diff --git a/server/src/core/@generated/comment-thread/comment-thread-scalar-field.enum.ts b/server/src/core/@generated/comment-thread/comment-thread-scalar-field.enum.ts index a4b02004a7c..8514803aae4 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-scalar-field.enum.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-scalar-field.enum.ts @@ -3,6 +3,9 @@ import { registerEnumType } from '@nestjs/graphql'; export enum CommentThreadScalarFieldEnum { id = "id", workspaceId = "workspaceId", + authorId = "authorId", + body = "body", + title = "title", deletedAt = "deletedAt", createdAt = "createdAt", updatedAt = "updatedAt" diff --git a/server/src/core/@generated/comment-thread/comment-thread-scalar-where-with-aggregates.input.ts b/server/src/core/@generated/comment-thread/comment-thread-scalar-where-with-aggregates.input.ts index 295edaa145f..60956bee4d9 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-scalar-where-with-aggregates.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-scalar-where-with-aggregates.input.ts @@ -2,6 +2,7 @@ import { Field } from '@nestjs/graphql'; import { InputType } from '@nestjs/graphql'; import { StringWithAggregatesFilter } from '../prisma/string-with-aggregates-filter.input'; import { HideField } from '@nestjs/graphql'; +import { StringNullableWithAggregatesFilter } from '../prisma/string-nullable-with-aggregates-filter.input'; import { DateTimeNullableWithAggregatesFilter } from '../prisma/date-time-nullable-with-aggregates-filter.input'; import { DateTimeWithAggregatesFilter } from '../prisma/date-time-with-aggregates-filter.input'; @@ -23,6 +24,15 @@ export class CommentThreadScalarWhereWithAggregatesInput { @HideField() workspaceId?: StringWithAggregatesFilter; + @Field(() => StringNullableWithAggregatesFilter, {nullable:true}) + authorId?: StringNullableWithAggregatesFilter; + + @Field(() => StringNullableWithAggregatesFilter, {nullable:true}) + body?: StringNullableWithAggregatesFilter; + + @Field(() => StringNullableWithAggregatesFilter, {nullable:true}) + title?: StringNullableWithAggregatesFilter; + @HideField() deletedAt?: DateTimeNullableWithAggregatesFilter; diff --git a/server/src/core/@generated/comment-thread/comment-thread-scalar-where.input.ts b/server/src/core/@generated/comment-thread/comment-thread-scalar-where.input.ts index 80585db9d9b..f88120aabf1 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-scalar-where.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-scalar-where.input.ts @@ -2,6 +2,7 @@ import { Field } from '@nestjs/graphql'; import { InputType } from '@nestjs/graphql'; import { StringFilter } from '../prisma/string-filter.input'; import { HideField } from '@nestjs/graphql'; +import { StringNullableFilter } from '../prisma/string-nullable-filter.input'; import { DateTimeNullableFilter } from '../prisma/date-time-nullable-filter.input'; import { DateTimeFilter } from '../prisma/date-time-filter.input'; @@ -23,6 +24,15 @@ export class CommentThreadScalarWhereInput { @HideField() workspaceId?: StringFilter; + @Field(() => StringNullableFilter, {nullable:true}) + authorId?: StringNullableFilter; + + @Field(() => StringNullableFilter, {nullable:true}) + body?: StringNullableFilter; + + @Field(() => StringNullableFilter, {nullable:true}) + title?: StringNullableFilter; + @HideField() deletedAt?: DateTimeNullableFilter; diff --git a/server/src/core/@generated/comment-thread/comment-thread-unchecked-create-without-comment-thread-targets.input.ts b/server/src/core/@generated/comment-thread/comment-thread-unchecked-create-without-comment-thread-targets.input.ts index 7a77e02ca08..d435ab711b8 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-unchecked-create-without-comment-thread-targets.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-unchecked-create-without-comment-thread-targets.input.ts @@ -15,6 +15,15 @@ export class CommentThreadUncheckedCreateWithoutCommentThreadTargetsInput { @HideField() workspaceId!: string; + @Field(() => String, {nullable:true}) + authorId?: string; + + @Field(() => String, {nullable:true}) + body?: string; + + @Field(() => String, {nullable:true}) + title?: string; + @HideField() deletedAt?: Date | string; diff --git a/server/src/core/@generated/comment-thread/comment-thread-unchecked-create-without-comments.input.ts b/server/src/core/@generated/comment-thread/comment-thread-unchecked-create-without-comments.input.ts index 23ad12f7199..a19053771a2 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-unchecked-create-without-comments.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-unchecked-create-without-comments.input.ts @@ -15,6 +15,15 @@ export class CommentThreadUncheckedCreateWithoutCommentsInput { @HideField() workspaceId!: string; + @Field(() => String, {nullable:true}) + authorId?: string; + + @Field(() => String, {nullable:true}) + body?: string; + + @Field(() => String, {nullable:true}) + title?: string; + @HideField() deletedAt?: Date | string; diff --git a/server/src/core/@generated/comment-thread/comment-thread-unchecked-create-without-workspace.input.ts b/server/src/core/@generated/comment-thread/comment-thread-unchecked-create-without-workspace.input.ts index 697f3100177..36657e8a2a8 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-unchecked-create-without-workspace.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-unchecked-create-without-workspace.input.ts @@ -13,6 +13,15 @@ export class CommentThreadUncheckedCreateWithoutWorkspaceInput { @Validator.IsOptional() id?: string; + @Field(() => String, {nullable:true}) + authorId?: string; + + @Field(() => String, {nullable:true}) + body?: string; + + @Field(() => String, {nullable:true}) + title?: string; + @HideField() deletedAt?: Date | string; diff --git a/server/src/core/@generated/comment-thread/comment-thread-unchecked-create.input.ts b/server/src/core/@generated/comment-thread/comment-thread-unchecked-create.input.ts index c67e5a29b7e..2733625b34a 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-unchecked-create.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-unchecked-create.input.ts @@ -16,6 +16,15 @@ export class CommentThreadUncheckedCreateInput { @HideField() workspaceId!: string; + @Field(() => String, {nullable:true}) + authorId?: string; + + @Field(() => String, {nullable:true}) + body?: string; + + @Field(() => String, {nullable:true}) + title?: string; + @HideField() deletedAt?: Date | string; diff --git a/server/src/core/@generated/comment-thread/comment-thread-unchecked-update-many-without-comment-threads.input.ts b/server/src/core/@generated/comment-thread/comment-thread-unchecked-update-many-without-comment-threads.input.ts index a8176bf8640..01d1fc79d35 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-unchecked-update-many-without-comment-threads.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-unchecked-update-many-without-comment-threads.input.ts @@ -1,6 +1,7 @@ import { Field } from '@nestjs/graphql'; import { InputType } from '@nestjs/graphql'; import { StringFieldUpdateOperationsInput } from '../prisma/string-field-update-operations.input'; +import { NullableStringFieldUpdateOperationsInput } from '../prisma/nullable-string-field-update-operations.input'; import { NullableDateTimeFieldUpdateOperationsInput } from '../prisma/nullable-date-time-field-update-operations.input'; import { HideField } from '@nestjs/graphql'; import { DateTimeFieldUpdateOperationsInput } from '../prisma/date-time-field-update-operations.input'; @@ -11,6 +12,15 @@ export class CommentThreadUncheckedUpdateManyWithoutCommentThreadsInput { @Field(() => StringFieldUpdateOperationsInput, {nullable:true}) id?: StringFieldUpdateOperationsInput; + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + authorId?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + body?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + title?: NullableStringFieldUpdateOperationsInput; + @HideField() deletedAt?: NullableDateTimeFieldUpdateOperationsInput; diff --git a/server/src/core/@generated/comment-thread/comment-thread-unchecked-update-many.input.ts b/server/src/core/@generated/comment-thread/comment-thread-unchecked-update-many.input.ts index e29d948537d..5d750564bbb 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-unchecked-update-many.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-unchecked-update-many.input.ts @@ -2,6 +2,7 @@ import { Field } from '@nestjs/graphql'; import { InputType } from '@nestjs/graphql'; import { StringFieldUpdateOperationsInput } from '../prisma/string-field-update-operations.input'; import { HideField } from '@nestjs/graphql'; +import { NullableStringFieldUpdateOperationsInput } from '../prisma/nullable-string-field-update-operations.input'; import { NullableDateTimeFieldUpdateOperationsInput } from '../prisma/nullable-date-time-field-update-operations.input'; import { DateTimeFieldUpdateOperationsInput } from '../prisma/date-time-field-update-operations.input'; @@ -14,6 +15,15 @@ export class CommentThreadUncheckedUpdateManyInput { @HideField() workspaceId?: StringFieldUpdateOperationsInput; + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + authorId?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + body?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + title?: NullableStringFieldUpdateOperationsInput; + @HideField() deletedAt?: NullableDateTimeFieldUpdateOperationsInput; diff --git a/server/src/core/@generated/comment-thread/comment-thread-unchecked-update-without-comment-thread-targets.input.ts b/server/src/core/@generated/comment-thread/comment-thread-unchecked-update-without-comment-thread-targets.input.ts index a3f3a2bfee8..b8daad2db36 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-unchecked-update-without-comment-thread-targets.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-unchecked-update-without-comment-thread-targets.input.ts @@ -2,6 +2,7 @@ import { Field } from '@nestjs/graphql'; import { InputType } from '@nestjs/graphql'; import { StringFieldUpdateOperationsInput } from '../prisma/string-field-update-operations.input'; import { HideField } from '@nestjs/graphql'; +import { NullableStringFieldUpdateOperationsInput } from '../prisma/nullable-string-field-update-operations.input'; import { NullableDateTimeFieldUpdateOperationsInput } from '../prisma/nullable-date-time-field-update-operations.input'; import { DateTimeFieldUpdateOperationsInput } from '../prisma/date-time-field-update-operations.input'; import { CommentUncheckedUpdateManyWithoutCommentThreadNestedInput } from '../comment/comment-unchecked-update-many-without-comment-thread-nested.input'; @@ -15,6 +16,15 @@ export class CommentThreadUncheckedUpdateWithoutCommentThreadTargetsInput { @HideField() workspaceId?: StringFieldUpdateOperationsInput; + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + authorId?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + body?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + title?: NullableStringFieldUpdateOperationsInput; + @HideField() deletedAt?: NullableDateTimeFieldUpdateOperationsInput; diff --git a/server/src/core/@generated/comment-thread/comment-thread-unchecked-update-without-comments.input.ts b/server/src/core/@generated/comment-thread/comment-thread-unchecked-update-without-comments.input.ts index 9c05d049c4d..70570fbe0d6 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-unchecked-update-without-comments.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-unchecked-update-without-comments.input.ts @@ -2,6 +2,7 @@ import { Field } from '@nestjs/graphql'; import { InputType } from '@nestjs/graphql'; import { StringFieldUpdateOperationsInput } from '../prisma/string-field-update-operations.input'; import { HideField } from '@nestjs/graphql'; +import { NullableStringFieldUpdateOperationsInput } from '../prisma/nullable-string-field-update-operations.input'; import { NullableDateTimeFieldUpdateOperationsInput } from '../prisma/nullable-date-time-field-update-operations.input'; import { DateTimeFieldUpdateOperationsInput } from '../prisma/date-time-field-update-operations.input'; import { CommentThreadTargetUncheckedUpdateManyWithoutCommentThreadNestedInput } from '../comment-thread-target/comment-thread-target-unchecked-update-many-without-comment-thread-nested.input'; @@ -15,6 +16,15 @@ export class CommentThreadUncheckedUpdateWithoutCommentsInput { @HideField() workspaceId?: StringFieldUpdateOperationsInput; + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + authorId?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + body?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + title?: NullableStringFieldUpdateOperationsInput; + @HideField() deletedAt?: NullableDateTimeFieldUpdateOperationsInput; diff --git a/server/src/core/@generated/comment-thread/comment-thread-unchecked-update-without-workspace.input.ts b/server/src/core/@generated/comment-thread/comment-thread-unchecked-update-without-workspace.input.ts index a9dbbbdfe69..b9537cdf0e4 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-unchecked-update-without-workspace.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-unchecked-update-without-workspace.input.ts @@ -1,6 +1,7 @@ import { Field } from '@nestjs/graphql'; import { InputType } from '@nestjs/graphql'; import { StringFieldUpdateOperationsInput } from '../prisma/string-field-update-operations.input'; +import { NullableStringFieldUpdateOperationsInput } from '../prisma/nullable-string-field-update-operations.input'; import { NullableDateTimeFieldUpdateOperationsInput } from '../prisma/nullable-date-time-field-update-operations.input'; import { HideField } from '@nestjs/graphql'; import { DateTimeFieldUpdateOperationsInput } from '../prisma/date-time-field-update-operations.input'; @@ -13,6 +14,15 @@ export class CommentThreadUncheckedUpdateWithoutWorkspaceInput { @Field(() => StringFieldUpdateOperationsInput, {nullable:true}) id?: StringFieldUpdateOperationsInput; + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + authorId?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + body?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + title?: NullableStringFieldUpdateOperationsInput; + @HideField() deletedAt?: NullableDateTimeFieldUpdateOperationsInput; diff --git a/server/src/core/@generated/comment-thread/comment-thread-unchecked-update.input.ts b/server/src/core/@generated/comment-thread/comment-thread-unchecked-update.input.ts index 73ee096f5aa..04f22edaecf 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-unchecked-update.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-unchecked-update.input.ts @@ -2,6 +2,7 @@ import { Field } from '@nestjs/graphql'; import { InputType } from '@nestjs/graphql'; import { StringFieldUpdateOperationsInput } from '../prisma/string-field-update-operations.input'; import { HideField } from '@nestjs/graphql'; +import { NullableStringFieldUpdateOperationsInput } from '../prisma/nullable-string-field-update-operations.input'; import { NullableDateTimeFieldUpdateOperationsInput } from '../prisma/nullable-date-time-field-update-operations.input'; import { DateTimeFieldUpdateOperationsInput } from '../prisma/date-time-field-update-operations.input'; import { CommentThreadTargetUncheckedUpdateManyWithoutCommentThreadNestedInput } from '../comment-thread-target/comment-thread-target-unchecked-update-many-without-comment-thread-nested.input'; @@ -16,6 +17,15 @@ export class CommentThreadUncheckedUpdateInput { @HideField() workspaceId?: StringFieldUpdateOperationsInput; + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + authorId?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + body?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + title?: NullableStringFieldUpdateOperationsInput; + @HideField() deletedAt?: NullableDateTimeFieldUpdateOperationsInput; diff --git a/server/src/core/@generated/comment-thread/comment-thread-update-many-mutation.input.ts b/server/src/core/@generated/comment-thread/comment-thread-update-many-mutation.input.ts index 4ac5fe47731..4fb732222d7 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-update-many-mutation.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-update-many-mutation.input.ts @@ -1,6 +1,7 @@ import { Field } from '@nestjs/graphql'; import { InputType } from '@nestjs/graphql'; import { StringFieldUpdateOperationsInput } from '../prisma/string-field-update-operations.input'; +import { NullableStringFieldUpdateOperationsInput } from '../prisma/nullable-string-field-update-operations.input'; import { NullableDateTimeFieldUpdateOperationsInput } from '../prisma/nullable-date-time-field-update-operations.input'; import { HideField } from '@nestjs/graphql'; import { DateTimeFieldUpdateOperationsInput } from '../prisma/date-time-field-update-operations.input'; @@ -11,6 +12,15 @@ export class CommentThreadUpdateManyMutationInput { @Field(() => StringFieldUpdateOperationsInput, {nullable:true}) id?: StringFieldUpdateOperationsInput; + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + authorId?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + body?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + title?: NullableStringFieldUpdateOperationsInput; + @HideField() deletedAt?: NullableDateTimeFieldUpdateOperationsInput; diff --git a/server/src/core/@generated/comment-thread/comment-thread-update-without-comment-thread-targets.input.ts b/server/src/core/@generated/comment-thread/comment-thread-update-without-comment-thread-targets.input.ts index 11962b372cb..b60350deba3 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-update-without-comment-thread-targets.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-update-without-comment-thread-targets.input.ts @@ -1,6 +1,7 @@ import { Field } from '@nestjs/graphql'; import { InputType } from '@nestjs/graphql'; import { StringFieldUpdateOperationsInput } from '../prisma/string-field-update-operations.input'; +import { NullableStringFieldUpdateOperationsInput } from '../prisma/nullable-string-field-update-operations.input'; import { NullableDateTimeFieldUpdateOperationsInput } from '../prisma/nullable-date-time-field-update-operations.input'; import { HideField } from '@nestjs/graphql'; import { DateTimeFieldUpdateOperationsInput } from '../prisma/date-time-field-update-operations.input'; @@ -13,6 +14,15 @@ export class CommentThreadUpdateWithoutCommentThreadTargetsInput { @Field(() => StringFieldUpdateOperationsInput, {nullable:true}) id?: StringFieldUpdateOperationsInput; + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + authorId?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + body?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + title?: NullableStringFieldUpdateOperationsInput; + @HideField() deletedAt?: NullableDateTimeFieldUpdateOperationsInput; diff --git a/server/src/core/@generated/comment-thread/comment-thread-update-without-comments.input.ts b/server/src/core/@generated/comment-thread/comment-thread-update-without-comments.input.ts index 4c2d34db466..6d5e3099b21 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-update-without-comments.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-update-without-comments.input.ts @@ -1,6 +1,7 @@ import { Field } from '@nestjs/graphql'; import { InputType } from '@nestjs/graphql'; import { StringFieldUpdateOperationsInput } from '../prisma/string-field-update-operations.input'; +import { NullableStringFieldUpdateOperationsInput } from '../prisma/nullable-string-field-update-operations.input'; import { NullableDateTimeFieldUpdateOperationsInput } from '../prisma/nullable-date-time-field-update-operations.input'; import { HideField } from '@nestjs/graphql'; import { DateTimeFieldUpdateOperationsInput } from '../prisma/date-time-field-update-operations.input'; @@ -13,6 +14,15 @@ export class CommentThreadUpdateWithoutCommentsInput { @Field(() => StringFieldUpdateOperationsInput, {nullable:true}) id?: StringFieldUpdateOperationsInput; + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + authorId?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + body?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + title?: NullableStringFieldUpdateOperationsInput; + @HideField() deletedAt?: NullableDateTimeFieldUpdateOperationsInput; diff --git a/server/src/core/@generated/comment-thread/comment-thread-update-without-workspace.input.ts b/server/src/core/@generated/comment-thread/comment-thread-update-without-workspace.input.ts index 0860a0f3302..f361462d20a 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-update-without-workspace.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-update-without-workspace.input.ts @@ -1,6 +1,7 @@ import { Field } from '@nestjs/graphql'; import { InputType } from '@nestjs/graphql'; import { StringFieldUpdateOperationsInput } from '../prisma/string-field-update-operations.input'; +import { NullableStringFieldUpdateOperationsInput } from '../prisma/nullable-string-field-update-operations.input'; import { NullableDateTimeFieldUpdateOperationsInput } from '../prisma/nullable-date-time-field-update-operations.input'; import { HideField } from '@nestjs/graphql'; import { DateTimeFieldUpdateOperationsInput } from '../prisma/date-time-field-update-operations.input'; @@ -13,6 +14,15 @@ export class CommentThreadUpdateWithoutWorkspaceInput { @Field(() => StringFieldUpdateOperationsInput, {nullable:true}) id?: StringFieldUpdateOperationsInput; + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + authorId?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + body?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + title?: NullableStringFieldUpdateOperationsInput; + @HideField() deletedAt?: NullableDateTimeFieldUpdateOperationsInput; diff --git a/server/src/core/@generated/comment-thread/comment-thread-update.input.ts b/server/src/core/@generated/comment-thread/comment-thread-update.input.ts index f9558ac23f9..4dea417273a 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-update.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-update.input.ts @@ -1,6 +1,7 @@ import { Field } from '@nestjs/graphql'; import { InputType } from '@nestjs/graphql'; import { StringFieldUpdateOperationsInput } from '../prisma/string-field-update-operations.input'; +import { NullableStringFieldUpdateOperationsInput } from '../prisma/nullable-string-field-update-operations.input'; import { NullableDateTimeFieldUpdateOperationsInput } from '../prisma/nullable-date-time-field-update-operations.input'; import { HideField } from '@nestjs/graphql'; import { DateTimeFieldUpdateOperationsInput } from '../prisma/date-time-field-update-operations.input'; @@ -14,6 +15,15 @@ export class CommentThreadUpdateInput { @Field(() => StringFieldUpdateOperationsInput, {nullable:true}) id?: StringFieldUpdateOperationsInput; + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + authorId?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + body?: NullableStringFieldUpdateOperationsInput; + + @Field(() => NullableStringFieldUpdateOperationsInput, {nullable:true}) + title?: NullableStringFieldUpdateOperationsInput; + @HideField() deletedAt?: NullableDateTimeFieldUpdateOperationsInput; diff --git a/server/src/core/@generated/comment-thread/comment-thread-where.input.ts b/server/src/core/@generated/comment-thread/comment-thread-where.input.ts index 8565dd9b847..f1dc57b2747 100644 --- a/server/src/core/@generated/comment-thread/comment-thread-where.input.ts +++ b/server/src/core/@generated/comment-thread/comment-thread-where.input.ts @@ -2,6 +2,7 @@ import { Field } from '@nestjs/graphql'; import { InputType } from '@nestjs/graphql'; import { StringFilter } from '../prisma/string-filter.input'; import { HideField } from '@nestjs/graphql'; +import { StringNullableFilter } from '../prisma/string-nullable-filter.input'; import { DateTimeNullableFilter } from '../prisma/date-time-nullable-filter.input'; import { DateTimeFilter } from '../prisma/date-time-filter.input'; import { CommentThreadTargetListRelationFilter } from '../comment-thread-target/comment-thread-target-list-relation-filter.input'; @@ -26,6 +27,15 @@ export class CommentThreadWhereInput { @HideField() workspaceId?: StringFilter; + @Field(() => StringNullableFilter, {nullable:true}) + authorId?: StringNullableFilter; + + @Field(() => StringNullableFilter, {nullable:true}) + body?: StringNullableFilter; + + @Field(() => StringNullableFilter, {nullable:true}) + title?: StringNullableFilter; + @HideField() deletedAt?: DateTimeNullableFilter; diff --git a/server/src/core/@generated/comment-thread/comment-thread.model.ts b/server/src/core/@generated/comment-thread/comment-thread.model.ts index 430b1964bb2..ebca169cbdf 100644 --- a/server/src/core/@generated/comment-thread/comment-thread.model.ts +++ b/server/src/core/@generated/comment-thread/comment-thread.model.ts @@ -16,6 +16,15 @@ export class CommentThread { @HideField() workspaceId!: string; + @Field(() => String, {nullable:true}) + authorId!: string | null; + + @Field(() => String, {nullable:true}) + body!: string | null; + + @Field(() => String, {nullable:true}) + title!: string | null; + @HideField() deletedAt!: Date | null; diff --git a/server/src/core/@generated/comment-thread/create-many-comment-thread.args.ts b/server/src/core/@generated/comment-thread/create-many-comment-thread.args.ts index eb14acb1b73..3400a43fbf9 100644 --- a/server/src/core/@generated/comment-thread/create-many-comment-thread.args.ts +++ b/server/src/core/@generated/comment-thread/create-many-comment-thread.args.ts @@ -9,8 +9,8 @@ export class CreateManyCommentThreadArgs { @Field(() => [CommentThreadCreateManyInput], {nullable:false}) @Type(() => CommentThreadCreateManyInput) - @ValidateNested({each: true}) @Type(() => CommentThreadCreateManyInput) + @ValidateNested({each: true}) data!: Array; @Field(() => Boolean, {nullable:true}) diff --git a/server/src/core/@generated/comment-thread/create-one-comment-thread.args.ts b/server/src/core/@generated/comment-thread/create-one-comment-thread.args.ts index 20ed8d3e5ef..08d3bb10892 100644 --- a/server/src/core/@generated/comment-thread/create-one-comment-thread.args.ts +++ b/server/src/core/@generated/comment-thread/create-one-comment-thread.args.ts @@ -9,7 +9,7 @@ export class CreateOneCommentThreadArgs { @Field(() => CommentThreadCreateInput, {nullable:false}) @Type(() => CommentThreadCreateInput) - @ValidateNested({each: true}) @Type(() => CommentThreadCreateInput) + @ValidateNested({each: true}) data!: CommentThreadCreateInput; } diff --git a/server/src/core/@generated/comment-thread/update-many-comment-thread.args.ts b/server/src/core/@generated/comment-thread/update-many-comment-thread.args.ts index ccf3aeaf479..b8a35f9bc4a 100644 --- a/server/src/core/@generated/comment-thread/update-many-comment-thread.args.ts +++ b/server/src/core/@generated/comment-thread/update-many-comment-thread.args.ts @@ -10,8 +10,8 @@ export class UpdateManyCommentThreadArgs { @Field(() => CommentThreadUpdateManyMutationInput, {nullable:false}) @Type(() => CommentThreadUpdateManyMutationInput) - @ValidateNested({each: true}) @Type(() => CommentThreadUpdateManyMutationInput) + @ValidateNested({each: true}) data!: CommentThreadUpdateManyMutationInput; @Field(() => CommentThreadWhereInput, {nullable:true}) diff --git a/server/src/core/@generated/comment-thread/update-one-comment-thread.args.ts b/server/src/core/@generated/comment-thread/update-one-comment-thread.args.ts index 0c7ba727741..276840fa4f1 100644 --- a/server/src/core/@generated/comment-thread/update-one-comment-thread.args.ts +++ b/server/src/core/@generated/comment-thread/update-one-comment-thread.args.ts @@ -10,8 +10,8 @@ export class UpdateOneCommentThreadArgs { @Field(() => CommentThreadUpdateInput, {nullable:false}) @Type(() => CommentThreadUpdateInput) - @ValidateNested({each: true}) @Type(() => CommentThreadUpdateInput) + @ValidateNested({each: true}) data!: CommentThreadUpdateInput; @Field(() => CommentThreadWhereUniqueInput, {nullable:false}) diff --git a/server/src/core/@generated/comment/create-many-comment.args.ts b/server/src/core/@generated/comment/create-many-comment.args.ts index fc752ae2b36..bf04460523b 100644 --- a/server/src/core/@generated/comment/create-many-comment.args.ts +++ b/server/src/core/@generated/comment/create-many-comment.args.ts @@ -9,8 +9,8 @@ export class CreateManyCommentArgs { @Field(() => [CommentCreateManyInput], {nullable:false}) @Type(() => CommentCreateManyInput) - @ValidateNested({each: true}) @Type(() => CommentCreateManyInput) + @ValidateNested({each: true}) data!: Array; @Field(() => Boolean, {nullable:true}) diff --git a/server/src/core/@generated/comment/create-one-comment.args.ts b/server/src/core/@generated/comment/create-one-comment.args.ts index 573b1a2e6d2..7733d478d57 100644 --- a/server/src/core/@generated/comment/create-one-comment.args.ts +++ b/server/src/core/@generated/comment/create-one-comment.args.ts @@ -9,7 +9,7 @@ export class CreateOneCommentArgs { @Field(() => CommentCreateInput, {nullable:false}) @Type(() => CommentCreateInput) - @ValidateNested({each: true}) @Type(() => CommentCreateInput) + @ValidateNested({each: true}) data!: CommentCreateInput; } diff --git a/server/src/core/@generated/comment/update-many-comment.args.ts b/server/src/core/@generated/comment/update-many-comment.args.ts index 2ed02c08dcb..18e51d1357e 100644 --- a/server/src/core/@generated/comment/update-many-comment.args.ts +++ b/server/src/core/@generated/comment/update-many-comment.args.ts @@ -10,8 +10,8 @@ export class UpdateManyCommentArgs { @Field(() => CommentUpdateManyMutationInput, {nullable:false}) @Type(() => CommentUpdateManyMutationInput) - @ValidateNested({each: true}) @Type(() => CommentUpdateManyMutationInput) + @ValidateNested({each: true}) data!: CommentUpdateManyMutationInput; @Field(() => CommentWhereInput, {nullable:true}) diff --git a/server/src/core/@generated/comment/update-one-comment.args.ts b/server/src/core/@generated/comment/update-one-comment.args.ts index efeb6180f87..67e7638315d 100644 --- a/server/src/core/@generated/comment/update-one-comment.args.ts +++ b/server/src/core/@generated/comment/update-one-comment.args.ts @@ -10,8 +10,8 @@ export class UpdateOneCommentArgs { @Field(() => CommentUpdateInput, {nullable:false}) @Type(() => CommentUpdateInput) - @ValidateNested({each: true}) @Type(() => CommentUpdateInput) + @ValidateNested({each: true}) data!: CommentUpdateInput; @Field(() => CommentWhereUniqueInput, {nullable:false}) diff --git a/server/src/core/@generated/company/create-many-company.args.ts b/server/src/core/@generated/company/create-many-company.args.ts index 08e78f224af..7cf83a51446 100644 --- a/server/src/core/@generated/company/create-many-company.args.ts +++ b/server/src/core/@generated/company/create-many-company.args.ts @@ -9,8 +9,8 @@ export class CreateManyCompanyArgs { @Field(() => [CompanyCreateManyInput], {nullable:false}) @Type(() => CompanyCreateManyInput) - @ValidateNested({each: true}) @Type(() => CompanyCreateManyInput) + @ValidateNested({each: true}) data!: Array; @Field(() => Boolean, {nullable:true}) diff --git a/server/src/core/@generated/company/create-one-company.args.ts b/server/src/core/@generated/company/create-one-company.args.ts index c8dd6a03315..dbef92eae29 100644 --- a/server/src/core/@generated/company/create-one-company.args.ts +++ b/server/src/core/@generated/company/create-one-company.args.ts @@ -9,7 +9,7 @@ export class CreateOneCompanyArgs { @Field(() => CompanyCreateInput, {nullable:false}) @Type(() => CompanyCreateInput) - @ValidateNested({each: true}) @Type(() => CompanyCreateInput) + @ValidateNested({each: true}) data!: CompanyCreateInput; } diff --git a/server/src/core/@generated/company/update-many-company.args.ts b/server/src/core/@generated/company/update-many-company.args.ts index 6672abe3108..f722b5c4e80 100644 --- a/server/src/core/@generated/company/update-many-company.args.ts +++ b/server/src/core/@generated/company/update-many-company.args.ts @@ -10,8 +10,8 @@ export class UpdateManyCompanyArgs { @Field(() => CompanyUpdateManyMutationInput, {nullable:false}) @Type(() => CompanyUpdateManyMutationInput) - @ValidateNested({each: true}) @Type(() => CompanyUpdateManyMutationInput) + @ValidateNested({each: true}) data!: CompanyUpdateManyMutationInput; @Field(() => CompanyWhereInput, {nullable:true}) diff --git a/server/src/core/@generated/company/update-one-company.args.ts b/server/src/core/@generated/company/update-one-company.args.ts index ca5a6704933..5b6fcb30c5a 100644 --- a/server/src/core/@generated/company/update-one-company.args.ts +++ b/server/src/core/@generated/company/update-one-company.args.ts @@ -10,8 +10,8 @@ export class UpdateOneCompanyArgs { @Field(() => CompanyUpdateInput, {nullable:false}) @Type(() => CompanyUpdateInput) - @ValidateNested({each: true}) @Type(() => CompanyUpdateInput) + @ValidateNested({each: true}) data!: CompanyUpdateInput; @Field(() => CompanyWhereUniqueInput, {nullable:false}) diff --git a/server/src/core/@generated/person/create-many-person.args.ts b/server/src/core/@generated/person/create-many-person.args.ts index d78b614a49e..afa8386df85 100644 --- a/server/src/core/@generated/person/create-many-person.args.ts +++ b/server/src/core/@generated/person/create-many-person.args.ts @@ -9,8 +9,8 @@ export class CreateManyPersonArgs { @Field(() => [PersonCreateManyInput], {nullable:false}) @Type(() => PersonCreateManyInput) - @ValidateNested({each: true}) @Type(() => PersonCreateManyInput) + @ValidateNested({each: true}) data!: Array; @Field(() => Boolean, {nullable:true}) diff --git a/server/src/core/@generated/person/create-one-person.args.ts b/server/src/core/@generated/person/create-one-person.args.ts index 8651efd2c36..84db827ae88 100644 --- a/server/src/core/@generated/person/create-one-person.args.ts +++ b/server/src/core/@generated/person/create-one-person.args.ts @@ -9,7 +9,7 @@ export class CreateOnePersonArgs { @Field(() => PersonCreateInput, {nullable:false}) @Type(() => PersonCreateInput) - @ValidateNested({each: true}) @Type(() => PersonCreateInput) + @ValidateNested({each: true}) data!: PersonCreateInput; } diff --git a/server/src/core/@generated/person/update-many-person.args.ts b/server/src/core/@generated/person/update-many-person.args.ts index ba742bafdfc..801368ed86f 100644 --- a/server/src/core/@generated/person/update-many-person.args.ts +++ b/server/src/core/@generated/person/update-many-person.args.ts @@ -10,8 +10,8 @@ export class UpdateManyPersonArgs { @Field(() => PersonUpdateManyMutationInput, {nullable:false}) @Type(() => PersonUpdateManyMutationInput) - @ValidateNested({each: true}) @Type(() => PersonUpdateManyMutationInput) + @ValidateNested({each: true}) data!: PersonUpdateManyMutationInput; @Field(() => PersonWhereInput, {nullable:true}) diff --git a/server/src/core/@generated/person/update-one-person.args.ts b/server/src/core/@generated/person/update-one-person.args.ts index c70516db729..2501e66cc4a 100644 --- a/server/src/core/@generated/person/update-one-person.args.ts +++ b/server/src/core/@generated/person/update-one-person.args.ts @@ -10,8 +10,8 @@ export class UpdateOnePersonArgs { @Field(() => PersonUpdateInput, {nullable:false}) @Type(() => PersonUpdateInput) - @ValidateNested({each: true}) @Type(() => PersonUpdateInput) + @ValidateNested({each: true}) data!: PersonUpdateInput; @Field(() => PersonWhereUniqueInput, {nullable:false}) diff --git a/server/src/core/@generated/pipeline-progress/create-many-pipeline-progress.args.ts b/server/src/core/@generated/pipeline-progress/create-many-pipeline-progress.args.ts index 447f7bf6f97..c0f92417a9c 100644 --- a/server/src/core/@generated/pipeline-progress/create-many-pipeline-progress.args.ts +++ b/server/src/core/@generated/pipeline-progress/create-many-pipeline-progress.args.ts @@ -9,8 +9,8 @@ export class CreateManyPipelineProgressArgs { @Field(() => [PipelineProgressCreateManyInput], {nullable:false}) @Type(() => PipelineProgressCreateManyInput) - @ValidateNested({each: true}) @Type(() => PipelineProgressCreateManyInput) + @ValidateNested({each: true}) data!: Array; @Field(() => Boolean, {nullable:true}) diff --git a/server/src/core/@generated/pipeline-progress/create-one-pipeline-progress.args.ts b/server/src/core/@generated/pipeline-progress/create-one-pipeline-progress.args.ts index 3455dda8d86..252b38dabfe 100644 --- a/server/src/core/@generated/pipeline-progress/create-one-pipeline-progress.args.ts +++ b/server/src/core/@generated/pipeline-progress/create-one-pipeline-progress.args.ts @@ -9,7 +9,7 @@ export class CreateOnePipelineProgressArgs { @Field(() => PipelineProgressCreateInput, {nullable:false}) @Type(() => PipelineProgressCreateInput) - @ValidateNested({each: true}) @Type(() => PipelineProgressCreateInput) + @ValidateNested({each: true}) data!: PipelineProgressCreateInput; } diff --git a/server/src/core/@generated/pipeline-progress/update-many-pipeline-progress.args.ts b/server/src/core/@generated/pipeline-progress/update-many-pipeline-progress.args.ts index 6e2ecd02be0..532d3f5c2d1 100644 --- a/server/src/core/@generated/pipeline-progress/update-many-pipeline-progress.args.ts +++ b/server/src/core/@generated/pipeline-progress/update-many-pipeline-progress.args.ts @@ -10,8 +10,8 @@ export class UpdateManyPipelineProgressArgs { @Field(() => PipelineProgressUpdateManyMutationInput, {nullable:false}) @Type(() => PipelineProgressUpdateManyMutationInput) - @ValidateNested({each: true}) @Type(() => PipelineProgressUpdateManyMutationInput) + @ValidateNested({each: true}) data!: PipelineProgressUpdateManyMutationInput; @Field(() => PipelineProgressWhereInput, {nullable:true}) diff --git a/server/src/core/@generated/pipeline-progress/update-one-pipeline-progress.args.ts b/server/src/core/@generated/pipeline-progress/update-one-pipeline-progress.args.ts index b7fbafe4ba9..9d18d04c551 100644 --- a/server/src/core/@generated/pipeline-progress/update-one-pipeline-progress.args.ts +++ b/server/src/core/@generated/pipeline-progress/update-one-pipeline-progress.args.ts @@ -10,8 +10,8 @@ export class UpdateOnePipelineProgressArgs { @Field(() => PipelineProgressUpdateInput, {nullable:false}) @Type(() => PipelineProgressUpdateInput) - @ValidateNested({each: true}) @Type(() => PipelineProgressUpdateInput) + @ValidateNested({each: true}) data!: PipelineProgressUpdateInput; @Field(() => PipelineProgressWhereUniqueInput, {nullable:false}) diff --git a/server/src/core/@generated/pipeline-stage/create-many-pipeline-stage.args.ts b/server/src/core/@generated/pipeline-stage/create-many-pipeline-stage.args.ts index 92168e92be2..606acc20fdf 100644 --- a/server/src/core/@generated/pipeline-stage/create-many-pipeline-stage.args.ts +++ b/server/src/core/@generated/pipeline-stage/create-many-pipeline-stage.args.ts @@ -9,8 +9,8 @@ export class CreateManyPipelineStageArgs { @Field(() => [PipelineStageCreateManyInput], {nullable:false}) @Type(() => PipelineStageCreateManyInput) - @ValidateNested({each: true}) @Type(() => PipelineStageCreateManyInput) + @ValidateNested({each: true}) data!: Array; @Field(() => Boolean, {nullable:true}) diff --git a/server/src/core/@generated/pipeline-stage/create-one-pipeline-stage.args.ts b/server/src/core/@generated/pipeline-stage/create-one-pipeline-stage.args.ts index 5821b7a4322..0418d91cf4f 100644 --- a/server/src/core/@generated/pipeline-stage/create-one-pipeline-stage.args.ts +++ b/server/src/core/@generated/pipeline-stage/create-one-pipeline-stage.args.ts @@ -9,7 +9,7 @@ export class CreateOnePipelineStageArgs { @Field(() => PipelineStageCreateInput, {nullable:false}) @Type(() => PipelineStageCreateInput) - @ValidateNested({each: true}) @Type(() => PipelineStageCreateInput) + @ValidateNested({each: true}) data!: PipelineStageCreateInput; } diff --git a/server/src/core/@generated/pipeline-stage/update-many-pipeline-stage.args.ts b/server/src/core/@generated/pipeline-stage/update-many-pipeline-stage.args.ts index ce2c3fc9a94..a45ce9de4ad 100644 --- a/server/src/core/@generated/pipeline-stage/update-many-pipeline-stage.args.ts +++ b/server/src/core/@generated/pipeline-stage/update-many-pipeline-stage.args.ts @@ -10,8 +10,8 @@ export class UpdateManyPipelineStageArgs { @Field(() => PipelineStageUpdateManyMutationInput, {nullable:false}) @Type(() => PipelineStageUpdateManyMutationInput) - @ValidateNested({each: true}) @Type(() => PipelineStageUpdateManyMutationInput) + @ValidateNested({each: true}) data!: PipelineStageUpdateManyMutationInput; @Field(() => PipelineStageWhereInput, {nullable:true}) diff --git a/server/src/core/@generated/pipeline-stage/update-one-pipeline-stage.args.ts b/server/src/core/@generated/pipeline-stage/update-one-pipeline-stage.args.ts index 2a8995dc566..fe59b6317ef 100644 --- a/server/src/core/@generated/pipeline-stage/update-one-pipeline-stage.args.ts +++ b/server/src/core/@generated/pipeline-stage/update-one-pipeline-stage.args.ts @@ -10,8 +10,8 @@ export class UpdateOnePipelineStageArgs { @Field(() => PipelineStageUpdateInput, {nullable:false}) @Type(() => PipelineStageUpdateInput) - @ValidateNested({each: true}) @Type(() => PipelineStageUpdateInput) + @ValidateNested({each: true}) data!: PipelineStageUpdateInput; @Field(() => PipelineStageWhereUniqueInput, {nullable:false}) diff --git a/server/src/core/@generated/pipeline/create-many-pipeline.args.ts b/server/src/core/@generated/pipeline/create-many-pipeline.args.ts index 58d1a1ce760..9f0c2cba5a5 100644 --- a/server/src/core/@generated/pipeline/create-many-pipeline.args.ts +++ b/server/src/core/@generated/pipeline/create-many-pipeline.args.ts @@ -9,8 +9,8 @@ export class CreateManyPipelineArgs { @Field(() => [PipelineCreateManyInput], {nullable:false}) @Type(() => PipelineCreateManyInput) - @ValidateNested({each: true}) @Type(() => PipelineCreateManyInput) + @ValidateNested({each: true}) data!: Array; @Field(() => Boolean, {nullable:true}) diff --git a/server/src/core/@generated/pipeline/create-one-pipeline.args.ts b/server/src/core/@generated/pipeline/create-one-pipeline.args.ts index d27b30083d1..143dea4272d 100644 --- a/server/src/core/@generated/pipeline/create-one-pipeline.args.ts +++ b/server/src/core/@generated/pipeline/create-one-pipeline.args.ts @@ -9,7 +9,7 @@ export class CreateOnePipelineArgs { @Field(() => PipelineCreateInput, {nullable:false}) @Type(() => PipelineCreateInput) - @ValidateNested({each: true}) @Type(() => PipelineCreateInput) + @ValidateNested({each: true}) data!: PipelineCreateInput; } diff --git a/server/src/core/@generated/pipeline/update-many-pipeline.args.ts b/server/src/core/@generated/pipeline/update-many-pipeline.args.ts index 33a24fce201..338e0fedccc 100644 --- a/server/src/core/@generated/pipeline/update-many-pipeline.args.ts +++ b/server/src/core/@generated/pipeline/update-many-pipeline.args.ts @@ -10,8 +10,8 @@ export class UpdateManyPipelineArgs { @Field(() => PipelineUpdateManyMutationInput, {nullable:false}) @Type(() => PipelineUpdateManyMutationInput) - @ValidateNested({each: true}) @Type(() => PipelineUpdateManyMutationInput) + @ValidateNested({each: true}) data!: PipelineUpdateManyMutationInput; @Field(() => PipelineWhereInput, {nullable:true}) diff --git a/server/src/core/@generated/pipeline/update-one-pipeline.args.ts b/server/src/core/@generated/pipeline/update-one-pipeline.args.ts index fea3d76f552..460599fba49 100644 --- a/server/src/core/@generated/pipeline/update-one-pipeline.args.ts +++ b/server/src/core/@generated/pipeline/update-one-pipeline.args.ts @@ -10,8 +10,8 @@ export class UpdateOnePipelineArgs { @Field(() => PipelineUpdateInput, {nullable:false}) @Type(() => PipelineUpdateInput) - @ValidateNested({each: true}) @Type(() => PipelineUpdateInput) + @ValidateNested({each: true}) data!: PipelineUpdateInput; @Field(() => PipelineWhereUniqueInput, {nullable:false}) diff --git a/server/src/core/@generated/refresh-token/create-many-refresh-token.args.ts b/server/src/core/@generated/refresh-token/create-many-refresh-token.args.ts index abd1265fb51..0a8510995e3 100644 --- a/server/src/core/@generated/refresh-token/create-many-refresh-token.args.ts +++ b/server/src/core/@generated/refresh-token/create-many-refresh-token.args.ts @@ -9,8 +9,8 @@ export class CreateManyRefreshTokenArgs { @Field(() => [RefreshTokenCreateManyInput], {nullable:false}) @Type(() => RefreshTokenCreateManyInput) - @ValidateNested({each: true}) @Type(() => RefreshTokenCreateManyInput) + @ValidateNested({each: true}) data!: Array; @Field(() => Boolean, {nullable:true}) diff --git a/server/src/core/@generated/refresh-token/create-one-refresh-token.args.ts b/server/src/core/@generated/refresh-token/create-one-refresh-token.args.ts index cd6d099e463..fd6f04cef4f 100644 --- a/server/src/core/@generated/refresh-token/create-one-refresh-token.args.ts +++ b/server/src/core/@generated/refresh-token/create-one-refresh-token.args.ts @@ -9,7 +9,7 @@ export class CreateOneRefreshTokenArgs { @Field(() => RefreshTokenCreateInput, {nullable:false}) @Type(() => RefreshTokenCreateInput) - @ValidateNested({each: true}) @Type(() => RefreshTokenCreateInput) + @ValidateNested({each: true}) data!: RefreshTokenCreateInput; } diff --git a/server/src/core/@generated/refresh-token/update-many-refresh-token.args.ts b/server/src/core/@generated/refresh-token/update-many-refresh-token.args.ts index 51c0f78073f..4670c0f53c2 100644 --- a/server/src/core/@generated/refresh-token/update-many-refresh-token.args.ts +++ b/server/src/core/@generated/refresh-token/update-many-refresh-token.args.ts @@ -10,8 +10,8 @@ export class UpdateManyRefreshTokenArgs { @Field(() => RefreshTokenUpdateManyMutationInput, {nullable:false}) @Type(() => RefreshTokenUpdateManyMutationInput) - @ValidateNested({each: true}) @Type(() => RefreshTokenUpdateManyMutationInput) + @ValidateNested({each: true}) data!: RefreshTokenUpdateManyMutationInput; @Field(() => RefreshTokenWhereInput, {nullable:true}) diff --git a/server/src/core/@generated/refresh-token/update-one-refresh-token.args.ts b/server/src/core/@generated/refresh-token/update-one-refresh-token.args.ts index c878ef06b0c..53f7031d00c 100644 --- a/server/src/core/@generated/refresh-token/update-one-refresh-token.args.ts +++ b/server/src/core/@generated/refresh-token/update-one-refresh-token.args.ts @@ -10,8 +10,8 @@ export class UpdateOneRefreshTokenArgs { @Field(() => RefreshTokenUpdateInput, {nullable:false}) @Type(() => RefreshTokenUpdateInput) - @ValidateNested({each: true}) @Type(() => RefreshTokenUpdateInput) + @ValidateNested({each: true}) data!: RefreshTokenUpdateInput; @Field(() => RefreshTokenWhereUniqueInput, {nullable:false}) diff --git a/server/src/core/@generated/user/create-many-user.args.ts b/server/src/core/@generated/user/create-many-user.args.ts index e57cc3d602f..c4911579e19 100644 --- a/server/src/core/@generated/user/create-many-user.args.ts +++ b/server/src/core/@generated/user/create-many-user.args.ts @@ -9,8 +9,8 @@ export class CreateManyUserArgs { @Field(() => [UserCreateManyInput], {nullable:false}) @Type(() => UserCreateManyInput) - @ValidateNested({each: true}) @Type(() => UserCreateManyInput) + @ValidateNested({each: true}) data!: Array; @Field(() => Boolean, {nullable:true}) diff --git a/server/src/core/@generated/user/create-one-user.args.ts b/server/src/core/@generated/user/create-one-user.args.ts index 017efd8369f..0ae7729b142 100644 --- a/server/src/core/@generated/user/create-one-user.args.ts +++ b/server/src/core/@generated/user/create-one-user.args.ts @@ -9,7 +9,7 @@ export class CreateOneUserArgs { @Field(() => UserCreateInput, {nullable:false}) @Type(() => UserCreateInput) - @ValidateNested({each: true}) @Type(() => UserCreateInput) + @ValidateNested({each: true}) data!: UserCreateInput; } diff --git a/server/src/core/@generated/user/update-many-user.args.ts b/server/src/core/@generated/user/update-many-user.args.ts index 7b964a70042..0b492226d73 100644 --- a/server/src/core/@generated/user/update-many-user.args.ts +++ b/server/src/core/@generated/user/update-many-user.args.ts @@ -10,8 +10,8 @@ export class UpdateManyUserArgs { @Field(() => UserUpdateManyMutationInput, {nullable:false}) @Type(() => UserUpdateManyMutationInput) - @ValidateNested({each: true}) @Type(() => UserUpdateManyMutationInput) + @ValidateNested({each: true}) data!: UserUpdateManyMutationInput; @Field(() => UserWhereInput, {nullable:true}) diff --git a/server/src/core/@generated/user/update-one-user.args.ts b/server/src/core/@generated/user/update-one-user.args.ts index 819930ca93f..025f33e68d5 100644 --- a/server/src/core/@generated/user/update-one-user.args.ts +++ b/server/src/core/@generated/user/update-one-user.args.ts @@ -10,8 +10,8 @@ export class UpdateOneUserArgs { @Field(() => UserUpdateInput, {nullable:false}) @Type(() => UserUpdateInput) - @ValidateNested({each: true}) @Type(() => UserUpdateInput) + @ValidateNested({each: true}) data!: UserUpdateInput; @Field(() => UserWhereUniqueInput, {nullable:false}) diff --git a/server/src/core/@generated/workspace-member/create-many-workspace-member.args.ts b/server/src/core/@generated/workspace-member/create-many-workspace-member.args.ts index 6200d2a3cb7..62dd8da7c92 100644 --- a/server/src/core/@generated/workspace-member/create-many-workspace-member.args.ts +++ b/server/src/core/@generated/workspace-member/create-many-workspace-member.args.ts @@ -9,8 +9,8 @@ export class CreateManyWorkspaceMemberArgs { @Field(() => [WorkspaceMemberCreateManyInput], {nullable:false}) @Type(() => WorkspaceMemberCreateManyInput) - @ValidateNested({each: true}) @Type(() => WorkspaceMemberCreateManyInput) + @ValidateNested({each: true}) data!: Array; @Field(() => Boolean, {nullable:true}) diff --git a/server/src/core/@generated/workspace-member/create-one-workspace-member.args.ts b/server/src/core/@generated/workspace-member/create-one-workspace-member.args.ts index 81c65ffaba8..17614ef69fa 100644 --- a/server/src/core/@generated/workspace-member/create-one-workspace-member.args.ts +++ b/server/src/core/@generated/workspace-member/create-one-workspace-member.args.ts @@ -9,7 +9,7 @@ export class CreateOneWorkspaceMemberArgs { @Field(() => WorkspaceMemberCreateInput, {nullable:false}) @Type(() => WorkspaceMemberCreateInput) - @ValidateNested({each: true}) @Type(() => WorkspaceMemberCreateInput) + @ValidateNested({each: true}) data!: WorkspaceMemberCreateInput; } diff --git a/server/src/core/@generated/workspace-member/update-many-workspace-member.args.ts b/server/src/core/@generated/workspace-member/update-many-workspace-member.args.ts index 3b90fb76a26..d850a6eb068 100644 --- a/server/src/core/@generated/workspace-member/update-many-workspace-member.args.ts +++ b/server/src/core/@generated/workspace-member/update-many-workspace-member.args.ts @@ -10,8 +10,8 @@ export class UpdateManyWorkspaceMemberArgs { @Field(() => WorkspaceMemberUpdateManyMutationInput, {nullable:false}) @Type(() => WorkspaceMemberUpdateManyMutationInput) - @ValidateNested({each: true}) @Type(() => WorkspaceMemberUpdateManyMutationInput) + @ValidateNested({each: true}) data!: WorkspaceMemberUpdateManyMutationInput; @Field(() => WorkspaceMemberWhereInput, {nullable:true}) diff --git a/server/src/core/@generated/workspace-member/update-one-workspace-member.args.ts b/server/src/core/@generated/workspace-member/update-one-workspace-member.args.ts index 06e17b91737..4f5f2b2d4bf 100644 --- a/server/src/core/@generated/workspace-member/update-one-workspace-member.args.ts +++ b/server/src/core/@generated/workspace-member/update-one-workspace-member.args.ts @@ -10,8 +10,8 @@ export class UpdateOneWorkspaceMemberArgs { @Field(() => WorkspaceMemberUpdateInput, {nullable:false}) @Type(() => WorkspaceMemberUpdateInput) - @ValidateNested({each: true}) @Type(() => WorkspaceMemberUpdateInput) + @ValidateNested({each: true}) data!: WorkspaceMemberUpdateInput; @Field(() => WorkspaceMemberWhereUniqueInput, {nullable:false}) diff --git a/server/src/core/@generated/workspace/create-many-workspace.args.ts b/server/src/core/@generated/workspace/create-many-workspace.args.ts index 9dc7e7e9e65..11636c24d74 100644 --- a/server/src/core/@generated/workspace/create-many-workspace.args.ts +++ b/server/src/core/@generated/workspace/create-many-workspace.args.ts @@ -9,8 +9,8 @@ export class CreateManyWorkspaceArgs { @Field(() => [WorkspaceCreateManyInput], {nullable:false}) @Type(() => WorkspaceCreateManyInput) - @ValidateNested({each: true}) @Type(() => WorkspaceCreateManyInput) + @ValidateNested({each: true}) data!: Array; @Field(() => Boolean, {nullable:true}) diff --git a/server/src/core/@generated/workspace/create-one-workspace.args.ts b/server/src/core/@generated/workspace/create-one-workspace.args.ts index ce2dec1590a..22b1f766fb1 100644 --- a/server/src/core/@generated/workspace/create-one-workspace.args.ts +++ b/server/src/core/@generated/workspace/create-one-workspace.args.ts @@ -9,7 +9,7 @@ export class CreateOneWorkspaceArgs { @Field(() => WorkspaceCreateInput, {nullable:false}) @Type(() => WorkspaceCreateInput) - @ValidateNested({each: true}) @Type(() => WorkspaceCreateInput) + @ValidateNested({each: true}) data!: WorkspaceCreateInput; } diff --git a/server/src/core/@generated/workspace/update-many-workspace.args.ts b/server/src/core/@generated/workspace/update-many-workspace.args.ts index 7772c4a6920..ee0c3f95f42 100644 --- a/server/src/core/@generated/workspace/update-many-workspace.args.ts +++ b/server/src/core/@generated/workspace/update-many-workspace.args.ts @@ -10,8 +10,8 @@ export class UpdateManyWorkspaceArgs { @Field(() => WorkspaceUpdateManyMutationInput, {nullable:false}) @Type(() => WorkspaceUpdateManyMutationInput) - @ValidateNested({each: true}) @Type(() => WorkspaceUpdateManyMutationInput) + @ValidateNested({each: true}) data!: WorkspaceUpdateManyMutationInput; @Field(() => WorkspaceWhereInput, {nullable:true}) diff --git a/server/src/core/@generated/workspace/update-one-workspace.args.ts b/server/src/core/@generated/workspace/update-one-workspace.args.ts index d28d7161b4a..151ae42a15c 100644 --- a/server/src/core/@generated/workspace/update-one-workspace.args.ts +++ b/server/src/core/@generated/workspace/update-one-workspace.args.ts @@ -10,8 +10,8 @@ export class UpdateOneWorkspaceArgs { @Field(() => WorkspaceUpdateInput, {nullable:false}) @Type(() => WorkspaceUpdateInput) - @ValidateNested({each: true}) @Type(() => WorkspaceUpdateInput) + @ValidateNested({each: true}) data!: WorkspaceUpdateInput; @Field(() => WorkspaceWhereUniqueInput, {nullable:false}) diff --git a/server/src/core/company/company.resolver.ts b/server/src/core/company/company.resolver.ts index 2c9474a2e2d..af58a09e1e7 100644 --- a/server/src/core/company/company.resolver.ts +++ b/server/src/core/company/company.resolver.ts @@ -55,6 +55,23 @@ export class CompanyResolver { }); } + @Query(() => Company) + @UseGuards(AbilityGuard) + @CheckAbilities(ReadCompanyAbilityHandler) + async findUniqueCompany( + @Args('id') id: string, + @UserAbility() ability: AppAbility, + @PrismaSelector({ modelName: 'Company' }) + prismaSelect: PrismaSelect<'Company'>, + ): Promise> { + return this.companyService.findUniqueOrThrow({ + where: { + id: id, + }, + select: prismaSelect.value, + }); + } + @UseGuards(UpdateOneGuard) @Mutation(() => Company, { nullable: true, diff --git a/server/src/database/migrations/20230706072223_add_body_title_author_fields_to_comment_threads/migration.sql b/server/src/database/migrations/20230706072223_add_body_title_author_fields_to_comment_threads/migration.sql new file mode 100644 index 00000000000..7d1dd8f8984 --- /dev/null +++ b/server/src/database/migrations/20230706072223_add_body_title_author_fields_to_comment_threads/migration.sql @@ -0,0 +1,4 @@ +-- AlterTable +ALTER TABLE "comment_threads" ADD COLUMN "body" TEXT, +ADD COLUMN "title" TEXT, +ADD COLUMN "authorId" TEXT; \ No newline at end of file diff --git a/server/src/database/schema.prisma b/server/src/database/schema.prisma index 32d5aab92b8..4301cbc78a3 100644 --- a/server/src/database/schema.prisma +++ b/server/src/database/schema.prisma @@ -328,6 +328,11 @@ model CommentThread { /// @TypeGraphQL.omit(input: true, output: true) workspaceId String + authorId String? + + body String? + title String? + /// @TypeGraphQL.omit(input: true, output: true) deletedAt DateTime? diff --git a/server/src/guards/show-one.guard.ts b/server/src/guards/show-one.guard.ts new file mode 100644 index 00000000000..ef597c60db0 --- /dev/null +++ b/server/src/guards/show-one.guard.ts @@ -0,0 +1,12 @@ +import { CanActivate, Injectable } from '@nestjs/common'; +import { PrismaService } from 'src/database/prisma.service'; + +@Injectable() +export class ShowOneGuard implements CanActivate { + constructor(private prismaService: PrismaService) {} + + async canActivate(): Promise { + // TODO + return true; + } +}