Completed
Push — master ( 25f1a1...cad3e9 )
by ARCANEDEV
04:24
created

DashboardController   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 29
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
wmc 2
lcom 0
cbo 1
dl 0
loc 29
ccs 0
cts 11
cp 0
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 6 1
A index() 0 8 1
1
<?php namespace Arcanesoft\Tracker\Http\Controllers\Admin;
2
3
use Arcanedev\LaravelTracker\Models\SessionActivity;
4
5
/**
6
 * Class     DashboardController
7
 *
8
 * @package  Arcanesoft\Tracker\Http\Controllers\Admin
9
 * @author   ARCANEDEV <[email protected]>
10
 */
11
class DashboardController extends Controller
12
{
13
    /* ------------------------------------------------------------------------------------------------
14
     |  Constructor
15
     | ------------------------------------------------------------------------------------------------
16
     */
17
    /**
18
     * DashboardController constructor.
19
     */
20
    public function __construct()
21
    {
22
        parent::__construct();
23
24
        $this->setCurrentPage('tracker-dashboard');
25
    }
26
27
    /* ------------------------------------------------------------------------------------------------
28
     |  Main Functions
29
     | ------------------------------------------------------------------------------------------------
30
     */
31
    public function index()
32
    {
33
        $this->setTitle('Tracker');
34
35
        $activities = SessionActivity::all()->toArray();
36
37
        return $this->view('foundation.dashboard', compact('activities'));
38
    }
39
}
40