Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Walter Felipe
pad-upe
Commits
6257aecb
Commit
6257aecb
authored
Dec 16, 2022
by
alissonalbuquerque
Browse files
add correções
parent
de917d6a
Changes
2
Hide whitespace changes
Inline
Side-by-side
app/Http/Controllers/DashboardController.php
View file @
6257aecb
...
@@ -5,6 +5,7 @@ namespace App\Http\Controllers;
...
@@ -5,6 +5,7 @@ namespace App\Http\Controllers;
use
App\Models\Pad
;
use
App\Models\Pad
;
use
App\Models\Tabelas\Constants
;
use
App\Models\Tabelas\Constants
;
use
App\Models\UserPad
;
use
App\Models\UserPad
;
use
App\Models\UserType
;
use
App\Models\Util\Menu
;
use
App\Models\Util\Menu
;
use
App\Models\Util\MenuItemsAdmin
;
use
App\Models\Util\MenuItemsAdmin
;
use
App\Models\Util\MenuItemsTeacher
;
use
App\Models\Util\MenuItemsTeacher
;
...
@@ -27,9 +28,11 @@ class DashboardController extends Controller
...
@@ -27,9 +28,11 @@ class DashboardController extends Controller
if
(
$user
->
isTypeTeacher
())
if
(
$user
->
isTypeTeacher
())
{
{
$userType
=
$user
->
profile
(
UserType
::
TEACHER
);
$userPads
=
$userPads
=
UserPad
::
initQuery
()
UserPad
::
initQuery
()
->
whereUser
(
$user
->
id
)
->
whereUser
(
$user
Type
->
id
)
->
wherePadStatus
(
Status
::
ATIVO
)
->
wherePadStatus
(
Status
::
ATIVO
)
->
get
();
->
get
();
...
...
resources/views/dashboard.blade.php
View file @
6257aecb
...
@@ -7,7 +7,7 @@
...
@@ -7,7 +7,7 @@
@endif
@endif
@if(Auth::user()->isTypeTeacher())
@if(Auth::user()->isTypeTeacher())
@include('layouts.user-dashboard.dashboard_teacher', ['user' => Auth::user()])
@include('layouts.user-dashboard.dashboard_teacher', ['user' => Auth::user()
, 'userPads => $userPads'
])
@endif
@endif
@if(Auth::user()->isTypeDirector())
@if(Auth::user()->isTypeDirector())
...
...
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