mirror of
https://github.com/snipe/snipe-it.git
synced 2024-12-25 13:44:06 -08:00
Fixed #5168 - users without superadmin could not see custom fields UI even if granted
This commit is contained in:
parent
17e0154995
commit
c4db8d37c2
|
@ -140,6 +140,7 @@ class AuthServiceProvider extends ServiceProvider
|
||||||
|| $user->can('view', \App\Models\Company::class)
|
|| $user->can('view', \App\Models\Company::class)
|
||||||
|| $user->can('view', \App\Models\Manufacturer::class)
|
|| $user->can('view', \App\Models\Manufacturer::class)
|
||||||
|| $user->can('view', \App\Models\Company::class)
|
|| $user->can('view', \App\Models\Company::class)
|
||||||
|
|| $user->can('view', \App\Models\CustomField::class)
|
||||||
|| $user->can('view', \App\Models\Depreciation::class);
|
|| $user->can('view', \App\Models\Depreciation::class);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
@ -524,8 +524,8 @@
|
||||||
</a>
|
</a>
|
||||||
|
|
||||||
<ul class="treeview-menu">
|
<ul class="treeview-menu">
|
||||||
@can('view', \App\Models\Customfield::class)
|
@can('view', \App\Models\CustomField::class)
|
||||||
<li {!! (Request::is('custom_fields*') ? ' class="active"' : '') !!}>
|
<li {!! (Request::is('fields*') ? ' class="active"' : '') !!}>
|
||||||
<a href="{{ route('fields.index') }}">
|
<a href="{{ route('fields.index') }}">
|
||||||
{{ trans('admin/custom_fields/general.custom_fields') }}
|
{{ trans('admin/custom_fields/general.custom_fields') }}
|
||||||
</a>
|
</a>
|
||||||
|
|
Loading…
Reference in a new issue