From d92652d974ac04ca6fdd8b4da2676c716f1a9432 Mon Sep 17 00:00:00 2001 From: kaioken Date: Thu, 15 Feb 2024 19:21:20 -0400 Subject: [PATCH 1/2] refact: leads delete test --- tests/Connectors/Integration/Zoho/LeadActivityTest.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/Connectors/Integration/Zoho/LeadActivityTest.php b/tests/Connectors/Integration/Zoho/LeadActivityTest.php index 6d57d0521..fd8943d47 100644 --- a/tests/Connectors/Integration/Zoho/LeadActivityTest.php +++ b/tests/Connectors/Integration/Zoho/LeadActivityTest.php @@ -54,6 +54,8 @@ public function testLeadCreationWorkflow(): void $zohoService = new ZohoService($app, $company); $zohoService->deleteLead($lead); + $zohoService->leads->delete($result['leadId']); + $this->assertArrayHasKey('zohoLeadId', $result); $this->assertArrayHasKey('zohoRequest', $result); From e30a1f325944adf8f6100345503978dc7a762b3e Mon Sep 17 00:00:00 2001 From: kaioken Date: Sun, 18 Feb 2024 16:13:36 -0400 Subject: [PATCH 2/2] refact : signup phone --- graphql/schemas/Ecosystem/user.graphql | 1 + src/Kanvas/Auth/DataTransferObject/RegisterInput.php | 3 ++- tests/Connectors/Integration/Zoho/LeadActivityTest.php | 2 -- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/graphql/schemas/Ecosystem/user.graphql b/graphql/schemas/Ecosystem/user.graphql index 3dae9baba..0f58fbd95 100644 --- a/graphql/schemas/Ecosystem/user.graphql +++ b/graphql/schemas/Ecosystem/user.graphql @@ -104,6 +104,7 @@ input RegisterInput { password: String! @rules(apply: ["required", "min:8"]) password_confirmation: String! @rules(apply: ["required"]) company_name: String + phone_number: String custom_fields: [CustomFieldEntityInput!] } diff --git a/src/Kanvas/Auth/DataTransferObject/RegisterInput.php b/src/Kanvas/Auth/DataTransferObject/RegisterInput.php index ff9ae1a33..7cb4cf64b 100644 --- a/src/Kanvas/Auth/DataTransferObject/RegisterInput.php +++ b/src/Kanvas/Auth/DataTransferObject/RegisterInput.php @@ -51,7 +51,8 @@ public static function viaRequest(Request $request): self password: Hash::make($request->get('password')), default_company: $request->get('default_company') ?? null, role_ids: $roles, - custom_fields: $request->get('custom_fields') ?? [] + custom_fields: $request->get('custom_fields') ?? [], + phone_number: $request->get('phone_number') ?? null, ); } diff --git a/tests/Connectors/Integration/Zoho/LeadActivityTest.php b/tests/Connectors/Integration/Zoho/LeadActivityTest.php index fd8943d47..6d57d0521 100644 --- a/tests/Connectors/Integration/Zoho/LeadActivityTest.php +++ b/tests/Connectors/Integration/Zoho/LeadActivityTest.php @@ -54,8 +54,6 @@ public function testLeadCreationWorkflow(): void $zohoService = new ZohoService($app, $company); $zohoService->deleteLead($lead); - $zohoService->leads->delete($result['leadId']); - $this->assertArrayHasKey('zohoLeadId', $result); $this->assertArrayHasKey('zohoRequest', $result);