Completed
Push — master ( b355d9...43cc45 )
by Andrii
02:30
created

Sale   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 18
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
wmc 2
lcom 0
cbo 0
dl 0
loc 18
ccs 0
cts 14
cp 0
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A attributes() 0 6 1
A relations() 0 8 1
1
<?php
2
/**
3
 * API for Billing
4
 *
5
 * @link      https://github.com/hiqdev/billing-hiapi
6
 * @package   billing-hiapi
7
 * @license   BSD-3-Clause
8
 * @copyright Copyright (c) 2017, HiQDev (http://hiqdev.com/)
9
 */
10
11
namespace hiqdev\billing\hiapi\models;
12
13
use hiqdev\yii\DataMapper\query\attributes\IntegerAttribute;
14
15
class Sale extends AbstractModel
16
{
17
    public function attributes()
18
    {
19
        return [
20
            'id' => IntegerAttribute::class,
21
        ];
22
    }
23
24
    public function relations()
25
    {
26
        return [
27
            'target' => Target::class,
28
            'customer' => Customer::class,
29
            'plan' => Plan::class,
30
        ];
31
    }
32
}
33