<?php
namespace App\Providers;
use Illuminate\Support\ServiceProvider;
class AppServiceProvider extends ServiceProvider
{
/**
* Bootstrap any application services.
*
* @return void
*/
public function boot()
{
view()->composer('*', function($view) {
$view->with('isAdmin', true);
$view->with('isSupervisor', false);
});
/* Make sure you have a view named "index.blade.ctp" in a folder
named "customFolder" under "project/resources/views" folder.
*/
view()->composer(array("customFolder.index"), function($view) {
$view->with("xor", "XOR-1");
});
}
/**
* Register any application services.
*
* @return void
*/
public function register()
{
//
}
}