Completed
Pull Request — master (#6)
by
unknown
04:50
created

LocalDeliveryCost   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 30
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 0%

Importance

Changes 2
Bugs 1 Features 1
Metric Value
wmc 2
c 2
b 1
f 1
lcom 0
cbo 1
dl 0
loc 30
ccs 0
cts 13
cp 0
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A rules() 0 9 1
A getYmlBody() 0 4 1
1
<?php
2
namespace pastuhov\ymlcatalog\models;
3
4
class LocalDeliveryCost extends BaseModel
5
{
6
    /**
7
     * @inheritdoc
8
     */
9
    public static $tag = 'local_delivery_cost';
10
11
    public $value;
12
13
    /**
14
     * @inheritdoc
15
     */
16
    public function rules()
17
    {
18
        return [
19
            [
20
                ['value'],
21
                'integer',
22
            ],
23
        ];
24
    }
25
26
    /**
27
     * @inheritdoc
28
     */
29
    protected function getYmlBody()
30
    {
31
        return $this->value;
32
    }
33
}
34