| Server IP : 127.0.0.1 / Your IP : 192.168.99.1 Web Server : Apache/2.4.35 (Win64) OpenSSL/1.1.1b mod_fcgid/2.3.9 System : Windows NT WIN-JEJMB9EN0L0 10.0 build 14393 (Windows Server 2016) AMD64 User : Administrator ( 0) PHP Version : 7.4.33 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /wamp/www/SIPBOS_2020/application/modules/memo_penyesuaian/controllers/ |
Upload File : |
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
class Memo_penyesuaian extends Aktivitas_Controller {
public function __construct()
{
parent::__construct();
$this->modul_name = 'memo_penyesuaian';
$this->modul_display = 'Memo Penyesuaian';
$this->view_form = 'memo_form';
$this->view_daftar = 'memo_view';
$this->report_daftar = 'Daftar Memo Penyesuaian';
$this->report_form = 'Form Memo Penyesuaian';
$this->load->model('Memo_model','data_model');
$this->message_aktivitas_dihapus = 'Memo Penyesuaian telah dihapus.';
$this->message_aktivitas_gagal_dihapus = 'Memo Penyesuaian telah dicairkan, tidak bisa dihapus.';
}
function validasi()
{
}
public function rinci($id=0)
{
$result = $this->data_model->get_rinci_by_id($id);
$response = (object) NULL;
if ($result){
for($i=0; $i<count($result); $i++)
{
$response->rows[$i]['id'] = $result[$i]['ID_RINCIAN_PENYESUAIAN'];
$response->rows[$i]['cell'] = array(
$result[$i]['ID_RINCIAN_PENYESUAIAN'],
$result[$i]['ID_KEGIATAN'],
$result[$i]['ID_REKENING'],
$result[$i]['KODE_KEGIATAN_SKPD'],
$result[$i]['NAMA_KEGIATAN'],
$result[$i]['KODE_REKENING'],
$result[$i]['NAMA_REKENING'],
$result[$i]['DEBET'],
$result[$i]['KREDIT']
);
}
}
echo json_encode($response);
}
public function get_akun_penutup()
{
$response = (object) NULL;
$param = array(
'tipe' => $this->input->post('tipe') ? $this->input->post('tipe') : '',
'tgl' => $this->input->post('tgl') ? prepare_date($this->input->post('tgl')) : null,
'id_skpd' => $this->input->post('id_skpd') ? $this->input->post('id_skpd') : null,
);
if (!$param['tgl']) {
return;
}
$result = $this->data_model->get_akun_penutup($param);
if ($result){
for($i=0; $i<count($result); $i++)
{
$response->akun->rows[$i] = array(
'id' => -($i + 1),
'idr' => -($i + 1),
'idrek' => $result[$i]['ID_REKENING'],
'kdrek' => $result[$i]['KODE_REKENING'],
'nmrek' => $result[$i]['NAMA_REKENING'],
'debet' => $result[$i]['DEBET'],
'kredit' => $result[$i]['KREDIT']
);
}
$response->last = -($i);
}
$response->sql = $this->db->queries;
echo json_encode($response);
}
}