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
6411a7dd
Commit
6411a7dd
authored
Feb 27, 2023
by
novanbagus
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update reviewer sorting
parent
28bbc94a
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
82 additions
and
4 deletions
+82
-4
app/Http/Controllers/Reviewer/DaftarSeleksiController.php
+29
-3
resources/views/backend/reviewer/seleksi/index.blade.php
+53
-1
No files found.
app/Http/Controllers/Reviewer/DaftarSeleksiController.php
View file @
6411a7dd
...
@@ -39,13 +39,19 @@ class DaftarSeleksiController extends Controller
...
@@ -39,13 +39,19 @@ class DaftarSeleksiController extends Controller
public
function
index
()
public
function
index
()
{
{
return
view
(
'backend.reviewer.seleksi.index'
)
->
withTitle
(
'Daftar Proposal Seleksi Internal'
);
$periode
=
Periode
::
query
()
->
get
();
return
view
(
'backend.reviewer.seleksi.index'
,
compact
(
'periode'
))
->
withTitle
(
'Daftar Proposal Seleksi Internal'
);
}
}
/* AJAX request */
/* AJAX request */
public
function
getData
(
Request
$request
){
public
function
getData
(
Request
$request
){
$noidentitas
=
$this
->
rBiodata
->
noidentitas
;
$noidentitas
=
$this
->
rBiodata
->
noidentitas
;
// parameter
$administrasi
=
$request
->
get
(
'administrasi'
);
$status
=
$request
->
get
(
'status'
);
$tahun
=
$request
->
get
(
'tahun'
);
## Read value
## Read value
$draw
=
$request
->
get
(
'draw'
);
$draw
=
$request
->
get
(
'draw'
);
$start
=
$request
->
get
(
"start"
);
$start
=
$request
->
get
(
"start"
);
...
@@ -62,9 +68,29 @@ class DaftarSeleksiController extends Controller
...
@@ -62,9 +68,29 @@ class DaftarSeleksiController extends Controller
$searchValue
=
strtoupper
(
$search_arr
[
'value'
]);
// Search value
$searchValue
=
strtoupper
(
$search_arr
[
'value'
]);
// Search value
// Total records
// Total records
$statement
=
" AND (UPPER(JUDUL) LIKE '%"
.
$searchValue
.
"%') "
;
$statementGlobal
=
" 1=1 AND (NIDN_REVIEWER_ID_1 = '"
.
$noidentitas
.
"' OR NIDN_REVIEWER_ID_2 = '"
.
$noidentitas
.
"')"
;
$statementGlobal
=
" 1=1 AND (NIDN_REVIEWER_ID_1 = '"
.
$noidentitas
.
"' OR NIDN_REVIEWER_ID_2 = '"
.
$noidentitas
.
"')"
;
if
(
$administrasi
!=
"0"
)
{
// dikurang 1 karena di view mulai dari 0 sedangkan 0 itu menunggu persetujuan
$administrasi
=
$administrasi
-
1
;
$statementGlobal
.=
" AND (ambil_data_reviewer_proposal ( '"
.
$noidentitas
.
"', proposal_id, '3' ) = '"
.
$administrasi
.
"')"
;
}
if
(
$status
!=
"0"
)
{
// dikurang 1 karena di view mulai dari 0 sedangkan 0 itu menunggu persetujuan
$status
=
$status
-
1
;
$statementGlobal
.=
" AND (ambil_data_reviewer_proposal ( '"
.
$noidentitas
.
"', proposal_id, '2' ) = '"
.
$status
.
"')"
;
}
if
(
$tahun
!=
"0"
)
{
$statementGlobal
.=
" AND PERIODE = '"
.
$tahun
.
"'"
;
}
$totalRecords
=
DaftarProposal
::
select
(
'count(1) as allcount'
)
->
whereRaw
(
$statementGlobal
)
->
count
();
$totalRecords
=
DaftarProposal
::
select
(
'count(1) as allcount'
)
->
whereRaw
(
$statementGlobal
)
->
count
();
$statement
=
" AND (UPPER(JUDUL) LIKE '%"
.
$searchValue
.
"%') "
;
$totalRecordswithFilter
=
DaftarProposal
::
select
(
'count(1) as allcount'
)
$totalRecordswithFilter
=
DaftarProposal
::
select
(
'count(1) as allcount'
)
->
whereRaw
(
$statementGlobal
.
$statement
)
->
count
();
->
whereRaw
(
$statementGlobal
.
$statement
)
->
count
();
...
@@ -99,7 +125,7 @@ class DaftarSeleksiController extends Controller
...
@@ -99,7 +125,7 @@ class DaftarSeleksiController extends Controller
$status_administrasi
=
DB
::
select
(
"select ambil_data_reviewer_proposal('"
.
$noidentitas
.
"', '"
.
$proposal_id
.
"', '3')"
)[
0
]
->
ambil_data_reviewer_proposal
;
$status_administrasi
=
DB
::
select
(
"select ambil_data_reviewer_proposal('"
.
$noidentitas
.
"', '"
.
$proposal_id
.
"', '3')"
)[
0
]
->
ambil_data_reviewer_proposal
;
$proposal
=
'<a href="'
.
$url
.
'" target="_blank" class="btn btn-primary btn-sm waves-effect waves-light" role="button"><i class="fas fa-search"></i></a>'
;
$proposal
=
'<a href="'
.
$url
.
'" target="_blank" class="btn btn-primary btn-sm waves-effect waves-light" role="button"><i class="fas fa-search"></i></a>'
;
if
(
$status_nilai
>
0
||
$status_administrasi
==
'2'
)
if
(
$status_nilai
>
0
||
$status_administrasi
==
'2'
)
$status
=
'<span class="badge bg-success">Sudah dinilai</span>'
;
$status
=
'<span class="badge bg-success">Sudah dinilai</span>'
;
else
else
$status
=
'<span class="badge bg-danger">Belum dinilai</span>'
;
$status
=
'<span class="badge bg-danger">Belum dinilai</span>'
;
...
...
resources/views/backend/reviewer/seleksi/index.blade.php
View file @
6411a7dd
...
@@ -31,6 +31,48 @@
...
@@ -31,6 +31,48 @@
<div class="
col
-
12
">
<div class="
col
-
12
">
<div class="
card
">
<div class="
card
">
<div class="
card
-
body
">
<div class="
card
-
body
">
{!! csrf_field() !!}
<div class="
row
">
<div class="
col
-
md
-
4
">
<div class="
row
">
<label class="
col
-
sm
-
3
col
-
form
-
label
">Adminis : </label>
<div class="
col
-
sm
-
6
">
<select class="
form
-
select
select2
" name="
reqAdministrasi
" id="
reqAdministrasi
">
<option value="
0
">Semua</option>
<option value="
1
">Menunggu Penilaian</option>
<option value="
2
">Lolos</option>
<option value="
3
">Tidak Lolos</option>
</select>
</div>
</div>
</div>
<div class="
col
-
md
-
4
">
<div class="
row
">
<label class="
col
-
sm
-
3
col
-
form
-
label
">Status : </label>
<div class="
col
-
sm
-
6
">
<select class="
form
-
select
select2
" name="
reqStatus
" id="
reqStatus
">
<option value="
0
">Semua</option>
<option value="
2
">Sudah dinilai</option>
<option value="
3
">Belum dinilai</option>
</select>
</div>
</div>
</div>
<div class="
col
-
md
-
4
">
<div class="
row
">
<label class="
col
-
sm
-
3
col
-
form
-
label
">Tahun : </label>
<div class="
col
-
sm
-
6
">
<select class="
form
-
select
select2
" name="
reqTahun
" id="
reqTahun
">
<option value="
0
">Semua</option>
@foreach (
$periode
as
$res
)
<option value="
{{
$res
->
nama
}}
">{{
$res->nama
}}</option>
@endforeach
</select>
</div>
</div>
</div>
</div>
<br>
<table id="
example
" class="
table
table
-
bordered
dt
-
responsive
wrap
" style="
border
-
collapse
:
collapse
;
border
-
spacing
:
0
;
width
:
100
%
;
">
<table id="
example
" class="
table
table
-
bordered
dt
-
responsive
wrap
" style="
border
-
collapse
:
collapse
;
border
-
spacing
:
0
;
width
:
100
%
;
">
<thead>
<thead>
<tr>
<tr>
...
@@ -63,7 +105,13 @@
...
@@ -63,7 +105,13 @@
processing: true,
processing: true,
serverSide: true,
serverSide: true,
ajax: {
ajax: {
"
url
" : "
{{
route
(
'reviewer.getDaftarSeleksi'
)}}
"
"
url
" : "
{{
route
(
'reviewer.getDaftarSeleksi'
)}}
",
"
data
" : function ( data )
{
data.administrasi = $("
#reqAdministrasi").val();
data
.
status
=
$
(
"#reqStatus"
)
.
val
();
data
.
tahun
=
$
(
"#reqTahun"
)
.
val
();
}
},
},
columns
:
[
columns
:
[
{
data
:
'proposal_id'
},
{
data
:
'proposal_id'
},
...
@@ -83,6 +131,10 @@
...
@@ -83,6 +131,10 @@
}
}
]
]
});
});
$
(
'#reqAdministrasi, #reqStatus, #reqTahun'
)
.
change
(
function
(){
oTable
.
draw
();
});
});
});
function
confirmFinal
(
reqId
,
reqStatus
)
function
confirmFinal
(
reqId
,
reqStatus
)
...
...
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