first commit
This commit is contained in:
26
app/Http/ViewComposers/All.php
Normal file
26
app/Http/ViewComposers/All.php
Normal file
@@ -0,0 +1,26 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\ViewComposers;
|
||||
|
||||
use App\Traits\DateTime;
|
||||
use Illuminate\View\View;
|
||||
|
||||
class All
|
||||
{
|
||||
use DateTime;
|
||||
|
||||
/**
|
||||
* Bind data to the view.
|
||||
*
|
||||
* @param View $view
|
||||
* @return void
|
||||
*/
|
||||
public function compose(View $view)
|
||||
{
|
||||
// Make sure it's installed
|
||||
if (env('DB_DATABASE', '') != '') {
|
||||
// Share date format
|
||||
$view->with(['date_format' => $this->getCompanyDateFormat()]);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user