From ea6be8d6987b51f4f90da762783f160f619f3b2f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Benjamin=20Beganovi=C4=87?= Date: Wed, 31 Jan 2024 18:47:21 +0100 Subject: [PATCH] Add showRff method to ClientContact model --- app/Models/ClientContact.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/app/Models/ClientContact.php b/app/Models/ClientContact.php index c2a7e340fc84..04307dce367e 100644 --- a/app/Models/ClientContact.php +++ b/app/Models/ClientContact.php @@ -351,5 +351,12 @@ class ClientContact extends Authenticatable implements HasLocalePreference return config('ninja.react_url')."/#/clients/{$this->client->hashed_id}"; } + public function showRff(): bool + { + if (\strlen($this->first_name) === 0 || \strlen($this->last_name) === 0 || \strlen($this->email) === 0) { + return true; + } + return false; + } }