Add Laporan Bulanan, Laporan By Kelurahan, laporan By Kecamatan, and Fix Some Bugs

This commit is contained in:
2021-09-19 21:39:23 +07:00
parent 4a12d026fd
commit b42ee3ba25
25 changed files with 5098 additions and 51 deletions

View File

@@ -75,6 +75,15 @@ class AbsensiModel extends CI_Model
return $this->db->update($this->_table, $this, array('id_absensi' => $id_absensi));
}
public function getDesemberAbsensiByYearAndByKelurahan($tahun,$kelurahan){
$this->db->join('tb_user','tb_user.id_user = tb_absensi.id_pemilik');
$this->db->where('bulan', 12);
$this->db->where('tahun', $tahun);
$this->db->where('tb_absensi.kelurahan', $kelurahan);
//$this->db->limit(1);
return $absensi = $this->db->get($this->_table)->result();
}
public function getLastMonthAbsensi($bulan,$tahun){
$bulan = $bulan-1;
$this->db->where('bulan', $bulan);