1
0
mirror of synced 2025-01-30 23:01:43 +03:00
woocommerce-module/tests/datasets/data-base-retailcrm.php

144 lines
3.8 KiB
PHP
Raw Normal View History

2021-12-20 11:41:41 +03:00
<?php
namespace datasets;
2022-01-10 12:53:00 +03:00
/**
* PHP version 7.0
2022-01-10 12:53:00 +03:00
*
* Class DataBaseRetailCrm - Data set for WC_Retailcrm_Base.
*
* @category Integration
* @author RetailCRM <integration@retailcrm.ru>
* @license http://retailcrm.ru Proprietary
* @link http://retailcrm.ru
* @see http://help.retailcrm.ru
*/
2021-12-20 11:41:41 +03:00
class DataBaseRetailCrm
{
2022-11-25 12:17:22 +03:00
public static function getResponseCustomFields()
{
return [
'success' => true,
'customFields' => [
[
'name' => 'Test_Upload',
'code' => 'test_upload',
],
[
'name' => 'test123',
'code' => 'test',
],
]
];
}
2021-12-20 11:41:41 +03:00
public static function getResponseStatuses()
{
2022-05-05 18:09:54 +03:00
return [
2021-12-20 11:41:41 +03:00
'success' => true,
2022-05-05 18:09:54 +03:00
'statuses' => [
[
2021-12-20 11:41:41 +03:00
'name' => 'status1',
'code' => 'status1',
'active' => true
2022-05-05 18:09:54 +03:00
],
[
2021-12-20 11:41:41 +03:00
'name' => 'status2',
'code' => 'status2',
'active' => false
2022-05-05 18:09:54 +03:00
]
]
];
2021-12-20 11:41:41 +03:00
}
public static function getResponsePaymentTypes()
{
2022-05-05 18:09:54 +03:00
return [
2021-12-20 11:41:41 +03:00
'success' => true,
2022-05-05 18:09:54 +03:00
'paymentTypes' => [
[
2021-12-20 11:41:41 +03:00
'name' => 'payment1',
'code' => 'payment1',
'active' => true
2022-05-05 18:09:54 +03:00
],
[
2021-12-20 11:41:41 +03:00
'name' => 'payment2',
'code' => 'payment2',
'active' => false
2022-05-05 18:09:54 +03:00
],
[
'name' => 'payment3',
'code' => 'payment3',
'integrationModule' => [
'name' => 'test',
'active' => true,
],
'active' => true
],
[
'name' => 'payment4',
'code' => 'payment4',
'active' => true,
'sites' => ['prestaShop']
],
[
'name' => 'payment5',
'code' => 'payment5',
'active' => true,
'sites' => ['woocommerce']
]
2022-05-05 18:09:54 +03:00
]
];
2021-12-20 11:41:41 +03:00
}
public static function getResponseDeliveryTypes()
{
2022-05-05 18:09:54 +03:00
return [
2021-12-20 11:41:41 +03:00
'success' => true,
2022-05-05 18:09:54 +03:00
'deliveryTypes' => [
[
2021-12-20 11:41:41 +03:00
'name' => 'delivery1',
'code' => 'delivery1',
'active' => true
2022-05-05 18:09:54 +03:00
],
[
2021-12-20 11:41:41 +03:00
'name' => 'delivery2',
'code' => 'delivery2',
'active' => false
],
[
'name' => 'delivery3',
'code' => 'delivery3',
'active' => true,
'sites' => ['prestaShop']
],
[
'name' => 'delivery4',
'code' => 'delivery4',
'active' => true,
'sites' => ['woocommerce']
2022-05-05 18:09:54 +03:00
]
]
];
2021-12-20 11:41:41 +03:00
}
public static function getResponseOrderMethods()
{
2022-05-05 18:09:54 +03:00
return [
2021-12-20 11:41:41 +03:00
'success' => true,
2022-05-05 18:09:54 +03:00
'orderMethods' => [
[
2021-12-20 11:41:41 +03:00
'name' => 'orderMethod1',
'code' => 'orderMethod1',
'active' => true
2022-05-05 18:09:54 +03:00
],
[
2021-12-20 11:41:41 +03:00
'name' => 'orderMethod2',
'code' => 'orderMethod2',
'active' => false
2022-05-05 18:09:54 +03:00
]
]
];
2021-12-20 11:41:41 +03:00
}
2022-05-05 18:09:54 +03:00
}