@extends('header') @section('content') @parent @include('accounts.nav', ['selected' => ACCOUNT_USER_MANAGEMENT]) {!! Former::open($url)->autocomplete('off')->method($method)->addClass('warn-on-exit user-form')->rules(array( 'first_name' => 'required', 'last_name' => 'required', 'email' => 'required|email', )); !!} @if ($user) {!! Former::populate($user) !!} {{ Former::populateField('is_admin', intval($user->is_admin)) }} @endif
{!! Former::checkbox('create') ->text( trans('texts.create') ) ->value('create_') ->label(' ') ->id('create_all') !!} | {!! Former::checkbox('view') ->text( trans('texts.view') ) ->value('view_') ->label(' ') ->id('view_all') !!} | {!! Former::checkbox('edit') ->text( trans('texts.edit') ) ->value('edit_') ->label(' ') ->id('edit_all') !!} | @foreach (json_decode(PERMISSION_ENTITIES,1) as $permissionEntity) permissions,1); else $permissions = []; ?>|
---|---|---|---|
{{ ucfirst($permissionEntity) }} | {!! Former::checkbox('permissions[create_' . $permissionEntity . ']') ->label(' ') ->value('create_' . $permissionEntity . '') ->id('create_' . $permissionEntity . '') ->check(is_array($permissions) && in_array('create_' . $permissionEntity, $permissions, FALSE) ? true : false) !!} | {!! Former::checkbox('permissions[view_' . $permissionEntity . ']') ->label(' ') ->value('view_' . $permissionEntity . '') ->id('view_' . $permissionEntity . '') ->check(is_array($permissions) && in_array('view_' . $permissionEntity, $permissions, FALSE) ? true : false) !!} | {!! Former::checkbox('permissions[edit_' . $permissionEntity . ']') ->label(' ') ->value('edit_' . $permissionEntity . '') ->id('edit_' . $permissionEntity . '') ->check(is_array($permissions) && in_array('edit_' . $permissionEntity, $permissions, FALSE) ? true : false) !!} |