Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
simpmw
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
Alfiro Pratama
simpmw
Commits
45fc878b
Commit
45fc878b
authored
Mar 02, 2026
by
Alfiro Pratama
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix login sso
parent
a7c06275
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
88 additions
and
74 deletions
+88
-74
app/Http/Controllers/Authentication/LoginController.php
+4
-2
resources/views/backend/operator/jadwal_kegiatan/index.blade.php
+18
-0
resources/views/backend/operator/jenis/index.blade.php
+48
-72
resources/views/backend/operator/jenis_penilaian_monev/index.blade.php
+18
-0
No files found.
app/Http/Controllers/Authentication/LoginController.php
View file @
45fc878b
...
@@ -45,8 +45,6 @@ class LoginController extends Controller
...
@@ -45,8 +45,6 @@ class LoginController extends Controller
public
function
sso
(
$email
,
$session_id
)
public
function
sso
(
$email
,
$session_id
)
{
{
// $auth = $this->ssoRepo->sso($session_id);
try
{
try
{
$clientbiodata
=
new
Client
();
$clientbiodata
=
new
Client
();
$apiRequestbiodata
=
$clientbiodata
->
request
(
'GET'
,
'https://sso.unesa.ac.id/userid/'
.
$email
);
$apiRequestbiodata
=
$clientbiodata
->
request
(
'GET'
,
'https://sso.unesa.ac.id/userid/'
.
$email
);
...
@@ -63,8 +61,12 @@ class LoginController extends Controller
...
@@ -63,8 +61,12 @@ class LoginController extends Controller
// dd($auth);
// dd($auth);
if
(
!
is_array
(
$auth
))
{
if
(
!
is_array
(
$auth
))
{
$auth
=
$this
->
ssoRepo
->
sso
(
$session_id
);
if
(
!
is_array
(
$auth
))
{
return
redirect
(
'https://sso.unesa.ac.id/user'
);
return
redirect
(
'https://sso.unesa.ac.id/user'
);
}
}
}
$user
=
$this
->
userRepo
->
find
(
null
,
null
,
$auth
[
0
]
->
email
);
$user
=
$this
->
userRepo
->
find
(
null
,
null
,
$auth
[
0
]
->
email
);
// dd($user);
// dd($user);
...
...
resources/views/backend/operator/jadwal_kegiatan/index.blade.php
View file @
45fc878b
...
@@ -91,6 +91,24 @@ Dashboard
...
@@ -91,6 +91,24 @@ Dashboard
@section('js')
@section('js')
<script type="
text
/
javascript
">
<script type="
text
/
javascript
">
$(function() {
$(function() {
// SweetAlert dari session (setelah simpan jadwal)
@if(session('successMessage'))
Swal.fire({
icon: 'success',
title: 'Berhasil',
text: '{{ session('successMessage') }}',
confirmButtonText: 'OK'
});
@endif
@if(session('errorMessage'))
Swal.fire({
icon: 'error',
title: 'Gagal',
text: '{{ session('errorMessage') }}',
confirmButtonText: 'OK'
});
@endif
$('input[name^="
tanggal
"]').daterangepicker({
$('input[name^="
tanggal
"]').daterangepicker({
timePicker: true,
timePicker: true,
timePicker24Hour: true,
timePicker24Hour: true,
...
...
resources/views/backend/operator/jenis/index.blade.php
View file @
45fc878b
...
@@ -57,12 +57,30 @@
...
@@ -57,12 +57,30 @@
@section('js')
@section('js')
<script>
<script>
$(document).ready(function(){
$(document).ready(function(){
// SweetAlert dari session (setelah tambah/edit)
@if(session('successMessage'))
Swal.fire({
icon: 'success',
title: 'Berhasil',
text: '{{ session('successMessage') }}',
confirmButtonText: 'OK'
});
@endif
@if(session('errorMessage'))
Swal.fire({
icon: 'error',
title: 'Gagal',
text: '{{ session('errorMessage') }}',
confirmButtonText: 'OK'
});
@endif
// DataTable
// DataTable
var oTable = $('#example').DataTable({
var oTable = $('#example').DataTable({
processing: true,
processing: true,
serverSide: true,
serverSide: true,
ajax: {
ajax: {
"
url
" : "
{{
route
(
'operator.getJenis'
)
}}
"
"
url
" : "
{{
route
(
'operator.getJenis'
)
}}
"
},
},
columns: [
columns: [
{ data: 'jenis_id' },
{ data: 'jenis_id' },
...
@@ -86,93 +104,51 @@
...
@@ -86,93 +104,51 @@
title: "
Apakah
Anda
Yakin
?
",
title: "
Apakah
Anda
Yakin
?
",
text: "
Anda
akan
menghapus
data
ini
!
",
text: "
Anda
akan
menghapus
data
ini
!
",
icon: "
warning
",
icon: "
warning
",
showCancelButton:
!0
,
showCancelButton:
true
,
confirmButtonText: "
Ya
,
Hapus
data
!
",
confirmButtonText: "
Ya
,
Hapus
data
!
",
cancelButtonText: "
Tidak
,
Kembali
!
",
cancelButtonText: "
Tidak
,
Kembali
!
",
confirmButtonClass: "
btn
btn
-
success
mt
-
2
",
confirmButtonClass: "
btn
btn
-
success
mt
-
2
",
cancelButtonClass: "
btn
btn
-
danger
ms
-
2
mt
-
2
",
cancelButtonClass: "
btn
btn
-
danger
ms
-
2
mt
-
2
",
buttonsStyling: !1,
buttonsStyling: false,
allowOutsideClick: !1,
allowOutsideClick: false
showLoaderOnConfirm: true
}).then((result) => {
}).then((result) => {
if (result.value
){
if (result.isConfirmed
){
$.ajax({
$.ajax({
url:'
{
{url("/jenis/")}
}
/' +reqId
,
url: '{{ url("
operator
/
jenis
") }}/' + encodeURIComponent(reqId)
,
type:
'DELETE',
type:
'DELETE',
data:
{
data:
{
"
_token
": "
{{
csrf_token
()
}}
",
"
_token
": "
{{
csrf_token
()
}}
",
},
},
dataType: "
JSON
",
dataType: "
JSON
",
})
})
.done(function(response){
.done(function(response){
swal.fire('Deleted!', response.message, response.status).then(function(){
Swal.fire({
icon: response.status === 'success' ? 'success' : 'error',
title: response.status === 'success' ? 'Terhapus!' : 'Gagal',
text: response.message || (response.status === 'success' ? 'Data berhasil dihapus.' : 'Data gagal dihapus.')
}).then(function(){
location.reload();
location.reload();
});
});
})
})
.fail(function(){
.fail(function(xhr){
swal.fire('Oops...', 'Something went wrong with ajax !', 'error');
var msg = 'Terjadi kesalahan. Data gagal dihapus.';
if (xhr.responseJSON && xhr.responseJSON.message) msg = xhr.responseJSON.message;
Swal.fire({
icon: 'error',
title: 'Gagal',
text: msg
}).then(function(){
location.reload();
});
});
} else {
Swal.fire({
icon: 'info',
title: 'Batal',
text: 'Data batal dihapus.'
});
});
}
}
else
});
{
swal.fire('Batal!', 'Data batal dihapus.', 'error');
}
})
}
}
// }).then(function(t) {
// t.value ? Swal.fire({
// icon: "
success
",
// title: "
Sukses
!
",
// text: "
Data
berhasil
dihapus
.
",
// type: "
success
"
// }) : t.dismiss === Swal.DismissReason.cancel && Swal.fire({
// icon: "
error
",
// title: "
Batal
!
",
// text: "
Data
batal
dihapus
.
",
// type: "
error
"
// })
// });
// }
// function confirmDelete(reqId) {
// swal({
// title: "
Apakah
Anda
Yakin
?
",
// text: "
Anda
akan
menghapus
data
ini
!
",
// icon: "
warning
",
// buttons: true,
// dangerMode: true,
// })
// .then((willDelete) => {
// if (willDelete) {
// $.ajax({
// type:'DELETE',
// url:'
{
{url("/jenis/")}
}
/' +reqId,
// data:{
// "
_token
": "
{{
csrf_token
()
}}
",
// },
// dataType: "
JSON
",
// success: function (result) {
// // console.log(result);
// swal("
Sukses
!
", "
Data
berhasil
dihapus
.
", "
success
").then(function(){
// location.reload();
// });
// },
// error: function (xhr, ajaxOptions, thrownError) {
// swal("
Error
!
", "
Data
gagal
dihapus
.
", "
error
").then(function(){
// location.reload();
// });
// }
// });
// // document.location.reload();
// } else {
// swal("
Data
batal
dihapus
.
", {
// icon: "
error
",
// });
// }
// });
// };
</script>
</script>
@endsection
@endsection
resources/views/backend/operator/jenis_penilaian_monev/index.blade.php
View file @
45fc878b
...
@@ -53,6 +53,24 @@
...
@@ -53,6 +53,24 @@
@section('js')
@section('js')
<script>
<script>
$(document).ready(function(){
$(document).ready(function(){
// SweetAlert dari session (setelah edit)
@if(session('successMessage'))
Swal.fire({
icon: 'success',
title: 'Berhasil',
text: '{{ session('successMessage') }}',
confirmButtonText: 'OK'
});
@endif
@if(session('errorMessage'))
Swal.fire({
icon: 'error',
title: 'Gagal',
text: '{{ session('errorMessage') }}',
confirmButtonText: 'OK'
});
@endif
// DataTable
// DataTable
var oTable = $('#example').DataTable({
var oTable = $('#example').DataTable({
processing: true,
processing: true,
...
...
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