CompanyDataMenuBuilder::addItem()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 11
Code Lines 7

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 11
c 0
b 0
f 0
rs 9.4285
cc 1
eloc 7
nc 1
nop 1
1
<?php
2
3
/*
4
 * This file has been created by developers from BitBag.
5
 * Feel free to contact us once you face any issues or want to start
6
 * another great project.
7
 * You can find more information about us on https://bitbag.shop and write us
8
 * an email on [email protected].
9
 */
10
11
declare(strict_types=1);
12
13
namespace BitBag\SyliusInvoicingPlugin\Menu;
14
15
use Sylius\Bundle\UiBundle\Menu\Event\MenuBuilderEvent;
16
17
final class CompanyDataMenuBuilder
18
{
19
    public function addItem(MenuBuilderEvent $menuBuilderEvent): void
20
    {
21
        $configuration = $menuBuilderEvent->getMenu()->getChild('configuration');
22
        $configuration
23
            ->addChild('company_data', [
24
                'route' => 'bitbag_sylius_invoicing_plugin_admin_company_data_index',
25
            ])
26
            ->setLabel('bitbag_sylius_invoicing_plugin.ui.invoice_data')
27
            ->setLabelAttribute('icon', 'file text outline')
28
        ;
29
    }
30
}
31