Completed
Push — master ( cf838f...441ca2 )
by Dmitry
04:31
created

TariffPageCalculation::synchronize()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 1
Bugs 0 Features 1
Metric Value
c 1
b 0
f 1
dl 0
loc 4
ccs 0
cts 0
cp 0
rs 10
cc 1
eloc 2
nc 1
nop 0
crap 2
1
<?php
2
3
/*
4
 * Server module for HiPanel
5
 *
6
 * @link      https://github.com/hiqdev/hipanel-module-server
7
 * @package   hipanel-module-server
8
 * @license   BSD-3-Clause
9
 * @copyright Copyright (c) 2015-2016, HiQDev (http://hiqdev.com/)
10
 */
11
12
namespace hipanel\modules\server\cart;
13
14
use Yii;
15
16
/**
17
 * Class TariffPageCalculation is designed to calculate servers' prices
18
 * when server is not created yet (using tariff only) and is not added to the cart
19
 *
20
 * The class has dropped dependency on Cart module
21
 *
22
 * @package hipanel\modules\server\cart
23
 */
24
class TariffPageCalculation extends OrderCalculation
25
{
26
    /** {@inheritdoc} */
27
    public static function primaryKey()
28
    {
29
        return ['tariff_id'];
30
    }
31
32
    /** @inheritdoc */
33
    public function synchronize()
34
    {
35
        return true;
36
    }
37
}
38