text
unknown
abap
2 years ago
982 B
2
Indexable
$ids = []; $dataPeserta = $dataPeserta->select('id', 'id_jns_jadwal', 'id_peserta') ->chunk(1000, function ($tagihans) use (&$ids) { foreach ($tagihans as $tagihan) { if ($tagihan->id_jns_jadwal == 2) { if ($tagihan->peserta_r->id_type_class1 == 0) { $ids[] = $tagihan->id; } else { $cek_ajj = masterAJJ::where('id_pj_srtf', $tagihan->peserta_r->id_pj_srtf) ->where('id_srt', $tagihan->peserta_r->id_sert_alat) ->where('id_jns_class', $tagihan->peserta_r->id_type_class1) ->where('id_jns_jadwal', $tagihan->peserta_r->id_jns_jadwal_prog) ->first(); if ($cek_ajj) { $ids[] = $tagihan->id; } } } else { $ids[] = $tagihan->id; } } });
Editor is loading...