File manager - Edit - /home/web/vm-3fadc827.na4u.ru/www/bitrix/modules/sale/lib/exchange/entity/userprofilecontactcompany.php
Back
<?php namespace Bitrix\Sale\Exchange\Entity; use Bitrix\Crm\Order\Matcher\EntityMatchManager; use Bitrix\Crm\Order\Order; use Bitrix\Sale\Exchange\EntityType; use Bitrix\Sale\Result; class UserProfileContactCompany extends UserProfileImport { public function getOwnerTypeId() { return EntityType::USER_PROFILE_CONTACT_COMPANY; } public function add(array $params) { $result = new Result(); $r = parent::add($params); if($r->isSuccess()) { $userId = $this->getEntity()->getField('ID'); $property = $params["ORDER_PROP"]; $order = Order::create($userId); $order->getPropertyCollection()->setValuesFromPost(['PROPERTIES'=>$property], []); EntityMatchManager::getInstance()->match($order); } return $result; } }
| ver. 1.4 |
Github
|
.
| PHP 7.4.33 | Generation time: 0.26 |
proxy
|
phpinfo
|
Settings