OrderResource::getRisks()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 1
nc 1
nop 1
dl 0
loc 3
rs 10
c 0
b 0
f 0
1
<?php
2
3
namespace Signifly\Shopify\REST\Resources;
4
5
use Illuminate\Support\Collection;
6
7
class OrderResource extends ApiResource
8
{
9
    public function update(array $data): ApiResource
10
    {
11
        return $this->shopify->updateOrder($this->id, $data);
0 ignored issues
show
Bug Best Practice introduced by
The property id does not exist on Signifly\Shopify\REST\Resources\OrderResource. Since you implemented __get, consider adding a @property annotation.
Loading history...
12
    }
13
14
    public function delete(): void
15
    {
16
        $this->shopify->deleteOrder($this->id);
0 ignored issues
show
Bug Best Practice introduced by
The property id does not exist on Signifly\Shopify\REST\Resources\OrderResource. Since you implemented __get, consider adding a @property annotation.
Loading history...
17
    }
18
19
    public function cancel(): ApiResource
20
    {
21
        return $this->shopify->cancelOrder($this->id);
0 ignored issues
show
Bug Best Practice introduced by
The property id does not exist on Signifly\Shopify\REST\Resources\OrderResource. Since you implemented __get, consider adding a @property annotation.
Loading history...
22
    }
23
24
    public function close(): ApiResource
25
    {
26
        return $this->shopify->closeOrder($this->id);
0 ignored issues
show
Bug Best Practice introduced by
The property id does not exist on Signifly\Shopify\REST\Resources\OrderResource. Since you implemented __get, consider adding a @property annotation.
Loading history...
27
    }
28
29
    public function open(): ApiResource
30
    {
31
        return $this->shopify->openOrder($this->id);
0 ignored issues
show
Bug Best Practice introduced by
The property id does not exist on Signifly\Shopify\REST\Resources\OrderResource. Since you implemented __get, consider adding a @property annotation.
Loading history...
32
    }
33
34
    public function getFulfillments(array $params = []): Collection
35
    {
36
        return $this->shopify->getOrderFulfillments($this->id, $params);
0 ignored issues
show
Bug Best Practice introduced by
The property id does not exist on Signifly\Shopify\REST\Resources\OrderResource. Since you implemented __get, consider adding a @property annotation.
Loading history...
37
    }
38
39
    public function getRefunds(array $params = []): Collection
40
    {
41
        return $this->shopify->getOrderRefunds($this->id, $params);
0 ignored issues
show
Bug Best Practice introduced by
The property id does not exist on Signifly\Shopify\REST\Resources\OrderResource. Since you implemented __get, consider adding a @property annotation.
Loading history...
42
    }
43
44
    public function getRisks(array $params = []): Collection
45
    {
46
        return $this->shopify->getOrderRisks($this->id, $params);
0 ignored issues
show
Bug Best Practice introduced by
The property id does not exist on Signifly\Shopify\REST\Resources\OrderResource. Since you implemented __get, consider adding a @property annotation.
Loading history...
47
    }
48
49
    public function getTransactions(array $params = []): Collection
50
    {
51
        return $this->shopify->getOrderTransactions($this->id, $params);
0 ignored issues
show
Bug Best Practice introduced by
The property id does not exist on Signifly\Shopify\REST\Resources\OrderResource. Since you implemented __get, consider adding a @property annotation.
Loading history...
52
    }
53
}
54