Refactor: Morph strategy on PipelineProgress (#1065)
* Deprecate pipelineprogress backref on person to improve naming * Remove deprecated point of contact fields * Add company and person entities on pipelineprogress * Migrate data from old progressable to new entity fields * Codegen frontend * Use company Id, deprecate progressableId * Get rid of deprecated progressableId field * Remove deprecated progressableType field from pipeline progress * Remove useless migrations
This commit is contained in:
@ -639,6 +639,7 @@ export enum CommentableType {
|
||||
export type Company = {
|
||||
__typename?: 'Company';
|
||||
ActivityTarget?: Maybe<Array<ActivityTarget>>;
|
||||
PipelineProgress?: Maybe<Array<PipelineProgress>>;
|
||||
_activityCount: Scalars['Int'];
|
||||
accountOwner?: Maybe<User>;
|
||||
accountOwnerId?: Maybe<Scalars['String']>;
|
||||
@ -657,6 +658,7 @@ export type Company = {
|
||||
|
||||
export type CompanyCreateInput = {
|
||||
ActivityTarget?: InputMaybe<ActivityTargetCreateNestedManyWithoutCompanyInput>;
|
||||
PipelineProgress?: InputMaybe<PipelineProgressCreateNestedManyWithoutCompanyInput>;
|
||||
accountOwner?: InputMaybe<UserCreateNestedOneWithoutCompaniesInput>;
|
||||
address: Scalars['String'];
|
||||
createdAt?: InputMaybe<Scalars['DateTime']>;
|
||||
@ -677,6 +679,10 @@ export type CompanyCreateNestedOneWithoutPeopleInput = {
|
||||
connect?: InputMaybe<CompanyWhereUniqueInput>;
|
||||
};
|
||||
|
||||
export type CompanyCreateNestedOneWithoutPipelineProgressInput = {
|
||||
connect?: InputMaybe<CompanyWhereUniqueInput>;
|
||||
};
|
||||
|
||||
export type CompanyListRelationFilter = {
|
||||
every?: InputMaybe<CompanyWhereInput>;
|
||||
none?: InputMaybe<CompanyWhereInput>;
|
||||
@ -689,6 +695,7 @@ export type CompanyOrderByRelationAggregateInput = {
|
||||
|
||||
export type CompanyOrderByWithRelationInput = {
|
||||
ActivityTarget?: InputMaybe<ActivityTargetOrderByRelationAggregateInput>;
|
||||
PipelineProgress?: InputMaybe<PipelineProgressOrderByRelationAggregateInput>;
|
||||
accountOwner?: InputMaybe<UserOrderByWithRelationInput>;
|
||||
accountOwnerId?: InputMaybe<SortOrder>;
|
||||
address?: InputMaybe<SortOrder>;
|
||||
@ -723,6 +730,7 @@ export enum CompanyScalarFieldEnum {
|
||||
|
||||
export type CompanyUpdateInput = {
|
||||
ActivityTarget?: InputMaybe<ActivityTargetUpdateManyWithoutCompanyNestedInput>;
|
||||
PipelineProgress?: InputMaybe<PipelineProgressUpdateManyWithoutCompanyNestedInput>;
|
||||
accountOwner?: InputMaybe<UserUpdateOneWithoutCompaniesNestedInput>;
|
||||
address?: InputMaybe<Scalars['String']>;
|
||||
createdAt?: InputMaybe<Scalars['DateTime']>;
|
||||
@ -752,11 +760,17 @@ export type CompanyUpdateOneWithoutPeopleNestedInput = {
|
||||
disconnect?: InputMaybe<Scalars['Boolean']>;
|
||||
};
|
||||
|
||||
export type CompanyUpdateOneWithoutPipelineProgressNestedInput = {
|
||||
connect?: InputMaybe<CompanyWhereUniqueInput>;
|
||||
disconnect?: InputMaybe<Scalars['Boolean']>;
|
||||
};
|
||||
|
||||
export type CompanyWhereInput = {
|
||||
AND?: InputMaybe<Array<CompanyWhereInput>>;
|
||||
ActivityTarget?: InputMaybe<ActivityTargetListRelationFilter>;
|
||||
NOT?: InputMaybe<Array<CompanyWhereInput>>;
|
||||
OR?: InputMaybe<Array<CompanyWhereInput>>;
|
||||
PipelineProgress?: InputMaybe<PipelineProgressListRelationFilter>;
|
||||
accountOwner?: InputMaybe<UserRelationFilter>;
|
||||
accountOwnerId?: InputMaybe<StringNullableFilter>;
|
||||
address?: InputMaybe<StringFilter>;
|
||||
@ -1202,6 +1216,7 @@ export type NestedStringNullableFilter = {
|
||||
export type Person = {
|
||||
__typename?: 'Person';
|
||||
ActivityTarget?: Maybe<Array<ActivityTarget>>;
|
||||
PipelineProgress?: Maybe<Array<PipelineProgress>>;
|
||||
_activityCount: Scalars['Int'];
|
||||
activities: Array<Activity>;
|
||||
avatarUrl?: Maybe<Scalars['String']>;
|
||||
@ -1209,6 +1224,7 @@ export type Person = {
|
||||
comments: Array<Comment>;
|
||||
company?: Maybe<Company>;
|
||||
companyId?: Maybe<Scalars['String']>;
|
||||
contactPipelineProgresses?: Maybe<Array<PipelineProgress>>;
|
||||
createdAt: Scalars['DateTime'];
|
||||
displayName: Scalars['String'];
|
||||
email?: Maybe<Scalars['String']>;
|
||||
@ -1218,15 +1234,16 @@ export type Person = {
|
||||
lastName?: Maybe<Scalars['String']>;
|
||||
linkedinUrl?: Maybe<Scalars['String']>;
|
||||
phone?: Maybe<Scalars['String']>;
|
||||
pipelineProgresses?: Maybe<Array<PipelineProgress>>;
|
||||
updatedAt: Scalars['DateTime'];
|
||||
};
|
||||
|
||||
export type PersonCreateInput = {
|
||||
ActivityTarget?: InputMaybe<ActivityTargetCreateNestedManyWithoutPersonInput>;
|
||||
PipelineProgress?: InputMaybe<PipelineProgressCreateNestedManyWithoutPersonInput>;
|
||||
avatarUrl?: InputMaybe<Scalars['String']>;
|
||||
city?: InputMaybe<Scalars['String']>;
|
||||
company?: InputMaybe<CompanyCreateNestedOneWithoutPeopleInput>;
|
||||
contactPipelineProgresses?: InputMaybe<PipelineProgressCreateNestedManyWithoutPointOfContactInput>;
|
||||
createdAt?: InputMaybe<Scalars['DateTime']>;
|
||||
email?: InputMaybe<Scalars['String']>;
|
||||
firstName?: InputMaybe<Scalars['String']>;
|
||||
@ -1235,7 +1252,6 @@ export type PersonCreateInput = {
|
||||
lastName?: InputMaybe<Scalars['String']>;
|
||||
linkedinUrl?: InputMaybe<Scalars['String']>;
|
||||
phone?: InputMaybe<Scalars['String']>;
|
||||
pipelineProgresses?: InputMaybe<PipelineProgressCreateNestedManyWithoutPointOfContactInput>;
|
||||
updatedAt?: InputMaybe<Scalars['DateTime']>;
|
||||
};
|
||||
|
||||
@ -1247,7 +1263,11 @@ export type PersonCreateNestedOneWithoutActivityTargetInput = {
|
||||
connect?: InputMaybe<PersonWhereUniqueInput>;
|
||||
};
|
||||
|
||||
export type PersonCreateNestedOneWithoutPipelineProgressesInput = {
|
||||
export type PersonCreateNestedOneWithoutContactPipelineProgressesInput = {
|
||||
connect?: InputMaybe<PersonWhereUniqueInput>;
|
||||
};
|
||||
|
||||
export type PersonCreateNestedOneWithoutPipelineProgressInput = {
|
||||
connect?: InputMaybe<PersonWhereUniqueInput>;
|
||||
};
|
||||
|
||||
@ -1263,10 +1283,12 @@ export type PersonOrderByRelationAggregateInput = {
|
||||
|
||||
export type PersonOrderByWithRelationInput = {
|
||||
ActivityTarget?: InputMaybe<ActivityTargetOrderByRelationAggregateInput>;
|
||||
PipelineProgress?: InputMaybe<PipelineProgressOrderByRelationAggregateInput>;
|
||||
avatarUrl?: InputMaybe<SortOrder>;
|
||||
city?: InputMaybe<SortOrder>;
|
||||
company?: InputMaybe<CompanyOrderByWithRelationInput>;
|
||||
companyId?: InputMaybe<SortOrder>;
|
||||
contactPipelineProgresses?: InputMaybe<PipelineProgressOrderByRelationAggregateInput>;
|
||||
createdAt?: InputMaybe<SortOrder>;
|
||||
email?: InputMaybe<SortOrder>;
|
||||
firstName?: InputMaybe<SortOrder>;
|
||||
@ -1275,7 +1297,6 @@ export type PersonOrderByWithRelationInput = {
|
||||
lastName?: InputMaybe<SortOrder>;
|
||||
linkedinUrl?: InputMaybe<SortOrder>;
|
||||
phone?: InputMaybe<SortOrder>;
|
||||
pipelineProgresses?: InputMaybe<PipelineProgressOrderByRelationAggregateInput>;
|
||||
updatedAt?: InputMaybe<SortOrder>;
|
||||
};
|
||||
|
||||
@ -1303,9 +1324,11 @@ export enum PersonScalarFieldEnum {
|
||||
|
||||
export type PersonUpdateInput = {
|
||||
ActivityTarget?: InputMaybe<ActivityTargetUpdateManyWithoutPersonNestedInput>;
|
||||
PipelineProgress?: InputMaybe<PipelineProgressUpdateManyWithoutPersonNestedInput>;
|
||||
avatarUrl?: InputMaybe<Scalars['String']>;
|
||||
city?: InputMaybe<Scalars['String']>;
|
||||
company?: InputMaybe<CompanyUpdateOneWithoutPeopleNestedInput>;
|
||||
contactPipelineProgresses?: InputMaybe<PipelineProgressUpdateManyWithoutPointOfContactNestedInput>;
|
||||
createdAt?: InputMaybe<Scalars['DateTime']>;
|
||||
email?: InputMaybe<Scalars['String']>;
|
||||
firstName?: InputMaybe<Scalars['String']>;
|
||||
@ -1314,7 +1337,6 @@ export type PersonUpdateInput = {
|
||||
lastName?: InputMaybe<Scalars['String']>;
|
||||
linkedinUrl?: InputMaybe<Scalars['String']>;
|
||||
phone?: InputMaybe<Scalars['String']>;
|
||||
pipelineProgresses?: InputMaybe<PipelineProgressUpdateManyWithoutPointOfContactNestedInput>;
|
||||
updatedAt?: InputMaybe<Scalars['DateTime']>;
|
||||
};
|
||||
|
||||
@ -1330,7 +1352,12 @@ export type PersonUpdateManyWithoutWorkspaceNestedInput = {
|
||||
set?: InputMaybe<Array<PersonWhereUniqueInput>>;
|
||||
};
|
||||
|
||||
export type PersonUpdateOneWithoutPipelineProgressesNestedInput = {
|
||||
export type PersonUpdateOneWithoutContactPipelineProgressesNestedInput = {
|
||||
connect?: InputMaybe<PersonWhereUniqueInput>;
|
||||
disconnect?: InputMaybe<Scalars['Boolean']>;
|
||||
};
|
||||
|
||||
export type PersonUpdateOneWithoutPipelineProgressNestedInput = {
|
||||
connect?: InputMaybe<PersonWhereUniqueInput>;
|
||||
disconnect?: InputMaybe<Scalars['Boolean']>;
|
||||
};
|
||||
@ -1340,10 +1367,12 @@ export type PersonWhereInput = {
|
||||
ActivityTarget?: InputMaybe<ActivityTargetListRelationFilter>;
|
||||
NOT?: InputMaybe<Array<PersonWhereInput>>;
|
||||
OR?: InputMaybe<Array<PersonWhereInput>>;
|
||||
PipelineProgress?: InputMaybe<PipelineProgressListRelationFilter>;
|
||||
avatarUrl?: InputMaybe<StringNullableFilter>;
|
||||
city?: InputMaybe<StringNullableFilter>;
|
||||
company?: InputMaybe<CompanyRelationFilter>;
|
||||
companyId?: InputMaybe<StringNullableFilter>;
|
||||
contactPipelineProgresses?: InputMaybe<PipelineProgressListRelationFilter>;
|
||||
createdAt?: InputMaybe<DateTimeFilter>;
|
||||
email?: InputMaybe<StringNullableFilter>;
|
||||
firstName?: InputMaybe<StringNullableFilter>;
|
||||
@ -1352,7 +1381,6 @@ export type PersonWhereInput = {
|
||||
lastName?: InputMaybe<StringNullableFilter>;
|
||||
linkedinUrl?: InputMaybe<StringNullableFilter>;
|
||||
phone?: InputMaybe<StringNullableFilter>;
|
||||
pipelineProgresses?: InputMaybe<PipelineProgressListRelationFilter>;
|
||||
updatedAt?: InputMaybe<DateTimeFilter>;
|
||||
};
|
||||
|
||||
@ -1391,8 +1419,12 @@ export type PipelineProgress = {
|
||||
__typename?: 'PipelineProgress';
|
||||
amount?: Maybe<Scalars['Int']>;
|
||||
closeDate?: Maybe<Scalars['DateTime']>;
|
||||
company?: Maybe<Company>;
|
||||
companyId?: Maybe<Scalars['String']>;
|
||||
createdAt: Scalars['DateTime'];
|
||||
id: Scalars['ID'];
|
||||
person?: Maybe<Person>;
|
||||
personId?: Maybe<Scalars['String']>;
|
||||
pipeline: Pipeline;
|
||||
pipelineId: Scalars['String'];
|
||||
pipelineStage: PipelineStage;
|
||||
@ -1400,25 +1432,31 @@ export type PipelineProgress = {
|
||||
pointOfContact?: Maybe<Person>;
|
||||
pointOfContactId?: Maybe<Scalars['String']>;
|
||||
probability?: Maybe<Scalars['Int']>;
|
||||
progressableId: Scalars['String'];
|
||||
progressableType: PipelineProgressableType;
|
||||
updatedAt: Scalars['DateTime'];
|
||||
};
|
||||
|
||||
export type PipelineProgressCreateInput = {
|
||||
amount?: InputMaybe<Scalars['Int']>;
|
||||
closeDate?: InputMaybe<Scalars['DateTime']>;
|
||||
company?: InputMaybe<CompanyCreateNestedOneWithoutPipelineProgressInput>;
|
||||
createdAt?: InputMaybe<Scalars['DateTime']>;
|
||||
id?: InputMaybe<Scalars['String']>;
|
||||
person?: InputMaybe<PersonCreateNestedOneWithoutPipelineProgressInput>;
|
||||
pipeline: PipelineCreateNestedOneWithoutPipelineProgressesInput;
|
||||
pipelineStage: PipelineStageCreateNestedOneWithoutPipelineProgressesInput;
|
||||
pointOfContact?: InputMaybe<PersonCreateNestedOneWithoutPipelineProgressesInput>;
|
||||
pointOfContact?: InputMaybe<PersonCreateNestedOneWithoutContactPipelineProgressesInput>;
|
||||
probability?: InputMaybe<Scalars['Int']>;
|
||||
progressableId: Scalars['String'];
|
||||
progressableType: PipelineProgressableType;
|
||||
updatedAt?: InputMaybe<Scalars['DateTime']>;
|
||||
};
|
||||
|
||||
export type PipelineProgressCreateNestedManyWithoutCompanyInput = {
|
||||
connect?: InputMaybe<Array<PipelineProgressWhereUniqueInput>>;
|
||||
};
|
||||
|
||||
export type PipelineProgressCreateNestedManyWithoutPersonInput = {
|
||||
connect?: InputMaybe<Array<PipelineProgressWhereUniqueInput>>;
|
||||
};
|
||||
|
||||
export type PipelineProgressCreateNestedManyWithoutPointOfContactInput = {
|
||||
connect?: InputMaybe<Array<PipelineProgressWhereUniqueInput>>;
|
||||
};
|
||||
@ -1436,8 +1474,12 @@ export type PipelineProgressOrderByRelationAggregateInput = {
|
||||
export type PipelineProgressOrderByWithRelationInput = {
|
||||
amount?: InputMaybe<SortOrder>;
|
||||
closeDate?: InputMaybe<SortOrder>;
|
||||
company?: InputMaybe<CompanyOrderByWithRelationInput>;
|
||||
companyId?: InputMaybe<SortOrder>;
|
||||
createdAt?: InputMaybe<SortOrder>;
|
||||
id?: InputMaybe<SortOrder>;
|
||||
person?: InputMaybe<PersonOrderByWithRelationInput>;
|
||||
personId?: InputMaybe<SortOrder>;
|
||||
pipeline?: InputMaybe<PipelineOrderByWithRelationInput>;
|
||||
pipelineId?: InputMaybe<SortOrder>;
|
||||
pipelineStage?: InputMaybe<PipelineStageOrderByWithRelationInput>;
|
||||
@ -1445,23 +1487,21 @@ export type PipelineProgressOrderByWithRelationInput = {
|
||||
pointOfContact?: InputMaybe<PersonOrderByWithRelationInput>;
|
||||
pointOfContactId?: InputMaybe<SortOrder>;
|
||||
probability?: InputMaybe<SortOrder>;
|
||||
progressableId?: InputMaybe<SortOrder>;
|
||||
progressableType?: InputMaybe<SortOrder>;
|
||||
updatedAt?: InputMaybe<SortOrder>;
|
||||
};
|
||||
|
||||
export enum PipelineProgressScalarFieldEnum {
|
||||
Amount = 'amount',
|
||||
CloseDate = 'closeDate',
|
||||
CompanyId = 'companyId',
|
||||
CreatedAt = 'createdAt',
|
||||
DeletedAt = 'deletedAt',
|
||||
Id = 'id',
|
||||
PersonId = 'personId',
|
||||
PipelineId = 'pipelineId',
|
||||
PipelineStageId = 'pipelineStageId',
|
||||
PointOfContactId = 'pointOfContactId',
|
||||
Probability = 'probability',
|
||||
ProgressableId = 'progressableId',
|
||||
ProgressableType = 'progressableType',
|
||||
UpdatedAt = 'updatedAt',
|
||||
WorkspaceId = 'workspaceId'
|
||||
}
|
||||
@ -1469,17 +1509,29 @@ export enum PipelineProgressScalarFieldEnum {
|
||||
export type PipelineProgressUpdateInput = {
|
||||
amount?: InputMaybe<Scalars['Int']>;
|
||||
closeDate?: InputMaybe<Scalars['DateTime']>;
|
||||
company?: InputMaybe<CompanyUpdateOneWithoutPipelineProgressNestedInput>;
|
||||
createdAt?: InputMaybe<Scalars['DateTime']>;
|
||||
id?: InputMaybe<Scalars['String']>;
|
||||
person?: InputMaybe<PersonUpdateOneWithoutPipelineProgressNestedInput>;
|
||||
pipeline?: InputMaybe<PipelineUpdateOneRequiredWithoutPipelineProgressesNestedInput>;
|
||||
pipelineStage?: InputMaybe<PipelineStageUpdateOneRequiredWithoutPipelineProgressesNestedInput>;
|
||||
pointOfContact?: InputMaybe<PersonUpdateOneWithoutPipelineProgressesNestedInput>;
|
||||
pointOfContact?: InputMaybe<PersonUpdateOneWithoutContactPipelineProgressesNestedInput>;
|
||||
probability?: InputMaybe<Scalars['Int']>;
|
||||
progressableId?: InputMaybe<Scalars['String']>;
|
||||
progressableType?: InputMaybe<PipelineProgressableType>;
|
||||
updatedAt?: InputMaybe<Scalars['DateTime']>;
|
||||
};
|
||||
|
||||
export type PipelineProgressUpdateManyWithoutCompanyNestedInput = {
|
||||
connect?: InputMaybe<Array<PipelineProgressWhereUniqueInput>>;
|
||||
disconnect?: InputMaybe<Array<PipelineProgressWhereUniqueInput>>;
|
||||
set?: InputMaybe<Array<PipelineProgressWhereUniqueInput>>;
|
||||
};
|
||||
|
||||
export type PipelineProgressUpdateManyWithoutPersonNestedInput = {
|
||||
connect?: InputMaybe<Array<PipelineProgressWhereUniqueInput>>;
|
||||
disconnect?: InputMaybe<Array<PipelineProgressWhereUniqueInput>>;
|
||||
set?: InputMaybe<Array<PipelineProgressWhereUniqueInput>>;
|
||||
};
|
||||
|
||||
export type PipelineProgressUpdateManyWithoutPipelineStageNestedInput = {
|
||||
connect?: InputMaybe<Array<PipelineProgressWhereUniqueInput>>;
|
||||
disconnect?: InputMaybe<Array<PipelineProgressWhereUniqueInput>>;
|
||||
@ -1504,8 +1556,12 @@ export type PipelineProgressWhereInput = {
|
||||
OR?: InputMaybe<Array<PipelineProgressWhereInput>>;
|
||||
amount?: InputMaybe<IntNullableFilter>;
|
||||
closeDate?: InputMaybe<DateTimeNullableFilter>;
|
||||
company?: InputMaybe<CompanyRelationFilter>;
|
||||
companyId?: InputMaybe<StringNullableFilter>;
|
||||
createdAt?: InputMaybe<DateTimeFilter>;
|
||||
id?: InputMaybe<StringFilter>;
|
||||
person?: InputMaybe<PersonRelationFilter>;
|
||||
personId?: InputMaybe<StringNullableFilter>;
|
||||
pipeline?: InputMaybe<PipelineRelationFilter>;
|
||||
pipelineId?: InputMaybe<StringFilter>;
|
||||
pipelineStage?: InputMaybe<PipelineStageRelationFilter>;
|
||||
@ -1513,8 +1569,6 @@ export type PipelineProgressWhereInput = {
|
||||
pointOfContact?: InputMaybe<PersonRelationFilter>;
|
||||
pointOfContactId?: InputMaybe<StringNullableFilter>;
|
||||
probability?: InputMaybe<IntNullableFilter>;
|
||||
progressableId?: InputMaybe<StringFilter>;
|
||||
progressableType?: InputMaybe<EnumPipelineProgressableTypeFilter>;
|
||||
updatedAt?: InputMaybe<DateTimeFilter>;
|
||||
};
|
||||
|
||||
@ -2524,7 +2578,22 @@ export type GetPipelineProgressQueryVariables = Exact<{
|
||||
}>;
|
||||
|
||||
|
||||
export type GetPipelineProgressQuery = { __typename?: 'Query', findManyPipelineProgress: Array<{ __typename?: 'PipelineProgress', id: string, pipelineStageId: string, progressableType: PipelineProgressableType, progressableId: string, amount?: number | null, closeDate?: string | null, pointOfContactId?: string | null, probability?: number | null, pointOfContact?: { __typename?: 'Person', id: string, firstName?: string | null, lastName?: string | null, displayName: string, avatarUrl?: string | null } | null }> };
|
||||
export type GetPipelineProgressQuery = { __typename?: 'Query', findManyPipelineProgress: Array<{ __typename?: 'PipelineProgress', id: string, pipelineStageId: string, companyId?: string | null, personId?: string | null, amount?: number | null, closeDate?: string | null, pointOfContactId?: string | null, probability?: number | null, pointOfContact?: { __typename?: 'Person', id: string, firstName?: string | null, lastName?: string | null, displayName: string, avatarUrl?: string | null } | null }> };
|
||||
|
||||
export type DeleteManyPipelineProgressMutationVariables = Exact<{
|
||||
ids?: InputMaybe<Array<Scalars['String']> | Scalars['String']>;
|
||||
}>;
|
||||
|
||||
|
||||
export type DeleteManyPipelineProgressMutation = { __typename?: 'Mutation', deleteManyPipelineProgress: { __typename?: 'AffectedRows', count: number } };
|
||||
|
||||
export type UpdatePipelineStageMutationVariables = Exact<{
|
||||
id?: InputMaybe<Scalars['String']>;
|
||||
data: PipelineStageUpdateInput;
|
||||
}>;
|
||||
|
||||
|
||||
export type UpdatePipelineStageMutation = { __typename?: 'Mutation', updateOnePipelineStage?: { __typename?: 'PipelineStage', id: string, name: string, color: string } | null };
|
||||
|
||||
export type UpdateOnePipelineProgressMutationVariables = Exact<{
|
||||
id?: InputMaybe<Scalars['String']>;
|
||||
@ -2545,31 +2614,15 @@ export type UpdateOnePipelineProgressStageMutationVariables = Exact<{
|
||||
|
||||
export type UpdateOnePipelineProgressStageMutation = { __typename?: 'Mutation', updateOnePipelineProgress?: { __typename?: 'PipelineProgress', id: string } | null };
|
||||
|
||||
export type CreateOnePipelineProgressMutationVariables = Exact<{
|
||||
export type CreateOneCompanyPipelineProgressMutationVariables = Exact<{
|
||||
uuid: Scalars['String'];
|
||||
entityType: PipelineProgressableType;
|
||||
entityId: Scalars['String'];
|
||||
companyId: Scalars['String'];
|
||||
pipelineId: Scalars['String'];
|
||||
pipelineStageId: Scalars['String'];
|
||||
}>;
|
||||
|
||||
|
||||
export type CreateOnePipelineProgressMutation = { __typename?: 'Mutation', createOnePipelineProgress: { __typename?: 'PipelineProgress', id: string } };
|
||||
|
||||
export type DeleteManyPipelineProgressMutationVariables = Exact<{
|
||||
ids?: InputMaybe<Array<Scalars['String']> | Scalars['String']>;
|
||||
}>;
|
||||
|
||||
|
||||
export type DeleteManyPipelineProgressMutation = { __typename?: 'Mutation', deleteManyPipelineProgress: { __typename?: 'AffectedRows', count: number } };
|
||||
|
||||
export type UpdatePipelineStageMutationVariables = Exact<{
|
||||
id?: InputMaybe<Scalars['String']>;
|
||||
data: PipelineStageUpdateInput;
|
||||
}>;
|
||||
|
||||
|
||||
export type UpdatePipelineStageMutation = { __typename?: 'Mutation', updateOnePipelineStage?: { __typename?: 'PipelineStage', id: string, name: string, color: string } | null };
|
||||
export type CreateOneCompanyPipelineProgressMutation = { __typename?: 'Mutation', createOnePipelineProgress: { __typename?: 'PipelineProgress', id: string } };
|
||||
|
||||
export type SearchPeopleQueryVariables = Exact<{
|
||||
where?: InputMaybe<PersonWhereInput>;
|
||||
@ -4360,8 +4413,8 @@ export const GetPipelineProgressDocument = gql`
|
||||
findManyPipelineProgress(where: $where, orderBy: $orderBy) {
|
||||
id
|
||||
pipelineStageId
|
||||
progressableType
|
||||
progressableId
|
||||
companyId
|
||||
personId
|
||||
amount
|
||||
closeDate
|
||||
pointOfContactId
|
||||
@ -4405,6 +4458,75 @@ export function useGetPipelineProgressLazyQuery(baseOptions?: Apollo.LazyQueryHo
|
||||
export type GetPipelineProgressQueryHookResult = ReturnType<typeof useGetPipelineProgressQuery>;
|
||||
export type GetPipelineProgressLazyQueryHookResult = ReturnType<typeof useGetPipelineProgressLazyQuery>;
|
||||
export type GetPipelineProgressQueryResult = Apollo.QueryResult<GetPipelineProgressQuery, GetPipelineProgressQueryVariables>;
|
||||
export const DeleteManyPipelineProgressDocument = gql`
|
||||
mutation DeleteManyPipelineProgress($ids: [String!]) {
|
||||
deleteManyPipelineProgress(where: {id: {in: $ids}}) {
|
||||
count
|
||||
}
|
||||
}
|
||||
`;
|
||||
export type DeleteManyPipelineProgressMutationFn = Apollo.MutationFunction<DeleteManyPipelineProgressMutation, DeleteManyPipelineProgressMutationVariables>;
|
||||
|
||||
/**
|
||||
* __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<DeleteManyPipelineProgressMutation, DeleteManyPipelineProgressMutationVariables>) {
|
||||
const options = {...defaultOptions, ...baseOptions}
|
||||
return Apollo.useMutation<DeleteManyPipelineProgressMutation, DeleteManyPipelineProgressMutationVariables>(DeleteManyPipelineProgressDocument, options);
|
||||
}
|
||||
export type DeleteManyPipelineProgressMutationHookResult = ReturnType<typeof useDeleteManyPipelineProgressMutation>;
|
||||
export type DeleteManyPipelineProgressMutationResult = Apollo.MutationResult<DeleteManyPipelineProgressMutation>;
|
||||
export type DeleteManyPipelineProgressMutationOptions = Apollo.BaseMutationOptions<DeleteManyPipelineProgressMutation, DeleteManyPipelineProgressMutationVariables>;
|
||||
export const UpdatePipelineStageDocument = gql`
|
||||
mutation UpdatePipelineStage($id: String, $data: PipelineStageUpdateInput!) {
|
||||
updateOnePipelineStage(where: {id: $id}, data: $data) {
|
||||
id
|
||||
name
|
||||
color
|
||||
}
|
||||
}
|
||||
`;
|
||||
export type UpdatePipelineStageMutationFn = Apollo.MutationFunction<UpdatePipelineStageMutation, UpdatePipelineStageMutationVariables>;
|
||||
|
||||
/**
|
||||
* __useUpdatePipelineStageMutation__
|
||||
*
|
||||
* To run a mutation, you first call `useUpdatePipelineStageMutation` within a React component and pass it any options that fit your needs.
|
||||
* When your component renders, `useUpdatePipelineStageMutation` 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 [updatePipelineStageMutation, { data, loading, error }] = useUpdatePipelineStageMutation({
|
||||
* variables: {
|
||||
* id: // value for 'id'
|
||||
* data: // value for 'data'
|
||||
* },
|
||||
* });
|
||||
*/
|
||||
export function useUpdatePipelineStageMutation(baseOptions?: Apollo.MutationHookOptions<UpdatePipelineStageMutation, UpdatePipelineStageMutationVariables>) {
|
||||
const options = {...defaultOptions, ...baseOptions}
|
||||
return Apollo.useMutation<UpdatePipelineStageMutation, UpdatePipelineStageMutationVariables>(UpdatePipelineStageDocument, options);
|
||||
}
|
||||
export type UpdatePipelineStageMutationHookResult = ReturnType<typeof useUpdatePipelineStageMutation>;
|
||||
export type UpdatePipelineStageMutationResult = Apollo.MutationResult<UpdatePipelineStageMutation>;
|
||||
export type UpdatePipelineStageMutationOptions = Apollo.BaseMutationOptions<UpdatePipelineStageMutation, UpdatePipelineStageMutationVariables>;
|
||||
export const UpdateOnePipelineProgressDocument = gql`
|
||||
mutation UpdateOnePipelineProgress($id: String, $amount: Int, $closeDate: DateTime, $probability: Int, $pointOfContactId: String) {
|
||||
updateOnePipelineProgress(
|
||||
@ -4484,114 +4606,44 @@ export function useUpdateOnePipelineProgressStageMutation(baseOptions?: Apollo.M
|
||||
export type UpdateOnePipelineProgressStageMutationHookResult = ReturnType<typeof useUpdateOnePipelineProgressStageMutation>;
|
||||
export type UpdateOnePipelineProgressStageMutationResult = Apollo.MutationResult<UpdateOnePipelineProgressStageMutation>;
|
||||
export type UpdateOnePipelineProgressStageMutationOptions = Apollo.BaseMutationOptions<UpdateOnePipelineProgressStageMutation, UpdateOnePipelineProgressStageMutationVariables>;
|
||||
export const CreateOnePipelineProgressDocument = gql`
|
||||
mutation CreateOnePipelineProgress($uuid: String!, $entityType: PipelineProgressableType!, $entityId: String!, $pipelineId: String!, $pipelineStageId: String!) {
|
||||
export const CreateOneCompanyPipelineProgressDocument = gql`
|
||||
mutation CreateOneCompanyPipelineProgress($uuid: String!, $companyId: String!, $pipelineId: String!, $pipelineStageId: String!) {
|
||||
createOnePipelineProgress(
|
||||
data: {id: $uuid, progressableType: $entityType, progressableId: $entityId, pipeline: {connect: {id: $pipelineId}}, pipelineStage: {connect: {id: $pipelineStageId}}}
|
||||
data: {id: $uuid, company: {connect: {id: $companyId}}, pipeline: {connect: {id: $pipelineId}}, pipelineStage: {connect: {id: $pipelineStageId}}}
|
||||
) {
|
||||
id
|
||||
}
|
||||
}
|
||||
`;
|
||||
export type CreateOnePipelineProgressMutationFn = Apollo.MutationFunction<CreateOnePipelineProgressMutation, CreateOnePipelineProgressMutationVariables>;
|
||||
export type CreateOneCompanyPipelineProgressMutationFn = Apollo.MutationFunction<CreateOneCompanyPipelineProgressMutation, CreateOneCompanyPipelineProgressMutationVariables>;
|
||||
|
||||
/**
|
||||
* __useCreateOnePipelineProgressMutation__
|
||||
* __useCreateOneCompanyPipelineProgressMutation__
|
||||
*
|
||||
* 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:
|
||||
* To run a mutation, you first call `useCreateOneCompanyPipelineProgressMutation` within a React component and pass it any options that fit your needs.
|
||||
* When your component renders, `useCreateOneCompanyPipelineProgressMutation` 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({
|
||||
* const [createOneCompanyPipelineProgressMutation, { data, loading, error }] = useCreateOneCompanyPipelineProgressMutation({
|
||||
* variables: {
|
||||
* uuid: // value for 'uuid'
|
||||
* entityType: // value for 'entityType'
|
||||
* entityId: // value for 'entityId'
|
||||
* companyId: // value for 'companyId'
|
||||
* pipelineId: // value for 'pipelineId'
|
||||
* pipelineStageId: // value for 'pipelineStageId'
|
||||
* },
|
||||
* });
|
||||
*/
|
||||
export function useCreateOnePipelineProgressMutation(baseOptions?: Apollo.MutationHookOptions<CreateOnePipelineProgressMutation, CreateOnePipelineProgressMutationVariables>) {
|
||||
export function useCreateOneCompanyPipelineProgressMutation(baseOptions?: Apollo.MutationHookOptions<CreateOneCompanyPipelineProgressMutation, CreateOneCompanyPipelineProgressMutationVariables>) {
|
||||
const options = {...defaultOptions, ...baseOptions}
|
||||
return Apollo.useMutation<CreateOnePipelineProgressMutation, CreateOnePipelineProgressMutationVariables>(CreateOnePipelineProgressDocument, options);
|
||||
return Apollo.useMutation<CreateOneCompanyPipelineProgressMutation, CreateOneCompanyPipelineProgressMutationVariables>(CreateOneCompanyPipelineProgressDocument, options);
|
||||
}
|
||||
export type CreateOnePipelineProgressMutationHookResult = ReturnType<typeof useCreateOnePipelineProgressMutation>;
|
||||
export type CreateOnePipelineProgressMutationResult = Apollo.MutationResult<CreateOnePipelineProgressMutation>;
|
||||
export type CreateOnePipelineProgressMutationOptions = Apollo.BaseMutationOptions<CreateOnePipelineProgressMutation, CreateOnePipelineProgressMutationVariables>;
|
||||
export const DeleteManyPipelineProgressDocument = gql`
|
||||
mutation DeleteManyPipelineProgress($ids: [String!]) {
|
||||
deleteManyPipelineProgress(where: {id: {in: $ids}}) {
|
||||
count
|
||||
}
|
||||
}
|
||||
`;
|
||||
export type DeleteManyPipelineProgressMutationFn = Apollo.MutationFunction<DeleteManyPipelineProgressMutation, DeleteManyPipelineProgressMutationVariables>;
|
||||
|
||||
/**
|
||||
* __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<DeleteManyPipelineProgressMutation, DeleteManyPipelineProgressMutationVariables>) {
|
||||
const options = {...defaultOptions, ...baseOptions}
|
||||
return Apollo.useMutation<DeleteManyPipelineProgressMutation, DeleteManyPipelineProgressMutationVariables>(DeleteManyPipelineProgressDocument, options);
|
||||
}
|
||||
export type DeleteManyPipelineProgressMutationHookResult = ReturnType<typeof useDeleteManyPipelineProgressMutation>;
|
||||
export type DeleteManyPipelineProgressMutationResult = Apollo.MutationResult<DeleteManyPipelineProgressMutation>;
|
||||
export type DeleteManyPipelineProgressMutationOptions = Apollo.BaseMutationOptions<DeleteManyPipelineProgressMutation, DeleteManyPipelineProgressMutationVariables>;
|
||||
export const UpdatePipelineStageDocument = gql`
|
||||
mutation UpdatePipelineStage($id: String, $data: PipelineStageUpdateInput!) {
|
||||
updateOnePipelineStage(where: {id: $id}, data: $data) {
|
||||
id
|
||||
name
|
||||
color
|
||||
}
|
||||
}
|
||||
`;
|
||||
export type UpdatePipelineStageMutationFn = Apollo.MutationFunction<UpdatePipelineStageMutation, UpdatePipelineStageMutationVariables>;
|
||||
|
||||
/**
|
||||
* __useUpdatePipelineStageMutation__
|
||||
*
|
||||
* To run a mutation, you first call `useUpdatePipelineStageMutation` within a React component and pass it any options that fit your needs.
|
||||
* When your component renders, `useUpdatePipelineStageMutation` 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 [updatePipelineStageMutation, { data, loading, error }] = useUpdatePipelineStageMutation({
|
||||
* variables: {
|
||||
* id: // value for 'id'
|
||||
* data: // value for 'data'
|
||||
* },
|
||||
* });
|
||||
*/
|
||||
export function useUpdatePipelineStageMutation(baseOptions?: Apollo.MutationHookOptions<UpdatePipelineStageMutation, UpdatePipelineStageMutationVariables>) {
|
||||
const options = {...defaultOptions, ...baseOptions}
|
||||
return Apollo.useMutation<UpdatePipelineStageMutation, UpdatePipelineStageMutationVariables>(UpdatePipelineStageDocument, options);
|
||||
}
|
||||
export type UpdatePipelineStageMutationHookResult = ReturnType<typeof useUpdatePipelineStageMutation>;
|
||||
export type UpdatePipelineStageMutationResult = Apollo.MutationResult<UpdatePipelineStageMutation>;
|
||||
export type UpdatePipelineStageMutationOptions = Apollo.BaseMutationOptions<UpdatePipelineStageMutation, UpdatePipelineStageMutationVariables>;
|
||||
export type CreateOneCompanyPipelineProgressMutationHookResult = ReturnType<typeof useCreateOneCompanyPipelineProgressMutation>;
|
||||
export type CreateOneCompanyPipelineProgressMutationResult = Apollo.MutationResult<CreateOneCompanyPipelineProgressMutation>;
|
||||
export type CreateOneCompanyPipelineProgressMutationOptions = Apollo.BaseMutationOptions<CreateOneCompanyPipelineProgressMutation, CreateOneCompanyPipelineProgressMutationVariables>;
|
||||
export const SearchPeopleDocument = gql`
|
||||
query SearchPeople($where: PersonWhereInput, $limit: Int, $orderBy: [PersonOrderByWithRelationInput!]) {
|
||||
searchResults: findManyPerson(where: $where, take: $limit, orderBy: $orderBy) {
|
||||
|
||||
Reference in New Issue
Block a user