Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
simpkm
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Farendi Giotivano R.P
simpkm
Commits
c351c34d
Commit
c351c34d
authored
a month ago
by
Farendi Giotivano R.P
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update fakultas dosen
parent
ce52ec63
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
38 additions
and
1 deletions
+38
-1
app/Http/Controllers/DashboardController.php
+25
-1
app/Http/Controllers/GetDataApiController.php
+9
-0
resources/views/backend/mahasiswa/kelompok/index.blade.php
+4
-0
No files found.
app/Http/Controllers/DashboardController.php
View file @
c351c34d
...
...
@@ -21,7 +21,7 @@ class DashboardController extends Controller
$title
=
'Dashboard PKM'
;
$pengumuman
=
$pengumuman
=
Pengumuman
::
query
()
->
first
();
if
(
Auth
::
user
()
->
hasrole
([
'mahasiswa'
]))
{
if
(
Auth
::
user
()
->
hasrole
([
'mahasiswa'
]))
{
$user
=
Auth
::
user
()
->
rBiodata
->
noidentitas
;
$dataMhs
=
GetDataApiController
::
getAccount
(
$user
);
...
...
@@ -33,6 +33,30 @@ class DashboardController extends Controller
$biodata
->
update
(
$person
);
}
if
(
Auth
::
user
()
->
hasrole
([
'dosen'
])){
$user
=
Auth
::
user
()
->
rBiodata
->
email
;
$isdm
=
GetDataApiController
::
sso
(
$user
);
if
(
$isdm
[
0
]
->
nidn
)
{
$noidentitas
=
$isdm
[
0
]
->
nidn
;
}
else
{
if
(
$isdm
[
0
]
->
nuptk
)
{
$noidentitas
=
$isdm
[
0
]
->
nuptk
;
}
else
{
$noidentitas
=
$isdm
[
0
]
->
userid
;
}
}
$person
[
'noidentitas'
]
=
$noidentitas
;
$person
[
'fakultas'
]
=
$isdm
[
0
]
->
namaparentsatker
;
$person
[
'prodi'
]
=
$isdm
[
0
]
->
namasatker
;
$biodata
=
Biodata
::
where
(
'email'
,
$user
)
->
first
();
$biodata
->
update
(
$person
);
}
$data
=
[
'title'
=>
$title
,
'pengumuman'
=>
$pengumuman
,
...
...
This diff is collapsed.
Click to expand it.
app/Http/Controllers/GetDataApiController.php
View file @
c351c34d
...
...
@@ -44,4 +44,13 @@ class GetDataApiController extends Controller
return
$data
;
}
public
static
function
sso
(
$email
)
{
$client
=
new
Client
();
$apiRequest
=
$client
->
request
(
'GET'
,
'https://sso.unesa.ac.id/userid/'
.
$email
);
$isdm
=
json_decode
(
$apiRequest
->
getBody
()
->
getContents
());
return
$isdm
;
}
}
This diff is collapsed.
Click to expand it.
resources/views/backend/mahasiswa/kelompok/index.blade.php
View file @
c351c34d
...
...
@@ -99,6 +99,10 @@
<a onclick="
hapus
(
'{{ encrypt($item->kelompok_id) }}'
,
'row-{{ $token }}'
)
" class="
btn
btn
-
danger
btn
-
sm
">Hapus</a>
@endif
{{-- @if(
$item->revisi
== 1)
<a href="
{{
URL
::
to
(
'mahasiswa/kelompok-new'
,
encrypt
(
$item
->
kelompok_id
))
}}
" class="
btn
btn
-
warning
btn
-
sm
">Edit</a>
@endif --}}
<div id="
{{
'lihat'
.
$item
->
kelompok_id
}}
" class="
modal
fade
" tabindex="
-
1
" role="
dialog
"
aria-labelledby="
lihatLabel
" aria-hidden="
true
">
<div class="
modal
-
dialog
modal
-
xl
">
...
...
This diff is collapsed.
Click to expand it.
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