Completed
Pull Request — master (#34)
by
unknown
03:22
created

AccountQuery   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 13
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 1
dl 0
loc 13
ccs 0
cts 6
cp 0
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A withValues() 0 7 1
1
<?php
2
/**
3
 * Hosting module for HiPanel
4
 *
5
 * @link      https://github.com/hiqdev/hipanel-module-hosting
6
 * @package   hipanel-module-hosting
7
 * @license   BSD-3-Clause
8
 * @copyright Copyright (c) 2015-2019, HiQDev (http://hiqdev.com/)
9
 */
10
11
namespace hipanel\modules\hosting\models\query;
12
13
use hiqdev\hiart\ActiveQuery;
14
15
/**
16
 * Class AccountQuery
17
 * @package hipanel\modules\hosting\models\query
18
 */
19
class AccountQuery extends ActiveQuery
20
{
21
    /**
22
     * @return $this
23
     */
24
    public function withValues(): self
25
    {
26
        $this->joinWith('values');
27
        $this->andWhere(['with_values' => true]);
28
29
        return $this;
30
    }
31
}
32