Skip to content
This repository has been archived by the owner on Feb 7, 2025. It is now read-only.

Commit

Permalink
bump php version to 8.3.*
Browse files Browse the repository at this point in the history
Signed-off-by: mesilov <[email protected]>
  • Loading branch information
mesilov committed Jan 4, 2024
1 parent c7d4d47 commit 6a6ccef
Show file tree
Hide file tree
Showing 4 changed files with 41 additions and 73 deletions.
2 changes: 0 additions & 2 deletions .github/workflows/phpunit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@ jobs:
strategy:
matrix:
php-version:
- "8.1"
- "8.2"
- "8.3"
dependencies: [ highest ]
operating-system: [ ubuntu-latest, windows-latest ]
Expand Down
43 changes: 21 additions & 22 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,38 +12,37 @@
"license": "MIT",
"authors": [
{
"name": "Maxim Mesilov",
"name": "Maksim Mesilov",
"homepage": "https://github.com/mesilov/"
},
{
"name": "Kirill Hramov",
"homepage": "https://github.com/KarlsonComplete"
}
],
"config": {
"sort-packages": true
},
"require": {
"php": "8.1.* || 8.2.* || 8.3.*",
"php": "8.3.*",
"ext-json": "*",
"ext-bcmath": "*",
"ext-curl": "*",
"psr/log": "^1.1.4 || ^2.0 || ^3.0",
"ext-intl": "*",
"psr/log": "1.1.*",
"fig/http-message-util": "1.1.*",
"symfony/http-client": "5.4.* || 6.*",
"symfony/http-client-contracts": "^2.5 || ^3.1",
"symfony/http-foundation": "5.4.* || 6.*",
"symfony/event-dispatcher": "5.4.* || 6.*",
"ramsey/uuid": "^4.2.3",
"moneyphp/money": "3.* || 4.*",
"symfony/uid": "6.*",
"ext-intl": "*"
"ramsey/uuid": "4.7.*",
"moneyphp/money": "4.3.*",
"symfony/http-client": "7.0.*",
"symfony/http-client-contracts": "3.4.*",
"symfony/http-foundation": "7.0.*",
"symfony/event-dispatcher": "7.0.*",
"symfony/uid": "7.0.*"
},
"require-dev": {
"monolog/monolog": "2.1.*",
"symfony/console": "5.4.* || 6.*",
"symfony/dotenv": "5.4.* || 6.*",
"symfony/debug-bundle": "5.4.* || 6.*",
"phpstan/phpstan": "1.*",
"phpunit/phpunit": "9.5.*",
"symfony/stopwatch": "5.4.* || 6.*",
"monolog/monolog": "2.9.*",
"phpstan/phpstan": "1.10.*",
"phpunit/phpunit": "10.5.*",
"symfony/console": "7.0.*",
"symfony/dotenv": "7.0.*",
"symfony/debug-bundle": "7.0.*",
"symfony/stopwatch": "7.0.*",
"roave/security-advisories": "dev-master"
},
"autoload": {
Expand Down
40 changes: 17 additions & 23 deletions phpunit.xml.dist
Original file line number Diff line number Diff line change
@@ -1,25 +1,19 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.3/phpunit.xsd"
backupGlobals="false"
colors="true"
bootstrap="tests/bootstrap.php"
failOnRisky="true"
failOnWarning="true">
<coverage>
<include>
<directory>./src</directory>
</include>
</coverage>
<php>
<ini name="error_reporting" value="-1"/>
</php>
<testsuites>
<testsuite name="unit_tests">
<directory>./tests/Unit</directory>
</testsuite>
<testsuite name="integration_tests">
<directory>./tests/Integration</directory>
</testsuite>
</testsuites>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/10.5/phpunit.xsd" backupGlobals="false" colors="true" bootstrap="tests/bootstrap.php" failOnRisky="true" failOnWarning="true">
<php>
<ini name="error_reporting" value="-1"/>
</php>
<testsuites>
<testsuite name="unit_tests">
<directory>./tests/Unit</directory>
</testsuite>
<testsuite name="integration_tests">
<directory>./tests/Integration</directory>
</testsuite>
</testsuites>
<source>
<include>
<directory>./src</directory>
</include>
</source>
</phpunit>
29 changes: 3 additions & 26 deletions src/Services/CRM/Contact/Service/Batch.php
Original file line number Diff line number Diff line change
Expand Up @@ -121,8 +121,8 @@ class Batch extends AbstractBatchService
* WEB?: string,
* IM?: string,
* } $filter
* @param array $select = ['ID','HONORIFIC','NAME','SECOND_NAME','LAST_NAME','PHOTO','BIRTHDATE','TYPE_ID','SOURCE_ID','SOURCE_DESCRIPTION','POST','ADDRESS','ADDRESS_2','ADDRESS_CITY','ADDRESS_POSTAL_CODE','ADDRESS_REGION','ADDRESS_PROVINCE','ADDRESS_COUNTRY','ADDRESS_COUNTRY_CODE','ADDRESS_LOC_ADDR_ID','COMMENTS','OPENED','EXPORT','HAS_PHONE','HAS_EMAIL','HAS_IMOL','ASSIGNED_BY_ID','CREATED_BY_ID','MODIFY_BY_ID','DATE_CREATE','DATE_MODIFY','COMPANY_ID','COMPANY_IDS','LEAD_ID','ORIGINATOR_ID','ORIGIN_ID','ORIGIN_VERSION','FACE_ID','UTM_SOURCE','UTM_MEDIUM','UTM_CAMPAIGN','UTM_CONTENT','UTM_TERM','PHONE','EMAIL','WEB','IM']
* @param int|null $limit
* @param array $select = ['ID','HONORIFIC','NAME','SECOND_NAME','LAST_NAME','PHOTO','BIRTHDATE','TYPE_ID','SOURCE_ID','SOURCE_DESCRIPTION','POST','ADDRESS','ADDRESS_2','ADDRESS_CITY','ADDRESS_POSTAL_CODE','ADDRESS_REGION','ADDRESS_PROVINCE','ADDRESS_COUNTRY','ADDRESS_COUNTRY_CODE','ADDRESS_LOC_ADDR_ID','COMMENTS','OPENED','EXPORT','HAS_PHONE','HAS_EMAIL','HAS_IMOL','ASSIGNED_BY_ID','CREATED_BY_ID','MODIFY_BY_ID','DATE_CREATE','DATE_MODIFY','COMPANY_ID','COMPANY_IDS','LEAD_ID','ORIGINATOR_ID','ORIGIN_ID','ORIGIN_VERSION','FACE_ID','UTM_SOURCE','UTM_MEDIUM','UTM_CAMPAIGN','UTM_CONTENT','UTM_TERM','PHONE','EMAIL','WEB','IM']
* @param int|null $limit
*
* @return Generator<int, ContactItemResult>
* @throws BaseException
Expand Down Expand Up @@ -220,9 +220,7 @@ public function add(array $contacts): Generator
* 'params' => []
* ]
*
* @param array <int, array> $entityItems
*
* @param array $entityItems
* @param array<int, array> $entityItems
* @return Generator
* @throws BaseException
*/
Expand All @@ -247,25 +245,4 @@ public function delete(array $contactId): Generator
yield $key => new DeletedItemBatchResult($item);
}
}

/**
* Update contact
*
* Update elements in array with structure
* element_id => [ // contact id
* 'fields' => [], // contact fields to update
* 'params' => []
* ]
*
* @param array <int, array> $entityItems
*
* @return \Generator
* @throws \Bitrix24\SDK\Core\Exceptions\BaseException
*/
public function update(array $entityItems): Generator
{
foreach ($this->batch->updateEntityItems('crm.contact.update', $entityItems) as $key => $item) {
yield $key => new UpdatedItemBatchResult($item);
}
}
}

0 comments on commit 6a6ccef

Please sign in to comment.