Only allow users to create a new user via modal if they have users.create permission

This commit is contained in:
snipe 2017-01-11 14:54:39 -08:00
parent 9e4a391b8b
commit c7167fc73c

View file

@ -73,7 +73,9 @@
{!! $errors->first('assigned_user', '<span class="alert-msg"><i class="fa fa-times"></i> :message</span>') !!} {!! $errors->first('assigned_user', '<span class="alert-msg"><i class="fa fa-times"></i> :message</span>') !!}
</div> </div>
<div class="col-md-1 col-sm-1 text-left" style="margin-left: -20px; padding-top: 3px"> <div class="col-md-1 col-sm-1 text-left" style="margin-left: -20px; padding-top: 3px">
@can('users.create')
<a href='#' data-toggle="modal" data-target="#createModal" data-dependency="user" data-select='assigned_user' class="btn btn-sm btn-default">New</a> <a href='#' data-toggle="modal" data-target="#createModal" data-dependency="user" data-select='assigned_user' class="btn btn-sm btn-default">New</a>
@endcan
</div> </div>
</div> </div>