diff --git a/src/Model/Filter/Store/ProductPropertiesFilterType.php b/src/Model/Filter/Store/ProductPropertiesFilterType.php index 8842689..febb284 100644 --- a/src/Model/Filter/Store/ProductPropertiesFilterType.php +++ b/src/Model/Filter/Store/ProductPropertiesFilterType.php @@ -66,4 +66,12 @@ class ProductPropertiesFilterType * @Form\SerializedName("catalogs") */ public $catalogs; + + /** + * @var int[] + * + * @Form\Type("int[]") + * @Form\SerializedName("groups") + */ + public $groups; } diff --git a/src/Model/Request/Store/ProductPropertiesRequest.php b/src/Model/Request/Store/ProductPropertiesRequest.php index 07c4502..a331f36 100644 --- a/src/Model/Request/Store/ProductPropertiesRequest.php +++ b/src/Model/Request/Store/ProductPropertiesRequest.php @@ -23,6 +23,14 @@ class ProductPropertiesRequest implements RequestInterface { use PageLimitTrait; + /** + * @var ProductPropertiesSort + * + * @Form\Type("ProductPropertiesSort") + * @Form\SerializedName("sort") + */ + public $sort; + /** * @var \RetailCrm\Api\Model\Filter\Store\ProductPropertiesFilterType * diff --git a/src/Model/Request/Store/ProductPropertiesSort.php b/src/Model/Request/Store/ProductPropertiesSort.php new file mode 100644 index 0000000..78d9efb --- /dev/null +++ b/src/Model/Request/Store/ProductPropertiesSort.php @@ -0,0 +1,31 @@ +sort = new ProductPropertiesSort(); + $request->sort->offersCount = 'desc'; + $request->filter = new ProductPropertiesFilterType(); $request->filter->sites = ['moysklad', 'aliexpress']; $request->filter->visible = NumericBoolean::TRUE; $request->filter->variative = NumericBoolean::TRUE; + $request->filter->groups = [3676, 3679, 3680, 3724]; $mock = static::createApiMockBuilder('store/products/properties'); $mock->matchMethod(RequestMethod::GET)