2017 © Pedro Peláez
 

project spatie-laravel-dashboard

Spatie's Laravel Dashboard package.

image

konsulting/spatie-laravel-dashboard

Spatie's Laravel Dashboard package.

  • Wednesday, May 16, 2018
  • by konsulting
  • Repository
  • 1 Watchers
  • 1 Stars
  • 38 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 13 Versions
  • 0 % Grown

The README.md

Spatie.be Laravel Dashboard

Packaged version of the Spatie's Laravel Dashboard. The aim is to allow this handsome dashboard to be pulled into other projects, or customised heavily while keeping the core code isolated., (*1)

We will offer this repo to Spatie for them to maintain, so it may not exist for too long here., (*2)

Installation

With a new Laravel 5.5 app:, (*3)

  • composer require konsulting/spatie-laravel-dashboard
  • php artisan make:auth
  • php artisan migrate
  • Add a user: perhaps use php artisan tinker
  • The Spatie\\LaravelDashboard\\Providers\\DashboardServiceProvider is now auto-registered.
  • Add the schedule to your console kernel. Add (new \Spatie\LaravelDashboard\Console\DashboardSchedule($schedule))->handle(); to the handle method.
  • Add your pusher cluster settings to the config/broadcasting.php file
'pusher' => [
    ...
    'options' => [
        'cluster' => 'eu',
        'secure' => true,
    ],
]
  • If using google calendar, you need a service account - add the json file with credentials to storage/app/google-calendar/service-account-credentials.json
  • Add the .env items you need from the stubs/.env.example for the services you want to use.

For simple use

  • php artisan vendor:publish --provider=Spatie\\LaravelDashboard\\Providers\\DashboardServiceProvider --tag=basic
  • Start your queue listener and setup the Laravel scheduler.
  • Open the dashboard in your browser, login and wait for the update events to fill the dashboard.

Simple customisations are possible through the config file (config/dashboard.php) and the dashboard view (resources/views/vendor/dashboard/dashbooard.blade.php)., (*4)

If using any of these routes, you may need to explude them in your VerifyCsrfToken middleware., (*5)

      protected $except = [
          '/webhook/github',
          '/pusher/authenticate',
          '/oh-dear-webhooks',
      ];

To fully customise, it needs more work

You need to be comfortable with Vue and Laravel, (*6)

  • php artisan vendor:publish --provider=Spatie\\LaravelDashboard\\Providers\\DashboardServiceProvider --tag=advanced
  • add babel.rc and all package.json reqt's (see the packages .babelrc and package.json)
  • npm run prod to build the necessary files., (*7)

  • You can override the schedule by using your own Schedule class instead of Spatie\LaravelDashboard\Console\DashboardSchedule($schedule)., (*8)

  • You can either add to the Dashboard Update command by listening for the DashboardUpdated event, or by creating a new Command set in Spatie\Console\UpdateDashboardCommandSet

License

This project and the Laravel framework are open-sourced software licensed under the MIT license., (*9)

The Versions