diff --git a/.gitignore b/.gitignore index ec6658c5..2ffa2d62 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,6 @@ .DS_Store .project .buildpath +.idea/ /vendor /.settings \ No newline at end of file diff --git a/src/crm/api/handler/EntityAPIHandler.php b/src/crm/api/handler/EntityAPIHandler.php index e2b59b6c..9a0ea6ce 100644 --- a/src/crm/api/handler/EntityAPIHandler.php +++ b/src/crm/api/handler/EntityAPIHandler.php @@ -28,13 +28,14 @@ public static function getInstance($zcrmrecord) { return new EntityAPIHandler($zcrmrecord); } - - public function getRecord() + + public function getRecord(array $params = array()) { try { $this->requestMethod = APIConstants::REQUEST_METHOD_GET; $this->urlPath = $this->record->getModuleApiName() . "/" . $this->record->getEntityId(); $this->addHeader("Content-Type", "application/json"); + $this->setRequestParams($params); $responseInstance = APIRequest::getInstance($this)->getAPIResponse(); $recordDetails = $responseInstance->getResponseJSON()['data']; self::setRecordProperties($recordDetails[0]);