Created
July 19, 2019 03:04
-
-
Save suehok/842739b87c7cc87eee76cd29d21342b4 to your computer and use it in GitHub Desktop.
Enable PublishAction when Laravel boot up
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace App\Providers; | |
use Illuminate\Support\ServiceProvider; | |
use TCG\Voyager\Facades\Voyager; | |
class AppServiceProvider extends ServiceProvider | |
{ | |
/** | |
* Register any application services. | |
* | |
* @return void | |
*/ | |
public function register() | |
{ | |
// | |
} | |
/** | |
* Bootstrap any application services. | |
* | |
* @return void | |
*/ | |
public function boot() | |
{ | |
// Enable custom action for publish posts | |
Voyager::addAction(\App\Actions\PublishAction::class); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment