AuthorAdmin::configureListFields()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 6

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
dl 0
loc 6
ccs 0
cts 6
cp 0
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 1
crap 2
1
<?php
2
3
namespace Smart\ContentBundle\Admin;
4
5
use Smart\SonataBundle\Admin\AbstractAdmin;
6
use Sonata\AdminBundle\Datagrid\ListMapper;
7
use Sonata\AdminBundle\Form\FormMapper;
8
use Sonata\AdminBundle\Show\ShowMapper;
9
use Symfony\Component\Form\Extension\Core\Type\FileType;
10
use Vich\UploaderBundle\Form\Type\VichImageType;
11
12
/**
13
 * Nicolas Bastien <[email protected]>
14
 */
15
class AuthorAdmin extends AbstractAdmin
16
{
17
    /**
18
     * {@inheritdoc}
19
     */
20
    public function configureListFields(ListMapper $list)
21
    {
22
        $list
23
            ->addIdentifier('id')
24
        ;
25
    }
26
27
    /**
28
     * {@inheritdoc}
29
     */
30
    public function configureFormFields(FormMapper $form)
31
    {
32
        $form
33
            ->tab('tab.label_content')
34
                ->with('fieldset.label_general')
35
                ->end()
36
            ->end()
37
        ;
38
    }
39
40
    /**
41
     * {@inheritDoc}
42
     */
43
    protected function configureShowFields(ShowMapper $show)
44
    {
45
        $show
46
            ->tab('tab.label_content')
47
                ->with('fieldset.label_general')
48
                ->end()
49
            ->end()
50
        ;
51
    }
52
}
53