function t_vat_reg_dtl_restaurantForm_BeforeSelect(&$sender) { $t_vat_reg_dtl_restaurantForm_BeforeSelect = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $t_vat_reg_dtl_restaurantForm; //Compatibility //End t_vat_reg_dtl_restaurantForm_BeforeSelect //Custom Code @819-2A29BDB7 // ------------------------- // Write your own code here. $idVat = $t_vat_reg_dtl_restaurantForm->t_cust_account_id->GetValue(); $dbConn = new clsDBConnSIKP(); $sql = "select a.p_vat_type_dtl_id, b.vat_code as rest_service_type_code " . "from t_cust_account a, p_vat_type_dtl b " . "where a.p_vat_type_dtl_id=b.p_vat_type_dtl_id and a.t_cust_account_id = " . $idVat; $dbConn->query($sql); while ($dbConn->next_record()) { $restId = $dbConn->f("p_vat_type_dtl_id"); $restCode = $dbConn->f("rest_service_type_code"); } $t_vat_reg_dtl_restaurantForm->service_type_desc->SetValue($restCode); $t_vat_reg_dtl_restaurantForm->p_rest_service_type_id->SetValue($restId); // ------------------------- //End Custom Code //Close t_vat_reg_dtl_restaurantForm_BeforeSelect @94-6EBC2391 return $t_vat_reg_dtl_restaurantForm_BeforeSelect; }
function t_vat_reg_dtl_parkingForm_BeforeSelect(&$sender) { $t_vat_reg_dtl_parkingForm_BeforeSelect = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $t_vat_reg_dtl_parkingForm; //Compatibility //End t_vat_reg_dtl_parkingForm_BeforeSelect //Custom Code @822-2A29BDB7 // ------------------------- // Write your own code here. $CustId = $t_vat_reg_dtl_parkingForm->t_cust_account_id->GetValue(); $dbConn = new clsDBConnSIKP(); $query = "select a.p_vat_type_dtl_id, b.vat_code as parking_classification_code " . "from t_cust_account a, p_vat_type_dtl b " . "where a.p_vat_type_dtl_id = b.p_vat_type_dtl_id " . "and t_cust_account_id = " . $CustId; $dbConn->query($query); while ($dbConn->next_record()) { $idd = $dbConn->f("p_vat_type_dtl_id"); $code = $dbConn->f("parking_classification_code"); } $dbConn->close(); $t_vat_reg_dtl_parkingForm->p_parking_classification_id->SetValue($idd); $t_vat_reg_dtl_parkingForm->classification_desc->SetValue($code); // ------------------------- //End Custom Code //Close t_vat_reg_dtl_parkingForm_BeforeSelect @94-79EB8A58 return $t_vat_reg_dtl_parkingForm_BeforeSelect; }
function PageCetak($data, $user, $tahun, $tgl_penerimaan, $tgl_penerimaan_last, $npwpd) { $this->AliasNbPages(); $this->AddPage("L"); $this->SetFont('Arial', 'B', 12); $lheader = $this->lengthCell / 8; $lheader1 = $lheader * 1; $lheader2 = $lheader - 15; $lheader3 = $lheader * 3; $lheader4 = $lheader * 4; $dbConn = new clsDBConnSIKP(); $query = "SELECT a.*,\r\n c.region_name AS nama_kota,\r\n d.region_name AS nama_kecamatan,\r\n e.region_name AS nama_kelurahan\r\n FROM t_cust_account a\r\n LEFT JOIN p_region c ON a.brand_p_region_id = c.p_region_id\r\n LEFT JOIN p_region d ON a.brand_p_region_id_kec = d.p_region_id\r\n LEFT JOIN p_region e ON a.brand_p_region_id_kel = e.p_region_id\r\n where a.npwd = '" . $npwpd . "'"; $dbConn->query($query); $alamat = ''; while ($dbConn->next_record()) { //$alamat = $dbConn->f("brand_address_name")." .No ". $dbConn->f("brand_address_no")." RT/RW: ".$dbConn->f("brand_address_rt")."/".$dbConn->f("brand_address_rw"). ". KEC.".$dbConn->f("nama_kecamatan")." KEL.".$dbConn->f("nama_kelurahan"); $alamat = $dbConn->f("brand_address_name") . " .No " . $dbConn->f("brand_address_no"); } $dbConn->close(); $this->Cell($lheader2, $this->height, "NPWPD :"); $this->Cell($lheader1, $this->height, $npwpd); $this->Ln(); $this->Cell($lheader2, $this->height, "Alamat :"); $this->Cell($lheader1, $this->height, $alamat); $this->SetFont('Arial', '', 10); $this->Ln(); $this->Ln(); $ltable = $this->lengthCell / 26; $ltable1 = $ltable * 1; $ltable2 = $ltable * 2; $ltable3 = $ltable * 3; $ltable4 = $ltable * 4; $ltable5 = $ltable * 5; $ltable6 = $ltable * 6; $ltable7 = $ltable * 7; $ltable8 = $ltable * 8; $this->Cell($ltable4, $this->height + 2, "NAMA BADAN", "TBLR", 0, 'C'); $this->Cell($ltable3, $this->height + 2, "JENIS KETETAPAN", "TBLR", 0, 'C'); $this->Cell($ltable6, $this->height + 2, "PERIODE TRANSAKSI", "TBLR", 0, 'C'); $this->Cell($ltable3, $this->height + 2, "TGL PELAPORAN", "TBLR", 0, 'C'); $this->Cell($ltable3, $this->height + 2, "TOTAL PAJAK", "TBLR", 0, 'C'); $this->Cell($ltable5, $this->height + 2, "NO. KWITANSI", "TBLR", 0, 'C'); $this->Ln(); //isi kolom $this->SetWidths(array($ltable4, $ltable3, $ltable6, $ltable3, $ltable3, $ltable5)); $this->SetAligns(array("L", "C", "C", "C", "R", "L")); $no = 1; $jumlahperayat = array(); $jumlahperwaktu = array(); $jumlahtemp = 0; $i = 0; $total = 0; foreach ($data as $item) { //print data $this->RowMultiBorderWithHeight(array($item["company_name"], $item["type_code"], $item["periode_awal_laporan"] . " s.d " . $item["periode_akhir_laporan"], $item["tgl_pelaporan"], number_format($item["total_pajak"], 0, ',', '.'), $item["kuitansi_pembayaran"]), array('TBLR', 'TBLR', 'TBLR', 'TBLR', 'TBLR', 'TBLR'), $this->height); $no++; } }
function t_ppatForm_Button_Insert_OnClick(&$sender) { $t_ppatForm_Button_Insert_OnClick = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $t_ppatForm; //Compatibility //End t_ppatForm_Button_Insert_OnClick //Custom Code @374-2A29BDB7 // ------------------------- // Write your own code here. $dbConn = new clsDBConnSIKP(); $company_brand = $t_ppatForm->company_brand->GetValue(); $p_rqst_type_id = $t_ppatForm->p_rqst_type_id->GetValue(); $p_vat_type_dtl_id = $t_ppatForm->p_vat_type_dtl_id->GetValue(); $brand_address_name = $t_ppatForm->brand_address_name->GetValue(); $brand_address_no = $t_ppatForm->brand_address_no->GetValue(); $brand_address_rt = $t_ppatForm->brand_address_rt->GetValue(); $brand_address_rw = $t_ppatForm->brand_address_rw->GetValue(); $company_additional_addr = $t_ppatForm->company_additional_addr->GetValue(); $brand_p_region_id = $t_ppatForm->brand_p_region_id->GetValue(); $brand_p_region_id_kec = $t_ppatForm->brand_p_region_id_kec->GetValue(); $brand_p_region_id_kel = $t_ppatForm->brand_p_region_id_kel->GetValue(); $brand_phone_no = $t_ppatForm->brand_phone_no->GetValue(); $brand_mobile_no = $t_ppatForm->brand_mobile_no->GetValue(); $brand_fax_no = $t_ppatForm->brand_fax_no->GetValue(); $brand_zip_code = $t_ppatForm->brand_zip_code->GetValue(); $user = $t_ppatForm->created_by->GetValue(); $sql = "select * from f_insert_vat_reg_npwpd_jabatan(\r\n\t\t\t'{$user}', \r\n\t\t\t'{$company_brand}',\r\n\t\t\t'{$company_additional_addr}',\r\n\t\t\t'{$brand_address_name}',\r\n\t\t\t'{$brand_address_no}',\r\n\t\t\t'{$brand_address_rt}',\r\n\t\t\t'{$brand_address_rw}',\r\n\t\t\t{$brand_p_region_id_kel},\r\n\t\t\t{$brand_p_region_id_kec},\r\n\t\t\t{$brand_p_region_id},\r\n\t\t\t'{$brand_phone_no}',\r\n\t\t\t'{$brand_mobile_no}',\r\n\t\t\t'{$brand_fax_no}',\r\n\t\t\t'{$brand_zip_code}',\r\n\t\t\t{$p_rqst_type_id},\r\n\t\t\t{$p_vat_type_dtl_id}\r\n\t\t\t)"; //die($sql); $dbConn->query($sql); $dbConn->next_record(); $cust_id = $dbConn->f("v_customer_order_id"); $mess = $dbConn->f("o_result_msg"); if ($cust_id != 0 && $cust_id != "") { echo '<script language="javascript">'; echo "window.open('../report/cetak_surat_pengukuhan_npwpd_jabatan.php?CURR_DOC_ID={$cust_id}', \r\n\t\t\t\t'pengukuhan', 'height=,width=,left=0,top=0');"; echo "window.open('../report/cetak_form_pemutakhiran_data_npwpd_jabatan.php?t_customer_order_id={$cust_id}', \r\n\t\t\t\t'pemutakhiran', 'height=,width=,left=0,top=0');"; echo '</script>'; } else { $mess = str_replace('"', '', $mess); echo '<script language="javascript">'; echo 'alert("' . $mess . '");'; echo '</script>'; } echo '<script language="javascript">'; echo "location.href='t_vat_registration_npwpd_jabatan.php';"; echo '</script>'; return; // ------------------------- //End Custom Code //Close t_ppatForm_Button_Insert_OnClick @24-EE087F7F return $t_ppatForm_Button_Insert_OnClick; }
function Page_BeforeShow(&$sender) { $Page_BeforeShow = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $t_wp_registration_list; //Compatibility //End Page_BeforeShow //Custom Code @562-2A29BDB7 // ------------------------- // Write your own code here. global $Label1; $tampil = CCGetFromGet('tampil'); if ($tampil == 'T') { $Label1->SetText("<table border=1><tr><td>tes</td></tr></table>"); $tgl_penerimaan = CCGetFromGet("tgl_penerimaan", ""); //'15-12-2013'; $tgl_penerimaan_last = CCGetFromGet("tgl_penerimaan_last", ""); //'15-12-2013'; $jenis_pajak = CCGetFromGet("jenis_pajak", 0); // $tgl_penerimaan = '15-12-2013'; $user = CCGetUserLogin(); $data = array(); $dbConn = new clsDBConnSIKP(); if ($jenis_pajak == 0 || $jenis_pajak == "") { $query = "select a.*, b.vat_code, c.code as account_status from t_vat_registration a\r\n\t\t\tleft join p_vat_type_dtl z on z.p_vat_type_dtl_id = a.p_vat_type_dtl_id\r\n\t\t\tleft join p_vat_type b on b.p_vat_type_id = z.p_vat_type_id\r\n\t\t\tleft join t_customer_order y on y.t_customer_order_id = a.t_customer_order_id\r\n\t\t\tLEFT JOIN p_order_status C ON C .p_order_status_id = y .p_order_status_id\r\n\t\t\twhere trunc(registration_date) >= to_date('{$tgl_penerimaan}')\r\n\t\t\tAND trunc(registration_date) <= to_date('{$tgl_penerimaan_last}')\r\n\t\t\tORDER BY registration_date ASC"; } else { $query = "select a.*, b.vat_code, c.code as account_status from t_vat_registration a\r\n\t\t\tleft join p_vat_type_dtl z on z.p_vat_type_dtl_id = a.p_vat_type_dtl_id\r\n\t\t\tleft join p_vat_type b on b.p_vat_type_id = z.p_vat_type_id\r\n\t\t\tleft join t_customer_order y on y.t_customer_order_id = a.t_customer_order_id\r\n\t\t\tLEFT JOIN p_order_status C ON C .p_order_status_id = y .p_order_status_id\r\n\t\t\twhere trunc(registration_date) >= to_date('{$tgl_penerimaan}')\r\n\t\t\tAND trunc(registration_date) <= to_date('{$tgl_penerimaan_last}')\r\n\t\t\tAND a.p_vat_type_dtl_id in (select p_vat_type_dtl_id from p_vat_type_dtl\r\n\t\t\t\twhere p_vat_type_id = {$jenis_pajak})\r\n\t\t\tORDER BY registration_date ASC"; } //echo $query; //exit; $tgl_penerimaan = str_replace("'", "", $tgl_penerimaan); $dbConn->query($query); while ($dbConn->next_record()) { $data["t_cust_account_id"][] = $dbConn->f("t_cust_account_id"); $data["t_customer_id"][] = $dbConn->f("t_customer_id"); $data["npwd"][] = $dbConn->f("npwpd"); $data["vat_code"][] = $dbConn->f("vat_code"); $data["registration_date"][] = $dbConn->f("registration_date"); $data["wp_name"][] = $dbConn->f("wp_name"); $data["wp_address_name"][] = $dbConn->f("wp_address_name"); $data["company_name"][] = $dbConn->f("company_name"); $data["address_name"][] = $dbConn->f("address_name"); $data["account_status"][] = $dbConn->f("account_status"); } $dbConn->close(); $Label1->SetText(PageCetak($data, $user, $tgl_penerimaan, $tgl_penerimaan_last)); } // ------------------------- //End Custom Code //Close Page_BeforeShow @1-4BC230CD return $Page_BeforeShow; }
function t_vat_setllementForm_Button1_OnClick(&$sender) { $t_vat_setllementForm_Button1_OnClick = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $t_vat_setllementForm; //Compatibility //End t_vat_setllementForm_Button1_OnClick //Custom Code @165-2A29BDB7 // ------------------------- // Write your own code here. // ------------------------- //End Custom Code // ------------------------- // Write your own code here. $dbConn = new clsDBConnSIKP(); $cusAccId = $t_vat_setllementForm->t_cust_account_id->GetValue(); $User = CCGetUserLogin(); $p_account_status_id = $t_vat_setllementForm->p_account_status_id->GetValue(); $reason_status_id = $t_vat_setllementForm->reason_status_id->GetValue(); $reason_description = $t_vat_setllementForm->reason_description->GetValue(); $errorMsg = ''; //new fix if (!isset($p_vat_type_dtl_cls_id) || $p_vat_type_dtl_cls_id == '') { $p_vat_type_dtl_cls_id = 'NULL'; } if (empty($kamar)) { $kamar = 0; } //cek alasan lainnya if ($reason_status_id == 4 and !isset($reason_description) || $reason_description == '') { echo "<script> \r\n\t\t\talert('Keterangan harus diisi jika memilih alasan Lainnya');\r\n\t\t</script>"; } else { $sql = "select * from f_entry_mutasi_status_wp(" . $cusAccId . ",15," . $p_account_status_id . "," . $reason_status_id . ",'" . $reason_description . "','" . $User . "')"; //echo $sql; //die($sql); $dbConn->query($sql); $dbConn->next_record(); $cust_id = $dbConn->f("o_cust_order_id"); $mess = $dbConn->f("o_mess"); //modified by wiliam echo "<script> \r\n\t\t\talert('" . $mess . "');\r\n\t\t\twindow.opener.location.reload();\r\n\t\t\twindow.close();\r\n\t\t</script>"; exit; } // ------------------------- //Close t_vat_setllementForm_Button1_OnClick @164-6DBB2532 //return $t_vat_setllementForm_Button1_OnClick; }
function t_vat_registrationForm_Button4_OnClick(&$sender) { $t_vat_registrationForm_Button4_OnClick = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $t_vat_registrationForm; //Compatibility //End t_vat_registrationForm_Button4_OnClick //Custom Code @909-2A29BDB7 // ------------------------- // Write your own code here. $CusId = CCGetFromGet("CURR_DOC_ID", ""); $dbConn = new clsDBConnSIKP(); $sql = "select f_gen_npwpd(" . $CusId . ")as npwpd from dual"; $dbConn->query($sql); while ($dbConn->next_record()) { $val = $dbConn->f("npwpd"); } $t_vat_registrationForm->npwpd->SetValue($val); return; // ------------------------- //End Custom Code //Close t_vat_registrationForm_Button4_OnClick @908-D8012444 return $t_vat_registrationForm_Button4_OnClick; }
function LOV_BeforeShow(&$sender) { $LOV_BeforeShow = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $LOV; //Compatibility //End LOV_BeforeShow //Custom Code @8-2A29BDB7 // ------------------------- // Write your own code here. $i_vat_setllement = CCGetFromGet('i_vat_setllement_id'); $ubah = CCGetFromGet('ubah'); $in_flag_numeric = CCGetFromGet('in_flag_numeric'); $is_desc = CCGetFromGet('is_desc'); if ($ubah == 'T') { $user = CCGetUserLogin(); $data = array(); $dbConn = new clsDBConnSIKP(); $query = "select f_update_increasing_amt({$i_vat_setllement},{$in_flag_numeric},'{$is_desc}','{$user}') as msg"; $dbConn->query($query); while ($dbConn->next_record()) { echo "<script> \r\n\t\t\talert('" . $dbConn->f('msg') . "');\r\n\t\t\twindow.close();\r\n\t\t</script>"; exit; } } // ------------------------- //End Custom Code //Close LOV_BeforeShow @3-91C2A156 return $LOV_BeforeShow; }
function LOV_Button1_OnClick(&$sender) { $LOV_Button1_OnClick = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $LOV; //Compatibility //End LOV_Button1_OnClick //Custom Code @24-2A29BDB7 // ------------------------- // Write your own code here. $t_bphtb_registration_id = CCGetFromGet("t_bphtb_registration_id"); $alasan = $LOV->alasan->GetValue(); $user = CCGetUserLogin(); $dbConn = new clsDBConnSIKP(); if ($t_bphtb_registration_id != "" && $alasan != "" && $user != "") { $query = "select f_delete_bphtb from \r\n\t\t\tf_delete_bphtb(" . $t_bphtb_registration_id . ",'" . $alasan . "','" . $user . "')"; //echo $query;exit; $dbConn->query($query); $dbConn->next_record(); $result = $dbConn->f("f_delete_bphtb"); } else { $result = "id bphtb, alasan atau user login tidak boleh kosong"; } echo "<script> \r\n\t\talert('" . $result . "');\r\n\t\twindow.opener.location.reload();\r\n\t\twindow.close();\r\n\t</script>"; exit; // ------------------------- //End Custom Code //Close LOV_Button1_OnClick @16-408DE5C8 return $LOV_Button1_OnClick; }
function t_vat_setllementGrid_cetak_sptpd_BeforeShow(&$sender) { $t_vat_setllementGrid_cetak_sptpd_BeforeShow = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $t_vat_setllementGrid; //Compatibility //End t_vat_setllementGrid_cetak_sptpd_BeforeShow //Custom Code @301-2A29BDB7 // ------------------------- // Write your own code here. // ------------------------- //End Custom Code //DEL // ------------------------- //DEL // Write your own code here. $nilai = $t_vat_setllementGrid->t_vat_setllement_id->GetValue(); $dbConn = new clsDBConnSIKP(); $sql = "select count(*)as ada from t_vat_penalty where t_vat_setllement_id = " . $nilai; $dbConn->query($sql); $dbConn->next_record(); $ada = $dbConn->f("ada"); $dbConn->close(); if ($ada > 0) { //$nilai2 = $t_vat_setllementGrid->p_vat_type_id->GetValue(); $t_vat_setllementGrid->cetak_sptpd->SetValue("<input type='button' value='CETAK' style='WIDTH: 57px; HEIGHT: 22px' class='Button' onclick=\"" . "cetakStpd(" . $nilai . ",'tgl_tap')\">"); $t_vat_setllementGrid->cetak_sptpd2->SetValue("<input type='button' value='CETAK' style='WIDTH: 57px; HEIGHT: 22px' class='Button' onclick=\"" . "cetakStpd(" . $nilai . ",'tgl_bayar')\">"); } else { $t_vat_setllementGrid->cetak_sptpd->SetValue(""); $t_vat_setllementGrid->cetak_sptpd2->SetValue(""); } /* $action_button = CCGetFromGet("action_button",""); $action_button2 = CCGetFromGet("action_button2",""); if($action_button=='flag_payment' && $action_button2!='cetak_register'){ $dbConn = new clsDBConnSIKP(); $sql="select sikp.f_payment_manual(".CCGetFromGet('t_customer_order_id').",'".CCGetSession('UserLogin')."')"; $dbConn->query($sql); $dbConn->next_record(); echo " <script> alert('".$dbConn->f('f_payment_manual')."'); </script> "; $dbConn->close(); }else if($action_button2=='cetak_register'){ $dbConn = new clsDBConnSIKP(); $sql="select sikp.f_print_register(".CCGetFromGet('t_customer_order_id').",'".CCGetSession('UserLogin')."')"; $dbConn->query($sql); $dbConn->next_record(); print_laporan($dbConn->f('f_print_register')); $dbConn->close(); } */ // ------------------------- //Close t_vat_setllementGrid_cetak_sptpd_BeforeShow @300-BF0BB7F2 return $t_vat_setllementGrid_cetak_sptpd_BeforeShow; }
function t_vat_registrationForm_Button1_OnClick(&$sender) { $t_vat_registrationForm_Button1_OnClick = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $t_vat_registrationForm; //Compatibility //End t_vat_registrationForm_Button1_OnClick //Custom Code @862-2A29BDB7 // ------------------------- // Write your own code here. // ------------------------- //End Custom Code // ------------------------- // Write your own code here. $dbConn1 = new clsDBConnSIKP(); $order = $t_vat_registrationForm->order_no->GetValue(); $mobile = $t_vat_registrationForm->mobile_no_owner->GetValue(); $cari = "select t_customer_order_id from t_customer_order where order_no = '" . $order . "'"; $dbConn1->query($cari); while ($dbConn1->next_record()) { $kode = $dbConn1->f("t_customer_order_id"); } $sql_url = "select f_send_sms('" . $mobile . "','Kode Verifikasi Anda : " . $kode . "')from dual"; $dbConn1->query($sql_url); /* $sql_url = "select value from p_global_param where code = 'SMSG_URL'"; $dbConn1->query($sql_url); while($dbConn1->next_record()){ $val = $dbConn1->f("value"); } $ch = curl_init(); $url = $val."recipient=".$mobile."&messagetype=SMS:TEXT&messagedata=Kode+Verifikasi+Anda:+".$kode.""; curl_setopt($ch, CURLOPT_URL,$url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, http_build_query(array('body' => json_encode($postdata)))); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $server_output = curl_exec ($ch); curl_close ($ch); */ $sql = "INSERT INTO verifikasi(id_verifikasi,order_no,code) VALUES " . "(generate_id('sikp','verifikasi','id_verifikasi'),'" . $order . "','" . $kode . "')"; $dbConn1->query($sql); $dbConn1->close; $t_vat_registrationForm->pesan->SetValue("Data Telah Terkirim"); return; // ------------------------- //Close t_vat_registrationForm_Button1_OnClick @851-A9568806 return $t_vat_registrationForm_Button1_OnClick; }
function PageCetak($data) { $this->AddPage(); // $this->Cell(0, $this->height, $data["f_bphtb_receipt_duplicate"], 0, 0, "L"); $exp_data = explode("\n", $data["f_bphtb_receipt_duplicate"]); //get no kuitansi $exp_data1 = explode(":", $exp_data[0]); $encImageData = ''; $dbConn = new clsDBConnSIKP(); $query = "select f_encrypt_str('" . trim($exp_data1[1]) . "') AS enc_data"; $dbConn->query($query); while ($dbConn->next_record()) { $encImageData = $dbConn->f("enc_data"); } $dbConn->close(); if (empty($encImageData)) { $encImageData = "EmptyData"; } $this->Image('../images/logo_pemda.png', 37, 13, 25, 25); $this->Image('http://' . $_SERVER['HTTP_HOST'] . '/mpd/include/qrcode/generate-qr.php?param=' . $encImageData, 179, 13, 25, 25, 'PNG'); //$this->Image('http://172.16.20.2:81/mpd/include/qrcode/generate-qr.php?param='.encImageData,179,13,25,25,'PNG'); $this->SetFont('Arial', '', 11); $this->Cell(40, $this->height, "", "", 0, 'L'); $this->Cell(101, $this->height, "PEMERINTAH KOTA BANDUNG", "", 0, 'C'); $this->Cell(40, $this->height, "", "", 0, 'L'); $this->Ln(); $this->Cell(40, $this->height, "", "", 0, 'L'); $this->Cell(101, $this->height, "DINAS PELAYANAN PAJAK", "", 0, 'C'); $this->Cell(40, $this->height, "", "", 0, 'L'); $this->Ln(); $this->Cell(40, $this->height, "", "", 0, 'L'); $this->Cell(101, $this->height, "Jalan Wastukancana No 2", "", 0, 'C'); $this->Cell(40, $this->height, "", "", 0, 'L'); $this->Ln(); $this->Cell(40, $this->height, "", "", 0, 'L'); $this->Cell(101, $this->height, "Telp. 022 4235052 - Bandung", "", 0, 'C'); $this->Cell(40, $this->height, "", "", 0, 'L'); $this->Ln(); $this->SetFont('Arial', 'B', 14); $this->Cell(40, $this->height + 7, "", "B", 0, 'L'); $this->Cell(101, $this->height + 7, "Bukti Pembayaran Pajak BPHTB", "B", 0, 'C'); $this->Cell(40, $this->height + 7, "", "B", 0, 'L'); $this->Ln(5); $this->Ln(); $this->SetFont('Courier', '', 10); $data = explode("\n", $data["f_bphtb_receipt_duplicate"]); foreach ($data as $datum) { $this->Cell(241.3, $this->height, $datum, 0, 0, "L"); $this->Ln(); } $this->Cell(180, $this->height, "", "B", 0, "C"); }
function t_vat_setllementForm_Button1_OnClick(&$sender) { $t_vat_setllementForm_Button1_OnClick = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $t_vat_setllementForm; //Compatibility //End t_vat_setllementForm_Button1_OnClick //Custom Code @165-2A29BDB7 // ------------------------- // Write your own code here. // ------------------------- //End Custom Code // ------------------------- // Write your own code here. $dbConn = new clsDBConnSIKP(); $User = CCGetUserLogin(); $t_bphtb_registration_id = $t_vat_setllementForm->t_bphtb_registration_id->GetValue(); $alasan = $t_vat_setllementForm->alasan->GetValue(); $njop_pbb = $t_vat_setllementForm->njop_pbb->GetValue(); $bphtb_amt_final = $t_vat_setllementForm->bphtb_amt_final->GetValue(); $bphtb_amt_final_keberatan = $t_vat_setllementForm->bphtb_amt_final_keberatan->GetValue(); $errorMsg = ''; $sql = "select * from f_insert_bphtb_keberatan(" . $t_bphtb_registration_id . ",19," . $bphtb_amt_final_keberatan . "," . $bphtb_amt_final . ",'" . $alasan . "','" . $User . "')"; //echo $sql; //die($sql); $dbConn->query($sql); $dbConn->next_record(); $t_bphtb_keberatan_id = $dbConn->f("o_t_bphtb_keberatan_id"); $t_customer_order_id = $dbConn->f("o_t_customer_order_id"); $mess = $dbConn->f("o_mess"); $sql = "select sikp.f_first_submit_engine(511," . $t_customer_order_id . ",'" . CCGetSession('UserLogin') . "')"; $dbConn->query($sql); //modified by wiliam echo "<script> \r\n\t\talert('" . $mess . "');\r\n\t\twindow.opener.location.reload();\r\n\t\twindow.close();\r\n\t</script>"; // ------------------------- //Close t_vat_setllementForm_Button1_OnClick @164-6DBB2532 //return $t_vat_setllementForm_Button1_OnClick; }
function print_excel($param_arr) { $dbConn = new clsDBConnSIKP(); $query = "select upper(vat_code)as vat_code from p_vat_type where p_vat_type_id = " . $param_arr['p_vat_type_id']; $vat_code = ''; $dbConn->query($query); while ($dbConn->next_record()) { $vat_code = $dbConn->f("vat_code"); } $query = "select 'SURAT_TEGURAN_'||sequence_no||'_'||replace('" . $vat_code . "',' ','_')||'_PERIODE_'||replace(code,' ','_') AS judul\r\n\t\tfrom t_debt_letter a\r\n\t\tleft join p_finance_period x on a.p_finance_period_id=x.p_finance_period_id\r\n\t\twhere t_customer_order_id=" . $param_arr['t_customer_order_id']; $judul = ''; $dbConn->query($query); while ($dbConn->next_record()) { $judul = $dbConn->f("judul"); } startExcel("LAPORAN_" . $judul . ".xls"); echo "<div><h3> DAFTAR SURAT TEGURAN PAJAK " . $vat_code . " </h3></div>"; echo "<div><b>Tanggal cetak : " . date('d-M-Y') . "</b></div><br/>"; $no = 1; echo "<table border='1'>"; echo "<tr>\r\n\t\t<th>NO</th>\r\n\t\t<th>NPWPD</th>\t\r\n\t\t<th>NAMA</th>\r\n\t\t<th>ALAMAT</th>\r\n\t\t<th>JATUH TEMPO</th>\r\n\t\t<th>MASA PAJAK</th>\r\n\t\t<th>BESARNYA</th>\r\n\t\t<th>KETERANGAN</th>\r\n\t</tr>"; $query = "select * from f_debt_letter_list(" . $param_arr['t_customer_order_id'] . ") as a \r\n\t\t LEFT JOIN t_cust_account as b ON a.t_cust_account_id = b.t_cust_account_id\r\n\t\t WHERE a.p_vat_type_id = " . $param_arr['p_vat_type_id'] . " AND b.p_vat_type_dtl_id NOT IN (11, 15, 17, 21, 27, 30, 41, 42, 43)"; $dbConn->query($query); while ($dbConn->next_record()) { $items[] = $item = array('npwd' => $dbConn->f("npwd"), 'company_name' => $dbConn->f("company_name"), 'wp_name' => $dbConn->f("wp_name"), 'address_name' => $dbConn->f("address_name"), 'wp_address_name' => $dbConn->f("wp_address_name"), 'wp_address_no' => $dbConn->f("wp_address_no"), 'vat_code' => $dbConn->f("vat_code"), 'due_date' => $dbConn->f("due_date"), 'start_date' => $dbConn->f("start_date"), 'end_date' => $dbConn->f("end_date"), 'debt_amount' => $dbConn->f("debt_amount"), 'description' => $dbConn->f("description")); if ($item['company_name'] == '-' || empty($item['company_name'])) { $item['company_name'] = $item['wp_name']; } if ($item['address_name'] == '-' || empty($item['address_name'])) { $item['address_name'] = $item['wp_address_name'] . ' ' . $item['wp_address_no']; } echo "<tr>\r\n\t\t\t<td>" . $no . "</td>\r\n\t\t\t<td>" . $item['npwd'] . "</td>\r\n\t\t\t<td>" . $item['company_name'] . "</td>\r\n\t\t\t<td>" . $item['address_name'] . "</td>\r\n\t\t\t<td>" . $item['due_date'] . "</td>\r\n\t\t\t<td>" . $item['start_date'] . " s.d. " . $item['end_date'] . "</td>\r\n\t\t\t<td align='right'>" . number_format($item['debt_amount'], 2, ',', '.') . "</td>\r\n\t\t\t<td>" . $item['description'] . "</td>\r\n\t\t</tr>"; $no++; } echo "</table>"; exit; }
function t_vat_setllementGrid_cetak_sptpd_BeforeShow(&$sender) { $t_vat_setllementGrid_cetak_sptpd_BeforeShow = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $t_vat_setllementGrid; //Compatibility //End t_vat_setllementGrid_cetak_sptpd_BeforeShow // ------------------------- // Write your own code here. $pajak = $t_vat_setllementGrid->total_vat_amount->GetValue(); $denda = $t_vat_setllementGrid->total_penalty_amount->GetValue(); $totaltotal = $pajak + $denda; $t_vat_setllementGrid->total_total->SetValue($totaltotal); $nilai = $t_vat_setllementGrid->t_vat_setllement_id->GetValue(); $nilai2 = $t_vat_setllementGrid->p_vat_type_id->GetValue(); $t_vat_setllementGrid->cetak_sptpd->SetValue("<input type='button' style='display:none;' value='CETAK' style='WIDTH: 57px; HEIGHT: 22px' class='Button' onclick=\"" . "cetakSptpd(" . $nilai . "," . $nilai2 . ")\">"); $action_button = CCGetFromGet("action_button", ""); $action_button2 = CCGetFromGet("action_button2", ""); if ($action_button == 'flag_payment' && $action_button2 != 'cetak_register') { $dbConn = new clsDBConnSIKP(); $sql = "select sikp.f_payment_manual(" . CCGetFromGet('t_customer_order_id') . ",'" . CCGetSession('UserLogin') . "')"; $dbConn->query($sql); $dbConn->next_record(); echo "\r\n \t\t<script>\r\n \t\talert('" . $dbConn->f('f_payment_manual') . "');\r\n \t\t</script>\r\n \t\t"; $dbConn->close(); } else { if ($action_button2 == 'cetak_register') { $dbConn = new clsDBConnSIKP(); $sql = "select sikp.f_print_register(" . CCGetFromGet('t_customer_order_id') . ",'" . CCGetSession('UserLogin') . "')"; $dbConn->query($sql); $dbConn->next_record(); print_laporan($dbConn->f('f_print_register')); /*echo " <script> window.open('../services/print_string.php?input_number=".$dbConn->f('f_print_register')."', '_blank', 'location=yes,height=570,width=520,scrollbars=yes,status=yes'); </script> ";*/ $dbConn->close(); exit; } } // ------------------------- //Close t_vat_setllementGrid_cetak_sptpd_BeforeShow @300-BF0BB7F2 return $t_vat_setllementGrid_cetak_sptpd_BeforeShow; }
function sendSms() { include 'save_excel_2.php'; include '../../gammu/send_sms.php'; $SendSms = new SendSms(); $dbConn = new clsDBConnSIKP(); $query = "SELECT * FROM t_sms_outbox where is_sent = 'N'"; $dbConn->query($query); $data = array(); while ($dbConn->next_record()) { $data[] = $item = array('t_sms_outbox_id' => $dbConn->f("t_sms_outbox_id"), 'npwpd' => $dbConn->f("npwpd"), 'mobile_no' => $dbConn->f("mobile_no"), 'message' => $dbConn->f("message"), 'is_sent' => $dbConn->f("is_sent"), 'date_sent' => $dbConn->f("date_sent"), 'date_addded' => $dbConn->f("date_addded")); $SendSms->send($item["mobile_no"], $item["message"]); } for ($counter = 0; $counter < sizeof($data); $counter++) { $query = " UPDATE t_sms_outbox\r\n\t \t\tSET is_sent='Y',date_sent=sysdate\r\n\t \t\tWHERE t_sms_outbox_id=" . $data[$counter]['t_sms_outbox_id']; $dbConn->query($query); } }
function t_message_inboxGrid_BeforeSelect(&$sender) { $t_message_inboxGrid_BeforeSelect = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $t_message_inboxGrid; //Compatibility //End t_message_inboxGrid_BeforeSelect //Custom Code @226-2A29BDB7 // ------------------------- // Write your own code here. // ------------------------- //End Custom Code //Custom Code @289-2A29BDB7 // ------------------------- // Write your own code here. // ------------------------- //End Custom Code $t_message_inbox_id = CCGetFromGet('t_message_inbox_bphtb_id'); if (!empty($t_message_inbox_id)) { $dbConn1 = new clsDBConnSIKP(); $cari = "select message_status from t_message_inbox_bphtb where t_message_inbox_bphtb_id = " . $t_message_inbox_id; $dbConn1->query($cari); while ($dbConn1->next_record()) { $message_status = $dbConn1->f("message_status"); } if ($message_status == 'U') { $query = "update t_message_inbox_bphtb set message_status = 'V' where t_message_inbox_id = " . $t_message_inbox_id; $dbConn1->query($query); } } // ------------------------- // Write your own code here. $Component->DataSource->Parameters["urls_keyword"] = strtoupper(CCGetFromGet("s_keyword", NULL)); // ------------------------- //Close t_message_inboxGrid_BeforeSelect @2-E3E1E9CD return $t_message_inboxGrid_BeforeSelect; }
function SELECT_x_receipt_no_x_p_f_BeforeSelect(&$sender) { $SELECT_x_receipt_no_x_p_f_BeforeSelect = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $SELECT_x_receipt_no_x_p_f; //Compatibility //End SELECT_x_receipt_no_x_p_f_BeforeSelect //Custom Code @187-2A29BDB7 // ------------------------- // Write your own code here. $dbConn = new clsDBConnSIKP(); $cust_acc_id = CCGetFromGet('t_cust_account_id'); $sql = "select to_char(active_date,'dd-mm-yyyy') as active_date from t_cust_account where t_cust_account_id=" . $cust_acc_id; $dbConn->query($sql); $dbConn->next_record(); $cust_id = $dbConn->f("active_date"); $SELECT_x_receipt_no_x_p_f->DataSource->Parameters["expr189"] = $cust_id; // ------------------------- //End Custom Code //Close SELECT_x_receipt_no_x_p_f_BeforeSelect @2-7D0B9252 return $SELECT_x_receipt_no_x_p_f_BeforeSelect; }
function p_pass_byadminForm_Button_Ubah_OnClick(&$sender) { $p_pass_byadminForm_Button_Ubah_OnClick = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $p_pass_byadminForm; //Compatibility //End p_pass_byadminForm_Button_Ubah_OnClick //Custom Code @104-2A29BDB7 // ------------------------- // Write your own code here. global $FileName; global $PathToCurrentPage; $param = CCGetQueryString("QueryString", ""); $dbConn = new clsDBConnSIKP(); $old_pwd = $p_pass_byadminForm->o_user_pwd->GetValue(); $new_pwd1 = $p_pass_byadminForm->n_user_pwd1->GetValue(); $new_pwd2 = $p_pass_byadminForm->n_user_pwd2->GetValue(); $idUser = $p_pass_byadminForm->p_app_user_id->GetValue(); $sql = "select * from f_change_pass(" . $idUser . ",'" . $old_pwd . "','" . $new_pwd1 . "','" . $new_pwd2 . "')"; $dbConn->query($sql); $dbConn->next_record(); $mess = $dbConn->f("f_change_pass"); $dbConn->close(); echo '<script language="javascript">'; echo 'alert("' . $mess . '");'; echo '</script>'; $p_pass_byadminForm->o_user_pwd->SetValue(""); $p_pass_byadminForm->n_user_pwd1->SetValue(""); $p_pass_byadminForm->n_user_pwd2->SetValue(""); return; // ------------------------- //End Custom Code //Close p_pass_byadminForm_Button_Ubah_OnClick @26-C74BD412 return $p_pass_byadminForm_Button_Ubah_OnClick; }
function t_vat_registrationForm_BeforeSelect(&$sender) { $t_vat_registrationForm_BeforeSelect = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $t_vat_registrationForm; //Compatibility //End t_vat_registrationForm_BeforeSelect //Custom Code @686-2A29BDB7 // ------------------------- // Write your own code here. $CustId = CCGetFromGet("CURR_DOC_ID", ""); $dbConn = new clsDBConnSIKP(); $sql = "select p_settlement_type_id from t_vat_setllement where t_customer_order_id = " . $CustId; $dbConn->query($sql); $dbConn->next_record(); $nilai = $dbConn->f("p_settlement_type_id"); $dbConn->close(); $t_vat_registrationForm->Hidden1->SetValue($nilai); // ------------------------- //End Custom Code //Close t_vat_registrationForm_BeforeSelect @629-D64E68A4 return $t_vat_registrationForm_BeforeSelect; }
function getDataRowReklame($year_period_id, $date_awal, $date_akhir) { $dbConn = new clsDBConnSIKP(); $query = "SELECT SUM(target_amount) AS target, SUM(realisasi_amt) AS realisasi,\r\n\t\t\t\tSUM(debt_amt) AS piutang\r\n\t\t\t\tFROM f_target_vs_real_monthly_new(" . $year_period_id . ",9)\r\n\t\t\t\tWHERE trunc(start_date) >= '" . $date_awal . "'\r\n\t\t\t\tAND trunc(end_date) <= '" . $date_akhir . "'"; $dbConn->query($query); $result = array(); while ($dbConn->next_record()) { $result['target'] = $dbConn->f("target"); $result['piutang'] = $dbConn->f("piutang"); $result['realisasi'] = $dbConn->f("realisasi"); $result['selisih'] = $dbConn->f("realisasi") + $dbConn->f("piutang") - $dbConn->f("target"); $result['realisasiDanPiutang'] = $dbConn->f("realisasi") + $dbConn->f("piutang"); } $dbConn->close(); return $result; }
function print_excel($param_arr) { startExcel("lapora_global_per_wp"); echo "<div><h3> Penerimaan Global Per WP</h3></div>"; echo "<div><b>Jenis Pajak : " . $param_arr['rqst_type_code'] . "</b></div>"; echo "<div><b>Tanggal : " . dateToString($param_arr['date_start']) . " s.d " . dateToString($param_arr['date_end']) . "</b></div><br/>"; $dbConn = new clsDBConnSIKP(); $query = "select a.*, f_get_wilayah(b.npwd) as kode_wilayah , to_char(b.active_date,'dd-mm-yyyy') as active_date,\r\n\t\t\tb.brand_address_name ||' '|| nvl(b.brand_address_no,'') as alamat_new\r\n\t\t\tfrom sikp.f_laporan_global_wp2(" . $param_arr['p_rqst_type_id'] . ",'" . $param_arr['date_start'] . "', '" . $param_arr['date_end'] . "') a\r\n\t\t\tleft join t_cust_account b on a.npwpd = b.npwd\r\n\t\t\twhere f_get_wilayah_id(b.npwd) = " . $param_arr['kode_wilayah'] . " \r\n\t\t\torder by jenis_pajak,TRIM(company_brand)"; $dbConn->query($query); $no = 1; $jumlah = 0; echo '<table border="1">'; echo '<tr> <th>NO</th> <th>NAMA WP</th> <th>ALAMAT</th> <th>NPWPD</th> <th>BESARNYA (Rp)</th> <th>JML SSPD</th> <th>NAMA AYAT</th> <th>PENGUKUHAN</th> <th>KETERANGAN</th> </tr>'; while ($dbConn->next_record()) { $items[] = array('nama_wp' => $dbConn->f("nama_wp"), 'alamat_new' => $dbConn->f("alamat_new"), 'npwpd' => $dbConn->f("npwpd"), 'amount' => $dbConn->f("amount"), 'tot_sspd' => $dbConn->f("tot_sspd"), 'kode_wilayah' => $dbConn->f("kode_wilayah"), 'active_date' => $dbConn->f("active_date"), 'jenis_pajak' => $dbConn->f("jenis_pajak")); echo '<tr>'; echo '<td align="center">' . $no . '</td>'; echo '<td>' . $dbConn->f("nama_wp") . '</td>'; echo '<td>' . $dbConn->f("alamat_new") . '</td>'; echo '<td>' . $dbConn->f("npwpd") . '</td>'; echo '<td align="right">' . number_format($dbConn->f("amount"), 2, ",", ".") . '</td>'; echo '<td align="right">' . $dbConn->f("tot_sspd") . '</td>'; echo '<td>' . $dbConn->f('jenis_pajak') . '</td>'; echo '<td>' . $dbConn->f('active_date') . '</td>'; echo '<td>' . $dbConn->f('kode_wilayah') . '</td>'; echo '</tr>'; $jumlah += $dbConn->f("amount"); $jumlah_wp += $dbConn->f("tot_sspd"); $no++; } echo '<tr> <td colspan="4" align="center"> <b> JUMLAH </b> </td> <td align="right"><b>' . number_format($jumlah, 2, ",", ".") . '</b></td> <td align="right"><b>' . $jumlah_wp . '</b></td> </tr>'; echo '</table>'; exit; }
define("RelativePath", ".."); define("PathToCurrentPage", "/report/"); define("FileName", "cetak_formulir_skpdkb_pdf.php"); include_once RelativePath . "/Common.php"; include_once "../include/fpdf.php"; $dbConn = new clsDBConnSIKP(); $data = array(); $idVatSS = CCGetFromGet("t_vat_setllement_id", ""); if (empty($idVatSS)) { echo "Data Tidak Ditemukan"; exit; } else { $sql = "SELECT * " . "FROM v_vat_setllement " . "WHERE t_vat_setllement_id = " . $idVatSS; $dbConn->query($sql); while ($dbConn->next_record()) { $data["t_cust_account_id"] = $dbConn->f("t_cust_account_id"); $data["finance_period_code"] = $dbConn->f("finance_period_code"); $data["tahun"] = $dbConn->f("tahun"); $data["npwd"] = $dbConn->f("npwd"); $data["due_date"] = $dbConn->f("due_date"); $data["no_urut"] = $dbConn->f("order_no"); $data["jenis_pajak"] = $dbConn->f("jenis_pajak"); $data["debt_vat_amt"] = $dbConn->f("debt_vat_amt"); $data["terutang"] = $dbConn->f("terutang"); $data["cr_adjustment"] = $dbConn->f("cr_adjustment"); $data["cr_payment"] = $dbConn->f("cr_payment"); $data["cr_others"] = $dbConn->f("cr_others"); $data["db_interest_charge"] = $dbConn->f("db_interest_charge"); $data["db_increasing_charge"] = $dbConn->f("db_increasing_charge"); } $kpd = "select wp_name, wp_address_name, wp_kota\r\n\t\t\tfrom v_cust_account_update\r\n\t\t\twhere t_cust_account_id = " . $data["t_cust_account_id"];
function PageCetak($data) { $this->AliasNbPages(); $this->AddPage("P"); $this->SetFont('Arial', '', 10); // $this->Image('../images/logo_pemda.png',12,12,25,25); $lheader = $this->lengthCell / 8; $lheader1 = $lheader * 1; $lheader2 = $lheader * 2; $lheader3 = $lheader * 3; $lheader4 = $lheader * 4; $lheader5 = $lheader * 5; $lheader6 = $lheader * 6; $this->Cell($lheader1, $this->height - 2, "", "TL", 0, 'C'); $this->Cell($lheader2, $this->height - 2, "", "TR", 0, 'C'); $this->Cell($lheader3, $this->height - 2, "", "TR", 0, 'C'); $this->Cell($lheader2, $this->height - 2, "", "TR", 0, 'C'); $this->Ln(); $this->SetFont('Arial', '', 10); $this->Image('../images/logo_pemda.png', 12, 15, 20, 20); $this->Cell($lheader1, $this->height, "", "L", 0, 'C'); $this->Cell($lheader2, $this->height, "PEMERINTAH KOTA", "R", 0, 'C'); $this->SetFont('Arial', '', 12); $this->Cell($lheader3, $this->height, "SKPDKB", "R", 0, 'C'); $this->Cell($lheader2, $this->height, "", "R", 0, 'C'); $this->Ln(); /*$this->Cell($lheader1, $this->height, "", "L", 0, 'C'); $this->Cell($lheader2, $this->height, "BANDUNG", "R", 0, 'C'); $this->Cell($lheader3, $this->height, "(Surat Ketetapan Pajak Daerah Kurang Bayar)", "R", 0, 'C'); $this->Cell($lheader2, $this->height, "No. Urut", "R", 0, 'C'); $this->Ln();*/ $this->SetFont('Arial', '', 10); $this->Cell($lheader1, $this->height - 2, "", "L", 0, 'C'); $this->Cell($lheader2, $this->height - 2, "BANDUNG", "R", 0, 'C'); $this->SetFont('Arial', '', 9); $this->Cell($lheader3, $this->height - 2, "(Surat Ketetapan Pajak Daerah Kurang Bayar)", "R", 0, 'C'); $this->SetFont('Arial', '', 10); $this->Cell($lheader2, $this->height - 2, "No. Urut", "R", 0, 'C'); $this->Ln(); /* $this->Cell($lheader6, $this->height, "(Surat Ketetapan Pajak Daerah Kurang Bayar)", "LR", 0, 'C'); $this->Cell($lheader2, $this->height, "No. Urut", "R", 0, 'C'); $this->Ln();*/ $this->Cell($lheader1, $this->height + 1, "", "L", 0, 'C'); $this->Cell($lheader2, $this->height + 1, "DINAS PELAYANAN PAJAK", "R", 0, 'C'); $this->Cell($lheader3, $this->height + 1, " Masa Pajak : " . $data["finance_period_code"], "R", 0, 'L'); $this->Cell($lheader2, $this->height + 1, "", "R", 0, 'C'); $this->Ln($this->height - 4); // No Urut $this->Cell($lheader2 + $lheader4 + 1, $this->height, "", "R", 0, 'C'); $no_urut = str_split($data["no_urut"]); $this->kotak(1, 34, 1, $no_urut[0]); $this->kotak(1, 34, 1, $no_urut[1]); $this->kotak(1, 34, 1, $no_urut[2]); $this->kotak(1, 34, 1, $no_urut[3]); $this->kotak(1, 34, 1, $no_urut[4]); $this->kotak(1, 34, 1, $no_urut[5]); $this->kotak(1, 34, 1, $no_urut[6]); $this->kotak(1, 34, 1, $no_urut[7]); $this->Ln(); // ======= /*$this->Cell($lheader2, $this->height + 2, "", "BL", 0, 'R'); $this->Cell($lheader1, $this->height + 2, "Tahun Pajak ", "B", 0, 'L'); $this->Cell($lheader3, $this->height + 2, ": ".$data["tahun"], "BR", 0, 'L'); $this->Cell($lheader2, $this->height + 2, "", "BR", 0, 'C'); */ $this->Cell($lheader1, $this->height - 1, "", "L", 0, 'C'); $this->SetFont('Arial', '', 8); $this->Cell($lheader2, $this->height - 1, "Jalan Wastukancana No.2", "R", 0, 'C'); $this->SetFont('Arial', '', 10); $this->Cell($lheader3, $this->height - 1, " Tahun Pajak : " . $data["tahun"], "R", 0, 'L'); $this->Cell($lheader2, $this->height - 1, "No.Bayar", "R", 0, 'C'); $this->Ln(); // $this->Cell($lheader3, $this->height + 2, "", "BL", 0, 'R'); // $this->Cell($lheader3, $this->height + 2, "", "BR", 0, 'L'); // $this->Cell($lheader2, $this->height + 2, "", "BR", 0, 'C'); // $this->Ln(); $this->Cell($lheader1, $this->height + 1, "", "BL", 0, 'C'); $this->SetFont('Arial', '', 8); $this->Cell($lheader2, $this->height + 1, "Telp. 022-4235052 - Bandung", "BR", 0, 'C'); $this->SetFont('Arial', '', 10); $this->Cell($lheader3, $this->height + 1, "", "BR", 0, 'L'); $this->Cell($lheader2, $this->height + 1, $data["no_bayar"], "BR", 0, 'C'); $this->Ln(); $lbody = $this->lengthCell / 4; $lbody1 = $lbody * 1; $lbody2 = $lbody * 2; $lbody3 = $lbody * 3; $this->SetFont('Arial', '', 8); $this->Cell(5, $this->height, "", "L", 0, 'L'); $this->Cell($lbody1 - 5, $this->height, "Nama", "", 0, 'L'); $this->Cell($lbody3, $this->height, ": " . $data["wp_name"], "R", 0, 'L'); $this->Ln(); $this->Cell(5, $this->height, "", "L", 0, 'L'); $this->Cell($lbody1 - 5, $this->height, "Alamat", "", 0, 'L'); $this->Cell($lbody3, $this->height, ": " . $data["wp_address_name"], "R", 0, 'L'); $this->Ln(); $this->Cell(5, $this->height + 2, "", "L", 0, 'L'); $this->Cell($lbody1 - 5, $this->height + 2, "NPWPD", "", 0, 'L'); $this->Cell($lbody1, $this->height + 2, "", "", 0, 'L'); $this->Cell($lbody2, $this->height + 2, "", "R", 0, 'L'); $this->Ln($this->height - 4); $this->Cell($lbody1 + 3, $this->height, ":", "L", 0, 'R'); $rep_npwd = str_replace(".", "", $data["npwd"]); $arr1 = str_split($rep_npwd); $this->kotak(1, 34, 1, $arr1[0]); $this->kotakKosong(1, 34, 1); $this->kotak(1, 34, 1, $arr1[1]); $this->kotakKosong(1, 34, 1); $this->kotak(1, 34, 1, $arr1[2]); $this->kotak(1, 34, 1, $arr1[3]); $this->kotak(1, 34, 1, $arr1[4]); $this->kotak(1, 34, 1, $arr1[5]); $this->kotak(1, 34, 1, $arr1[6]); $this->kotak(1, 34, 1, $arr1[7]); $this->kotak(1, 34, 1, $arr1[8]); $this->kotakKosong(1, 34, 1); $this->kotak(1, 34, 1, $arr1[9]); $this->kotak(1, 34, 1, $arr1[10]); $this->kotakKosong(1, 34, 1); $this->kotak(1, 34, 1, $arr1[11]); $this->kotak(1, 34, 1, $arr1[12]); $this->Ln(); $this->Cell(5, $this->height, "", "BL", 0, 'L'); $this->Cell($lbody1 - 5, $this->height, "Tanggal jatuh tempo", "B", 0, 'L'); //$this->Cell($lbody3, $this->height, ": ".Date("d M Y",strtotime("+15 day")), "BR", 0, 'L'); $this->Cell($lbody3, $this->height, ": " . $data["tgl_jatuh_tempo"], "BR", 0, 'L'); $this->Ln(); //$this->tulis("I. Berdasarkan Pasal 65 ayat (2) dan (3) Peraturan Daerah Kota Bandung Nomor 20 Tahun 2011 tentang Pajak Daerah, telah dilakukan", "L"); $this->Cell(5, $this->height + 2, "", "L", 0, 'C'); $this->Cell($this->lengthCell - 10, $this->height + 2, "I. Berdasarkan Pasal 65 ayat (2) dan (3) Peraturan Daerah Kota Bandung Nomor 20 Tahun 2011 tentang Pajak Daerah, telah dilakukan", "", 0, "L"); $this->Cell(5, $this->height + 2, "", "R", 0, 'C'); $this->Ln(); $this->tulis(" pemeriksaan atau keterangan lain di atas pelaksanaan kewajiban :", "L"); $lbody = $this->lengthCell / 4; $lbody1 = $lbody * 1; $lbody2 = $lbody * 2; $lbody3 = $lbody * 3; $indent = $this->lengthCell / 30; $this->Cell(5, $this->height + 2, "", "L", 0, 'L'); $this->Cell($lbody1 - 5, $this->height + 2, " Ayat Pajak", "", 0, 'L'); $this->Cell($lbody3, $this->height + 2, ": ", "R", 0, 'L'); $this->Ln($this->height - 4); // Ayat Pajak $this->Cell($lbody1 + 3, $this->height, ":", "L", 0, 'R'); if (!empty($data["vat_code"])) { $arr_ayat = str_split($data["vat_code"]); } else { $arr_ayat = array(); $this->kotak(1, 45, 1, " - "); } //$this->kotak(1, 34, 6, ""); for ($i = 0; $i < count($arr_ayat); $i++) { if ($arr_ayat[$i] != " ") { $this->kotak(1, 45, 1, $arr_ayat[$i]); } else { $this->kotakKosong(1, 34, 1); } } $this->Ln(); // ========== $this->Cell(5, $this->height, "", "L", 0, 'L'); $this->Cell($lbody1 - 5, $this->height, " Nama Pajak", "", 0, 'L'); $this->Cell($lbody3, $this->height, ": " . $data["jenis_pajak"], "R", 0, 'L'); $this->Ln(); $this->tulis("II. Dari pemeriksaan atau keterangan lain tersebut di atas, perhitungan jumlah yang masih harus dibayar adalah sebagai berikut:", "L"); $lbodyx1 = $lbody1 / 2; $this->Cell(5, $this->height, "", "L", 0, 'L'); $this->Cell($lbody3 - 5, $this->height, " 1. Dasar Pengenaan", "", 0, 'L'); $this->Cell($lbodyx1, $this->height, "Rp ", "", 0, 'L'); $this->Cell($lbodyx1 - 10, $this->height, number_format($data["total_trans_amount"], 2, ",", "."), "", 0, 'R'); $this->Cell(10, $this->height, "", "R", 0, 'R'); $this->Ln(); $this->Cell(5, $this->height, "", "L", 0, 'L'); $this->Cell($lbody3 - 5, $this->height, " 2. Pajak yang Terutang", "", 0, 'L'); $this->Cell($lbodyx1, $this->height, "Rp ", "", 0, 'L'); $this->Cell($lbodyx1 - 10, $this->height, number_format($data["debt_vat_amt"], 2, ",", "."), "", 0, 'R'); $this->Cell(10, $this->height, "", "R", 0, 'R'); $this->Ln(); $this->tulis(" 3. Kredit Pajak", "L"); $this->Cell(10, $this->height, "", "L", 0, 'L'); $this->Cell($lbody2 - 10, $this->height, " a. Kompensasi kelebihan dari tahun sebelumnya", "", 0, 'L'); $this->Cell($lbodyx1, $this->height, "Rp ", "", 0, 'L'); $this->Cell($lbodyx1 - 10, $this->height, number_format($data["cr_adjustment"], 2, ",", "."), "", 0, 'R'); $this->Cell(10, $this->height, "", "", 0, 'R'); $this->Cell($lbody1, $this->height, "", "R", 0, 'L'); $this->Ln(); $this->Cell(10, $this->height, "", "L", 0, 'L'); $this->Cell($lbody2 - 10, $this->height, " b. Setoran yang dilakukan", "", 0, 'L'); $this->Cell($lbodyx1, $this->height, "Rp ", "", 0, 'L'); $this->Cell($lbodyx1 - 10, $this->height, number_format($data["cr_payment"], 2, ",", "."), "", 0, 'R'); $this->Cell(10, $this->height, "", "", 0, 'R'); $this->Cell($lbody1, $this->height, "", "R", 0, 'L'); $this->Ln(); $this->Cell(10, $this->height, "", "L", 0, 'L'); $this->Cell($lbody2 - 10, $this->height, " c. Lain-lain", "", 0, 'L'); $this->Cell($lbodyx1, $this->height, "Rp ", "B", 0, 'L'); $this->Cell($lbodyx1 - 10, $this->height, number_format($data["cr_others"], 2, ",", "."), "B", 0, 'R'); $this->Cell(10, $this->height, "", "", 0, 'R'); $this->Cell($lbody1, $this->height, "", "R", 0, 'L'); $this->Ln(); $jumno3 = $data["cr_others"] + $data["cr_payment"] + $data["cr_adjustment"]; $this->Cell(10, $this->height, "", "L", 0, 'L'); $this->Cell($lbody2 - 10, $this->height, " d. Jumlah yang dapat dikreditkan (a + b + c)", "", 0, 'L'); $this->Cell($lbodyx1, $this->height, "Rp ", "", 0, 'L'); $this->Cell($lbodyx1 - 10, $this->height, number_format($jumno3, 2, ",", "."), "", 0, 'R'); $this->Cell(10, $this->height, "", "", 0, 'R'); $this->Cell($lbody1, $this->height, "", "R", 0, 'L'); $this->Ln(); // $this->tulis("4. Jumlah kekurangan pembayaran Pokok Pajak (2-3d)", "L"); $this->Cell(5, $this->height, "", "L", 0, 'L'); $this->Cell($lbody3 - 5, $this->height, " 4. Jumlah kekurangan pembayaran Pokok Pajak (2-3d)", "", 0, 'L'); $this->Cell($lbodyx1, $this->height, "Rp ", "", 0, 'L'); $this->Cell($lbodyx1 - 10, $this->height, number_format($data["debt_vat_amt"] - $jumno3, 2, ",", "."), "", 0, 'R'); $this->Cell(10, $this->height, "", "R", 0, 'R'); $this->Ln(); $this->tulis(" 5. Sanksi Administrasi", "L"); $this->Cell(10, $this->height, "", "L", 0, 'L'); $this->Cell($lbody2 - 10, $this->height, " a. Bunga (Pasal 65 ayat(2)", "", 0, 'L'); $this->Cell($lbodyx1, $this->height, "Rp ", "", 0, 'L'); $this->Cell($lbodyx1 - 10, $this->height, number_format($data["total_penalty_amount"], 2, ",", "."), "", 0, 'R'); $this->Cell(10, $this->height, "", "", 0, 'R'); $this->Cell($lbody1, $this->height, "", "R", 0, 'L'); $this->Ln(); $this->Cell(10, $this->height, "", "L", 0, 'L'); $this->Cell($lbody2 - 10, $this->height, " b. Kenaikan (Pasal 65 ayat (3)", "", 0, 'L'); $this->Cell($lbodyx1, $this->height, "Rp ", "B", 0, 'L'); $this->Cell($lbodyx1 - 10, $this->height, number_format($data["db_increasing_charge"], 2, ",", "."), "B", 0, 'R'); $this->Cell(10, $this->height, "", "", 0, 'R'); $this->Cell($lbody1, $this->height, "", "R", 0, 'L'); $this->Ln(); $jumno5 = $data["total_penalty_amount"] + $data["db_increasing_charge"]; $this->Cell(10, $this->height, "", "L", 0, 'L'); $this->Cell($lbody2 - 10, $this->height, " c. Jumlah sanksi administrasi (a + b)", "", 0, 'L'); $this->Cell($lbody1, $this->height, "", "", 0, 'L'); $this->Cell($lbodyx1, $this->height, "Rp ", "B", 0, 'L'); $this->Cell($lbodyx1 - 10, $this->height, number_format($jumno5, 2, ",", "."), "B", 0, 'R'); $this->Cell(10, $this->height, "", "R", 0, 'R'); $this->Ln(); $jumno4 = $data["debt_vat_amt"] - $jumno3; $total = $jumno4 + $jumno5; $this->Cell(5, $this->height, "", "L", 0, 'L'); $this->Cell($lbody3 - 5, $this->height, " 6. Jumlah yang masih harus dibayar (4 + 5c)", "", 0, 'L'); $this->Cell($lbodyx1, $this->height, "Rp ", "", 0, 'L'); $this->Cell($lbodyx1 - 10, $this->height, number_format($total, 2, ",", "."), "", 0, 'R'); $this->Cell(10, $this->height, "", "R", 0, 'R'); $this->Ln(); $dbConn2 = new clsDBConnSIKP(); $total = isset($total) ? abs($total) : 0; $hrf = "select replace(f_terbilang('" . $total . "','IDR'), ' ', ' ') as dengan_huruf"; //echo $hrf;exit; $dbConn2->query($hrf); while ($dbConn2->next_record()) { $huruf = $dbConn2->f("dengan_huruf"); } $this->Cell($this->lengthCell, $this->height, "", "BLR", 0, 'L'); $this->Ln(); $this->Cell(5, $this->height + 2, "", "BL", 0, 'L'); $this->Cell($lbody1 - 5, $this->height + 2, "Dengan huruf", "B", 0, 'L'); $this->Cell($lbody3, $this->height + 2, "", "BR", 0, 'L'); $this->Ln($this->height - 4); // Dengan huruf $this->Cell($lbody1 - 5, $this->height, "", "", 0, 'L'); $this->kotak(25, 34, 1, $huruf); $this->Ln(); // ============ $this->SetFont('Arial', 'U', 8); $this->Cell($lbody1, $this->height + 1, "PERHATIAN:", "L", 0, 'L'); $this->Cell($lbody3, $this->height, "", "R", 0, 'L'); $this->Ln(); $this->SetFont('Arial', '', 8); $this->tulis("1. Harap penyetoran dilakukan melalui Kas Daerah atau tempat lain yang ditunjuk dengan menggunakan Surat Setoran Pajak Daerah (SSPD)", "L"); $this->tulis("2. Apabila SKPDKB ini tidak atau kurang dibayar setelah lewat waktu paling lama 15 hari kalender sejak SKPDKB ini diterbitkan dikenakan", "L"); $this->tulis(" sanksi administrasi berupa bunga sebesar 2% per bulan.", "L"); $this->Cell($lbody3 - 10, $this->height, "", "L", 0, 'L'); //$this->Cell($lbody1 + 10, $this->height, "Bandung, " . Date("d M Y") /*. $data["tanggal"]*/, "R", 0, 'C'); $this->Cell($lbody1 + 10, $this->height, "Bandung, " . $data["tgl_setllement"], "R", 0, 'C'); $this->Ln(); $this->Cell($lbody3 - 10, $this->height, "", "L", 0, 'L'); $this->Cell($lbody1 + 10, $this->height, "a.n KEPALA DINAS PELAYANAN PAJAK", "R", 0, 'C'); $this->Ln(); $this->Cell($lbody3 - 10, $this->height, "", "L", 0, 'L'); $this->Cell($lbody1 + 10, $this->height, "KEPALA BIDANG PAJAK PENDAFTARAN", "R", 0, 'C'); $this->Ln(); $this->Cell($lbody3 - 10, $this->height, "", "L", 0, 'L'); $this->Cell($lbody1 + 10, $this->height, "KOTA BANDUNG", "R", 0, 'C'); $this->newLine(); $this->Cell($this->lengthCell, $this->height, "", "LR", 0, 'L'); $this->Ln(); $this->Cell($lbody3 - 10, $this->height, "", "L", 0, 'L'); $this->Cell($lbody1 + 10, $this->height, "", "R", 0, 'C'); $this->Ln(); $this->Cell($lbody3 - 10, $this->height, "", "L", 0, 'L'); //$this->Cell($lbody1 + 10, $this->height, "H. SONI BAKHTIYAR, S.Sos, M.Si", "R", 0, 'C'); $this->Cell($lbody1 + 10, $this->height, "Drs. H. GUN GUN SUMARYANA", "R", 0, 'C'); $this->Ln(); $this->Cell($lbody3 - 10, $this->height, "", "BL", 0, 'L'); //$this->Cell($lbody1 + 8, $this->height, "NIP. 19750625 199403 1 001", "BT", 0, 'C'); //isi nip $this->Cell($lbody1 + 8, $this->height, "NIP. 19700806 199101 1 001", "BT", 0, 'C'); //isi nip $this->Cell(2, $this->height, "", "BR", 0, 'L'); $this->Ln($this->height + 4); $this->SetFont('Arial', '', 6); $this->Cell($this->lengthCell, $this->height, "覧覧覧覧覧覧覧覧覧覧覧覧覧覧覧覧覧覧覧覧 Gunting di sini 覧覧覧覧覧覧覧覧覧覧覧覧覧覧覧覧覧覧覧覧 ", "", 0, 'C'); $this->SetFont('Arial', '', 8); $this->Ln(); $this->Cell($lbody1, $this->height, "", "TL", 0, 'L'); $this->Cell($lbody2, $this->height, "", "T", 0, 'C'); $this->Cell($lbody1, $this->height, "No. SKPDKB : " . $data["no_urut"], "TR", 0, 'L'); $this->Ln(); $this->SetFont('Arial', '', 11); $this->Cell($lbody1, $this->height, "", "L", 0, 'L'); $this->Cell($lbody2, $this->height, "TANDA TERIMA", "", 0, 'C'); $this->Cell($lbody1, $this->height, "", "R", 0, 'C'); $this->Ln(); $this->SetFont('Arial', '', 8); $this->Cell($lbody1, $this->height, " NPWPD", "L", 0, 'L'); $this->Cell($lbody3, $this->height, ": " . $data["npwd"], "R", 0, 'L'); $this->Ln(); $this->Cell($lbody1, $this->height, " Nama", "L", 0, 'L'); $this->Cell($lbody3, $this->height, ": " . $data["wp_name"], "R", 0, 'L'); $this->Ln(); $this->Cell($lbody1, $this->height, " Alamat", "L", 0, 'L'); $this->Cell($lbody3, $this->height, ": " . $data["wp_address_name"], "R", 0, 'L'); $this->Ln(); $this->Cell($lbody3 - 10, $this->height, "", "L", 0, 'L'); $this->Cell($lbody1 + 10, $this->height, "Bandung, " . Date("d M Y"), "R", 0, 'C'); $this->Ln(); $this->Cell($lbody3 - 10, $this->height, "", "L", 0, 'L'); $this->Cell($lbody1 + 10, $this->height, "Yang Menerima, ", "R", 0, 'C'); $this->newLine(); $this->Cell($this->lengthCell, $this->height, "", "LR", 0, 'L'); $this->Ln(); $this->Cell($lbody3 - 10, $this->height, "", "BL", 0, 'L'); $this->Cell($lbody1 + 10, $this->height, "(............................................................)", "BR", 0, 'C'); }
function print_laporan($param_arr) { include "../include/fpdf17/mc_table.php"; $_BORDER = 0; $_FONT = 'Times'; $_FONTSIZE = 10; $pdf = new PDF_MC_Table(); $size = $pdf->_getpagesize('Legal'); $pdf->DefPageSize = $size; $pdf->CurPageSize = $size; $pdf->AddPage('Landscape', 'Legal'); $pdf->SetFont('helvetica', '', $_FONTSIZE); $pdf->SetRightMargin(5); $pdf->SetLeftMargin(9); $pdf->SetAutoPageBreak(false, 0); $textFilter = ''; if (!empty($param_arr['filter_lap'])) { if ($param_arr['filter_lap'] == 1) { //sudah bayar $textFilter = '(Sudah Bayar)'; } if ($param_arr['filter_lap'] == 2) { //belum bayar $textFilter = '(Belum Bayar)'; } if ($param_arr['filter_lap'] == 3) { //belum bayar $textFilter = '(Nihil)'; } } $pdf->SetFont('helvetica', '', 12); $pdf->SetWidths(array(200)); $pdf->ln(1); $pdf->RowMultiBorderWithHeight(array("DAFTAR NOTA VERIFIKASI BPHTB " . $textFilter), array('', ''), 6); //$pdf->ln(8); $pdf->SetWidths(array(40, 200)); $pdf->ln(4); $pdf->RowMultiBorderWithHeight(array("TANGGAL", ": " . dateToString($param_arr['date_start'], "-") . " s/d " . dateToString($param_arr['date_end'], "-")), array('', ''), 6); $dbConn = new clsDBConnSIKP(); $whereClause = ''; if (!empty($param_arr['date_start']) && !empty($param_arr['date_end'])) { $whereClause .= " AND (trunc(reg_bphtb.creation_date) BETWEEN '" . $param_arr['date_start'] . "'"; $whereClause .= " AND '" . $param_arr['date_end'] . "')"; } else { if (!empty($param_arr['date_start']) && empty($param_arr['date_end'])) { $whereClause .= " AND trunc(reg_bphtb.creation_date) >= '" . $param_arr['date_start'] . "'"; } else { if (empty($param_arr['date_start']) && !empty($param_arr['date_end'])) { $whereClause .= " AND trunc(reg_bphtb.creation_date) <= '" . $param_arr['date_end'] . "'"; } } } if (!empty($param_arr['filter_lap'])) { if ($param_arr['filter_lap'] == 1) { //sudah bayar $whereClause .= " AND (payment.receipt_no is not null or payment.receipt_no <> '') "; $whereClause .= " AND ( bphtb_amt_final > 0 ) "; } if ($param_arr['filter_lap'] == 2) { //belum bayar $whereClause .= " AND ( payment.receipt_no is null or payment.receipt_no = '') "; $whereClause .= " AND ( bphtb_amt_final > 0 ) "; } if ($param_arr['filter_lap'] == 3) { //nihil $whereClause .= " AND ( bphtb_amt_final < 1 ) "; } } $query = "SELECT\r\n\t\t\t\tto_char(reg_bphtb.creation_date, 'YYYY-MM-DD') as creation_date,\r\n\t\t\t\tregistration_no,\r\n\t\t\t\twp_name,\r\n\t\t\t\treg_bphtb.p_bphtb_legal_doc_type_id,\r\n\t\t\t\tbphtb_doc.description,\r\n\t\t\t\tnjop_pbb,\r\n\t\t\t\tland_area,\r\n\t\t\t\tland_total_price,\r\n\t\t\t\tbuilding_area,\r\n\t\t\t\tbuilding_total_price,\r\n\t\t\t\tmarket_price,\r\n\t\t\t\tbphtb_amt_final,\r\n\t\t\t\tland_price_per_m,\r\n\t\t\t\tbuilding_price_per_m\r\n\t\t\tFROM\r\n\t\t\t\tsikp.t_bphtb_registration reg_bphtb\r\n\t\t\tLEFT JOIN p_bphtb_legal_doc_type bphtb_doc on bphtb_doc.p_bphtb_legal_doc_type_id = reg_bphtb.p_bphtb_legal_doc_type_id\r\n\t\t\tLEFT JOIN t_customer_order cust_order ON cust_order.t_customer_order_id = reg_bphtb.t_customer_order_id \r\n\t\t\tLEFT JOIN t_payment_receipt_bphtb payment ON reg_bphtb.t_bphtb_registration_id = payment.t_bphtb_registration_id \r\n\t\t\tWHERE cust_order.p_order_status_id <> 1"; $query .= $whereClause; $query .= " order by trunc(reg_bphtb.creation_date) ASC,upper(wp_name) ASC"; $dbConn->query($query); $items = array(); $pdf->SetFont('helvetica', '', 9); $pdf->ln(2); $pdf->SetWidths(array(10, 24, 20, 15, 40, 18, 22, 25, 20, 61, 61, 27)); $pdf->SetAligns(array('C', 'C', 'C', 'C', 'C', 'C', 'C', 'C', 'C', 'C', 'C', 'C')); $pdf->SetWidths(array(10, 24, 23, 37, 30, 35, 18, 28, 24, 28, 25, 40, 18, 18, 18, 18, 18)); $pdf->SetFont('arial', '', 7); $pdf->RowMultiBorderWithHeight(array("NO", "TANGGAL", "NO.REGISTRASI", "NAMA WP", "JENIS TRANSAKSI", "NOP", "LT / LB", "HARGA TANAH / m2 (Rp)", "HARGA BANGUNAN / m2 (Rp)", "TOTAL NJOP (Rp)", "HARGA PASAR / TRANSAKSI / LELANG (Rp)", "NILAI PAJAK YANG HARUS DIBAYAR(Rp)"), array('LTB', 'LTB', 'LBT', 'LTB', 'TLB', 'TLB', 'TLB', 'TLB', 'TLB', 'TLBR'), 5); $pdf->SetFont('arial', '', 8); $no = 1; $pdf->SetAligns(array('C', 'L', 'L', 'L', 'L', 'L', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R')); $jumlah = 0; $jumlah = 0; $total_nilai_pajak = 0; $nilai_njop = 0; while ($dbConn->next_record()) { $items[] = $item = array('creation_date' => $dbConn->f("creation_date"), 'registration_no' => $dbConn->f("registration_no"), 'wp_name' => $dbConn->f("wp_name"), 'p_bphtb_legal_doc_type_id' => $dbConn->f("p_bphtb_legal_doc_type_id"), 'description' => $dbConn->f("description"), 'njop_pbb' => $dbConn->f("njop_pbb"), 'land_area' => $dbConn->f("land_area"), 'land_total_price' => $dbConn->f("land_total_price"), 'building_area' => $dbConn->f("building_area"), 'building_total_price' => $dbConn->f("building_total_price"), 'market_price' => $dbConn->f("market_price"), 'bphtb_amt_final' => $dbConn->f("bphtb_amt_final"), 'land_price_per_m' => $dbConn->f("land_price_per_m"), 'building_price_per_m' => $dbConn->f("building_price_per_m")); $nilai_njop = $dbConn->f("building_total_price") + $dbConn->f("land_total_price"); $pdf->RowMultiBorderWithHeight(array($no, dateToString($item['creation_date']), $item['registration_no'], $item['wp_name'], $item['description'], $item['njop_pbb'], number_format($item['land_area'], 0, ",", ".") . " / " . number_format($item['building_area'], 0, ",", "."), number_format($item['land_price_per_m'], 2, ",", "."), number_format($item['building_price_per_m'], 2, ",", "."), number_format($nilai_njop, 2, ",", "."), number_format($item['market_price'], 2, ",", "."), number_format($item['bphtb_amt_final'], 2, ",", ".")), array('LB', 'LB', 'LB', 'LB', 'LB', 'LB', 'LB', 'LB', 'LB', 'LB', 'LBR'), 6); $jumlah += $dbConn->f("amount"); // $jumlah_wp+=$dbConn->f("jumlah_wp"); $total_nilai_pajak += $item['bphtb_amt_final']; $no++; } $pdf->SetWidths(array(282, 40)); $pdf->SetAligns(array('C', 'R')); $pdf->SetFont('arial', 'B', 8); $pdf->RowMultiBorderWithHeight(array("TOTAL", number_format($total_nilai_pajak, 2, ",", ".")), array('LB', 'LBR'), 6); /*print_r($items); exit;*/ //$pdf->SetWidths(array(250,70)); $pdf->ln(12); $pdf->SetAligns(array("C", "C")); $pdf->SetWidths(array(169, 163)); $pdf->RowMultiBorderWithHeight(array("Mengetahui, \n Kepala Seksi Penyelesaian Piutang \n\n\n\n\n\n\n\n RACHMAT SATIADI, SIP, M.Si. \n ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯ ", "\n Koordinator BPHTB" . "\n\n\n\n\n\n\n\n ZAENAL MANSUR \n ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯ "), array("", ""), 4); $pdf->RowMultiBorderWithHeight(array("NIP : 19691104.1998.03.1.007", "NIP : 19630817.1989.01.1.006"), array("", ""), 1); //$pdf->RowMultiBorderWithHeight(array("","KASIE VOP"),array('','','','','','',''),6); $pdf->Output("", "I"); exit; }
<?php define("RelativePath", ".."); define("PathToCurrentPage", "/report/"); define("FileName", "cetak_formulir_surat_teguran_pdf.php"); include_once RelativePath . "/Common.php"; $npwpd = CCGetFromGet("npwpd", ""); $dbConn = new clsDBConnSIKP(); $query = "select * from t_payment_receipt a\r\n\t\tleft join t_cust_account b on a.npwd=b.npwd\r\n\t\tleft join t_customer c on b.t_customer_id = c.t_customer_id\r\n\t\twhere a.npwd = upper('" . $npwpd . "')\r\n\t\tORDER BY payment_date desc limit 1"; $dbConn->query($query); $data = array(); if ($dbConn->next_record()) { $json = array('items' => array(), 'message' => 'data ditemukan', 'success' => 'success'); $item = array('npwd' => $dbConn->f("npwd"), 'payment_vat_amount' => $dbConn->f("payment_vat_amount"), 'finance_period_code' => $dbConn->f("finance_period_code"), 'merk_dagang' => $dbConn->f("company_brand"), 'alamat_merk_dagang' => $dbConn->f("brand_address_name") . " " . $dbConn->f("brand_address_no"), 'pemilik' => $dbConn->f("company_owner"), 'alamat_pemilik' => $dbConn->f("address_name_owner") . " " . $dbConn->f("address_no_owner")); $json['items'] = $item; print_r($json); /*$myXMLData = "<?xml version='1.0' encoding='UTF-8'?> <pembayaran_wp> <npwd>".$dbConn->f("npwd")."</npwd> <payment_vat_amount>".$dbConn->f("payment_vat_amount")."</payment_vat_amount> <finance_period_code>".$dbConn->f("finance_period_code")."</finance_period_code> <merk_dagang>".$dbConn->f("company_brand")."</merk_dagang> <alamat_merk_dagang>".$dbConn->f("brand_address_name")." ".$dbConn->f("brand_address_no")."</alamat_merk_dagang> <pemilik>".$dbConn->f("company_owner")."</pemilik> <alamat_pemilik>".$dbConn->f("address_name_owner")." ".$dbConn->f("address_no_owner")."</alamat_pemilik> </pembayaran_wp>"; print_r($myXMLData);*/ } else { $json = array('items' => array(), 'message' => 'data tidak ditemukan', 'success' => 'fail'); /*$myXMLData =
include "../include/fpdf17/mc_table.php"; $t_customer_order_id = CCGetFromGet("t_customer_order_id", ""); //$t_customer_order_id = 67; //$dataArr = array(); // $dataBaru = array(); if (empty($t_customer_order_id)) { echo "data tidak ada"; exit; } $dbConn = new clsDBConnSIKP(); $query = "select b.vat_code,to_char(a.registration_date,'dd Mon yyyy') as registration_date_2,company_owner,a.* from t_vat_registration a \r\n\t\tleft join p_vat_type_dtl b on a.p_vat_type_dtl_id = b.p_vat_type_dtl_id\r\n\t\twhere t_customer_order_id = " . $t_customer_order_id; //echo $query;exit; $dbConn->query($query); $data = array(); while ($dbConn->next_record()) { $data = array('npwpd' => $dbConn->f("npwpd"), 'company_name' => $dbConn->f("company_owner"), 'company_brand' => $dbConn->f("company_brand"), 'brand_address_name' => $dbConn->f("brand_address_name") . ' ' . $dbConn->f("brand_address_no"), 'registration_date' => $dbConn->f("registration_date_2"), 'vat_code' => $dbConn->f("vat_code")); $dbConn->close(); } //print_r($data);exit; $_HEIGHT = 4; $_BORDER = 0; $_FONT = 'Times'; $_FONTSIZE = 10; $pdf = new PDF_MC_Table(); $size = $pdf->_getpagesize('Legal'); $size[1] = 6; $pdf->DefPageSize = $size; $pdf->CurPageSize = $size; $pdf->AddPage('L', array(200, 150)); //$pdf->AddPage('P',array(210,296)); $pdf->SetFont('helvetica', '', $_FONTSIZE);
function Page_BeforeShow(&$sender) { $Page_BeforeShow = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $t_customer_create_uname; //Compatibility //End Page_BeforeShow //Custom Code @529-2A29BDB7 // ------------------------- $generate = CCGetFromGet("generate"); $t_customer_id = CCGetFromGet("t_customer_id"); $result = ''; if ($generate == "yes" and !empty($t_customer_id)) { $dbConn = new clsDBConnSIKP(); $query = "SELECT * FROM f_create_uname_password_wp(" . $t_customer_id . ") as hasil"; $dbConn->query($query); while ($dbConn->next_record()) { $result = $dbConn->f("hasil"); } $dbConn->close(); print_r($result); exit; } // ------------------------- //End Custom Code //Close Page_BeforeShow @1-4BC230CD return $Page_BeforeShow; }
function PageCetak($data, $user) { $this->AliasNbPages(); $this->AddPage("P"); $encImageData = ''; $dbConn = new clsDBConnSIKP(); $query = "select f_encrypt_str('" . $data['registration_no'] . "') AS enc_data"; $dbConn->query($query); while ($dbConn->next_record()) { $encImageData = $dbConn->f("enc_data"); } $this->Image('../images/logo_pemda.png', 20, 10, 25, 25); $this->Image('http://' . $_SERVER['HTTP_HOST'] . '/mpd/include/qrcode/generate-qr.php?param=' . $encImageData, 165, 10, 25, 25, 'PNG'); $this->SetFont("Arial", "B", 12); $this->Cell($this->lengthCell, $this->height, "", "", 0, "C"); $this->Ln(); $this->Cell($this->lengthCell, $this->height, "NOTA VERIFIKASI KURANG BAYAR", "", 0, "C"); $this->Ln(); $this->Cell($this->lengthCell, $this->height, "BEA PEROLEHAN HAK ATAS TANAH DAN BANGUNAN", "", 0, "C"); $this->Ln(); $this->newLine(); $this->Cell($this->lengthCell, $this->height, "JENIS TRANSAKSI: " . strtoupper($data['doc_name']), "", 0, "C"); $this->Ln(); $this->Cell($this->lengthCell, $this->height, "NO REGISTRASI: " . strtoupper($data['registration_no']), "", 0, "C"); $this->newLine(); $this->newLine(); $lbody = $this->lengthCell / 20; $lbody1 = $lbody * 1; $lbody4 = $lbody * 4; $lbody10 = $lbody * 15; $this->barisBaru("A", "1 Nama Wajib Pajak", ": " . $data["wp_name"]); $this->barisBaru("", "2 NPWP", ": " . $data["npwp"]); $this->barisBaru("", "3 Alamat Wajib Pajak", ": " . $data["wp_address_name"]); $this->barisBaru("", "4 RT/RW", ": " . $data["wp_rt"] . "/" . $data["wp_rw"]); $this->barisBaru("", "5 Kelurahan/Desa", ": " . $data["wp_region_kel"]); $this->barisBaru("", "6 Kecamatan", ": " . $data["wp_region_kec"]); $this->barisBaru("", "7 Kabupaten/Kota", ": " . $data["wp_region"]); $this->Ln(); $this->barisBaru("B", "1 Nomor Objek Pajak PBB ", ": " . $data["njop_pbb"]); $this->barisBaru("", "2 Letak tanah atau bangunan", ": " . $data["object_address_name"]); $this->barisBaru("", "3 RT/RW", ": " . $data["object_rt"] . "/" . $data["object_rw"]); $this->barisBaru("", "4 Kelurahan/Desa", ": " . $data["object_region_kel"]); $this->barisBaru("", "5 Kecamatan", ": " . $data["object_region_kec"]); $this->barisBaru("", "6 Kabupaten/Kota", ": " . $data["object_region"]); $this->barisBaru("", "7 Dokumen Pendukung", ": " . $data["doc_name"]); $this->Ln(); $this->barisBaru("C", "Penghitungan NJOP PBB", ""); $lbodyx = ($this->lengthCell - $lbody1) / 9; $lbodyx1 = $lbodyx * 1; $lbodyx2 = $lbodyx * 2; $lbodyx3 = $lbodyx * 3; $this->Cell($lbody1, $this->height, "", "", 0, ""); $this->SetWidths(array($lbodyx1, $lbodyx2, $lbodyx3, $lbodyx3)); $this->SetAligns(array("C", "C", "C", "C")); $this->RowMultiBorderWithHeight(array("\nUraian", "Luas\n(Diisi luas tanah dan atau bangunan yang haknya diperoleh)", "NJOP PBB / m2\n(Diisi berdasarkan SPPT PBB tahun terjadinya perolehan hak / Tahun", "\nLuas x NJOP PBB / m2"), array("TBL", "TBR", "TBLR", "TBLR"), $this->height); $this->Cell($lbody1, $this->height, "", "", 0, ""); $this->Cell($lbodyx1, $this->height, "Tanah (bumi)", "L", 0, ""); $this->Cell($lbodyx1, $this->height, number_format($data["land_area"], 0, ",", "."), "", 0, "R"); $this->Cell($lbodyx1, $this->height, "m2", "R", 0, "L"); $this->Cell($lbodyx1, $this->height, "Rp", "", 0, "L"); $this->Cell($lbodyx1, $this->height, number_format($data["land_price_per_m"], 0, ",", "."), "", 0, "R"); $this->Cell($lbodyx1, $this->height, "", "R", 0, ""); $this->Cell($lbodyx1, $this->height, "Rp", "", 0, "L"); $this->Cell($lbodyx1, $this->height, number_format($data["land_total_price"], 0, ",", "."), "", 0, "R"); $this->Cell($lbodyx1, $this->height, "", "R", 0, ""); $this->Ln(); $this->Cell($lbody1, $this->height, "", "", 0, ""); $this->Cell($lbodyx1, $this->height, "Bangunan", "L", 0, ""); $this->Cell($lbodyx1, $this->height, number_format($data["building_area"], 0, ",", "."), "", 0, "R"); $this->Cell($lbodyx1, $this->height, "m2", "R", 0, "L"); $this->Cell($lbodyx1, $this->height, "Rp", "", 0, "L"); $this->Cell($lbodyx1, $this->height, number_format($data["building_price_per_m"], 0, ",", "."), "", 0, "R"); $this->Cell($lbodyx1, $this->height, "", "R", 0, ""); $this->Cell($lbodyx1, $this->height, "Rp", "", 0, "L"); $this->Cell($lbodyx1, $this->height, number_format($data["building_total_price"], 0, ",", "."), "", 0, "R"); $this->Cell($lbodyx1, $this->height, "", "R", 0, ""); $this->Ln(); $this->Cell($lbody1, $this->height, "", "", 0, ""); $this->Cell($lbodyx1, $this->height, "", "L", 0, ""); $this->Cell($lbodyx1, $this->height, "", "", 0, "R"); $this->Cell($lbodyx1, $this->height, "", "R", 0, "L"); $this->Cell($lbodyx1, $this->height, "", "", 0, "L"); $this->Cell($lbodyx1, $this->height, "", "", 0, "R"); $this->Cell($lbodyx1, $this->height, "NJOP PBB", "R", 0, "R"); $this->Cell($lbodyx1, $this->height, "Rp", "", 0, "L"); $this->Cell($lbodyx1, $this->height, number_format($data["land_total_price"] + $data["building_total_price"], 0, ",", "."), "", 0, "R"); $this->Cell($lbodyx1, $this->height, "", "R", 0, ""); $this->Ln(); $jenis_harga_bphtb = $data["jenis_harga_bphtb"]; if (empty($jenis_harga_bphtb)) { $jenis_harga_bphtb = 99; } $jenis_harga = array(1 => 'Harga Transaksi', 2 => 'Harga Pasar', 3 => 'Harga Lelang', 99 => 'Harga Pasar'); $this->Cell($lbody1, $this->height, "", "", 0, ""); $this->Cell($lbodyx1, $this->height, "", "BL", 0, ""); $this->Cell($lbodyx1, $this->height, "", "B", 0, "R"); $this->Cell($lbodyx1, $this->height, "", "BR", 0, "L"); $this->Cell($lbodyx1, $this->height, "", "B", 0, "L"); $this->Cell($lbodyx1 - 20, $this->height, "", "B", 0, "R"); $this->Cell($lbodyx1 + 20, $this->height, $jenis_harga[$jenis_harga_bphtb], "RB", 0, "R"); $this->Cell($lbodyx1, $this->height, "Rp", "B", 0, "L"); $this->Cell($lbodyx1, $this->height, number_format($data["market_price"], 0, ",", "."), "B", 0, "R"); $this->Cell($lbodyx1, $this->height, "", "BR", 0, ""); $this->Ln(); $this->Ln(); $this->Cell($lbody1, $this->height, "", "", 0, ""); $this->Cell($this->length - $lbody1, $this->height, "Jenis perolehan hak atas tanah dan atau bangunan", "", 0, ""); $this->Ln(); $this->Ln(); $this->Cell($lbody1, $this->height, "", "", 0, ""); $this->Cell($this->length - $lbody1, $this->height, "PENGHITUNGAN BPHTB", "", 0, ""); $this->Ln(); $this->barisBaru2($lbody1, "Nilai Perolehan Objek Pajak (NPOP)", "", "Rp", $data["npop"]); $this->barisBaru2($lbody1, "Nilai Perolehan Objek Pajak Tidak Kena Pajak (NPOPTKP)", "", "Rp", $data["npop_tkp"]); if ($data["npop_kp"] == 0) { $this->barisBaruStr($lbody1, "Nilai Perolehan Objek Pajak Kena Pajak (NPOPKP)", "", "Rp", "NIHIL"); } else { $this->barisBaru2($lbody1, "Nilai Perolehan Objek Pajak Kena Pajak (NPOPKP)", "", "Rp", $data["npop_kp"]); } if ($data["npop_kp"] == 0) { $this->barisBaruStr($lbody1, "Bea Perolehan Hak atas Tanah dan Bangunan yang terutang", "5%", "Rp", "NIHIL"); } else { $this->barisBaru2($lbody1, "Bea Perolehan Hak atas Tanah dan Bangunan yang terutang", "5%", "Rp", $data["bphtb_amt"]); } $this->barisBaru2($lbody1, "Bea Perolehan Hak atas Tanah dan Bangunan potongan", "", "Rp", $data["bphtb_discount"]); if ($data["npop_kp"] == 0) { $this->barisBaruStr($lbody1, "Bea Perolehan Hak atas Tanah dan Bangunan yang harus dibayar", "", "Rp", "NIHIL"); } else { $this->barisBaru2($lbody1, "Bea Perolehan Hak atas Tanah dan Bangunan yang harus dibayar", "", "Rp", $data["bphtb_amt_final_old"]); } $this->barisBaru2($lbody1, "Nilai Pajak Yang Sudah Dibayar", "", "Rp", $data["prev_payment_amount"]); $this->barisBaru2($lbody1, "Total Kekurangan Pembayaran", "", "Rp", $data["bphtb_amt_final"]); $this->newLine(); $lbody = $this->lengthCell / 4; $lbody1 = $lbody * 1; $lbody2 = $lbody * 2; $lbody3 = $lbody * 3; $this->SetFont("Arial", "i", 8); $this->Cell($lbody1 + 10, $this->height, " Keterangan: Nota ini bukan bukti pembayaran", "", 0, 'L'); $this->Ln(); //$this->Cell($lbody1 + 10, $this->height, " Catatan: ".$data["description"], "", 0, 'L'); $this->SetWidths(array(9, 150, $lbodyx2)); $this->SetAligns(array("L", "L")); $this->RowMultiBorderWithHeight(array("", "Catatan : " . $data["description"]), array("", ""), $this->height - 2); $this->SetFont("Arial", "B", 10); //$this->Ln(); $this->Cell($this->lengthCell, $this->height, "", "", 0, 'L'); $this->Cell($lbody1 - 103, $this->height, "Bandung, " . date("d-m-Y"), "", 0, 'C'); $this->Ln(); $this->Cell($lbody1 + 10, $this->height, "KOORDINATOR PEMERIKSA", "", 0, 'C'); $this->Cell($lbody3 - $lbody1 - 20, $this->height, "", "", 0, 'L'); $this->Cell($lbody1 + 10, $this->height, "PETUGAS PEMERIKSA", "", 0, 'C'); $this->Ln(); $this->Cell($lbody1 + 10, $this->height, "BPHTB", "", 0, 'C'); $this->Cell($lbody3 - $lbody1 - 20, $this->height, "", "", 0, 'L'); $this->Cell($lbody1 + 10, $this->height, "BPHTB", "", 0, 'C'); $this->Ln(); $this->Cell($lbody3 - 10, $this->height, "", "", 0, 'L'); $this->Ln(); $this->newLine(); //$this->Cell($lbody3 - 10, $this->height, "", "", 0, 'L'); //$this->Cell($lbody1 + 10, $this->height, "(....................................)", "", 0, 'C'); $this->Cell($lbody1 + 10, $this->height - 4, "(ZAENAL MANSUR)", "", 0, 'C'); $this->Cell(202, $this->height - 4, "( " . $data['verificated_by'] . " )", "", 0, 'C'); $this->newLine(); $this->Cell($lbody1 + 10, $this->height - 4, "NIP : 19630817.1989.01.1.006 ", "", 0, 'C'); $this->Cell(202, $this->height - 4, "NIP : " . $data['verificated_nip'] . " ", "", 0, 'C'); }
function GetCetakExcel($data, $data2, $data3, $user, $tgl_penerimaan) { startExcel("laporan_target_vs_realisasi_perbandingan.xls"); $output = ''; $output .= '<table> <tr>'; $output = '<table id="table-piutang" class="grid-table-container" border="0" cellspacing="0" cellpadding="0" width="100%"> <tr> <td valign="top"> <table class="grid-table" border="0" cellspacing="0" cellpadding="0"> <tr> <td class="th" colspan=11 align="center"><strong>TARGET DAN REALISASI PERBANDINGAN</strong></td> </tr> <tr> <td class="th" colspan=11 align="center"><strong>SAMPAI TANGGAL ' . $tgl_penerimaan . '</strong></td> </tr> <tr> </tr> </table> <table id="table-piutang-detil" class="Grid" border="1" cellspacing="0" cellpadding="3px"> <tr class="Caption">'; $tahun = substr($tgl_penerimaan, 6, 4); $tgl_penerimaan2 = substr($tgl_penerimaan, 0, 6) . ($tahun - 1); $tgl_penerimaan3 = substr($tgl_penerimaan, 0, 6) . ($tahun - 2); $output .= '<th rowspan=2 style="text-align:center;">NO</th>'; $output .= '<th rowspan=2 style="text-align:center;">JENIS PAJAK</th>'; $output .= '<th colspan=3 style="text-align:center;">' . ($tahun - 2) . '</th>'; $output .= '<th colspan=3 style="text-align:center;">' . ($tahun - 1) . '</th>'; $output .= '<th colspan=3 style="text-align:center;">' . $tahun . '</th></tr>'; $output .= '<tr class="Caption"><th style="text-align:center;">TARGET</th>'; $output .= '<th style="text-align:center;">REALISASI</th>'; $output .= '<th style="text-align:center;">% REAL</th>'; $output .= '<th style="text-align:center;">TARGET</th>'; $output .= '<th style="text-align:center;">REALISASI</th>'; $output .= '<th style="text-align:center;">% REAL</th>'; $output .= '<th style="text-align:center;">TARGET</th>'; $output .= '<th style="text-align:center;">REALISASI</th>'; $output .= '<th style="text-align:center;">% REAL</th>'; $output .= '</tr>'; $no = 1; $total_target = 0; $total_realisasi = 0; $total_target2 = 0; $total_realisasi2 = 0; $total_target3 = 0; $total_realisasi3 = 0; $bulan = substr($tgl_penerimaan, 3, 2); for ($i = 0; $i < count($data['nama_jns_pajak']); $i++) { //print data $query = "select sum(target_amt)as target \r\n\t\t\t\t\tfrom t_revenue_target_dtl where t_revenue_target_id = \r\n\t\t\t\t\t(select t_revenue_target_id from t_revenue_target\r\n\t\t\t\t\t where p_vat_type_id = " . $data['p_vat_type_id'][$i] . "\r\n\t\t\t\t\t\tand p_year_period_id =\r\n\t\t\t\t\t\t\t(select p_year_period_id from p_year_period \r\n\t\t\t\t\t\t\twhere to_date('" . $tgl_penerimaan . "','dd-mm-yyyy') BETWEEN start_date and end_date\r\n\t\t\t\t\t\t\t)\r\n\t\t\t\t\t)"; //echo $query;exit; $dbConn = new clsDBConnSIKP(); $dbConn->query($query); $dbConn->next_record(); $target = $dbConn->f('target'); $query = "select sum(target_amt)as target \r\n\t\t\t\t\tfrom t_revenue_target_dtl where t_revenue_target_id = \r\n\t\t\t\t\t(select t_revenue_target_id from t_revenue_target\r\n\t\t\t\t\t where p_vat_type_id = " . $data['p_vat_type_id'][$i] . "\r\n\t\t\t\t\t\tand p_year_period_id =\r\n\t\t\t\t\t\t\t(select p_year_period_id from p_year_period \r\n\t\t\t\t\t\t\twhere to_date('" . $tgl_penerimaan2 . "','dd-mm-yyyy') BETWEEN start_date and end_date\r\n\t\t\t\t\t\t\t)\r\n\t\t\t\t\t)"; $dbConn->query($query); $dbConn->next_record(); $target2 = $dbConn->f('target'); $query = "select sum(target_amt)as target \r\n\t\t\t\t\tfrom t_revenue_target_dtl where t_revenue_target_id = \r\n\t\t\t\t\t(select t_revenue_target_id from t_revenue_target\r\n\t\t\t\t\t where p_vat_type_id = " . $data['p_vat_type_id'][$i] . "\r\n\t\t\t\t\t\tand p_year_period_id =\r\n\t\t\t\t\t\t\t(select p_year_period_id from p_year_period \r\n\t\t\t\t\t\t\twhere to_date('" . $tgl_penerimaan3 . "','dd-mm-yyyy') BETWEEN start_date and end_date\r\n\t\t\t\t\t\t\t)\r\n\t\t\t\t\t)"; $dbConn->query($query); $dbConn->next_record(); $target3 = $dbConn->f('target'); $output .= '<tr>'; $output .= '<td style="font-weight:bold;" align="left">' . $no . '</td>'; $output .= '<td style="font-weight:bold;" align="left">' . strtoupper($data["nama_jns_pajak"][$i]) . '</td>'; $output .= '<td style="font-weight:bold;" align="right">' . number_format($target3, 0, ',', '.') . '</td>'; $output .= '<td style="font-weight:bold;" align="right">' . number_format($data3["realisasi"][$i], 0, ',', '.') . '</td>'; $output .= '<td style="font-weight:bold;" align="right">' . number_format($data3["realisasi"][$i] / $target3 * 100, 2, ',', '.') . ' %</td>'; $output .= '<td style="font-weight:bold;" align="right">' . number_format($target2, 0, ',', '.') . '</td>'; $output .= '<td style="font-weight:bold;" align="right">' . number_format($data2["realisasi"][$i], 0, ',', '.') . '</td>'; $output .= '<td style="font-weight:bold;" align="right">' . number_format($data2["realisasi"][$i] / $target2 * 100, 2, ',', '.') . ' %</td>'; $output .= '<td style="font-weight:bold;" align="right">' . number_format($target, 0, ',', '.') . '</td>'; $output .= '<td style="font-weight:bold;" align="right">' . number_format($data["realisasi"][$i], 0, ',', '.') . '</td>'; $output .= '<td style="font-weight:bold;" align="right">' . number_format($data["realisasi"][$i] / $target * 100, 2, ',', '.') . ' %</td>'; $output .= '</tr>'; $no++; $total_target += $target; $total_realisasi += $data["realisasi"][$i]; $total_target2 += $target2; $total_realisasi2 += $data2["realisasi"][$i]; $total_target3 += $target3; $total_realisasi3 += $data3["realisasi"][$i]; } $output .= '<tr>'; $output .= '<td style="font-weight:bold;" align="left"></td>'; $output .= '<td style="font-weight:bold;" align="left">JUMLAH</td>'; $output .= '<td style="font-weight:bold;" align="right">' . number_format($total_target3, 0, ',', '.') . '</td>'; $output .= '<td style="font-weight:bold;" align="right">' . number_format($total_realisasi3, 0, ',', '.') . '</td>'; $output .= '<td style="font-weight:bold;" align="right">' . number_format($total_realisasi3 / $total_target3 * 100, 2, ',', '.') . ' %</td>'; $output .= '<td style="font-weight:bold;" align="right">' . number_format($total_target2, 0, ',', '.') . '</td>'; $output .= '<td style="font-weight:bold;" align="right">' . number_format($total_realisasi2, 0, ',', '.') . '</td>'; $output .= '<td style="font-weight:bold;" align="right">' . number_format($total_realisasi2 / $total_target2 * 100, 2, ',', '.') . ' %</td>'; $output .= '<td style="font-weight:bold;" align="right">' . number_format($total_target, 0, ',', '.') . '</td>'; $output .= '<td style="font-weight:bold;" align="right">' . number_format($total_realisasi, 0, ',', '.') . '</td>'; $output .= '<td style="font-weight:bold;" align="right">' . number_format($total_realisasi / $total_target * 100, 2, ',', '.') . ' %</td>'; $output .= '</tr>'; $output .= '</table></table>'; echo $output; exit; }