Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
Platform
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
Platform
Commits
dfcedff2
Commit
dfcedff2
authored
Nov 21, 2014
by
Nicolas Widart
Browse files
Options
Browse Files
Download
Plain Diff
Merge commit '
4273e495
'
* commit '
4273e495
': Squashed 'Modules/User/' changes from c5fd9da..4cfd87c
parents
c9f40fc9
4273e495
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
21 additions
and
9 deletions
+21
-9
UserController.php
Modules/User/Http/Controllers/Admin/UserController.php
+16
-4
create.blade.php
Modules/User/Resources/views/admin/roles/create.blade.php
+1
-1
edit.blade.php
Modules/User/Resources/views/admin/roles/edit.blade.php
+1
-1
create.blade.php
Modules/User/Resources/views/admin/users/create.blade.php
+1
-1
edit.blade.php
Modules/User/Resources/views/admin/users/edit.blade.php
+1
-1
index.blade.php
Modules/User/Resources/views/admin/users/index.blade.php
+1
-1
No files found.
Modules/User/Http/Controllers/Admin/UserController.php
View file @
dfcedff2
...
...
@@ -3,6 +3,7 @@
use
Illuminate\Support\Facades\Redirect
;
use
Illuminate\Support\Facades\View
;
use
Laracasts\Flash\Flash
;
use
Modules\Core\Contracts\Authentication
;
use
Modules\Core\Permissions\PermissionManager
;
use
Modules\User\Http\Requests\CreateUserRequest
;
use
Modules\User\Http\Requests\UpdateUserRequest
;
...
...
@@ -19,14 +20,23 @@ class UserController extends BaseUserModuleController
* @var RoleRepository
*/
private
$role
;
public
function
__construct
(
PermissionManager
$permissions
,
UserRepository
$user
,
RoleRepository
$role
)
{
/**
* @var Authentication
*/
private
$auth
;
public
function
__construct
(
PermissionManager
$permissions
,
UserRepository
$user
,
RoleRepository
$role
,
Authentication
$auth
)
{
parent
::
__construct
();
$this
->
permissions
=
$permissions
;
$this
->
user
=
$user
;
$this
->
role
=
$role
;
$this
->
auth
=
$auth
;
}
/**
...
...
@@ -38,7 +48,9 @@ class UserController extends BaseUserModuleController
{
$users
=
$this
->
user
->
all
();
return
View
::
make
(
'user::admin.users.index'
,
compact
(
'users'
));
$currentUser
=
$this
->
auth
->
check
();
return
View
::
make
(
'user::admin.users.index'
,
compact
(
'users'
,
'currentUser'
));
}
/**
...
...
Modules/User/Resources/views/admin/roles/create.blade.php
View file @
dfcedff2
...
...
@@ -10,7 +10,7 @@
@stop
@section('styles')
<link href="
{{{
Module
::
asset
(
'core
'
,
'
css/vendor/iCheck/flat/blue.css'
)
}}}
" rel="
stylesheet
" type="
text
/
css
" />
<link href="
{{{
Module
::
asset
(
'core
:
css/vendor/iCheck/flat/blue.css'
)
}}}
" rel="
stylesheet
" type="
text
/
css
" />
@stop
@section('content')
...
...
Modules/User/Resources/views/admin/roles/edit.blade.php
View file @
dfcedff2
...
...
@@ -12,7 +12,7 @@
@stop
@section('styles')
<link href="
{{{
Module
::
asset
(
'core
'
,
'
css/vendor/iCheck/flat/blue.css'
)
}}}
" rel="
stylesheet
" type="
text
/
css
" />
<link href="
{{{
Module
::
asset
(
'core
:
css/vendor/iCheck/flat/blue.css'
)
}}}
" rel="
stylesheet
" type="
text
/
css
" />
@stop
@section('content')
...
...
Modules/User/Resources/views/admin/users/create.blade.php
View file @
dfcedff2
...
...
@@ -12,7 +12,7 @@
@stop
@section('styles')
<link href="
{{{
Module
::
asset
(
'core
'
,
'
css/vendor/iCheck/flat/blue.css'
)
}}}
" rel="
stylesheet
" type="
text
/
css
" />
<link href="
{{{
Module
::
asset
(
'core
:
css/vendor/iCheck/flat/blue.css'
)
}}}
" rel="
stylesheet
" type="
text
/
css
" />
@stop
@section('content')
...
...
Modules/User/Resources/views/admin/users/edit.blade.php
View file @
dfcedff2
...
...
@@ -12,7 +12,7 @@
@stop
@section('styles')
<link href="
{{{
Module
::
asset
(
'core
'
,
'
css/vendor/iCheck/flat/blue.css'
)
}}}
" rel="
stylesheet
" type="
text
/
css
" />
<link href="
{{{
Module
::
asset
(
'core
:
css/vendor/iCheck/flat/blue.css'
)
}}}
" rel="
stylesheet
" type="
text
/
css
" />
@stop
@section('content')
...
...
Modules/User/Resources/views/admin/users/index.blade.php
View file @
dfcedff2
...
...
@@ -62,7 +62,7 @@
<td>
<div
class=
"btn-group"
>
<a
href=
"{{ URL::route('dashboard.user.edit', [$user->id]) }}"
class=
"btn btn-default btn-flat"
><i
class=
"glyphicon glyphicon-pencil"
></i></a>
<?php
if
(
$user
->
id
!=
\Cartalyst\Sentinel\Laravel\Facades\Sentinel
::
check
()
->
id
)
:
?>
<?php
if
(
$user
->
id
!=
$currentUser
->
id
)
:
?>
<button
class=
"btn btn-danger btn-flat"
data-toggle=
"modal"
data-target=
"#confirmation-{{ $user->id }}"
><i
class=
"glyphicon glyphicon-trash"
></i></button>
<?php
endif
;
?>
</div>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment