mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
Restrict modules to selfhost installs
This commit is contained in:
parent
24e4d2d418
commit
90289fc018
@ -759,6 +759,7 @@ class AccountController extends BaseController
|
||||
$account = $user->account;
|
||||
$modules = Input::get('modules');
|
||||
|
||||
if (Utils::isSelfHost()) {
|
||||
// get all custom modules, including disabled
|
||||
$custom_modules = collect(Input::get('custom_modules'))->each(function ($item, $key) {
|
||||
$module = Module::find($item);
|
||||
@ -772,6 +773,7 @@ class AccountController extends BaseController
|
||||
$item->disable();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
$user->force_pdfjs = Input::get('force_pdfjs') ? true : false;
|
||||
$user->save();
|
||||
|
@ -189,6 +189,7 @@
|
||||
</label>
|
||||
</div>
|
||||
@endforeach
|
||||
@if (Utils::isSelfHost())
|
||||
@foreach (Module::all() as $value)
|
||||
{{ ($value->boot()) }}
|
||||
<div class="checkbox">
|
||||
@ -197,6 +198,7 @@
|
||||
</label>
|
||||
</div>
|
||||
@endforeach
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
|
Loading…
x
Reference in New Issue
Block a user