@extends($layout) @section('content')
{!! Form::open(['route' => 'messages.store']) !!}
@if(checkRole(['owner']))
{{ Form::label('branch_id', getphrase('branch')) }} {{Form::select('branch_id', $branches, null, ['class'=>'form-control','onChange'=>'getUsersByBranch()', 'id'=>'branch_id' ])}}
@else {{ Form::hidden('branch_id', getUserRecord()->branch_id, array('id'=>'branch_id')) }} @endif
{!! Form::label('Select User', 'Select User', ['class' => 'control-label']) !!} {{Form::select('recipients[]', $users, null, ['class'=>'form-control select2', 'name'=>'recipients[]', 'id'=>'users', 'multiple'=>'true'])}}
{!! Form::label('subject', 'Subject', ['class' => 'control-label']) !!} {!! Form::text('subject', null, ['class' => 'form-control']) !!}
{!! Form::label('message', 'Message', ['class' => 'control-label']) !!} {!! Form::textarea('message', null, ['class' => 'form-control']) !!}
{!! Form::submit('Submit', ['class' => 'btn btn-primary btn-lg']) !!}
{!! Form::close() !!}
@stop @section('footer_scripts')