mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-11-05 18:52:44 +01:00
patch for basic web views
This commit is contained in:
parent
c8c965384d
commit
d7fa857f10
@ -38,10 +38,13 @@ class HeaderComposer
|
||||
{
|
||||
if(!auth()->user())
|
||||
return [];
|
||||
/
|
||||
//companies
|
||||
$companies = auth()->user()->companies;
|
||||
|
||||
$companies = auth()->user()->companies
|
||||
|
||||
//companies
|
||||
$data['current_company'] = $companies->first();
|
||||
$data['companies'] = $companies;
|
||||
/*
|
||||
$data['current_company'] = $companies->first(function ($company){
|
||||
return $company->id == auth()->user()->company()->id;
|
||||
});
|
||||
@ -49,7 +52,7 @@ class HeaderComposer
|
||||
$data['companies'] = $companies->reject(function ($company){
|
||||
return $company->id == auth()->user()->company()->id;
|
||||
});
|
||||
|
||||
*/
|
||||
return $data;
|
||||
}
|
||||
|
||||
|
@ -22,7 +22,7 @@ class ComposerServiceProvider extends ServiceProvider
|
||||
*/
|
||||
public function boot()
|
||||
{
|
||||
/*
|
||||
|
||||
view()->composer('*', 'App\Http\ViewComposers\HeaderComposer');
|
||||
|
||||
view()->composer(
|
||||
@ -31,7 +31,7 @@ class ComposerServiceProvider extends ServiceProvider
|
||||
],
|
||||
'App\Http\ViewComposers\TranslationComposer'
|
||||
);
|
||||
*/
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user