Completed
Push — master ( 3f89d7...f790e9 )
by Mike
30:28 queued 29:00
created

NovaServiceProvider   A

Complexity

Total Complexity 7

Size/Duplication

Total Lines 78
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Importance

Changes 0
Metric Value
wmc 7
lcom 0
cbo 0
dl 0
loc 78
c 0
b 0
f 0
rs 10

7 Methods

Rating   Name   Duplication   Size   Complexity  
A boot() 0 8 1
A routes() 0 6 1
A gate() 0 6 1
A cards() 0 5 1
A tools() 0 4 1
A register() 0 4 1
A resources() 0 4 1
1
<?php namespace GeneaLabs\LaravelModelCaching\Tests\Fixtures\Providers;
2
3
use Illuminate\Support\Facades\Gate;
4
use Laravel\Nova\Nova;
5
use Laravel\Nova\NovaApplicationServiceProvider;
6
7
class NovaServiceProvider extends NovaApplicationServiceProvider
8
{
9
    /**
10
     * Bootstrap any application services.
11
     *
12
     * @return void
13
     */
14
    public function boot()
15
    {
16
        parent::boot();
17
18
        Nova::serving(function () {
19
            Nova::style('laravel-nova-custom-styles', __DIR__ . '/../../public/css/nova.css');
20
        });
21
    }
22
23
    /**
24
     * Register the Nova routes.
25
     *
26
     * @return void
27
     */
28
    protected function routes()
29
    {
30
        Nova::routes()
31
            ->withAuthenticationRoutes()
32
            ->withPasswordResetRoutes();
33
    }
34
35
    /**
36
     * Register the Nova gate.
37
     *
38
     * This gate determines who can access Nova in non-local environments.
39
     *
40
     * @return void
41
     */
42
    protected function gate()
43
    {
44
        Gate::define('viewNova', function () {
45
            return true;
46
        });
47
    }
48
49
    /**
50
     * Get the cards that should be displayed on the Nova dashboard.
51
     *
52
     * @return array
53
     */
54
    protected function cards()
55
    {
56
        return [
57
        ];
58
    }
59
60
    /**
61
     * Get the tools that should be listed in the Nova sidebar.
62
     *
63
     * @return array
64
     */
65
    public function tools()
66
    {
67
        return [];
68
    }
69
70
    /**
71
     * Register any application services.
72
     *
73
     * @return void
74
     */
75
    public function register()
76
    {
77
        //
78
    }
79
80
    protected function resources()
81
    {
82
        // See NovaTestCase
83
    }
84
}
85