Completed
Push — develop ( c603db...77b219 )
by
unknown
16:24 queued 08:23
created

UserStatusContainer::setViewPartial()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 5
rs 9.4285
cc 1
eloc 3
nc 1
nop 1
1
<?php
2
/**
3
 * YAWIK
4
 *
5
 * @filesource
6
 * @copyright (c) 2013 - 2016 Cross Solution (http://cross-solution.de)
7
 * @license   MIT
8
 */
9
10
/** Auth forms */
11
namespace Auth\Form;
12
13
use Core\Form\Container;
14
use Core\Form\ViewPartialProviderInterface;
15
16
/**
17
 * Form container for user status.
18
 *
19
 * @author fedys
20
 */
21
class UserStatusContainer extends Container implements ViewPartialProviderInterface
22
{
23
    
24
    /**
25
     * View partial name.
26
     * @var string
27
     */
28
    protected $partial = 'auth/form/user-status-container';
29
    
30
    /**
31
     * @see \Core\Form\ViewPartialProviderInterface::getViewPartial()
32
     */
33
    public function getViewPartial()
34
    {
35
        return $this->partial;
36
    }
37
    
38
    /**
39
     * @see \Core\Form\ViewPartialProviderInterface::setViewPartial()
40
     */
41
    public function setViewPartial($partial)
42
    {
43
        $this->partial = $partial;
44
        return $this;
45
    }
46
47
    /**
48
     * Initializes the container.
49
     *
50
     * @see \Zend\Form\Element::init()
51
     */
52
    public function init()
53
    {
54
        $this->setForms([
55
            'status' => [
56
                'type' => 'Auth/UserStatus',
57
                'property' => true
58
            ]
59
        ]);
60
    }
61
}
62