@@ -138,7 +138,7 @@ |
||
| 138 | 138 | $response = $this->postRequest('/private/api/v2/json/contacts/set', $parameters); |
| 139 | 139 | |
| 140 | 140 | if (isset($response['contacts']['add'])) { |
| 141 | - $result = array_map(function ($item) { |
|
| 141 | + $result = array_map(function($item) { |
|
| 142 | 142 | return $item['id']; |
| 143 | 143 | }, $response['contacts']['add']); |
| 144 | 144 | } else { |
@@ -99,7 +99,7 @@ |
||
| 99 | 99 | $response = $this->postRequest('/private/api/v2/json/pipelines/set', $parameters); |
| 100 | 100 | |
| 101 | 101 | if (isset($response['pipelines']['add']['pipelines'])) { |
| 102 | - $result = array_map(function ($item) { |
|
| 102 | + $result = array_map(function($item) { |
|
| 103 | 103 | return $item['id']; |
| 104 | 104 | }, $response['pipelines']['add']['pipelines']); |
| 105 | 105 | } else { |
@@ -75,7 +75,7 @@ |
||
| 75 | 75 | $response = $this->postRequest('/private/api/v2/json/customers_periods/set', $parameters); |
| 76 | 76 | |
| 77 | 77 | if (isset($response['customers_periods']['set'])) { |
| 78 | - $result = array_map(function ($item) { |
|
| 78 | + $result = array_map(function($item) { |
|
| 79 | 79 | return $item['id']; |
| 80 | 80 | }, $response['customers_periods']['set']); |
| 81 | 81 | } else { |
@@ -104,7 +104,7 @@ |
||
| 104 | 104 | $response = $this->postRequest('/private/api/v2/json/customers/set', $parameters); |
| 105 | 105 | |
| 106 | 106 | if (isset($response['customers']['add'])) { |
| 107 | - $result = array_map(function ($item) { |
|
| 107 | + $result = array_map(function($item) { |
|
| 108 | 108 | return $item['id']; |
| 109 | 109 | }, $response['customers']['add']['customers']); |
| 110 | 110 | } else { |
@@ -77,7 +77,7 @@ |
||
| 77 | 77 | $response = $this->postRequest('/private/api/v2/json/fields/set', $parameters); |
| 78 | 78 | |
| 79 | 79 | if (isset($response['fields']['add'])) { |
| 80 | - $result = array_map(function ($item) { |
|
| 80 | + $result = array_map(function($item) { |
|
| 81 | 81 | return $item['id']; |
| 82 | 82 | }, $response['fields']['add']); |
| 83 | 83 | } else { |
@@ -35,7 +35,7 @@ |
||
| 35 | 35 | * @param array $parameters Массив параметров к amoCRM API |
| 36 | 36 | * @return array Ответ amoCRM API |
| 37 | 37 | */ |
| 38 | - public function apiList($parameters=[]) |
|
| 38 | + public function apiList($parameters = []) |
|
| 39 | 39 | { |
| 40 | 40 | $response = $this->getRequest('/private/api/v2/json/catalogs/list', $parameters); |
| 41 | 41 | |