Skip to content

Commit

Permalink
Merge pull request #75 from bakaphp/feat/create-lead-new-fields
Browse files Browse the repository at this point in the history
Feat/ add new fields lead - agents
  • Loading branch information
lizandro-mc authored Sep 19, 2023
2 parents 6397d63 + 702522f commit 0ee1509
Show file tree
Hide file tree
Showing 4 changed files with 38 additions and 6 deletions.
5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
"version": "0.0.36",

"version": "0.0.37",
"license": "MIT",
"main": "dist/index.js",
"typings": "dist/index.d.ts",
Expand Down Expand Up @@ -58,4 +59,4 @@
"graphql": "^16.6.0",
"typescript-transform-paths": "^3.4.6"
}
}
}
33 changes: 31 additions & 2 deletions src/mutations/leads.mutation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,25 +11,54 @@ export const CREATE_LEAD_MUTATION = gql`
created_at
description
reason_lost
owner {
user {
id
firstname
lastname
}
user {
owner {
id
firstname
lastname
displayname
}
company {
id
name
}
organization {
name
}
people {
name
contacts {
type {
name
}
value
}
}
receiver {
name
uuid
}
status {
id
name
is_default
}
type {
name
}
source {
name
}
pipeline {
name
}
stage {
name
}
custom_fields {
data {
name
Expand Down
4 changes: 3 additions & 1 deletion src/queries/agents.query.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@ export const GET_ALL_AGENTS_QUERY = gql`
data {
member_id
name
status_id
status {
name
}
total_leads
created_at
user {
Expand Down
2 changes: 1 addition & 1 deletion src/types/agents.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ interface User {
export interface Agent {
member_id: number;
name: string;
status_id?: number;
status?: { name: string };
total_leads?: number;
user?: User;
}
Expand Down

0 comments on commit 0ee1509

Please sign in to comment.