Completed
Push — master ( 333ab3...9dcc44 )
by Laurent
02:27
created

ActionsFlightLog   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 25
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 0

Importance

Changes 0
Metric Value
dl 0
loc 25
rs 10
c 0
b 0
f 0
wmc 1
lcom 1
cbo 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A addSearchEntry() 0 12 1
1
<?php
2
/**
3
 *
4
 */
5
6
/**
7
 * ActionsFlightLog class
8
 *
9
 * @author Laurent De Coninck <[email protected]>
10
 */
11
class ActionsFlightLog
12
{
13
14
    public $results = [];
15
16
    /**
17
     * Add entry in search list
18
     *
19
     * @param array $searchInfo
20
     *
21
     * @return int
22
     */
23
    public function addSearchEntry($searchInfo)
24
    {
25
        global $langs;
26
27
        $langs->load("mymodule@flightLog");
28
29
        $this->results["flightLog"] = [
30
            'label' => $langs->trans("Search flight"),
31
            'text'  => $langs->trans("Search flight"),
32
            'url'   => DOL_URL_ROOT . '/flightLog/list.php?mainmenu=flightLog&sall='.$searchInfo['search_boxvalue']
33
        ];
34
    }
35
}