PHPackages                             josegus/laravel-dash - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. josegus/laravel-dash

ActiveProject

josegus/laravel-dash
====================

Simple dashboard for laravel

1.0.0(6y ago)3151[23 PRs](https://github.com/josegus/laravel-dash/pulls)MITHTMLPHP &gt;=7.0

Since Apr 10Pushed 3y ago3 watchersCompare

[ Source](https://github.com/josegus/laravel-dash)[ Packagist](https://packagist.org/packages/josegus/laravel-dash)[ RSS](/packages/josegus-laravel-dash/feed)WikiDiscussions master Synced yesterday

READMEChangelog (1)Dependencies (2)Versions (25)Used By (0)

Dash: Laravel admin panel
-------------------------

[](#dash-laravel-admin-panel)

Installation
------------

[](#installation)

Install the package in any laravel app executing:

```
composer require josegus/laravel-dash
```

Once installed, export js and css files executing:

```
php artisan vendor:publish --tag:laravel-dash:assets
```

Configuration
-------------

[](#configuration)

Config file is documented itself, export it executing:

```
php artisan vendor:publish --tag=laravel-dash:config
```

Customizing views
-----------------

[](#customizing-views)

Export all view files:

```
php artisan vendor:publish --tag=laravel-dash:views
```

Export only layout views:

```
php artisan vendor:publish --tag=laravel-dash:layout-views
```

Export only auth views:

```
php artisan vendor:publish --tag=laravel-dash:auth-views
```

Build from source
-----------------

[](#build-from-source)

You can export the resources (js and sass files) to make your own build executing:

`bash php artisan vendor:publish --tag=laravel-dash:resources `

The assets will now be located in the `resources/dash` directory.

DataTables
----------

[](#datatables)

The best way to use DataTables in any Laravel app is to use [laravel-datatables](https://github.com/yajra/laravel-datatables), from [Arjay Angeles (yajra)](https://github.com/yajra). The laravel-datatables package comes with many features to include/use datatables y many ways.

I prefer to use `datatables()` helper with ajax server side. Dash comes with an abstract class to help you build your ajax response. Here is an example for an User model :

### 1. Create a route to data source

[](#1-create-a-route-to-data-source)

Since we will return a json response, api.php is a good place to put your datatable routes. You can create the path and route name as you wish, for example:

```
