Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
  • Loading branch information
santos-sabanari committed Nov 3, 2020
1 parent f337117 commit 7edab7c
Show file tree
Hide file tree
Showing 4 changed files with 39 additions and 1 deletion.
11 changes: 11 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,17 @@ composer require laravel/fortify
php artisan vendor:publish --provider="Laravel\Fortify\FortifyServiceProvider"
```

Install laravel permission by spatie
```bash
composer require spatie/laravel-permission
php artisan vendor:publish --provider="Spatie\Permission\PermissionServiceProvider"
```

Install laravel datatable package
```bash
composer require santos-sabanari/laravel-datatables
```

Install the package via composer:

```bash
Expand Down
7 changes: 7 additions & 0 deletions src/Console/Commands/InstallCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,13 @@ public function handle()
'--tag' => 'database',
]);

// routes
file_put_contents(
base_path('routes/web.php'),
file_get_contents(__DIR__ . '/stubs/routes/web.stub'),
FILE_APPEND
);

$this->info('All done!');
}
}
2 changes: 1 addition & 1 deletion src/Console/Commands/stubs/routes/web.stub
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use App\Http\Controllers\Backend\DashboardController;
use App\Models\Role;
use App\Models\User;
use Illuminate\Support\Facades\Route;
use SantosSabanari\LaravelFoundation\Http\Controllers\DashboardController;
use SantosSabanari\LaravelFoundation\Http\Controllers\RoleController;
use SantosSabanari\LaravelFoundation\Http\Controllers\UserController;
use SantosSabanari\LaravelFoundation\Http\Controllers\UserPasswordController;
Expand Down
20 changes: 20 additions & 0 deletions src/Http/Controllers/DashboardController.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<?php

namespace SantosSabanari\LaravelFoundation\Http\Controllers;

use App\Http\Controllers\Controller;
use Illuminate\Http\Request;

class DashboardController extends Controller
{
/**
* Handle the incoming request.
*
* @param \Illuminate\Http\Request $request
* @return \Illuminate\Http\Response
*/
public function __invoke(Request $request)
{
return view('laravel-foundation::system.dashboard');
}
}

0 comments on commit 7edab7c

Please sign in to comment.