1
0
Fork 0
mirror of synced 2025-04-20 01:21:01 +00:00

add response models

This commit is contained in:
Sergey Chazov 2020-09-29 11:33:19 +03:00
parent 8cd87c54f5
commit e81bde0ee7
25 changed files with 719 additions and 145 deletions

View file

@ -0,0 +1,38 @@
<?php
/**
* PHP version 7.1
*
* @category Integration
* @package Intaro\RetailCrm\Model\Api\Response\Loyalty
* @author retailCRM <integration@retailcrm.ru>
* @license MIT
* @link http://retailcrm.ru
* @see http://retailcrm.ru/docs
*/
namespace Intaro\RetailCrm\Model\Api;
/**
* Class CalculateMaximum
*
* @package Intaro\RetailCrm\Model\Api
*/
class CalculateMaximum
{
/**
* Привилегия с максимальной выгодой
*
* @var string $privilegeType
*
* @Mapping\Type("string")
* @Mapping\SerializedName("privilegeType")
*/
public $privilegeType;
/**
* @var \Intaro\RetailCrm\Model\Api\AbstractLoyaltyEvent
*
* @Mapping\Type("\Intaro\RetailCrm\Model\Api\AbstractLoyaltyEvent")
* @Mapping\SerializedName("loyaltyEvent")
*/
public $loyaltyEvent;
}

View file

@ -0,0 +1,30 @@
<?php
/**
* PHP version 7.1
*
* @category Integration
* @package Intaro\RetailCrm\Model\Api
* @author retailCRM <integration@retailcrm.ru>
* @license MIT
* @link http://retailcrm.ru
* @see http://retailcrm.ru/docs
*/
namespace Intaro\RetailCrm\Model\Api;
/**
* Class AbstractLoyaltyEvent
*
* @package Intaro\RetailCrm\Model\Api
*/
class AbstractLoyaltyEvent
{
/**
* ID события
*
* @var integer $id
*
* @Mapping\Type("integer")
* @Mapping\SerializedName("id")
*/
public $id;
}

View file

@ -299,4 +299,14 @@ class Customer extends AbstractApiModel
* @Mapping\SerializedName("mainCustomerContact")
*/
public $mainCustomerContact;
/**
* Персональная скидка
*
* @var double $mainCustomerContact
*
* @Mapping\Type("double")
* @Mapping\SerializedName("personalDiscount")
*/
public $personalDiscount;
}

View file

@ -18,6 +18,16 @@ namespace Intaro\RetailCrm\Model\Api;
*/
class LoyaltyAccount
{
/**
* Номер телефона
*
* @var boolean $active
*
* @Mapping\Type("boolean")
* @Mapping\SerializedName("active")
*/
public $active;
/**
* Номер телефона
*
@ -47,4 +57,42 @@ class LoyaltyAccount
* @Mapping\SerializedName("id")
*/
public $id;
/**
* Количество бонусов
*
* @var float $amount
*
* @Mapping\Type("float")
* @Mapping\SerializedName("amount")
*/
public $amount;
/**
* Дата создания
*
* @var \DateTime $createdAt
*
* @Mapping\Type("DateTime<'Y-m-d H:i:s'>")
* @Mapping\SerializedName("createdAt")
*/
public $createdAt;
/**
* @var \DateTime $activatedAt
*
* @Mapping\Type("DateTime<'Y-m-d H:i:s'>")
* @Mapping\SerializedName("activatedAt")
*/
public $activatedAt;
/**
* Идентификатор последней смс-верификации
*
* @var string $lastCheckId
*
* @Mapping\Type("string")
* @Mapping\SerializedName("lastCheckId")
*/
public $lastCheckId;
}

View file

@ -0,0 +1,60 @@
<?php
/**
* PHP version 7.1
*
* @category Integration
* @package Intaro\RetailCrm\Model\Api\Response\Loyalty
* @author retailCRM <integration@retailcrm.ru>
* @license MIT
* @link http://retailcrm.ru
* @see http://retailcrm.ru/docs
*/
namespace Intaro\RetailCrm\Model\Api;
/**
* Class LoyaltyCalculation
*
* @package Intaro\RetailCrm\Model\Api
*/
class LoyaltyCalculation
{
/**
* Тип привилегии
*
* @var string $privilegeType
*
* @Mapping\Type("string")
* @Mapping\SerializedName("privilegeType")
*/
public $privilegeType;
/**
* Суммарная скидка на заказ
*
* @var float $amount
*
* @Mapping\Type("float")
* @Mapping\SerializedName("amount")
*/
public $amount;
/**
* Будет начислено бонусов
*
* @var float $bonuses
*
* @Mapping\Type("float")
* @Mapping\SerializedName("bonuses")
*/
public $bonuses;
/**
* Итоговая сумма выгоды
*
* @var float $total
*
* @Mapping\Type("float")
* @Mapping\SerializedName("total")
*/
public $total;
}

View file

@ -0,0 +1,40 @@
<?php
/**
* PHP version 7.1
*
* @category Integration
* @package Intaro\RetailCrm\Model\Api
* @author retailCRM <integration@retailcrm.ru>
* @license MIT
* @link http://retailcrm.ru
* @see http://retailcrm.ru/docs
*/
namespace Intaro\RetailCrm\Model\Api;
/**
* Class LoyaltyLevel
*
* @package Intaro\RetailCrm\Model\Api
*/
class LoyaltyLevel
{
/**
* ID уровня
*
* @var integer $id
*
* @Mapping\Type("string")
* @Mapping\SerializedName("id")
*/
public $id;
/**
* Название уровня
*
* @var string $name
*
* @Mapping\Type("string")
* @Mapping\SerializedName("name")
*/
public $name;
}

View file

@ -0,0 +1,90 @@
<?php
/**
* PHP version 7.1
*
* @category Integration
* @package Intaro\RetailCrm\Model\Api
* @author retailCRM <integration@retailcrm.ru>
* @license MIT
* @link http://retailcrm.ru
* @see http://retailcrm.ru/docs
*/
namespace Intaro\RetailCrm\Model\Api;
/**
* Class OrderProduct
*
* @package Intaro\RetailCrm\Model\Api
*/
class OrderProduct
{
/**
* Количество списанных бонусов
*
* @var double $bonusesChargeTotal
*
* @Mapping\Type("double")
* @Mapping\SerializedName("bonusesChargeTotal")
*/
public $bonusesChargeTotal;
/**
* Количество начисленных бонусов
*
* @var double $bonusesCreditTotal
*
* @Mapping\Type("double")
* @Mapping\SerializedName("bonusesCreditTotal")
*/
public $bonusesCreditTotal;
/**
* Тип цены
*
* @var \Intaro\RetailCrm\Model\Api\PriceType
*
* @Mapping\Type("\Intaro\RetailCrm\Model\Api\PriceType")
* @Mapping\SerializedName("priceType")
*/
public $priceType;
/**
* Цена товара/SKU
*
* @var double $initialPrice
*
* @Mapping\Type("double")
* @Mapping\SerializedName("initialPrice")
*/
public $initialPrice;
/**
* Итоговая денежная скидка на единицу товара c учетом всех скидок на товар и заказ
*
* @var double $discountTotal
*
* @Mapping\Type("double")
* @Mapping\SerializedName("discountTotal")
*/
public $discountTotal;
/**
* Ставка НДС
*
* @var string $vatRate
*
* @Mapping\Type("string")
* @Mapping\SerializedName("vatRate")
*/
public $vatRate;
/**
* Количество
*
* @var float $quantity
*
* @Mapping\Type("float")
* @Mapping\SerializedName("quantity")
*/
public $quantity;
}

View file

@ -17,14 +17,14 @@ use Intaro\RetailCrm\Model\Api\AbstractApiModel;
/**
* Class LoyaltyAccountActivateRequest
*
* @package Intaro\RetailCrm\Model\Api\Response\SmsVerification
* @package Intaro\RetailCrm\Model\Api\Request\Loyalty\Account
*/
class LoyaltyAccountActivateRequest extends AbstractApiModel
{
/**
* Id участия в программе лояльности
*
* @var string $loyaltyId
* @var integer $loyaltyId
*
* @Mapping\Type("integer")
* @Mapping\SerializedName("id")

View file

@ -17,7 +17,7 @@ use Intaro\RetailCrm\Model\Api\AbstractApiModel;
/**
* Class LoyaltyAccountCreateRequest
*
* @package Intaro\RetailCrm\Model\Api\Response\SmsVerification
* @package Intaro\RetailCrm\Model\Api\Request\Loyalty\Account
*/
class LoyaltyAccountCreateRequest extends AbstractApiModel
{

View file

@ -17,7 +17,7 @@ use Intaro\RetailCrm\Model\Api\AbstractApiModel;
/**
* Class LoyaltyAccountEditRequest
*
* @package Intaro\RetailCrm\Model\Api\Response\SmsVerification
* @package Intaro\RetailCrm\Model\Api\Request\Loyalty\Account
*/
class LoyaltyAccountEditRequest extends AbstractApiModel
{

View file

@ -17,7 +17,7 @@ use Intaro\RetailCrm\Model\Api\AbstractApiModel;
/**
* Class LoyaltyCalculateRequest
*
* @package Intaro\RetailCrm\Model\Api\Response\SmsVerification
* @package Intaro\RetailCrm\Model\Api\Request\Loyalty
*/
class LoyaltyCalculateRequest extends AbstractApiModel
{

View file

@ -17,7 +17,7 @@ use Intaro\RetailCrm\Model\Api\AbstractApiModel;
/**
* Class OrderLoyaltyApplyRequest
*
* @package Intaro\RetailCrm\Model\Api\Response\SmsVerification
* @package Intaro\RetailCrm\Model\Api\Request\Order\Loyalty
*/
class OrderLoyaltyApplyRequest extends AbstractApiModel
{

View file

@ -1,33 +0,0 @@
<?php
/**
* PHP version 7.1
*
* @category Integration
* @package Intaro\RetailCrm\Model\Api\Request\Loyalty\Account
* @author retailCRM <integration@retailcrm.ru>
* @license MIT
* @link http://retailcrm.ru
* @see http://retailcrm.ru/docs
*/
namespace Intaro\RetailCrm\Model\Api\Request\Loyalty\Account;
use Intaro\RetailCrm\Component\Json\Mapping;
use Intaro\RetailCrm\Model\Api\AbstractApiModel;
/**
* Class LoyaltyAccountActivateRequest
*
* @package Intaro\RetailCrm\Model\Api\Response\SmsVerification
*/
class LoyaltyAccountActivateRequest extends AbstractApiModel
{
/**
* Id участия в программе лояльности
*
* @var string $loyaltyId
*
* @Mapping\Type("integer")
* @Mapping\SerializedName("id")
*/
public $loyaltyId;
}

View file

@ -0,0 +1,49 @@
<?php
/**
* PHP version 7.1
*
* @category Integration
* @package Intaro\RetailCrm\Model\Api\Response\Loyalty\Account
* @author retailCRM <integration@retailcrm.ru>
* @license MIT
* @link http://retailcrm.ru
* @see http://retailcrm.ru/docs
*/
namespace Intaro\RetailCrm\Model\Api\Response\Loyalty\Account;
use Intaro\RetailCrm\Component\Json\Mapping;
use Intaro\RetailCrm\Model\Api\AbstractApiModel;
/**
* Class LoyaltyAccountActivateResponse
*
* @package Intaro\RetailCrm\Model\Api\Response\Loyalty\Account
*/
class LoyaltyAccountActivateResponse extends AbstractApiModel
{
/**
* Результат запроса (успешный/неуспешный)
*
* @var boolean $success
*
* @Mapping\Type("boolean")
* @Mapping\SerializedName("success")
*/
public $success;
/**
* @var \Intaro\RetailCrm\Model\Api\LoyaltyAccount
*
* @Mapping\Type("\Intaro\RetailCrm\Model\Api\LoyaltyAccount")
* @Mapping\SerializedName("loyalty_account")
*/
public $loyaltyAccount;
/**
* @var \Intaro\RetailCrm\Model\Api\SmsVerification
*
* @Mapping\Type("\Intaro\RetailCrm\Model\Api\SmsVerification")
* @Mapping\SerializedName("verification")
*/
public $verification;
}

View file

@ -1,31 +0,0 @@
<?php
/**
* PHP version 7.1
*
* @category Integration
* @package Intaro\RetailCrm\Model\Api\Request\Loyalty\Account
* @author retailCRM <integration@retailcrm.ru>
* @license MIT
* @link http://retailcrm.ru
* @see http://retailcrm.ru/docs
*/
namespace Intaro\RetailCrm\Model\Api\Request\Loyalty\Account;
use Intaro\RetailCrm\Component\Json\Mapping;
use Intaro\RetailCrm\Model\Api\AbstractApiModel;
/**
* Class LoyaltyAccountCreateRequest
*
* @package Intaro\RetailCrm\Model\Api\Response\SmsVerification
*/
class LoyaltyAccountCreateRequest extends AbstractApiModel
{
/**
* @var \Intaro\RetailCrm\Model\Api\SerializedCreateLoyaltyAccount
*
* @Mapping\Type("\Intaro\RetailCrm\Model\Api\SerializedCreateLoyaltyAccount")
* @Mapping\SerializedName("loyalty_account")
*/
public $loyaltyAccount;
}

View file

@ -0,0 +1,48 @@
<?php
/**
* PHP version 7.1
*
* @category Integration
* @package Intaro\RetailCrm\Model\Api\Response\Loyalty\Account
* @author retailCRM <integration@retailcrm.ru>
* @license MIT
* @link http://retailcrm.ru
* @see http://retailcrm.ru/docs
*/
namespace Intaro\RetailCrm\Model\Api\Response\Loyalty\Account;
use Intaro\RetailCrm\Model\Api\AbstractApiModel;
/**
* Class LoyaltyAccountCreateResponse
*
* @package Intaro\RetailCrm\Model\Api\Response\Loyalty\Account
*/
class LoyaltyAccountCreateResponse extends AbstractApiModel
{
/**
* Результат запроса (успешный/неуспешный)
*
* @var boolean $success
*
* @Mapping\Type("boolean")
* @Mapping\SerializedName("success")
*/
public $success;
/**
* @var \Intaro\RetailCrm\Model\Api\LoyaltyAccount
*
* @Mapping\Type("\Intaro\RetailCrm\Model\Api\LoyaltyAccount")
* @Mapping\SerializedName("loyalty_account")
*/
public $loyaltyAccount;
/**
* @var array $warnings
*
* @Mapping\Type("array")
* @Mapping\SerializedName("warnings")
*/
public $warnings;
}

View file

@ -1,31 +0,0 @@
<?php
/**
* PHP version 7.1
*
* @category Integration
* @package Intaro\RetailCrm\Model\Api\Request\Loyalty\Account
* @author retailCRM <integration@retailcrm.ru>
* @license MIT
* @link http://retailcrm.ru
* @see http://retailcrm.ru/docs
*/
namespace Intaro\RetailCrm\Model\Api\Request\Loyalty\Account;
use Intaro\RetailCrm\Component\Json\Mapping;
use Intaro\RetailCrm\Model\Api\AbstractApiModel;
/**
* Class LoyaltyAccountEditRequest
*
* @package Intaro\RetailCrm\Model\Api\Response\SmsVerification
*/
class LoyaltyAccountEditRequest extends AbstractApiModel
{
/**
* @var \Intaro\RetailCrm\Model\Api\LoyaltyAccount
*
* @Mapping\Type("\Intaro\RetailCrm\Model\Api\LoyaltyAccount")
* @Mapping\SerializedName("loyalty_account")
*/
public $loyaltyAccount;
}

View file

@ -0,0 +1,49 @@
<?php
/**
* PHP version 7.1
*
* @category Integration
* @package Intaro\RetailCrm\Model\Api\Response\Loyalty\Account
* @author retailCRM <integration@retailcrm.ru>
* @license MIT
* @link http://retailcrm.ru
* @see http://retailcrm.ru/docs
*/
namespace Intaro\RetailCrm\Model\Api\Response\Loyalty\Account;
use Intaro\RetailCrm\Component\Json\Mapping;
use Intaro\RetailCrm\Model\Api\AbstractApiModel;
/**
* Class LoyaltyAccountEditResponse
*
* @package Intaro\RetailCrm\Model\Api\Response\Loyalty\Account
*/
class LoyaltyAccountEditResponse extends AbstractApiModel
{
/**
* Результат запроса (успешный/неуспешный)
*
* @var boolean $success
*
* @Mapping\Type("boolean")
* @Mapping\SerializedName("success")
*/
public $success;
/**
* @var \Intaro\RetailCrm\Model\Api\LoyaltyAccount
*
* @Mapping\Type("\Intaro\RetailCrm\Model\Api\LoyaltyAccount")
* @Mapping\SerializedName("loyalty_account")
*/
public $loyaltyAccount;
/**
* @var array $warnings
*
* @Mapping\Type("array")
* @Mapping\SerializedName("warnings")
*/
public $warnings;
}

View file

@ -1,40 +0,0 @@
<?php
/**
* PHP version 7.1
*
* @category Integration
* @package Intaro\RetailCrm\Model\Api\Request\Loyalty
* @author retailCRM <integration@retailcrm.ru>
* @license MIT
* @link http://retailcrm.ru
* @see http://retailcrm.ru/docs
*/
namespace Intaro\RetailCrm\Model\Api\Request\Loyalty;
use Intaro\RetailCrm\Component\Json\Mapping;
use Intaro\RetailCrm\Model\Api\AbstractApiModel;
/**
* Class LoyaltyCalculateRequest
*
* @package Intaro\RetailCrm\Model\Api\Response\SmsVerification
*/
class LoyaltyCalculateRequest extends AbstractApiModel
{
/**
* @var string $site
*
* @Mapping\Type("string")
* @Mapping\SerializedName("site")
*/
public $site;
/**
* @var \Intaro\RetailCrm\Model\Api\SerializedOrder
*
* @Mapping\Type("\Intaro\RetailCrm\Model\Api\SerializedOrder")
* @Mapping\SerializedName("order")
*/
public $order;
}

View file

@ -0,0 +1,58 @@
<?php
/**
* PHP version 7.1
*
* @category Integration
* @package Intaro\RetailCrm\Model\Api\Response\Loyalty
* @author retailCRM <integration@retailcrm.ru>
* @license MIT
* @link http://retailcrm.ru
* @see http://retailcrm.ru/docs
*/
namespace Intaro\RetailCrm\Model\Api\Response\Loyalty;
use Intaro\RetailCrm\Model\Api\AbstractApiModel;
/**
* Class LoyaltyCalculateResponse
*
* @package Intaro\RetailCrm\Model\Api\Response\Loyalty
*/
class LoyaltyCalculateResponse extends AbstractApiModel
{
/**
* Результат запроса (успешный/неуспешный)
*
* @var boolean $success
*
* @Mapping\Type("boolean")
* @Mapping\SerializedName("success")
*/
public $success;
/**
* @var \Intaro\RetailCrm\Model\Api\SerializedLoyaltyOrder
*
* @Mapping\Type("\Intaro\RetailCrm\Model\Api\SerializedLoyaltyOrder")
* @Mapping\SerializedName("order")
*/
public $order;
/**
* @var \Intaro\RetailCrm\Model\Api\CalculateMaximum
*
* @Mapping\Type("\Intaro\RetailCrm\Model\Api\CalculateMaximum")
* @Mapping\SerializedName("maximum")
*/
public $maximum;
/**
* Позиция в заказе
*
* @var array $calculations
*
* @Mapping\Type("array<Intaro\RetailCrm\Model\Api\LoyaltyCalculation>")
* @Mapping\SerializedName("calculations")
*/
public $calculations;
}

View file

@ -0,0 +1,49 @@
<?php
/**
* PHP version 7.1
*
* @category Integration
* @package Intaro\RetailCrm\Model\Api\Response\Order\Loyalty
* @author retailCRM <integration@retailcrm.ru>
* @license MIT
* @link http://retailcrm.ru
* @see http://retailcrm.ru/docs
*/
namespace Intaro\RetailCrm\Model\Api\Response\Order\Loyalty;
use Intaro\RetailCrm\Component\Json\Mapping;
use Intaro\RetailCrm\Model\Api\AbstractApiModel;
/**
* Class OrderLoyaltyApplyResponse
*
* @package Intaro\RetailCrm\Model\Api\Response\SmsVerification
*/
class OrderLoyaltyApplyResponse extends AbstractApiModel
{
/**
* Результат запроса (успешный/неуспешный)
*
* @var boolean $success
*
* @Mapping\Type("boolean")
* @Mapping\SerializedName("success")
*/
public $success;
/**
* @var \Intaro\RetailCrm\Model\Api\SerializedLoyaltyOrder
*
* @Mapping\Type("\Intaro\RetailCrm\Model\Api\SerializedLoyaltyOrder")
* @Mapping\SerializedName("order")
*/
public $order;
/**
* @var \Intaro\RetailCrm\Model\Api\SmsVerification
*
* @Mapping\Type("\Intaro\RetailCrm\Model\Api\SerializedLoyaltyOrder")
* @Mapping\SerializedName("verification")
*/
public $verification;
}

View file

@ -0,0 +1,121 @@
<?php
/**
* PHP version 7.1
*
* @category Integration
* @package Intaro\RetailCrm\Model\Api
* @author retailCRM <integration@retailcrm.ru>
* @license MIT
* @link http://retailcrm.ru
* @see http://retailcrm.ru/docs
*/
namespace Intaro\RetailCrm\Model\Api;
/**
* Метод применения бонусов по программе лояльности
* Class SerializedLoyaltyOrder
*
* @package Intaro\RetailCrm\Model\Api
*/
class SerializedLoyaltyOrder
{
/**
* Количество начисленных бонусов
*
* @var double $bonusesCreditTotal
*
* @Mapping\Type("double")
* @Mapping\SerializedName("bonusesCreditTotal")
*/
public $bonusesCreditTotal;
/**
* Количество списанных бонусов
*
* @var double $bonusesChargeTotal
*
* @Mapping\Type("double")
* @Mapping\SerializedName("bonusesChargeTotal")
*/
public $bonusesChargeTotal;
/**
* Общая сумма с учетом скидки
*
* @var double $totalSumm
*
* @Mapping\Type("double")
* @Mapping\SerializedName("totalSumm")
*/
public $totalSumm;
/**
* Персональная скидка на заказ
*
* @var double $personalDiscountPercent
*
* @Mapping\Type("double")
* @Mapping\SerializedName("personalDiscountPercent")
*/
public $personalDiscountPercent;
/**
* @var \Intaro\RetailCrm\Model\Api\LoyaltyAccount
*
* @Mapping\Type("\Intaro\RetailCrm\Model\Api\LoyaltyAccount")
* @Mapping\SerializedName("loyaltyAccount")
*/
public $loyaltyAccount;
/**
* @var \Intaro\RetailCrm\Model\Api\LoyaltyLevel
*
* @Mapping\Type("\Intaro\RetailCrm\Model\Api\LoyaltyLevel")
* @Mapping\SerializedName("loyaltyLevel")
*/
public $loyaltyLevel;
/**
* @var \Intaro\RetailCrm\Model\Api\AbstractLoyaltyEvent
*
* @Mapping\Type("\Intaro\RetailCrm\Model\Api\AbstractLoyaltyEvent")
* @Mapping\SerializedName("loyaltyEvent")
*/
public $loyaltyEvent;
/**
* @var \Intaro\RetailCrm\Model\Api\Customer
*
* @Mapping\Type("\Intaro\RetailCrm\Model\Api\Customer")
* @Mapping\SerializedName("customer")
*/
public $customer;
/**
* @var \Intaro\RetailCrm\Model\Api\SerializedOrderDelivery
*
* @Mapping\Type("\Intaro\RetailCrm\Model\Api\SerializedOrderDelivery")
* @Mapping\SerializedName("delivery")
*/
public $delivery;
/**
* Магазин
*
* @var string $site
*
* @Mapping\Type("string")
* @Mapping\SerializedName("site")
*/
public $site;
/**
* Позиция в заказе
*
* @var array $items
*
* @Mapping\Type("array<Intaro\RetailCrm\Model\Api\OrderProduct>")
* @Mapping\SerializedName("items")
*/
public $items;
}

View file

@ -19,7 +19,7 @@ namespace Intaro\RetailCrm\Model\Api;
class SerializedOrderDelivery
{
/**
* Цена товара/SKU
* Цена товара/SKU/Стоимость доставки
*
* @var double $cost
*

View file

@ -11,8 +11,11 @@
*/
namespace Intaro\RetailCrm\Model\Api;
use DateTime;
/**
* Class SmsVerification
*
* @package Intaro\RetailCrm\Model\Api
*/
class SmsVerification extends AbstractApiModel
@ -70,7 +73,7 @@ class SmsVerification extends AbstractApiModel
/**
* @param \DateTime $createdAt
*/
public function setCreatedAt(\DateTime $createdAt): void
public function setCreatedAt(DateTime $createdAt): void
{
$this->createdAt = $createdAt;
}
@ -94,7 +97,7 @@ class SmsVerification extends AbstractApiModel
/**
* @param \DateTime $verifiedAt
*/
public function setVerifiedAt(\DateTime $verifiedAt): void
public function setVerifiedAt(DateTime $verifiedAt): void
{
$this->verifiedAt = $verifiedAt;
}
@ -102,7 +105,7 @@ class SmsVerification extends AbstractApiModel
/**
* @param \DateTime $expiredAt
*/
public function setExpiredAt(\DateTime $expiredAt): void
public function setExpiredAt(DateTime $expiredAt): void
{
$this->expiredAt = $expiredAt;
}

16
tests/bitrixbootstrap.php Executable file
View file

@ -0,0 +1,16 @@
<?php
use Bitrix\Main\Loader;
define ('NOT_CHECK_PERMISSIONS', true);
define ('NO_AGENT_CHECK', true);
$GLOBALS['DBType'] = 'mysql';
$_SERVER['DOCUMENT_ROOT'] = realpath(__DIR__ . '/../..' );
require($_SERVER['DOCUMENT_ROOT'] . '/bitrix/modules/main/include/prolog_before.php');
$_SESSION['SESS_AUTH']['USER_ID'] = 1;
require_once $_SERVER['DOCUMENT_ROOT'] . '/vendor/autoload.php';
Loader::includeModule('intaro.retailcrm');
Loader::includeModule('sale');
require_once $_SERVER['DOCUMENT_ROOT'] . '/local/tests/helpers/Helpers.php';