Passed
Push — master ( 248ab7...5ed1ac )
by Vuong
14:10
created

RequestData::rules()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 2
nc 1
nop 0
dl 0
loc 4
rs 10
c 0
b 0
f 0
1
<?php
2
/**
3
 * @link https://github.com/vuongxuongminh/yii2-gatewayclients
4
 * @copyright Copyright (c) 2018 Vuong Xuong Minh
5
 * @license [New BSD License](http://www.opensource.org/licenses/bsd-license.php)
6
 */
7
8
9
namespace vxm\examples\gatewayclients;
10
11
use vxm\gatewayclients\RequestData as BaseRequestData;
12
13
/**
14
 * Class RequestData
15
 *
16
 * @author Vuong Minh <[email protected]>
17
 * @since 1.0
18
 */
19
class RequestData extends BaseRequestData
20
{
21
22
    /**
23
     * @inheritdoc
24
     */
25
    public function rules()
26
    {
27
        return [
28
            [['amount'], 'required', 'on' => ['refund', 'charge']]
29
        ];
30
    }
31
32
}