-
Notifications
You must be signed in to change notification settings - Fork 212
/
Copy pathRecurringApplicationCharge.php
69 lines (60 loc) · 1.62 KB
/
RecurringApplicationCharge.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
<?php
/**
* Created by PhpStorm.
* @author Tareq Mahmood <tareqtms@yahoo.com>
* Created at 8/19/16 6:30 PM UTC+06:00
*
* @see https://help.shopify.com/api/reference/recurringapplicationcharge Shopify API Reference for RecurringApplicationCharge
*/
namespace PHPShopify;
/**
* --------------------------------------------------------------------------
* RecurringApplicationCharge -> Child Resources
* --------------------------------------------------------------------------
* @property-read UsageCharge $UsageCharge
*
* @method UsageCharge UsageCharge(integer $id = null)
*
* --------------------------------------------------------------------------
* RecurringApplicationCharge -> Custom actions
* --------------------------------------------------------------------------
* @method array activate() Activate a recurring application charge
*
*/
class RecurringApplicationCharge extends ShopifyResource
{
/**
* @inheritDoc
*/
protected $resourceKey = 'recurring_application_charge';
/**
* @inheritDoc
*/
public $countEnabled = false;
/**
* @inheritDoc
*/
protected $childResource = array(
'UsageCharge',
);
/**
* @inheritDoc
*/
protected $customPostActions = array(
'activate',
);
/*
* Customize a recurring application charge
*
* @param array $data
*
* @return array
*
*/
public function customize($dataArray)
{
$dataArray = $this->wrapData($dataArray);
$url = $this->generateUrl($dataArray, 'customize');
return $this->put(array(), $url);
}
}