| Conditions | 2 |
| Paths | 2 |
| Total Lines | 22 |
| Code Lines | 12 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 13 |
| CRAP Score | 2 |
| Changes | 1 | ||
| Bugs | 1 | Features | 0 |
| 1 | <?php |
||
| 42 | 5 | public function display(array $db_data, $editing = false) |
|
| 43 | { |
||
| 44 | 5 | $title = $this->user->lang('LINKS'); |
|
| 45 | 5 | $menu_id = $db_data['settings']['menu_id']; |
|
| 46 | |||
| 47 | 5 | $data = $this->_get_menu($menu_id); |
|
| 48 | |||
| 49 | 5 | if (!sizeof($data)) |
|
| 50 | 5 | { |
|
| 51 | return array( |
||
| 52 | 4 | 'title' => $title, |
|
| 53 | 4 | 'content' => $this->_get_message($menu_id, $editing), |
|
| 54 | 4 | ); |
|
| 55 | } |
||
| 56 | |||
| 57 | 1 | $this->tree->display_list($data, $this->ptemplate, 'tree'); |
|
| 58 | |||
| 59 | return array( |
||
| 60 | 1 | 'title' => $title, |
|
| 61 | 1 | 'content' => $this->ptemplate->render_view('blitze/sitemaker', 'blocks/links.html', 'links_block'), |
|
| 62 | 1 | ); |
|
| 63 | } |
||
| 64 | } |
||
| 65 |