Fix filtering of api query results (#340)
This commit is contained in:
parent
01fe3c9741
commit
8b01b9844b
@ -1,3 +1,6 @@
|
||||
## 2024-08-06 4.8.1
|
||||
* Fix filtering of api query results
|
||||
|
||||
## 2024-07-15 4.8.0
|
||||
* Added loyalty program
|
||||
|
||||
|
@ -2892,7 +2892,7 @@ class WC_Retailcrm_Client_V5
|
||||
/** List of participation in the loyalty program */
|
||||
public function getLoyaltyAccountList(array $filter = [], $limit = null, $page = null)
|
||||
{
|
||||
$parameters = $this->buildParameters($filter, $limit, $page);
|
||||
$parameters = $this->buildParameters($filter, $page, $limit);
|
||||
|
||||
return $this->client->makeRequest(
|
||||
'/loyalty/accounts',
|
||||
@ -2904,7 +2904,7 @@ class WC_Retailcrm_Client_V5
|
||||
/** List of loyalty programs */
|
||||
public function getListLoyalty(array $filter = [], $limit = null, $page = null)
|
||||
{
|
||||
$parameters = $this->buildParameters($filter, $limit, $page);
|
||||
$parameters = $this->buildParameters($filter, $page, $limit);
|
||||
|
||||
return $this->client->makeRequest(
|
||||
'/loyalty/loyalties',
|
||||
@ -2950,7 +2950,7 @@ class WC_Retailcrm_Client_V5
|
||||
/** History of the client's bonus account */
|
||||
public function getClientBonusHistory(int $clientIdLoyalty, array $filter = [], $limit = null, $page = null)
|
||||
{
|
||||
$parameters = $this->buildParameters($filter, $limit, $page);
|
||||
$parameters = $this->buildParameters($filter, $page, $limit);
|
||||
$parameters['id'] = $clientIdLoyalty;
|
||||
|
||||
return $this->client->makeRequest(
|
||||
@ -2967,7 +2967,7 @@ class WC_Retailcrm_Client_V5
|
||||
$limit = null,
|
||||
$page = null
|
||||
) {
|
||||
$parameters = $this->buildParameters($filter, $limit, $page);
|
||||
$parameters = $this->buildParameters($filter, $page, $limit);
|
||||
$parameters['id'] = $clientIdLoyalty;
|
||||
$parameters['status'] = $status;
|
||||
|
||||
@ -2981,7 +2981,7 @@ class WC_Retailcrm_Client_V5
|
||||
/** Bonus account history for all participants */
|
||||
public function getBonusHistory(string $cursor, array $filter = [], $limit = null)
|
||||
{
|
||||
$parameters = $this->buildParameters($filter, $limit);
|
||||
$parameters = $this->buildParameters($filter, null, $limit);
|
||||
$parameters['cursor'] = $cursor;
|
||||
|
||||
return $this->client->makeRequest(
|
||||
@ -3134,7 +3134,7 @@ class WC_Retailcrm_Client_V5
|
||||
return $params;
|
||||
}
|
||||
|
||||
protected function buildParameters(array $filter = [], $limit = null, $page = null): array
|
||||
protected function buildParameters(array $filter = [], $page = null, $limit = null): array
|
||||
{
|
||||
$parameters = [];
|
||||
|
||||
|
@ -5,7 +5,7 @@ Tags: Интеграция, Simla.com, simla
|
||||
Requires PHP: 7.0
|
||||
Requires at least: 5.3
|
||||
Tested up to: 6.5
|
||||
Stable tag: 4.8.0
|
||||
Stable tag: 4.8.1
|
||||
License: GPLv1 or later
|
||||
License URI: http://www.gnu.org/licenses/gpl-1.0.html
|
||||
|
||||
@ -82,6 +82,9 @@ Asegúrate de tener una clave API específica para cada tienda. Las siguientes i
|
||||
|
||||
|
||||
== Changelog ==
|
||||
= 4.8.1 =
|
||||
* Fix filtering of api query results
|
||||
|
||||
= 4.8.0 =
|
||||
* Added loyalty program
|
||||
|
||||
|
@ -5,7 +5,7 @@
|
||||
* Description: Integration plugin for WooCommerce & Simla.com
|
||||
* Author: RetailDriver LLC
|
||||
* Author URI: http://retailcrm.pro/
|
||||
* Version: 4.8.0
|
||||
* Version: 4.8.1
|
||||
* Tested up to: 6.5
|
||||
* Requires Plugins: woocommerce
|
||||
* WC requires at least: 5.4
|
||||
|
@ -16,7 +16,7 @@
|
||||
*
|
||||
* @link https://wordpress.org/plugins/woo-retailcrm/
|
||||
*
|
||||
* @version 4.8.0
|
||||
* @version 4.8.1
|
||||
*
|
||||
* @package RetailCRM
|
||||
*/
|
||||
|
Loading…
x
Reference in New Issue
Block a user