mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/izyim.git
synced 2026-08-23 06:23:59 +00:00
Merge branch 'create-contact-new' into Contact-Cleanup
# Conflicts: # app/Classes/Modules/Contacts/DataTransferObjects/ContactObject.php # app/Classes/Modules/Contacts/Exceptions/CannotCreateContactException.php # app/Classes/Modules/Contacts/Services/CreatesContact.php # app/Classes/Modules/ControllersLogic/Contacts/CreateContactLogic.php # app/Http/Controllers/Contacts/CreateContactController.php # routes/api.php
This commit is contained in:
@@ -1,10 +1,16 @@
|
||||
<?php
|
||||
|
||||
namespace App\Classes\Modules\Contacts\DataTransferObjects;
|
||||
namespace App\Modules\Contacts\DataTransferObjects;
|
||||
|
||||
class ContactObject
|
||||
{
|
||||
|
||||
/** @var int */
|
||||
private $type;
|
||||
|
||||
/** @var int */
|
||||
private $referenceId;
|
||||
|
||||
/** @var string */
|
||||
private $name;
|
||||
|
||||
@@ -17,29 +23,39 @@ class ContactObject
|
||||
/** @var string */
|
||||
private $email;
|
||||
|
||||
/** @var int|null */
|
||||
private $type;
|
||||
|
||||
/** @var int|null */
|
||||
private $referenceId;
|
||||
|
||||
/** @var int|null */
|
||||
private $id;
|
||||
|
||||
|
||||
/**
|
||||
* ContactObject constructor.
|
||||
* @param int $type
|
||||
* @param int $referenceId
|
||||
* @param string $name
|
||||
* @param string $designation
|
||||
* @param string $contact
|
||||
* @param string $email
|
||||
*/
|
||||
public function __construct(string $name, string $designation,string $contact, string $email)
|
||||
public function __construct(int $type, int $referenceId, string $name, string $designation, string $contact, string $email)
|
||||
{
|
||||
$this->type = $type;
|
||||
$this->referenceId = $referenceId;
|
||||
$this->name = $name;
|
||||
$this->designation = $designation;
|
||||
$this->email = $email;
|
||||
$this->contact = $contact;
|
||||
$this->email = $email;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return int
|
||||
*/
|
||||
public function getType(): int
|
||||
{
|
||||
return $this->type;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return int
|
||||
*/
|
||||
public function getReferenceId(): int
|
||||
{
|
||||
return $this->referenceId;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -58,14 +74,6 @@ class ContactObject
|
||||
return $this->designation;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
public function getEmail(): string
|
||||
{
|
||||
return $this->email;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
@@ -75,52 +83,14 @@ class ContactObject
|
||||
}
|
||||
|
||||
/**
|
||||
* @return int|null
|
||||
* @return string
|
||||
*/
|
||||
public function getType(): ?int
|
||||
public function getEmail(): string
|
||||
{
|
||||
return $this->type;
|
||||
return $this->email;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return int|null
|
||||
*/
|
||||
public function getReferenceId(): ?int
|
||||
{
|
||||
return $this->referenceId;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return int|null
|
||||
*/
|
||||
public function getId()
|
||||
{
|
||||
return $this->id;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int|null $type
|
||||
*/
|
||||
public function setType($type)
|
||||
{
|
||||
$this->type = $type;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int|null $referenceId
|
||||
*/
|
||||
public function setReferenceId($referenceId)
|
||||
{
|
||||
$this->referenceId = $referenceId;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int|null $id
|
||||
*/
|
||||
public function setId($id)
|
||||
{
|
||||
$this->id = $id;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user