// collect(DB::select("select *, ambil_jumlah_penilaian_seleksi(reviewer_proposal_id_1) nilai_1, ambil_jumlah_penilaian_seleksi(reviewer_proposal_id_2) nilai_2, round((ambil_jumlah_penilaian_seleksi(reviewer_proposal_id_1) + ambil_jumlah_penilaian_seleksi(reviewer_proposal_id_2 )) / 2, 2) as rata from vw_daftar_proposal('".$statementGlobal.$statement."') ORDER BY ".$columnName." ".$columnSortOrder))
// ->get();
$records=collect(DB::select("select *, ambil_jumlah_penilaian_seleksi(reviewer_proposal_id_1) nilai_1, ambil_jumlah_penilaian_seleksi(reviewer_proposal_id_2) nilai_2, round((ambil_jumlah_penilaian_seleksi(reviewer_proposal_id_1) + ambil_jumlah_penilaian_seleksi(reviewer_proposal_id_2 )) / 2, 2) as rata from vw_daftar_proposal('".$statementGlobal.$statement."') ORDER BY ".$columnName." ".$columnSortOrder))
$totalRecords=DaftarProposal::select('count(1) as allcount')->whereRaw($statementGlobal)->count();
$statement=" AND (UPPER(JUDUL) LIKE '%".$searchValue."%' OR UPPER(IDENTITAS_KETUA) LIKE '%".$searchValue."%' OR UPPER(IDENTITAS_DOSPEM) LIKE '%".$searchValue."%') ";
$statement=" AND (UPPER(JUDUL) LIKE '%".$searchValue."%' OR UPPER(IDENTITAS_KETUA) LIKE '%".$searchValue."%' OR UPPER(IDENTITAS_DOSPEM) LIKE '%".$searchValue."%') ";