GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

CashOnDelivery   A
last analyzed

Complexity

Total Complexity 9

Size/Duplication

Total Lines 93
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 1

Importance

Changes 0
Metric Value
wmc 9
lcom 1
cbo 1
dl 0
loc 93
rs 10
c 0
b 0
f 0

9 Methods

Rating   Name   Duplication   Size   Complexity  
A setEnabled() 0 4 1
A setTitle() 0 4 1
A setNewOrderStatus() 0 4 1
A setPaymentFromApplicableCountries() 0 4 1
A setSpecificCountry() 0 4 1
A setInstructions() 0 4 1
A setMinOrderTotal() 0 4 1
A setMaxOrderTotal() 0 4 1
A setSortOrder() 0 4 1
1
<?php
2
3
namespace Magium\Magento\Actions\Admin\Configuration\PaymentMethods;
4
5
6
class CashOnDelivery extends AbstractPaymentMethod
7
{
8
    const NAME = 'Cash On Delivery Payment';
9
    const ACTION = 'Admin\Configuration\PaymentMethods\CashOnDelivery';
10
11
    protected $section = 'Payment Methods/' . self::NAME;
12
13
    protected $settings = [
14
        'payment_cashondelivery_active'             => 0,
15
        'payment_cashondelivery_title'              => 'Cash On Delivery',
16
        'payment_cashondelivery_order_status'       => null,
17
        'payment_cashondelivery_allowspecific'      => null,
18
        'payment_cashondelivery_specificcountry'    => null,
19
        'payment_cashondelivery_instructions'       => null,
20
        'payment_cashondelivery_min_order_total'    => null,
21
        'payment_cashondelivery_max_order_total'    => null,
22
        'payment_cashondelivery_sort_order'         => null
23
    ];
24
25
    /**
26
     * @param string $enabled
27
     */
28
    public function setEnabled($enabled)
29
    {
30
        $this->settings['payment_cashondelivery_active'] = $enabled;
31
    }
32
33
    /**
34
     * @param string $title
35
     */
36
    public function setTitle($title)
37
    {
38
        $this->settings['payment_cashondelivery_title'] = $title;
39
    }
40
41
    /**
42
     * @param string $order_status
43
     */
44
    public function setNewOrderStatus($order_status)
45
    {
46
        $this->settings['payment_cashondelivery_order_status'] = $order_status;
47
    }
48
49
    /**
50
     * @param string $allowspecific
51
     */
52
    public function setPaymentFromApplicableCountries($allowspecific)
53
    {
54
        $this->settings['payment_cashondelivery_allowspecific'] = $allowspecific;
55
    }
56
57
    /**
58
     * @param string|array $specificcountry
59
     */
60
    public function setSpecificCountry($specificcountry)
61
    {
62
        $this->settings['payment_cashondelivery_specificcountry'] = $specificcountry;
63
    }
64
65
    /**
66
     * @param string $instructions
67
     */
68
    public function setInstructions($instructions)
69
    {
70
        $this->settings['payment_cashondelivery_instructions'] = $instructions;
71
    }
72
73
    /**
74
     * @param string $min_order_total
75
     */
76
    public function setMinOrderTotal($min_order_total)
77
    {
78
        $this->settings['payment_cashondelivery_min_order_total'] = $min_order_total;
79
    }
80
81
    /**
82
     * @param string $max_order_total
83
     */
84
    public function setMaxOrderTotal($max_order_total)
85
    {
86
        $this->settings['payment_cashondelivery_max_order_total'] = $max_order_total;
87
    }
88
89
    /**
90
     * @param string $sort_order
91
     */
92
    public function setSortOrder($sort_order)
93
    {
94
        $this->settings['payment_cashondelivery_sort_order'] = $sort_order;
95
    }
96
97
98
}