1
0
mirror of synced 2024-11-30 17:26:06 +03:00
bitrix-module/intaro.retailcrm/lib/model/bitrix/xml/xmloffer.php
Alex Lushpai e3e0d41ff5
Backport (#242)
* Add PRICE_DELIVERY for history exchange
* Fix bug with LocationTable fqn
* Fix bug with ProductType
* Changed options for prices and corps
* CustomersUpload: finding uniq clients by externalId
* Restore shipment before deleting

Co-authored-by: Sergey Chazov <oitv18@gmail.com>
2022-02-04 15:16:14 +03:00

142 lines
2.2 KiB
PHP
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<?php
/**
* PHP version 7.1
*
* @category Integration
* @package Intaro\RetailCrm\Model\Bitrix
* @author RetailCRM <integration@retailcrm.ru>
* @license MIT
* @link http://retailcrm.ru
* @see http://retailcrm.ru/docs
*/
namespace Intaro\RetailCrm\Model\Bitrix\Xml;
/**
* Class XmlOffer
* @package Intaro\RetailCrm\Model\Bitrix\Xml
*/
class XmlOffer
{
/**
* @var int
*/
public $id;
/**
* @var int
*/
public $productId;
/**
* @var int
*/
public $quantity;
/**
* @var string
*/
public $picture;
/**
* @var string
*/
public $url;
/**
* @var float
*/
public $price;
/**
* Категории, к которым относится товар
*
* @var array
*/
public $categoryIds;
/**
* @var string
*/
public $name;
/**
* @var int
*/
public $xmlId;
/**
* @var string
*/
public $productName;
/**
* @var OfferParam[]
*/
public $params;
/**
* @var string
*/
public $vendor;
/**
* @var Unit
*/
public $unitCode;
/**
* ставка налога (НДС)
*
* @var string
*/
public $vatRate;
/**
* штрих-код
*
* @var string
*/
public $barcode;
/**
* Закупочная цена
*
* @var mixed|null
*/
public $purchasePrice;
/**
* Вес товара
*
* @var int
*/
public $weight;
/**
* Габариты товара
*
* @var string
*/
public $dimensions;
/**
* Тип каталога
* \Bitrix\Catalog\ProductTable::TYPE_PRODUCT - простой товар
* \Bitrix\Catalog\ProductTable::TYPE_SKU товар с торговыми предложениями
* \Bitrix\Catalog\ProductTable::TYPE_OFFER торговое предложение
*
* @var int
*/
public $productType;
/**
* @param $productValue
* @param $offerValue
* @return mixed
*/
public function mergeValues($productValue, $offerValue)
{
return empty($offerValue) ? $productValue : $offerValue;
}
}