721 lines
51 KiB
PHP
721 lines
51 KiB
PHP
|
<div class="mb-3 row">
|
||
|
<span class="col-2 col-form-label fw-bold">@lang('permissions') : </span>
|
||
|
<div class="col-10">
|
||
|
<ul class="ulBorder">
|
||
|
<li>
|
||
|
<input type="checkbox" class="all-rights-checkbox" name="allPermission" id="allPermission">
|
||
|
<label class="form-check-label all-rights-label" for="allPermission">@lang('all') @lang('permissions')</label>
|
||
|
|
||
|
<ul>
|
||
|
<!-- Homepage -->
|
||
|
<li class="current sub_cat_box top-border ">
|
||
|
<input type="checkbox" name="home_page" id="home_page" {{ in_array('home_page', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="home_page">@lang('homepage')</label>
|
||
|
</li>
|
||
|
|
||
|
<!-- brands -->
|
||
|
<li class="current sub_cat_box">
|
||
|
<input type="checkbox">
|
||
|
<label class="form-check-label">@lang('brand') @lang('permissions')</label>
|
||
|
<ul>
|
||
|
<li>
|
||
|
<input type="checkbox" name="brands_viewAny" id="brands_viewAny" {{ in_array('brands_viewAny', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="brands_viewAny">@lang('viewAny')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="brands_viewAny_deleted" id="brands_viewAny_deleted" {{ in_array('brands_viewAny_deleted', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="brand_viewAny_deleted">@lang('viewAny_deleted')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="brands_view" id="brands_view" {{ in_array('brands_view', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="brands_view">@lang('view')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="brands_create" id="brands_create" {{ in_array('brands_create', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="brands_create">@lang('create')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="brands_edit" id="brands_edit" {{ in_array('brands_edit', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="brands_edit">@lang('edit')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="brands_delete" id="brands_delete" {{ in_array('brands_delete', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="brands_delete">@lang('delete')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="brands_delete_force" id="brands_delete_force" {{ in_array('brands_delete_force', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="brands_delete_force">@lang('delete_force')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="brands_restore" id="brands_restore" {{ in_array('brands_restore', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="brands_restore">@lang('restore')</label>
|
||
|
</li>
|
||
|
|
||
|
</ul>
|
||
|
</li>
|
||
|
|
||
|
<!-- models -->
|
||
|
<li class="current sub_cat_box">
|
||
|
<input type="checkbox">
|
||
|
<label class="form-check-label">@lang('model') @lang('permissions')</label>
|
||
|
<ul>
|
||
|
<li>
|
||
|
<input type="checkbox" name="models_viewAny" id="models_viewAny" {{ in_array('models_viewAny', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="models_viewAny">@lang('viewAny')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="models_viewAny_deleted" id="models_viewAny_deleted" {{ in_array('models_viewAny_deleted', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="models_viewAny_deleted">@lang('viewAny_deleted')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="models_view" id="models_view" {{ in_array('models_view', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="models_view">@lang('view')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="models_create" id="models_create" {{ in_array('models_create', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="models_create">@lang('create')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="models_edit" id="models_edit" {{ in_array('models_edit', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="models_edit">@lang('edit')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="models_delete" id="models_delete" {{ in_array('models_delete', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="models_delete">@lang('delete')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="models_delete_force" id="models_delete_force" {{ in_array('models_delete_force', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="models_delete_force">@lang('delete_force')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="models_restore" id="models_restore" {{ in_array('models_restore', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="models_restore">@lang('restore')</label>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</li>
|
||
|
|
||
|
<!-- products -->
|
||
|
<li class="current sub_cat_box">
|
||
|
<input type="checkbox">
|
||
|
<label class="form-check-label">@lang('product') @lang('permissions')</label>
|
||
|
<ul>
|
||
|
<li>
|
||
|
<input type="checkbox" name="products_viewAny" id="products_viewAny" {{ in_array('products_viewAny', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="products_viewAny">@lang('viewAny')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="products_viewAny_deleted" id="products_viewAny_delete" {{ in_array('products_viewAny_deleted', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="products_viewAny_deleted">@lang('viewAny_deleted')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="products_view" id="products_view" {{ in_array('products_view', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="products_view">@lang('view')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="products_create" id="products_create" {{ in_array('products_create', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="products_create">@lang('create')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="products_edit" id="products_edit" {{ in_array('products_edit', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="products_edit">@lang('edit')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="products_delete" id="products_delete" {{ in_array('products_delete', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="products_delete">@lang('delete')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="products_delete_force" id="products_delete_force" {{ in_array('products_delete_force', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="products_delete_force">@lang('delete_force')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="products_restore" id="products_restore" {{ in_array('products_restore', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="products_restore">@lang('restore')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="products_amount_add" id="products_amount_add" {{ in_array('products_amount_add', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="products_amount_add">@lang('amount_add')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="products_amount_remove" id="products_amount_remove" {{ in_array('products_amount_remove', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="products_amount_remove">@lang('amount_remove')</label>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</li>
|
||
|
|
||
|
<!-- products categories -->
|
||
|
<li class="current sub_cat_box">
|
||
|
<input type="checkbox" name="">
|
||
|
<label class="form-check-label" for="category">@lang('product') @lang('category') @lang('permissions')</label>
|
||
|
<ul>
|
||
|
<li>
|
||
|
<input type="checkbox" name="categories_viewAny" id="categories_viewAny" {{ in_array('categories_viewAny', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="categories_viewAny">@lang('viewAny')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="categories_viewAny_deleted" id="categories_viewAny_deleted" {{ in_array('categories_viewAny_deleted', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="categories_viewAny_deleted">@lang('viewAny_deleted')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="categories_view" id="categories_view" {{ in_array('categories_view', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="categories_view">@lang('view')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="categories_create" id="categories_create" {{ in_array('categories_create', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="categories_create">@lang('create')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="categories_edit" id="categories_edit" {{ in_array('categories_edit', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="categories_edit">@lang('edit')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="categories_delete" id="categories_delete" {{ in_array('categories_delete', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="categories_delete">@lang('delete')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="categories_delete_force" id="categories_delete_force" {{ in_array('categories_delete_force', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="categories_delete_force">@lang('delete_force')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="categories_restore" id="categories_restore" {{ in_array('categories_restore', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="categories_restore">@lang('restore')</label>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</li>
|
||
|
|
||
|
<!-- products subcategories -->
|
||
|
<li class="current sub_cat_box">
|
||
|
<input type="checkbox" name="">
|
||
|
<label class="form-check-label" for="subcategory">@lang('product') @lang('subcategory') @lang('permissions')</label>
|
||
|
<ul>
|
||
|
<li>
|
||
|
<input type="checkbox" name="subcategories_viewAny" id="subcategories_viewAny" {{ in_array('subcategories_viewAny', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="subcategories_viewAny">@lang('viewAny')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="subcategories_viewAny_deleted" id="subcategories_viewAny_deleted" {{ in_array('subcategories_viewAny_deleted', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="subcategories_viewAny_deleted">@lang('viewAny_deleted')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="subcategories_view" id="subcategories_view" {{ in_array('subcategories_view', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="subcategories_view">@lang('view')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="subcategories_create" id="subcategories_create" {{ in_array('subcategories_create', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="subcategories_create">@lang('create')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="subcategories_edit" id="subcategories_edit" {{ in_array('subcategories_edit', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="subcategories_edit">@lang('edit')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="subcategories_delete" id="subcategories_delete" {{ in_array('subcategories_delete', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="subcategories_delete">@lang('delete')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="subcategories_delete_force" id="subcategories_delete_force" {{ in_array('subcategories_delete_force', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="subcategories_delete_force">@lang('delete_force')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="subcategories_restore" id="subcategories_restore" {{ in_array('subcategories_restore', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="subcategories_restore">@lang('restore')</label>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</li>
|
||
|
|
||
|
<!-- users -->
|
||
|
<li class="current sub_cat_box">
|
||
|
<input type="checkbox">
|
||
|
<label class="form-check-label">@lang('user') @lang('permissions')</label>
|
||
|
<ul>
|
||
|
<li>
|
||
|
<input type="checkbox" name="users_viewAny" id="users_viewAny" {{ in_array('users_viewAny', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="users_viewAny">@lang('viewAny')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="users_viewAny_deleted" id="users_viewAny_deleted" {{ in_array('users_viewAny_deleted', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="users_viewAny_deleted">@lang('viewAny_deleted')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="users_view" id="users_view" {{ in_array('users_view', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="users_view">@lang('view')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="users_create" id="users_create" {{ in_array('users_create', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="users_create">@lang('create')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="users_edit" id="users_edit" {{ in_array('users_edit', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="users_edit">@lang('edit')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="users_edit_role" id="users_edit_role" {{ in_array('users_edit_role', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="users_edit_role">@lang('update') @lang('role')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="users_edit_username" id="users_edit_username" {{ in_array('users_edit_username', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="users_edit_username">@lang('update') @lang('username')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="users_delete" id="users_delete" {{ in_array('users_delete', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="users_delete">@lang('delete')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="users_delete_force" id="users_delete_force" {{ in_array('users_delete_force', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="users_delete_force">@lang('delete_force')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="users_restore" id="users_restore" {{ in_array('users_restore', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="users_restore">@lang('restore')</label>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</li>
|
||
|
|
||
|
<!-- PDF -->
|
||
|
<li class="current sub_cat_box">
|
||
|
<input type="checkbox" >
|
||
|
<label class="form-check-label">PDF @lang('permissions')</label>
|
||
|
<ul>
|
||
|
<li>
|
||
|
<input type="checkbox" name="pdf_viewAny" id="pdf_viewAny" {{ in_array('pdf_viewAny', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="pdf_viewAny">@lang('viewAny')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="pdf_view" id="pdf_view" {{ in_array('pdf_view', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="pdf_view">@lang('view')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="pdf_delete" id="pdf_delete" {{ in_array('pdf_delete', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="pdf_delete">@lang('delete')</label>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</li>
|
||
|
|
||
|
<!-- buildings -->
|
||
|
<li class="current sub_cat_box">
|
||
|
<input type="checkbox">
|
||
|
<label class="form-check-label">@lang('building') @lang('permissions')</label>
|
||
|
<ul>
|
||
|
<li>
|
||
|
<input type="checkbox" name="buildings_viewAny" id="buildings_viewAny" {{ in_array('buildings_viewAny', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="buildings_viewAny">@lang('viewAny')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="buildings_viewAny_deleted" id="buildings_viewAny_deleted" {{ in_array('buildings_viewAny_deleted', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="buildings_viewAny_deleted">@lang('viewAny_deleted')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="buildings_view" id="buildings_view" {{ in_array('buildings_view', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="buildings_view">@lang('view')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="buildings_create" id="buildings_create" {{ in_array('buildings_create', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="buildings_create">@lang('create')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="buildings_edit" id="buildings_edit" {{ in_array('buildings_edit', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="buildings_edit">@lang('edit')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="buildings_delete" id="buildings_delete" {{ in_array('buildings_delete', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="buildings_delete">@lang('delete')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="buildings_delete_force" id="buildings_delete_force" {{ in_array('buildings_delete_force', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="buildings_delete_force">@lang('delete_force')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="buildings_restore" id="buildings_restore" {{ in_array('buildings_restore', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="buildings_restore">@lang('restore')</label>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</li>
|
||
|
|
||
|
<!-- rooms -->
|
||
|
<li class="current sub_cat_box">
|
||
|
<input type="checkbox">
|
||
|
<label class="form-check-label">@lang('room') @lang('permissions')</label>
|
||
|
<ul>
|
||
|
<li>
|
||
|
<input type="checkbox" name="rooms_viewAny" id="rooms_viewAny" {{ in_array('rooms_viewAny', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="rooms_viewAny">@lang('viewAny')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="rooms_viewAny_deleted" id="rooms_viewAny_deleted" {{ in_array('rooms_viewAny_deleted', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="rooms_viewAny_deleted">@lang('viewAny_deleted')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="rooms_view" id="rooms_view" {{ in_array('rooms_view', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="rooms_view">@lang('view')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="rooms_create" id="rooms_create" {{ in_array('rooms_create', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="rooms_create">@lang('create')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="rooms_edit" id="rooms_edit" {{ in_array('rooms_edit', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="rooms_edit">@lang('edit')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="rooms_delete" id="rooms_delete" {{ in_array('rooms_delete', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="rooms_delete">@lang('delete')</label>
|
||
|
</li>
|
||
|
|
||
|
<li>
|
||
|
<input type="checkbox" name="rooms_delete_force" id="rooms_delete_force" {{ in_array('rooms_delete_force', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="rooms_delete_force">@lang('delete_force')</label>
|
||
|
</li>
|
||
|
|
||
|
<li>
|
||
|
<input type="checkbox" name="rooms_restore" id="rooms_restore" {{ in_array('rooms_restore', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="rooms_restore">@lang('restore')</label>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</li>
|
||
|
|
||
|
<li class="current sub_cat_box">
|
||
|
<input type="checkbox" >
|
||
|
<label class="form-check-label">@lang('cabel') @lang('category') @lang('permissions')</label>
|
||
|
<ul>
|
||
|
<li>
|
||
|
<input type="checkbox" name="cabelCategories_viewAny" id="cabelCategories_viewAny" {{ in_array('cabelCategories_viewAny', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="cabelCategories_viewAny">@lang('viewAny')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="cabelCategories_viewAny_deleted" id="cabelCategories_viewAny_deleted" {{ in_array('cabelCategories_viewAny_deleted', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="cabelCategories_viewAny_deleted">@lang('viewAny_deleted')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="cabelCategories_view" id="cabelCategories_view" {{ in_array('cabelCategories_view', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="cabelCategories_view">@lang('view')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="cabelCategories_create" id="cabelCategories_create" {{ in_array('cabelCategories_create', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="cabelCategories_create">@lang('create')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="cabelCategories_edit" id="cabelCategories_edit" {{ in_array('cabelCategories_edit', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="cabelCategories_edit">@lang('edit')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="cabelCategories_delete" id="cabelCategories_delete" {{ in_array('cabelCategories_delete', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="cabelCategories_delete">@lang('delete')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="cabelCategories_delete_force" id="cabelCategories_delete_force" {{ in_array('cabelCategories_delete_force', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="cabelCategories_delete_force">@lang('delete_force')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="cabelCategories_restore" id="cabelCategories_restore" {{ in_array('cabelCategories_restore', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="cabelCategories_restore">@lang('restore')</label>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</li>
|
||
|
<li class="current sub_cat_box">
|
||
|
<input type="checkbox" >
|
||
|
<label class="form-check-label">@lang('cabel') @lang('permissions')</label>
|
||
|
<ul>
|
||
|
<li>
|
||
|
<input type="checkbox" name="cabels_viewAny" id="cabels_viewAny" {{ in_array('cabels_viewAny', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="cabels_viewAny">@lang('viewAny')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="cabels_viewAny_deleted" id="cabels_viewAny_deleted" {{ in_array('cabels_viewAny_deleted', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="cabels_viewAny_deleted">@lang('viewAny_deleted')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="cabels_view" id="cabels_view" {{ in_array('cabels_view', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="cabels_view">@lang('view')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="cabels_create" id="cabels_create" {{ in_array('cabels_create', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="cabels_create">@lang('create')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="cabels_edit" id="cabels_edit" {{ in_array('cabels_edit', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="cabels_edit">@lang('edit')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="cabels_delete" id="cabels_delete" {{ in_array('cabels_delete', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="cabels_delete">@lang('delete')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="cabels_delete_force" id="cabels_delete_force" {{ in_array('cabels_delete_force', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="cabels_delete_force">@lang('delete_force')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="cabels_amount_add" id="cabels_amount_add" {{ in_array('cabels_amount_add', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="cabels_amount_add">@lang('amount_add')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="cabels_amount_remove" id="cabels_amount_remove" {{ in_array('cabels_amount_remove', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="cabels_amount_remove">@lang('amount_remove')</label>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</li>
|
||
|
<li class="current sub_cat_box">
|
||
|
<input type="checkbox" >
|
||
|
<label class="form-check-label">@lang('role') @lang('permissions')</label>
|
||
|
<ul>
|
||
|
<li>
|
||
|
<input type="checkbox" name="roles_viewAny" id="roles_viewAny" {{ in_array('roles_viewAny', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="roles_viewAny">@lang('viewAny')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="roles_viewAny_deleted" id="roles_viewAny_deleted" {{ in_array('roles_viewAny_deleted', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="roles_viewAny_deleted">@lang('viewAny_deleted')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="roles_view" id="roles_view" {{ in_array('roles_view', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="roles_view">@lang('view')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="roles_create" id="roles_create" {{ in_array('roles_create', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="roles_create">@lang('create')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="roles_edit" id="roles_edit" {{ in_array('roles_edit', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="roles_edit">@lang('edit')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="roles_edit_permissions" id="roles_edit_permissions" {{ in_array('roles_edit_permissions', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="roles_edit_permissions">@lang('give') @lang('permissions')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="roles_delete" id="roles_delete" {{ in_array('roles_delete', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="roles_delete">@lang('delete')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="roles_delete_force" id="roles_delete_force" {{ in_array('roles_delete_force', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="roles_delete_force">@lang('delete_force')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="roles_restore" id="roles_restore" {{ in_array('roles_restore', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="roles_restore">@lang('restore')</label>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</li>
|
||
|
<li class="current sub_cat_box">
|
||
|
<input type="checkbox" >
|
||
|
<label class="form-check-label">@lang('loan') @lang('permissions')</label>
|
||
|
<ul>
|
||
|
<li>
|
||
|
<input type="checkbox" name="loans_viewAny" id="loans_viewAny" {{ in_array('loans_viewAny', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="loans_viewAny">@lang('viewAny')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="loans_create_user" id="loans_create_user" {{ in_array('loans_create_user', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="loans_create_user">@lang('create') @lang('user') @lang('loan')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="loans_create_laptop" id="loans_create_laptop" {{ in_array('loans_create_laptop', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="loans_create_laptop">@lang('create') @lang('laptop') @lang('loan')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="loans_return" id="loans_return" {{ in_array('loans_return', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="loans_return">@lang('return')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="loans_adjust" id="loans_adjust" {{ in_array('loans_adjust', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="loans_adjust">@lang('adjust') @lang('date_end')</label>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</li>
|
||
|
<li class="current sub_cat_box">
|
||
|
<input type="checkbox" >
|
||
|
<label class="form-check-label">@lang('reservation') @lang('permissions')</label>
|
||
|
<ul>
|
||
|
<li>
|
||
|
<input type="checkbox" name="reservations_viewAny" id="reservations_viewAny" {{ in_array('reservations_viewAny', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="reservations_viewAny">@lang('viewAny')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="reservations_create" id="reservations_create" {{ in_array('reservations_create', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="reservations_create">@lang('create')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="reservations_cancel" id="reservations_cancel" {{ in_array('reservations_cancel', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="reservations_cancel">@lang('cancel')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="reservations_validate" id="reservations_validate" {{ in_array('reservations_validate', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="reservations_validate">@lang('validate')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="reservations_setup" id="reservations_setup" {{ in_array('reservations_setup', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="reservations_setup">@lang('setup')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="reservations_pickup" id="reservations_pickup" {{ in_array('reservations_pickup', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="reservations_pickup">@lang('pickup')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="reservations_return" id="reservations_return" {{ in_array('reservations_return', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="reservations_return">@lang('return')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="reservations_adjust" id="reservations_adjust" {{ in_array('reservations_adjust', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="reservations_adjust">@lang('adjust') @lang('date_end')</label>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</li>
|
||
|
<li class="current sub_cat_box">
|
||
|
<input type="checkbox" >
|
||
|
<label class="form-check-label">@lang('note') @lang('permissions')</label>
|
||
|
<ul>
|
||
|
<li>
|
||
|
<input type="checkbox" name="notes_viewAny" id="notes_viewAny" {{ in_array('notes_viewAny', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="notes_viewAny">@lang('viewAny')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="notes_viewAny_deleted" id="notes_viewAny_deleted" {{ in_array('notes_viewAny_deleted', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="notes_viewAny_deleted">@lang('viewAny_deleted')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="notes_view" id="notes_view" {{ in_array('notes_view', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="notes_view">@lang('view')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="notes_create" id="notes_create" {{ in_array('notes_create', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="notes_create">@lang('create')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="notes_edit" id="notes_edit" {{ in_array('notes_edit', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="notes_edit">@lang('edit')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="notes_delete" id="notes_delete" {{ in_array('notes_delete', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="notes_delete">@lang('delete')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="notes_delete_force" id="notes_delete_force" {{ in_array('notes_delete_force', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="notes_delete_force">@lang('delete_force')</label>
|
||
|
</li>
|
||
|
<li>
|
||
|
<input type="checkbox" name="notes_restore" id="notes_restore" {{ in_array('notes_restore', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="notes_restore">@lang('restore')</label>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</li>
|
||
|
<li class="current sub_cat_box">
|
||
|
<input type="checkbox" name="logs_viewAny" id="logs_viewAny" {{ in_array('logs_viewAny', $permissions) ? 'checked' : null }}>
|
||
|
<label for="logs_viewAny" class="form-check-label">@lang('log') @lang('permissions')</label>
|
||
|
</li>
|
||
|
<li class="current sub_cat_box">
|
||
|
<input type="checkbox" name="statistics" id="statistics" {{ in_array('statistics', $permissions) ? 'checked' : null }}>
|
||
|
<label class="form-check-label" for="statistics">@lang('stat') @lang('permissions')</label>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</div>
|
||
|
</div>
|
||
|
@section('scripting')
|
||
|
<script>
|
||
|
// in any of the input fields with the type checkbox change the function is run
|
||
|
$('input[type="checkbox"]').change(function(e) {
|
||
|
|
||
|
let checked = $(this).prop("checked"),
|
||
|
container = $(this).parent(),
|
||
|
siblings = container.siblings();
|
||
|
|
||
|
// goes through the parent to find its children and checks them
|
||
|
container.find('input[type="checkbox"]').prop({
|
||
|
indeterminate: false,
|
||
|
checked: checked
|
||
|
});
|
||
|
|
||
|
function checkSiblings(el) {
|
||
|
|
||
|
let parent = el.parent().parent(),
|
||
|
all = true;
|
||
|
|
||
|
el.siblings().each(function() {
|
||
|
let returnValue = all = ($(this).children('input[type="checkbox"]').prop("checked") === checked);
|
||
|
return returnValue;
|
||
|
});
|
||
|
|
||
|
if (all && checked) {
|
||
|
|
||
|
parent.children('input[type="checkbox"]').prop({
|
||
|
indeterminate: false,
|
||
|
checked: checked
|
||
|
});
|
||
|
|
||
|
checkSiblings(parent);
|
||
|
|
||
|
} else if (all && !checked) {
|
||
|
|
||
|
parent.children('input[type="checkbox"]').prop("checked", checked);
|
||
|
parent.children('input[type="checkbox"]').prop("indeterminate", (parent.find('input[type="checkbox"]:checked').length > 0));
|
||
|
checkSiblings(parent);
|
||
|
|
||
|
} else {
|
||
|
|
||
|
el.parents("li").children('input[type="checkbox"]').prop({
|
||
|
indeterminate: true,
|
||
|
checked: false
|
||
|
});
|
||
|
|
||
|
}
|
||
|
|
||
|
}
|
||
|
|
||
|
checkSiblings(container);
|
||
|
|
||
|
// Get current permissions groups checkbox
|
||
|
let containerCheckBox = container.parent().parent().children('input[type="checkbox"]');
|
||
|
|
||
|
// Check if checkbox is all permissions
|
||
|
if(container.children().hasClass('all-rights-checkbox')){
|
||
|
if (checked)
|
||
|
container.children().find('ul').show();
|
||
|
else
|
||
|
container.children().find('ul').hide();
|
||
|
}else {
|
||
|
// Check if permission checkbox is group parent
|
||
|
if (container.hasClass('sub_cat_box')) {
|
||
|
if (checked)
|
||
|
container.find('ul').show();
|
||
|
else
|
||
|
container.find('ul').hide();
|
||
|
// Check if checkbox is a sub permission
|
||
|
} else {
|
||
|
if (checked)
|
||
|
container.parent().parent().find('ul').show();
|
||
|
else {
|
||
|
if (containerCheckBox.prop('indeterminate'))
|
||
|
container.parent().parent().find('ul').show();
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
});
|
||
|
|
||
|
$(".current").click(function(e){
|
||
|
$(this).find('ul').toggle();
|
||
|
})
|
||
|
|
||
|
$(() => {
|
||
|
let checkBoxes = $('.ulBorder').find('.sub_cat_box > input[type="checkbox"]');
|
||
|
$.each(checkBoxes, (index, checkBox) => {
|
||
|
let totalCheckBoxCount = $(checkBox).parent().children().find('input[type="checkbox"]').length,
|
||
|
checkedCheckBoxCount = $(checkBox).parent().children().find('input[type="checkbox"]:checked').length;
|
||
|
|
||
|
if(checkedCheckBoxCount > 0)
|
||
|
$(checkBox).parent().children('ul').show();
|
||
|
|
||
|
if(totalCheckBoxCount > 0) {
|
||
|
if (totalCheckBoxCount == checkedCheckBoxCount)
|
||
|
$(checkBox).prop('checked', true);
|
||
|
else if (checkedCheckBoxCount > 0 && checkedCheckBoxCount != totalCheckBoxCount)
|
||
|
$(checkBox).prop('indeterminate', true);
|
||
|
}
|
||
|
});
|
||
|
})
|
||
|
</script>
|
||
|
@endsection
|
||
|
<style>
|
||
|
li{
|
||
|
list-style-type: none;
|
||
|
}
|
||
|
</style>
|