function Header_BeforeShow() { //Header_BeforeShow @1-86E61FAE //Custom Code @22-2A29BDB7 global $now; global $accounting; global $regcharges; global $Tpl; include "../Version.php"; $Tpl->SetVar("versions", $ItechclVersion); $Tpl->SetVar("sitename", $now["sitename"]); $Tpl->SetVar("siteemail", $now["siteemail"]); $Tpl->SetVar("homeurl", $now["homeurl"]); $Tpl->SetVar("secureurl", $now["secureurl"]); $Tpl->SetVar("notifyemail", $now["notifyemail"]); $Tpl->SetVar("paypal", $accounting["paypal"]); $Tpl->SetVar("listing_fee", $regcharges["listing_fee"]); $Tpl->SetVar("homepage_fee", $regcharges["home_fee"]); $Tpl->SetVar("category_fee", $regcharges["cat_fee"]); $Tpl->SetVar("gallery_fee", $regcharges["gallery_fee"]); $Tpl->SetVar("image_preview_fee", $regcharges["image_pre_fee"]); $Tpl->SetVar("slide_fee", $regcharges["slide_fee"]); $Tpl->SetVar("counter_fee", $regcharges["counter_fee"]); $Tpl->SetVar("bold_fee", $regcharges["bold_fee"]); $Tpl->SetVar("highlight_fee", $regcharges["high_fee"]); $Tpl->SetVar("upload_fee", $regcharges["upload_fee"]); $Tpl->SetVar("make_offer_image", $images["make_offer_image"]); $Tpl->SetVar("currency", $regcharges["currency"]); $Tpl->SetVar("AdminName", CCGetUserLogin()); //End Custom Code }
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 Initialize() { if (!$this->Visible) { return; } $this->DataSource->Parameters["expr30"] = CCGetUserLogin(); }
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 Page_BeforeShow(&$sender) { $Page_BeforeShow = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $t_rep_lap_harian; //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'; $kode_bank = CCGetFromGet("kode_bank", ""); // $tgl_penerimaan = '15-12-2013'; $user = CCGetUserLogin(); $data = array(); $dbConn = new clsDBConnSIKP(); $query = "select * from f_rep_lap_harian_bdhr_mod_2('{$tgl_penerimaan}','{$kode_bank}') order by nomor_ayat"; $tgl_penerimaan = str_replace("'", "", $tgl_penerimaan); $dbConn->query($query); while ($dbConn->next_record()) { $data["nomor_ayat"][] = $dbConn->f("nomor_ayat"); $data["nama_ayat"][] = $dbConn->f("nama_ayat"); $data["nama_jns_pajak"][] = $dbConn->f("nama_jns_pajak"); $data["kode_jns_pajak"][] = $dbConn->f("kode_jns_pajak"); $data["jns_pajak"][] = $dbConn->f("jns_pajak"); $data["type_ayat"][] = $dbConn->f("type_ayat"); $data["p_vat_type_id"][] = $dbConn->f("p_vat_type_id"); $data["p_vat_type_dtl_id"][] = $dbConn->f("p_vat_type_dtl_id"); $data["bulan"][] = $dbConn->f("bulan"); $data["tahun"][] = $dbConn->f("tahun"); $data["jml_hari_ini"][] = $dbConn->f("jml_hari_ini"); $data["jml_sd_hari_lalu"][] = $dbConn->f("jml_sd_hari_lalu"); $data["jml_sd_hari_ini"][] = $dbConn->f("jml_sd_hari_ini"); $data["jml_transaksi"][] = $dbConn->f("jml_transaksi"); $data["jml_transaksi_sampai_kemarin"][] = $dbConn->f("jml_transaksi_sampai_kemarin"); $data["jml_transaksi_sampai_hari_ini"][] = $dbConn->f("jml_transaksi_sampai_hari_ini"); } $dbConn->close(); $Label1->SetText(PageCetak($data, $user, $tgl_penerimaan)); } // ------------------------- //End Custom Code //Close Page_BeforeShow @1-4BC230CD return $Page_BeforeShow; }
function Page_BeforeShow(&$sender) { $Page_BeforeShow = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $t_rep_lap_bpps_piutang2; //Compatibility //End Page_BeforeShow global $Label1; // ------------------------- // Write your own code here. $doAction = CCGetFromGet('doAction', ''); if ($doAction != '') { $p_vat_type_id = CCGetFromGet("p_vat_type_id", ""); $p_year_period_id = CCGetFromGet("p_year_period_id", ""); $tgl_penerimaan = CCGetFromGet("tgl_penerimaan", ""); $tgl_penerimaan_last = CCGetFromGet("tgl_penerimaan_last", ""); $year_code = CCGetFromGet("year_code", ""); $kode_wilayah = CCGetFromGet("kode_wilayah", ""); $tgl_penerimaan = "'" . $tgl_penerimaan . "'"; $tgl_penerimaan_last = "'" . $tgl_penerimaan_last . "'"; $kode_wilayah = "'" . $kode_wilayah . "'"; $date_start = str_replace("'", "", $year_code); $year_date = $year_code; $user = CCGetUserLogin(); $data = array(); $dbConn = new clsDBConnSIKP(); $jenis_laporan = CCGetFromGet("jenis_laporan", "all"); $query = "select to_char(active_date,'dd-mm-yyyy') as active_date2,*,\r\n\t\t\tcase \r\n\t\t\t\twhen payment_date is not null then to_char(payment_date,'dd-mm-yyyy')\r\n\t\t\t\telse ''\r\n\t\t\tend as payment_date \r\n\t\tfrom f_rep_bpps_piutang2new_mod_2_per_wilayah({$p_vat_type_id}, {$p_year_period_id}, {$tgl_penerimaan}, {$tgl_penerimaan_last}, 1,{$kode_wilayah}) a\r\n\t\tleft join t_cust_account x on a.npwpd = x.npwd \r\n\t\torder by kode_ayat, npwpd, masa_pajak"; //echo $query; exit; $dbConn->query($query); $tgl_penerimaan = str_replace("'", "", $tgl_penerimaan); $tgl_penerimaan_last = str_replace("'", "", $tgl_penerimaan_last); $tahun = date("Y", strtotime($tgl_penerimaan)); while ($dbConn->next_record()) { $data[] = array("address" => $dbConn->f("address"), "company_name" => $dbConn->f("company_name"), "kode_jns_trans" => $dbConn->f("kode_jns_trans"), "jns_trans" => $dbConn->f("jns_trans"), "kode_jns_pajak" => $dbConn->f("kode_jns_pajak"), "kode_ayat" => $dbConn->f("kode_ayat"), "jns_pajak" => $dbConn->f("jns_pajak"), "jns_ayat" => $dbConn->f("jns_ayat"), "nama_ayat" => $dbConn->f("nama_ayat"), "no_kohir" => $dbConn->f("no_kohir"), "wp_name" => $dbConn->f("company_brand"), "wp_address_name" => $dbConn->f("brand_address_name"), "wp_address_no" => $dbConn->f("brand_address_no"), "active_date2" => $dbConn->f("active_date2"), "npwpd" => $dbConn->f("npwpd"), "jumlah_terima" => $dbConn->f("jumlah_terima"), "masa_pajak" => $dbConn->f("masa_pajak"), "kd_tap" => $dbConn->f("kd_tap"), "keterangan" => $dbConn->f("keterangan"), "payment_date" => $dbConn->f("payment_date"), "jam" => $dbConn->f("jam")); } } if ($doAction == 'view_html2') { $Label1->SetText(GetCetakHTML2($data)); } if ($doAction == 'view_excel') { GetCetakHTML2($data); } // ------------------------- //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 Page_BeforeShow(&$sender) { $Page_BeforeShow = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $t_rep_lap_harian_v2; //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 = '15-12-2013'; $user = CCGetUserLogin(); $data = array(); $dbConn = new clsDBConnSIKP(); $tgl_penerimaan = str_replace("'", "", $tgl_penerimaan); $query = " \r\n\t\t\t\tselect\r\n\t\t\t\t\tnama_jns_pajak,sum(jml_sd_hari_ini) as realisasi,p_vat_type_id \r\n\t\t\t\tfrom f_rep_lap_harian_bdhr_mod_1('" . $tgl_penerimaan . "') \r\n\t\t\t\twhere p_vat_type_id in (1,2,3,4,5,6)\r\n\t\t\t\tGROUP BY nama_jns_pajak,p_vat_type_id\r\n\t\t\t\tORDER BY p_vat_type_id"; //echo $query;exit; $tgl_penerimaan = str_replace("'", "", $tgl_penerimaan); $dbConn->query($query); while ($dbConn->next_record()) { $data['nama_jns_pajak'][] = $dbConn->f('nama_jns_pajak'); $data['realisasi'][] = $dbConn->f('realisasi'); $data['p_vat_type_id'][] = $dbConn->f('p_vat_type_id'); } $dbConn->close(); $excel = CCGetFromGet('excel'); if ($excel == 'T') { GetCetakExcel($data, $user, $tgl_penerimaan); } else { $Label1->SetText(PageCetak($data, $user, $tgl_penerimaan)); } } // ------------------------- //End Custom Code //Close Page_BeforeShow @1-4BC230CD return $Page_BeforeShow; }
function Page_BeforeShow(&$sender) { $Page_BeforeShow = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $t_rep_lap_bpps_piutang2; //Compatibility //End Page_BeforeShow global $Label1; // ------------------------- // Write your own code here. $doAction = CCGetFromGet('doAction'); if ($doAction == 'view_html') { $p_vat_type_id = CCGetFromGet("p_vat_type_id", ""); //$year_code = CCGetFromGet("year_code", ""); $tgl_penerimaan = "'01-01-2010'"; $tgl_penerimaan_last = "'31-12-2014'"; $i_flag_setoran = 1; $p_year_period_id = 4; //year_period_id 4 = 2013 //year_period_id 16 = 2014 $date_start = str_replace("'", "", $year_code); //$year_date = DateTime::createFromFormat('d-m-Y', $date_start)->format('Y'); $year_date = $year_code; $user = CCGetUserLogin(); $data = array(); $dbConn = new clsDBConnSIKP(); $jenis_laporan = "all"; $query = "select *,trunc(payment_date) \r\n\t\t\tfrom f_rep_bpps_piutang2new_rm_masuk_resto({$p_vat_type_id}, {$p_year_period_id}, {$tgl_penerimaan}, to_char(sysdate,'dd-mm-yyyy'), {$i_flag_setoran}) \r\n\t\t\torder by p_vat_type_dtl_id, wp_name,npwpd, payment_date"; //echo $query; exit; $dbConn->query($query); $tgl_penerimaan = str_replace("'", "", $tgl_penerimaan); $tgl_penerimaan_last = str_replace("'", "", $tgl_penerimaan_last); $tahun = date("Y", strtotime($tgl_penerimaan)); while ($dbConn->next_record()) { $data[] = array("address" => $dbConn->f("address"), "company_name" => $dbConn->f("company_name"), "kode_jns_trans" => $dbConn->f("kode_jns_trans"), "jns_trans" => $dbConn->f("jns_trans"), "kode_jns_pajak" => $dbConn->f("kode_jns_pajak"), "kode_ayat" => $dbConn->f("kode_ayat"), "jns_pajak" => $dbConn->f("jns_pajak"), "jns_ayat" => $dbConn->f("jns_ayat"), "nama_ayat" => $dbConn->f("nama_ayat"), "no_kohir" => $dbConn->f("no_kohir"), "wp_name" => $dbConn->f("wp_name"), "wp_address_name" => $dbConn->f("wp_address_name"), "wp_address_no" => $dbConn->f("wp_address_no"), "npwpd" => $dbConn->f("npwpd"), "jumlah_terima" => $dbConn->f("jumlah_terima"), "masa_pajak" => $dbConn->f("masa_pajak"), "kd_tap" => $dbConn->f("kd_tap"), "keterangan" => $dbConn->f("keterangan"), "payment_date" => $dbConn->f("payment_date"), "jam" => $dbConn->f("jam")); } $dbConn->close(); $Label1->SetText(GetCetakHTML($data)); } // ------------------------- //Close Page_BeforeShow @1-4BC230CD return $Page_BeforeShow; }
function Page_BeforeShow(&$sender) { $Page_BeforeShow = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $t_bphtb_registration_list_check_date; //Compatibility //End Page_BeforeShow //Custom Code @703-2A29BDB7 // ------------------------- // Write your own code here. global $Label1; if (CCGetFromGet("doAction") == "html") { $s_keyword = CCGetFromGet("s_keyword", ""); $date_start_laporan = CCGetFromGet("date_start_laporan", ""); $date_end_laporan = CCGetFromGet("date_end_laporan", ""); $user = CCGetUserLogin(); $data = array(); $dbConn = new clsDBConnSIKP(); $query = "SELECT * FROM t_payment_receipt_bphtb x\r\n\t\t\tLEFT JOIN t_bphtb_registration y ON y.t_bphtb_registration_id = x.t_bphtb_registration_id\r\n\t\t\tLEFT JOIN t_customer_order z ON y.t_customer_order_id = z.t_customer_order_id\r\n\t\t\tWHERE\r\n\t\t\t\tcheck_date IS NOT NULL\r\n\t\t\tAND wp_name ILIKE '%{$s_keyword}%'"; if ($date_end_laporan != "" && $date_start_laporan != "") { $query .= "AND(check_date BETWEEN to_date ('{$date_start_laporan}') AND ('{$date_end_laporan}'))"; } else { if ($date_end_laporan != "") { $query .= "AND(check_date <= to_date ('{$date_end_laporan}') )"; } if ($date_start_laporan != "") { $query .= "AND(check_date >= to_date ('{$date_start_laporan}') )"; } } $dbConn->query($query); while ($dbConn->next_record()) { $data[] = array("wp_name" => $dbConn->f("wp_name"), "order_no" => $dbConn->f("order_no"), "receipt_no" => $dbConn->f("receipt_no"), "check_date" => $dbConn->f("check_date"), "wp_address_name" => $dbConn->f("wp_address_name"), "t_payment_receipt_id" => $dbConn->f("t_payment_receipt_id"), "t_bphtb_registration_id" => $dbConn->f("t_bphtb_registration_id"), "bphtb_registration_no" => $dbConn->f("bphtb_registration_no"), "t_customer_order_id" => $dbConn->f("t_customer_order_id"), "payment_date" => $dbConn->f("payment_date"), "payment_vat_amount" => $dbConn->f("payment_vat_amount")); } $dbConn->close(); $Label1->SetText(GetCetakHTML($data)); } // ------------------------- //End Custom Code //Close Page_BeforeShow @1-4BC230CD return $Page_BeforeShow; }
function MasterPage_OnInitializeView(&$sender) { $MasterPage_OnInitializeView = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $MasterPage; //Compatibility //End MasterPage_OnInitializeView //Custom Code @8-2A29BDB7 // ------------------------- // Write your own code here. if (CCGetUserLogin() == "") { header("Location: login.php"); exit; } // ------------------------- //End Custom Code //Close MasterPage_OnInitializeView @1-CF24638A return $MasterPage_OnInitializeView; }
function t_vat_registrationForm_Button7_OnClick(&$sender) { $t_vat_registrationForm_Button7_OnClick = true; $Component =& $sender; $Container =& CCGetParentContainer($sender); global $t_vat_registrationForm; //Compatibility //End t_vat_registrationForm_Button7_OnClick $sql = "select f_update_acc_status(" . $t_vat_registrationForm->t_cust_account_id->Value . ",3,'TUTUP SEMENTARA POSISI PIUTANG',sysdate, '" . CCGetUserLogin() . "')"; $dbConn = new clsDBConnSIKP(); if ($dbConn->query($sql)) { $dbConn->next_record(); if ($dbConn->Record['o_result_msg'] != 'OK') { $t_vat_registrationForm->Errors->addError($dbConn->Record['o_result_msg']); } } else { $t_vat_registrationForm->Errors->addError('Gagal update status'); } //Close t_vat_registrationForm_Button7_OnClick @961-41E34245 return $t_vat_registrationForm_Button7_OnClick; }
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 Update() { global $CCSLocales; global $DefaultDateFormat; $this->CmdExecution = true; $this->cp["p_vat_type_id"] = new clsSQLParameter("ctrlp_vat_type_id", ccsFloat, "", "", $this->p_vat_type_id->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["registration_date"] = new clsSQLParameter("ctrlregistration_date", ccsText, "", "", $this->registration_date->GetValue(true), "", false, $this->ErrorBlock); $this->cp["company_name"] = new clsSQLParameter("ctrlcompany_name", ccsText, "", "", $this->company_name->GetValue(true), "", false, $this->ErrorBlock); $this->cp["company_brand"] = new clsSQLParameter("ctrlcompany_brand", ccsText, "", "", $this->company_brand->GetValue(true), "", false, $this->ErrorBlock); $this->cp["address_no"] = new clsSQLParameter("ctrladdress_no", ccsText, "", "", $this->address_no->GetValue(true), "", false, $this->ErrorBlock); $this->cp["address_name"] = new clsSQLParameter("ctrladdress_name", ccsText, "", "", $this->address_name->GetValue(true), "", false, $this->ErrorBlock); $this->cp["address_rt"] = new clsSQLParameter("ctrladdress_rt", ccsText, "", "", $this->address_rt->GetValue(true), "", false, $this->ErrorBlock); $this->cp["address_rw"] = new clsSQLParameter("ctrladdress_rw", ccsText, "", "", $this->address_rw->GetValue(true), "", false, $this->ErrorBlock); $this->cp["p_region_id_kelurahan"] = new clsSQLParameter("ctrlp_region_id_kelurahan", ccsText, "", "", $this->p_region_id_kelurahan->GetValue(true), "", false, $this->ErrorBlock); $this->cp["p_region_id_kecamatan"] = new clsSQLParameter("ctrlp_region_id_kecamatan", ccsText, "", "", $this->p_region_id_kecamatan->GetValue(true), "", false, $this->ErrorBlock); $this->cp["p_region_id"] = new clsSQLParameter("ctrlp_region_id", ccsText, "", "", $this->p_region_id->GetValue(true), "", false, $this->ErrorBlock); $this->cp["phone_no"] = new clsSQLParameter("ctrlphone_no", ccsText, "", "", $this->phone_no->GetValue(true), "", false, $this->ErrorBlock); $this->cp["mobile_no"] = new clsSQLParameter("ctrlmobile_no", ccsText, "", "", $this->mobile_no->GetValue(true), "", false, $this->ErrorBlock); $this->cp["fax_no"] = new clsSQLParameter("ctrlfax_no", ccsText, "", "", $this->fax_no->GetValue(true), "", false, $this->ErrorBlock); $this->cp["zip_code"] = new clsSQLParameter("ctrlzip_code", ccsText, "", "", $this->zip_code->GetValue(true), "", false, $this->ErrorBlock); $this->cp["updated_by"] = new clsSQLParameter("ctrlupdated_by", ccsText, "", "", $this->updated_by->GetValue(true), "", false, $this->ErrorBlock); $this->cp["t_cust_account_id"] = new clsSQLParameter("ctrlt_cust_account_id", ccsText, "", "", $this->t_cust_account_id->GetValue(true), "", false, $this->ErrorBlock); $this->cp["npwd"] = new clsSQLParameter("ctrlnpwd", ccsText, "", "", $this->npwd->GetValue(true), "", false, $this->ErrorBlock); $this->cp["wp_name"] = new clsSQLParameter("ctrlwp_name", ccsText, "", "", $this->wp_name->GetValue(true), "", false, $this->ErrorBlock); $this->cp["wp_address_name"] = new clsSQLParameter("ctrlwp_address_name", ccsText, "", "", $this->wp_address_name->GetValue(true), "", false, $this->ErrorBlock); $this->cp["wp_address_no"] = new clsSQLParameter("ctrlwp_address_no", ccsText, "", "", $this->wp_address_no->GetValue(true), "", false, $this->ErrorBlock); $this->cp["wp_address_rt"] = new clsSQLParameter("ctrlwp_address_rt", ccsText, "", "", $this->wp_address_rt->GetValue(true), "", false, $this->ErrorBlock); $this->cp["wp_address_rw"] = new clsSQLParameter("ctrlwp_address_rw", ccsText, "", "", $this->wp_address_rw->GetValue(true), "", false, $this->ErrorBlock); $this->cp["wp_p_region_id_kelurahan"] = new clsSQLParameter("ctrlwp_p_region_id_kelurahan", ccsFloat, "", "", $this->wp_p_region_id_kelurahan->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["wp_p_region_id_kecamatan"] = new clsSQLParameter("ctrlwp_p_region_id_kecamatan", ccsFloat, "", "", $this->wp_p_region_id_kecamatan->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["wp_p_region_id"] = new clsSQLParameter("ctrlwp_p_region_id", ccsFloat, "", "", $this->wp_p_region_id->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["wp_phone_no"] = new clsSQLParameter("ctrlwp_phone_no", ccsText, "", "", $this->wp_phone_no->GetValue(true), "", false, $this->ErrorBlock); $this->cp["wp_mobile_no"] = new clsSQLParameter("ctrlwp_mobile_no", ccsText, "", "", $this->wp_mobile_no->GetValue(true), "", false, $this->ErrorBlock); $this->cp["wp_fax_no"] = new clsSQLParameter("ctrlwp_fax_no", ccsText, "", "", $this->wp_fax_no->GetValue(true), "", false, $this->ErrorBlock); $this->cp["wp_zip_code"] = new clsSQLParameter("ctrlwp_zip_code", ccsText, "", "", $this->wp_zip_code->GetValue(true), "", false, $this->ErrorBlock); $this->cp["wp_email"] = new clsSQLParameter("ctrlwp_email", ccsText, "", "", $this->wp_email->GetValue(true), "", false, $this->ErrorBlock); $this->cp["brand_address_name"] = new clsSQLParameter("ctrlbrand_address_name", ccsText, "", "", $this->brand_address_name->GetValue(true), "", false, $this->ErrorBlock); $this->cp["brand_address_no"] = new clsSQLParameter("ctrlbrand_address_no", ccsText, "", "", $this->brand_address_no->GetValue(true), "", false, $this->ErrorBlock); $this->cp["brand_address_rt"] = new clsSQLParameter("ctrlbrand_address_rt", ccsText, "", "", $this->brand_address_rt->GetValue(true), "", false, $this->ErrorBlock); $this->cp["brand_address_rw"] = new clsSQLParameter("ctrlbrand_address_rw", ccsText, "", "", $this->brand_address_rw->GetValue(true), "", false, $this->ErrorBlock); $this->cp["brand_p_region_id_kel"] = new clsSQLParameter("ctrlbrand_p_region_id_kel", ccsFloat, "", "", $this->brand_p_region_id_kel->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["brand_p_region_id_kec"] = new clsSQLParameter("ctrlbrand_p_region_id_kec", ccsFloat, "", "", $this->brand_p_region_id_kec->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["brand_p_region_id"] = new clsSQLParameter("ctrlbrand_p_region_id", ccsFloat, "", "", $this->brand_p_region_id->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["brand_phone_no"] = new clsSQLParameter("ctrlbrand_phone_no", ccsText, "", "", $this->brand_phone_no->GetValue(true), "", false, $this->ErrorBlock); $this->cp["brand_mobile_no"] = new clsSQLParameter("ctrlbrand_mobile_no", ccsText, "", "", $this->brand_mobile_no->GetValue(true), "", false, $this->ErrorBlock); $this->cp["brand_fax_no"] = new clsSQLParameter("ctrlbrand_fax_no", ccsText, "", "", $this->brand_fax_no->GetValue(true), "", false, $this->ErrorBlock); $this->cp["brand_zip_code"] = new clsSQLParameter("ctrlbrand_zip_code", ccsText, "", "", $this->brand_zip_code->GetValue(true), "", false, $this->ErrorBlock); $this->cp["p_account_status_id"] = new clsSQLParameter("ctrlp_account_status_id", ccsFloat, "", "", $this->p_account_status_id->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["activation_no"] = new clsSQLParameter("ctrlactivation_no", ccsText, "", "", $this->activation_no->GetValue(true), "", false, $this->ErrorBlock); $this->cp["p_vat_type_dtl_id"] = new clsSQLParameter("ctrlp_vat_type_dtl_id", ccsFloat, "", "", $this->p_vat_type_dtl_id->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["modification_by"] = new clsSQLParameter("expr651", ccsText, "", "", CCGetUserLogin(), "", false, $this->ErrorBlock); $this->cp["company_owner"] = new clsSQLParameter("ctrlcompany_owner", ccsText, "", "", $this->company_owner->GetValue(true), "", false, $this->ErrorBlock); $this->cp["p_job_position_id"] = new clsSQLParameter("ctrlp_job_position_id", ccsInteger, "", "", $this->p_job_position_id->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["address_name_owner"] = new clsSQLParameter("ctrladdress_name_owner", ccsText, "", "", $this->address_name_owner->GetValue(true), "", false, $this->ErrorBlock); $this->cp["address_no_owner"] = new clsSQLParameter("ctrladdress_no_owner", ccsText, "", "", $this->address_no_owner->GetValue(true), "", false, $this->ErrorBlock); $this->cp["address_rt_owner"] = new clsSQLParameter("ctrladdress_rt_owner", ccsText, "", "", $this->address_rt_owner->GetValue(true), "", false, $this->ErrorBlock); $this->cp["address_rw_owner"] = new clsSQLParameter("ctrladdress_rw_owner", ccsText, "", "", $this->address_rw_owner->GetValue(true), "", false, $this->ErrorBlock); $this->cp["p_region_id_owner"] = new clsSQLParameter("ctrlp_region_id_owner", ccsInteger, "", "", $this->p_region_id_owner->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["p_region_id_kec_owner"] = new clsSQLParameter("ctrlp_region_id_kec_owner", ccsInteger, "", "", $this->p_region_id_kec_owner->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["p_region_id_kel_owner"] = new clsSQLParameter("ctrlp_region_id_kel_owner", ccsInteger, "", "", $this->p_region_id_kel_owner->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["phone_no_owner"] = new clsSQLParameter("ctrlphone_no_owner", ccsText, "", "", $this->phone_no_owner->GetValue(true), "", false, $this->ErrorBlock); $this->cp["fax_no_owner"] = new clsSQLParameter("ctrlfax_no_owner", ccsText, "", "", $this->fax_no_owner->GetValue(true), "", false, $this->ErrorBlock); $this->cp["mobile_no_owner"] = new clsSQLParameter("ctrlmobile_no_owner", ccsText, "", "", $this->mobile_no_owner->GetValue(true), "", false, $this->ErrorBlock); $this->cp["email_address"] = new clsSQLParameter("ctrlemail_address", ccsText, "", "", $this->email_address->GetValue(true), "", false, $this->ErrorBlock); $this->cp["zip_code_owner"] = new clsSQLParameter("ctrlzip_code_owner", ccsText, "", "", $this->zip_code_owner->GetValue(true), "", false, $this->ErrorBlock); $this->cp["t_customer_id"] = new clsSQLParameter("ctrlt_customer_id", ccsInteger, "", "", $this->t_customer_id->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["t_cust_acc_masa_jab_detail_id"] = new clsSQLParameter("ctrlt_cust_acc_masa_jab_detail_id", ccsInteger, "", "", $this->t_cust_acc_masa_jab_detail_id->GetValue(true), 0, false, $this->ErrorBlock); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeBuildUpdate", $this->Parent); if (!is_null($this->cp["p_vat_type_id"]->GetValue()) and !strlen($this->cp["p_vat_type_id"]->GetText()) and !is_bool($this->cp["p_vat_type_id"]->GetValue())) { $this->cp["p_vat_type_id"]->SetValue($this->p_vat_type_id->GetValue(true)); } if (!strlen($this->cp["p_vat_type_id"]->GetText()) and !is_bool($this->cp["p_vat_type_id"]->GetValue(true))) { $this->cp["p_vat_type_id"]->SetText(0); } if (!is_null($this->cp["registration_date"]->GetValue()) and !strlen($this->cp["registration_date"]->GetText()) and !is_bool($this->cp["registration_date"]->GetValue())) { $this->cp["registration_date"]->SetValue($this->registration_date->GetValue(true)); } if (!is_null($this->cp["company_name"]->GetValue()) and !strlen($this->cp["company_name"]->GetText()) and !is_bool($this->cp["company_name"]->GetValue())) { $this->cp["company_name"]->SetValue($this->company_name->GetValue(true)); } if (!is_null($this->cp["company_brand"]->GetValue()) and !strlen($this->cp["company_brand"]->GetText()) and !is_bool($this->cp["company_brand"]->GetValue())) { $this->cp["company_brand"]->SetValue($this->company_brand->GetValue(true)); } if (!is_null($this->cp["address_no"]->GetValue()) and !strlen($this->cp["address_no"]->GetText()) and !is_bool($this->cp["address_no"]->GetValue())) { $this->cp["address_no"]->SetValue($this->address_no->GetValue(true)); } if (!is_null($this->cp["address_name"]->GetValue()) and !strlen($this->cp["address_name"]->GetText()) and !is_bool($this->cp["address_name"]->GetValue())) { $this->cp["address_name"]->SetValue($this->address_name->GetValue(true)); } if (!is_null($this->cp["address_rt"]->GetValue()) and !strlen($this->cp["address_rt"]->GetText()) and !is_bool($this->cp["address_rt"]->GetValue())) { $this->cp["address_rt"]->SetValue($this->address_rt->GetValue(true)); } if (!is_null($this->cp["address_rw"]->GetValue()) and !strlen($this->cp["address_rw"]->GetText()) and !is_bool($this->cp["address_rw"]->GetValue())) { $this->cp["address_rw"]->SetValue($this->address_rw->GetValue(true)); } if (!is_null($this->cp["p_region_id_kelurahan"]->GetValue()) and !strlen($this->cp["p_region_id_kelurahan"]->GetText()) and !is_bool($this->cp["p_region_id_kelurahan"]->GetValue())) { $this->cp["p_region_id_kelurahan"]->SetValue($this->p_region_id_kelurahan->GetValue(true)); } if (!is_null($this->cp["p_region_id_kecamatan"]->GetValue()) and !strlen($this->cp["p_region_id_kecamatan"]->GetText()) and !is_bool($this->cp["p_region_id_kecamatan"]->GetValue())) { $this->cp["p_region_id_kecamatan"]->SetValue($this->p_region_id_kecamatan->GetValue(true)); } if (!is_null($this->cp["p_region_id"]->GetValue()) and !strlen($this->cp["p_region_id"]->GetText()) and !is_bool($this->cp["p_region_id"]->GetValue())) { $this->cp["p_region_id"]->SetValue($this->p_region_id->GetValue(true)); } if (!is_null($this->cp["phone_no"]->GetValue()) and !strlen($this->cp["phone_no"]->GetText()) and !is_bool($this->cp["phone_no"]->GetValue())) { $this->cp["phone_no"]->SetValue($this->phone_no->GetValue(true)); } if (!is_null($this->cp["mobile_no"]->GetValue()) and !strlen($this->cp["mobile_no"]->GetText()) and !is_bool($this->cp["mobile_no"]->GetValue())) { $this->cp["mobile_no"]->SetValue($this->mobile_no->GetValue(true)); } if (!is_null($this->cp["fax_no"]->GetValue()) and !strlen($this->cp["fax_no"]->GetText()) and !is_bool($this->cp["fax_no"]->GetValue())) { $this->cp["fax_no"]->SetValue($this->fax_no->GetValue(true)); } if (!is_null($this->cp["zip_code"]->GetValue()) and !strlen($this->cp["zip_code"]->GetText()) and !is_bool($this->cp["zip_code"]->GetValue())) { $this->cp["zip_code"]->SetValue($this->zip_code->GetValue(true)); } if (!is_null($this->cp["updated_by"]->GetValue()) and !strlen($this->cp["updated_by"]->GetText()) and !is_bool($this->cp["updated_by"]->GetValue())) { $this->cp["updated_by"]->SetValue($this->updated_by->GetValue(true)); } if (!is_null($this->cp["t_cust_account_id"]->GetValue()) and !strlen($this->cp["t_cust_account_id"]->GetText()) and !is_bool($this->cp["t_cust_account_id"]->GetValue())) { $this->cp["t_cust_account_id"]->SetValue($this->t_cust_account_id->GetValue(true)); } if (!is_null($this->cp["npwd"]->GetValue()) and !strlen($this->cp["npwd"]->GetText()) and !is_bool($this->cp["npwd"]->GetValue())) { $this->cp["npwd"]->SetValue($this->npwd->GetValue(true)); } if (!is_null($this->cp["wp_name"]->GetValue()) and !strlen($this->cp["wp_name"]->GetText()) and !is_bool($this->cp["wp_name"]->GetValue())) { $this->cp["wp_name"]->SetValue($this->wp_name->GetValue(true)); } if (!is_null($this->cp["wp_address_name"]->GetValue()) and !strlen($this->cp["wp_address_name"]->GetText()) and !is_bool($this->cp["wp_address_name"]->GetValue())) { $this->cp["wp_address_name"]->SetValue($this->wp_address_name->GetValue(true)); } if (!is_null($this->cp["wp_address_no"]->GetValue()) and !strlen($this->cp["wp_address_no"]->GetText()) and !is_bool($this->cp["wp_address_no"]->GetValue())) { $this->cp["wp_address_no"]->SetValue($this->wp_address_no->GetValue(true)); } if (!is_null($this->cp["wp_address_rt"]->GetValue()) and !strlen($this->cp["wp_address_rt"]->GetText()) and !is_bool($this->cp["wp_address_rt"]->GetValue())) { $this->cp["wp_address_rt"]->SetValue($this->wp_address_rt->GetValue(true)); } if (!is_null($this->cp["wp_address_rw"]->GetValue()) and !strlen($this->cp["wp_address_rw"]->GetText()) and !is_bool($this->cp["wp_address_rw"]->GetValue())) { $this->cp["wp_address_rw"]->SetValue($this->wp_address_rw->GetValue(true)); } if (!is_null($this->cp["wp_p_region_id_kelurahan"]->GetValue()) and !strlen($this->cp["wp_p_region_id_kelurahan"]->GetText()) and !is_bool($this->cp["wp_p_region_id_kelurahan"]->GetValue())) { $this->cp["wp_p_region_id_kelurahan"]->SetValue($this->wp_p_region_id_kelurahan->GetValue(true)); } if (!strlen($this->cp["wp_p_region_id_kelurahan"]->GetText()) and !is_bool($this->cp["wp_p_region_id_kelurahan"]->GetValue(true))) { $this->cp["wp_p_region_id_kelurahan"]->SetText(0); } if (!is_null($this->cp["wp_p_region_id_kecamatan"]->GetValue()) and !strlen($this->cp["wp_p_region_id_kecamatan"]->GetText()) and !is_bool($this->cp["wp_p_region_id_kecamatan"]->GetValue())) { $this->cp["wp_p_region_id_kecamatan"]->SetValue($this->wp_p_region_id_kecamatan->GetValue(true)); } if (!strlen($this->cp["wp_p_region_id_kecamatan"]->GetText()) and !is_bool($this->cp["wp_p_region_id_kecamatan"]->GetValue(true))) { $this->cp["wp_p_region_id_kecamatan"]->SetText(0); } if (!is_null($this->cp["wp_p_region_id"]->GetValue()) and !strlen($this->cp["wp_p_region_id"]->GetText()) and !is_bool($this->cp["wp_p_region_id"]->GetValue())) { $this->cp["wp_p_region_id"]->SetValue($this->wp_p_region_id->GetValue(true)); } if (!strlen($this->cp["wp_p_region_id"]->GetText()) and !is_bool($this->cp["wp_p_region_id"]->GetValue(true))) { $this->cp["wp_p_region_id"]->SetText(0); } if (!is_null($this->cp["wp_phone_no"]->GetValue()) and !strlen($this->cp["wp_phone_no"]->GetText()) and !is_bool($this->cp["wp_phone_no"]->GetValue())) { $this->cp["wp_phone_no"]->SetValue($this->wp_phone_no->GetValue(true)); } if (!is_null($this->cp["wp_mobile_no"]->GetValue()) and !strlen($this->cp["wp_mobile_no"]->GetText()) and !is_bool($this->cp["wp_mobile_no"]->GetValue())) { $this->cp["wp_mobile_no"]->SetValue($this->wp_mobile_no->GetValue(true)); } if (!is_null($this->cp["wp_fax_no"]->GetValue()) and !strlen($this->cp["wp_fax_no"]->GetText()) and !is_bool($this->cp["wp_fax_no"]->GetValue())) { $this->cp["wp_fax_no"]->SetValue($this->wp_fax_no->GetValue(true)); } if (!is_null($this->cp["wp_zip_code"]->GetValue()) and !strlen($this->cp["wp_zip_code"]->GetText()) and !is_bool($this->cp["wp_zip_code"]->GetValue())) { $this->cp["wp_zip_code"]->SetValue($this->wp_zip_code->GetValue(true)); } if (!is_null($this->cp["wp_email"]->GetValue()) and !strlen($this->cp["wp_email"]->GetText()) and !is_bool($this->cp["wp_email"]->GetValue())) { $this->cp["wp_email"]->SetValue($this->wp_email->GetValue(true)); } if (!is_null($this->cp["brand_address_name"]->GetValue()) and !strlen($this->cp["brand_address_name"]->GetText()) and !is_bool($this->cp["brand_address_name"]->GetValue())) { $this->cp["brand_address_name"]->SetValue($this->brand_address_name->GetValue(true)); } if (!is_null($this->cp["brand_address_no"]->GetValue()) and !strlen($this->cp["brand_address_no"]->GetText()) and !is_bool($this->cp["brand_address_no"]->GetValue())) { $this->cp["brand_address_no"]->SetValue($this->brand_address_no->GetValue(true)); } if (!is_null($this->cp["brand_address_rt"]->GetValue()) and !strlen($this->cp["brand_address_rt"]->GetText()) and !is_bool($this->cp["brand_address_rt"]->GetValue())) { $this->cp["brand_address_rt"]->SetValue($this->brand_address_rt->GetValue(true)); } if (!is_null($this->cp["brand_address_rw"]->GetValue()) and !strlen($this->cp["brand_address_rw"]->GetText()) and !is_bool($this->cp["brand_address_rw"]->GetValue())) { $this->cp["brand_address_rw"]->SetValue($this->brand_address_rw->GetValue(true)); } if (!is_null($this->cp["brand_p_region_id_kel"]->GetValue()) and !strlen($this->cp["brand_p_region_id_kel"]->GetText()) and !is_bool($this->cp["brand_p_region_id_kel"]->GetValue())) { $this->cp["brand_p_region_id_kel"]->SetValue($this->brand_p_region_id_kel->GetValue(true)); } if (!strlen($this->cp["brand_p_region_id_kel"]->GetText()) and !is_bool($this->cp["brand_p_region_id_kel"]->GetValue(true))) { $this->cp["brand_p_region_id_kel"]->SetText(0); } if (!is_null($this->cp["brand_p_region_id_kec"]->GetValue()) and !strlen($this->cp["brand_p_region_id_kec"]->GetText()) and !is_bool($this->cp["brand_p_region_id_kec"]->GetValue())) { $this->cp["brand_p_region_id_kec"]->SetValue($this->brand_p_region_id_kec->GetValue(true)); } if (!strlen($this->cp["brand_p_region_id_kec"]->GetText()) and !is_bool($this->cp["brand_p_region_id_kec"]->GetValue(true))) { $this->cp["brand_p_region_id_kec"]->SetText(0); } if (!is_null($this->cp["brand_p_region_id"]->GetValue()) and !strlen($this->cp["brand_p_region_id"]->GetText()) and !is_bool($this->cp["brand_p_region_id"]->GetValue())) { $this->cp["brand_p_region_id"]->SetValue($this->brand_p_region_id->GetValue(true)); } if (!strlen($this->cp["brand_p_region_id"]->GetText()) and !is_bool($this->cp["brand_p_region_id"]->GetValue(true))) { $this->cp["brand_p_region_id"]->SetText(0); } if (!is_null($this->cp["brand_phone_no"]->GetValue()) and !strlen($this->cp["brand_phone_no"]->GetText()) and !is_bool($this->cp["brand_phone_no"]->GetValue())) { $this->cp["brand_phone_no"]->SetValue($this->brand_phone_no->GetValue(true)); } if (!is_null($this->cp["brand_mobile_no"]->GetValue()) and !strlen($this->cp["brand_mobile_no"]->GetText()) and !is_bool($this->cp["brand_mobile_no"]->GetValue())) { $this->cp["brand_mobile_no"]->SetValue($this->brand_mobile_no->GetValue(true)); } if (!is_null($this->cp["brand_fax_no"]->GetValue()) and !strlen($this->cp["brand_fax_no"]->GetText()) and !is_bool($this->cp["brand_fax_no"]->GetValue())) { $this->cp["brand_fax_no"]->SetValue($this->brand_fax_no->GetValue(true)); } if (!is_null($this->cp["brand_zip_code"]->GetValue()) and !strlen($this->cp["brand_zip_code"]->GetText()) and !is_bool($this->cp["brand_zip_code"]->GetValue())) { $this->cp["brand_zip_code"]->SetValue($this->brand_zip_code->GetValue(true)); } if (!is_null($this->cp["p_account_status_id"]->GetValue()) and !strlen($this->cp["p_account_status_id"]->GetText()) and !is_bool($this->cp["p_account_status_id"]->GetValue())) { $this->cp["p_account_status_id"]->SetValue($this->p_account_status_id->GetValue(true)); } if (!strlen($this->cp["p_account_status_id"]->GetText()) and !is_bool($this->cp["p_account_status_id"]->GetValue(true))) { $this->cp["p_account_status_id"]->SetText(0); } if (!is_null($this->cp["activation_no"]->GetValue()) and !strlen($this->cp["activation_no"]->GetText()) and !is_bool($this->cp["activation_no"]->GetValue())) { $this->cp["activation_no"]->SetValue($this->activation_no->GetValue(true)); } if (!is_null($this->cp["p_vat_type_dtl_id"]->GetValue()) and !strlen($this->cp["p_vat_type_dtl_id"]->GetText()) and !is_bool($this->cp["p_vat_type_dtl_id"]->GetValue())) { $this->cp["p_vat_type_dtl_id"]->SetValue($this->p_vat_type_dtl_id->GetValue(true)); } if (!strlen($this->cp["p_vat_type_dtl_id"]->GetText()) and !is_bool($this->cp["p_vat_type_dtl_id"]->GetValue(true))) { $this->cp["p_vat_type_dtl_id"]->SetText(0); } if (!is_null($this->cp["modification_by"]->GetValue()) and !strlen($this->cp["modification_by"]->GetText()) and !is_bool($this->cp["modification_by"]->GetValue())) { $this->cp["modification_by"]->SetValue(CCGetUserLogin()); } if (!is_null($this->cp["company_owner"]->GetValue()) and !strlen($this->cp["company_owner"]->GetText()) and !is_bool($this->cp["company_owner"]->GetValue())) { $this->cp["company_owner"]->SetValue($this->company_owner->GetValue(true)); } if (!is_null($this->cp["p_job_position_id"]->GetValue()) and !strlen($this->cp["p_job_position_id"]->GetText()) and !is_bool($this->cp["p_job_position_id"]->GetValue())) { $this->cp["p_job_position_id"]->SetValue($this->p_job_position_id->GetValue(true)); } if (!strlen($this->cp["p_job_position_id"]->GetText()) and !is_bool($this->cp["p_job_position_id"]->GetValue(true))) { $this->cp["p_job_position_id"]->SetText(0); } if (!is_null($this->cp["address_name_owner"]->GetValue()) and !strlen($this->cp["address_name_owner"]->GetText()) and !is_bool($this->cp["address_name_owner"]->GetValue())) { $this->cp["address_name_owner"]->SetValue($this->address_name_owner->GetValue(true)); } if (!is_null($this->cp["address_no_owner"]->GetValue()) and !strlen($this->cp["address_no_owner"]->GetText()) and !is_bool($this->cp["address_no_owner"]->GetValue())) { $this->cp["address_no_owner"]->SetValue($this->address_no_owner->GetValue(true)); } if (!is_null($this->cp["address_rt_owner"]->GetValue()) and !strlen($this->cp["address_rt_owner"]->GetText()) and !is_bool($this->cp["address_rt_owner"]->GetValue())) { $this->cp["address_rt_owner"]->SetValue($this->address_rt_owner->GetValue(true)); } if (!is_null($this->cp["address_rw_owner"]->GetValue()) and !strlen($this->cp["address_rw_owner"]->GetText()) and !is_bool($this->cp["address_rw_owner"]->GetValue())) { $this->cp["address_rw_owner"]->SetValue($this->address_rw_owner->GetValue(true)); } if (!is_null($this->cp["p_region_id_owner"]->GetValue()) and !strlen($this->cp["p_region_id_owner"]->GetText()) and !is_bool($this->cp["p_region_id_owner"]->GetValue())) { $this->cp["p_region_id_owner"]->SetValue($this->p_region_id_owner->GetValue(true)); } if (!strlen($this->cp["p_region_id_owner"]->GetText()) and !is_bool($this->cp["p_region_id_owner"]->GetValue(true))) { $this->cp["p_region_id_owner"]->SetText(0); } if (!is_null($this->cp["p_region_id_kec_owner"]->GetValue()) and !strlen($this->cp["p_region_id_kec_owner"]->GetText()) and !is_bool($this->cp["p_region_id_kec_owner"]->GetValue())) { $this->cp["p_region_id_kec_owner"]->SetValue($this->p_region_id_kec_owner->GetValue(true)); } if (!strlen($this->cp["p_region_id_kec_owner"]->GetText()) and !is_bool($this->cp["p_region_id_kec_owner"]->GetValue(true))) { $this->cp["p_region_id_kec_owner"]->SetText(0); } if (!is_null($this->cp["p_region_id_kel_owner"]->GetValue()) and !strlen($this->cp["p_region_id_kel_owner"]->GetText()) and !is_bool($this->cp["p_region_id_kel_owner"]->GetValue())) { $this->cp["p_region_id_kel_owner"]->SetValue($this->p_region_id_kel_owner->GetValue(true)); } if (!strlen($this->cp["p_region_id_kel_owner"]->GetText()) and !is_bool($this->cp["p_region_id_kel_owner"]->GetValue(true))) { $this->cp["p_region_id_kel_owner"]->SetText(0); } if (!is_null($this->cp["phone_no_owner"]->GetValue()) and !strlen($this->cp["phone_no_owner"]->GetText()) and !is_bool($this->cp["phone_no_owner"]->GetValue())) { $this->cp["phone_no_owner"]->SetValue($this->phone_no_owner->GetValue(true)); } if (!is_null($this->cp["fax_no_owner"]->GetValue()) and !strlen($this->cp["fax_no_owner"]->GetText()) and !is_bool($this->cp["fax_no_owner"]->GetValue())) { $this->cp["fax_no_owner"]->SetValue($this->fax_no_owner->GetValue(true)); } if (!is_null($this->cp["mobile_no_owner"]->GetValue()) and !strlen($this->cp["mobile_no_owner"]->GetText()) and !is_bool($this->cp["mobile_no_owner"]->GetValue())) { $this->cp["mobile_no_owner"]->SetValue($this->mobile_no_owner->GetValue(true)); } if (!is_null($this->cp["email_address"]->GetValue()) and !strlen($this->cp["email_address"]->GetText()) and !is_bool($this->cp["email_address"]->GetValue())) { $this->cp["email_address"]->SetValue($this->email_address->GetValue(true)); } if (!is_null($this->cp["zip_code_owner"]->GetValue()) and !strlen($this->cp["zip_code_owner"]->GetText()) and !is_bool($this->cp["zip_code_owner"]->GetValue())) { $this->cp["zip_code_owner"]->SetValue($this->zip_code_owner->GetValue(true)); } if (!is_null($this->cp["t_customer_id"]->GetValue()) and !strlen($this->cp["t_customer_id"]->GetText()) and !is_bool($this->cp["t_customer_id"]->GetValue())) { $this->cp["t_customer_id"]->SetValue($this->t_customer_id->GetValue(true)); } if (!strlen($this->cp["t_customer_id"]->GetText()) and !is_bool($this->cp["t_customer_id"]->GetValue(true))) { $this->cp["t_customer_id"]->SetText(0); } if (!is_null($this->cp["t_cust_acc_masa_jab_detail_id"]->GetValue()) and !strlen($this->cp["t_cust_acc_masa_jab_detail_id"]->GetText()) and !is_bool($this->cp["t_cust_acc_masa_jab_detail_id"]->GetValue())) { $this->cp["t_cust_acc_masa_jab_detail_id"]->SetValue($this->t_cust_acc_masa_jab_detail_id->GetValue(true)); } if (!strlen($this->cp["t_cust_acc_masa_jab_detail_id"]->GetText()) and !is_bool($this->cp["t_cust_acc_masa_jab_detail_id"]->GetValue(true))) { $this->cp["t_cust_acc_masa_jab_detail_id"]->SetText(0); } $this->SQL = "UPDATE t_cust_acc_masa_jab_detail\n" . " SET t_customer_id=" . $this->SQLValue($this->cp["t_customer_id"]->GetDBValue(), ccsInteger) . ", \n" . " company_owner='" . $this->SQLValue($this->cp["company_owner"]->GetDBValue(), ccsText) . "', p_job_position_id=" . $this->SQLValue($this->cp["p_job_position_id"]->GetDBValue(), ccsInteger) . ", address_name_owner='" . $this->SQLValue($this->cp["address_name_owner"]->GetDBValue(), ccsText) . "', address_no_owner='" . $this->SQLValue($this->cp["address_no_owner"]->GetDBValue(), ccsText) . "', \n" . " address_rt_owner='" . $this->SQLValue($this->cp["address_rt_owner"]->GetDBValue(), ccsText) . "', address_rw_owner='" . $this->SQLValue($this->cp["address_rw_owner"]->GetDBValue(), ccsText) . "', p_region_id_kel_owner=" . $this->SQLValue($this->cp["p_region_id_kel_owner"]->GetDBValue(), ccsInteger) . ", \n" . " p_region_id_kec_owner=" . $this->SQLValue($this->cp["p_region_id_kec_owner"]->GetDBValue(), ccsInteger) . ", p_region_id_owner=" . $this->SQLValue($this->cp["p_region_id_owner"]->GetDBValue(), ccsInteger) . ", phone_no_owner='" . $this->SQLValue($this->cp["phone_no_owner"]->GetDBValue(), ccsText) . "', \n" . " mobile_no_owner='" . $this->SQLValue($this->cp["mobile_no_owner"]->GetDBValue(), ccsText) . "', fax_no_owner='" . $this->SQLValue($this->cp["fax_no_owner"]->GetDBValue(), ccsText) . "', zip_code_owner='" . $this->SQLValue($this->cp["zip_code_owner"]->GetDBValue(), ccsText) . "', email_address='" . $this->SQLValue($this->cp["email_address"]->GetDBValue(), ccsText) . "', \n" . " \n" . "\t\t\t t_cust_account_id=" . $this->SQLValue($this->cp["t_cust_account_id"]->GetDBValue(), ccsText) . ", npwd='" . $this->SQLValue($this->cp["npwd"]->GetDBValue(), ccsText) . "', p_vat_type_id=" . $this->SQLValue($this->cp["p_vat_type_id"]->GetDBValue(), ccsFloat) . ",\n" . " activation_no='" . $this->SQLValue($this->cp["activation_no"]->GetDBValue(), ccsText) . "', \n" . " wp_name='" . $this->SQLValue($this->cp["wp_name"]->GetDBValue(), ccsText) . "', wp_address_name='" . $this->SQLValue($this->cp["wp_address_name"]->GetDBValue(), ccsText) . "', \n" . " wp_address_no='" . $this->SQLValue($this->cp["wp_address_no"]->GetDBValue(), ccsText) . "', wp_address_rt='" . $this->SQLValue($this->cp["wp_address_rt"]->GetDBValue(), ccsText) . "', wp_address_rw='" . $this->SQLValue($this->cp["wp_address_rw"]->GetDBValue(), ccsText) . "', wp_p_region_id_kelurahan=" . $this->SQLValue($this->cp["wp_p_region_id_kelurahan"]->GetDBValue(), ccsFloat) . ", \n" . " wp_p_region_id_kecamatan=" . $this->SQLValue($this->cp["wp_p_region_id_kecamatan"]->GetDBValue(), ccsFloat) . ", wp_p_region_id=" . $this->SQLValue($this->cp["wp_p_region_id"]->GetDBValue(), ccsFloat) . ", wp_phone_no='" . $this->SQLValue($this->cp["wp_phone_no"]->GetDBValue(), ccsText) . "', \n" . " wp_mobile_no='" . $this->SQLValue($this->cp["wp_mobile_no"]->GetDBValue(), ccsText) . "', wp_fax_no='" . $this->SQLValue($this->cp["wp_fax_no"]->GetDBValue(), ccsText) . "', wp_zip_code='" . $this->SQLValue($this->cp["wp_zip_code"]->GetDBValue(), ccsText) . "', wp_email='" . $this->SQLValue($this->cp["wp_email"]->GetDBValue(), ccsText) . "', company_name='" . $this->SQLValue($this->cp["company_name"]->GetDBValue(), ccsText) . "', \n" . " address_name='" . $this->SQLValue($this->cp["address_name"]->GetDBValue(), ccsText) . "', address_no='" . $this->SQLValue($this->cp["address_no"]->GetDBValue(), ccsText) . "', address_rt='" . $this->SQLValue($this->cp["address_rt"]->GetDBValue(), ccsText) . "', address_rw='" . $this->SQLValue($this->cp["address_rw"]->GetDBValue(), ccsText) . "', p_region_id_kelurahan=" . $this->SQLValue($this->cp["p_region_id_kelurahan"]->GetDBValue(), ccsText) . ", \n" . " p_region_id_kecamatan=" . $this->SQLValue($this->cp["p_region_id_kecamatan"]->GetDBValue(), ccsText) . ", p_region_id=" . $this->SQLValue($this->cp["p_region_id"]->GetDBValue(), ccsText) . ", phone_no='" . $this->SQLValue($this->cp["phone_no"]->GetDBValue(), ccsText) . "', mobile_no='" . $this->SQLValue($this->cp["mobile_no"]->GetDBValue(), ccsText) . "', \n" . " fax_no='" . $this->SQLValue($this->cp["fax_no"]->GetDBValue(), ccsText) . "', zip_code='" . $this->SQLValue($this->cp["zip_code"]->GetDBValue(), ccsText) . "', company_brand='" . $this->SQLValue($this->cp["company_brand"]->GetDBValue(), ccsText) . "', brand_address_name='" . $this->SQLValue($this->cp["brand_address_name"]->GetDBValue(), ccsText) . "', \n" . " brand_address_no='" . $this->SQLValue($this->cp["brand_address_no"]->GetDBValue(), ccsText) . "', brand_address_rt='" . $this->SQLValue($this->cp["brand_address_rt"]->GetDBValue(), ccsText) . "', brand_address_rw='" . $this->SQLValue($this->cp["brand_address_rw"]->GetDBValue(), ccsText) . "', brand_p_region_id_kel=" . $this->SQLValue($this->cp["brand_p_region_id_kel"]->GetDBValue(), ccsFloat) . ", \n" . " brand_p_region_id_kec=" . $this->SQLValue($this->cp["brand_p_region_id_kec"]->GetDBValue(), ccsFloat) . ", brand_p_region_id=" . $this->SQLValue($this->cp["brand_p_region_id"]->GetDBValue(), ccsFloat) . ", brand_phone_no='" . $this->SQLValue($this->cp["brand_phone_no"]->GetDBValue(), ccsText) . "', \n" . " brand_mobile_no='" . $this->SQLValue($this->cp["brand_mobile_no"]->GetDBValue(), ccsText) . "', brand_fax_no='" . $this->SQLValue($this->cp["brand_fax_no"]->GetDBValue(), ccsText) . "', brand_zip_code='" . $this->SQLValue($this->cp["brand_zip_code"]->GetDBValue(), ccsText) . "', updated_date=sysdate, \n" . " updated_by='" . $this->SQLValue($this->cp["modification_by"]->GetDBValue(), ccsText) . "', p_vat_type_dtl_id=" . $this->SQLValue($this->cp["p_vat_type_dtl_id"]->GetDBValue(), ccsFloat) . "\n" . "\t WHERE t_cust_acc_masa_jab_detail_id=" . $this->SQLValue($this->cp["t_cust_acc_masa_jab_detail_id"]->GetDBValue(), ccsInteger) . ";"; $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeExecuteUpdate", $this->Parent); if ($this->Errors->Count() == 0 && $this->CmdExecution) { $this->query($this->SQL); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "AfterExecuteUpdate", $this->Parent); } }
<?php define("RelativePath", ".."); define("PathToCurrentPage", "/report/"); define("FileName", "cetak_rep_bpps.php"); include_once RelativePath . "/Common.php"; // include_once("../include/fpdf.php"); require "../include/qrcode/fpdf17/fpdf.php"; $t_bphtb_registration_id = CCGetFromGet("t_bphtb_registration_id", ""); // $t_bphtb_registration_id = 23; $user = CCGetUserLogin(); $data = array(); $dbConn = new clsDBConnSIKP(); $query = "select a.*,\r\nb.region_name as wp_region,\r\nc.region_name as wp_region_kec,\r\nd.region_name as wp_region_kel,\r\ne.region_name as object_region,\r\nf.region_name as object_region_kec,\r\ng.region_name as object_region_kel,\r\nh.description as doc_name,\r\n(a.bphtb_amt - a.bphtb_discount) AS bphtb_amt_final_old,\r\nj.payment_vat_amount AS prev_payment_amount\r\n\r\n\r\nfrom t_bphtb_registration as a \r\nleft join p_region as b\r\n\ton a.wp_p_region_id = b.p_region_id\r\nleft join p_region as c\r\n\ton a.wp_p_region_id_kec = c.p_region_id\r\nleft join p_region as d\r\n\ton a.wp_p_region_id_kel = d.p_region_id\r\nleft join p_region as e\r\n\ton a.object_p_region_id = e.p_region_id\r\nleft join p_region as f\r\n\ton a.object_p_region_id_kec = f.p_region_id\r\nleft join p_region as g\r\n\ton a.object_p_region_id_kel = g.p_region_id\r\nleft join p_bphtb_legal_doc_type as h\r\n\ton a.p_bphtb_legal_doc_type_id = h.p_bphtb_legal_doc_type_id\r\nleft join t_bphtb_registration as i\r\n\ton a.registration_no_ref = i.registration_no\r\nleft join t_payment_receipt_bphtb as j\r\n\ton i.t_bphtb_registration_id = j.t_bphtb_registration_id\r\nwhere a.t_bphtb_registration_id = {$t_bphtb_registration_id}"; $dbConn->query($query); while ($dbConn->next_record()) { $data["wp_name"] = $dbConn->f("wp_name"); $data["npwp"] = $dbConn->f("npwp"); $data["wp_address_name"] = $dbConn->f("wp_address_name"); $data["wp_rt"] = $dbConn->f("wp_rt"); $data["wp_rw"] = $dbConn->f("wp_rw"); $data["wp_region"] = $dbConn->f("wp_region"); $data["wp_region_kec"] = $dbConn->f("wp_region_kec"); $data["wp_region_kel"] = $dbConn->f("wp_region_kel"); $data["njop_pbb"] = $dbConn->f("njop_pbb"); $data["object_address_name"] = $dbConn->f("object_address_name"); $data["object_rt"] = $dbConn->f("object_rt"); $data["object_rw"] = $dbConn->f("object_rw"); $data["object_region"] = $dbConn->f("object_region"); $data["object_region_kec"] = $dbConn->f("object_region_kec"); $data["object_region_kel"] = $dbConn->f("object_region_kel");
function Update() { global $CCSLocales; global $DefaultDateFormat; $this->CmdExecution = true; $this->cp["block_status"] = new clsSQLParameter("ctrlblock_status", ccsText, "", "", $this->block_status->GetValue(true), "", false, $this->ErrorBlock); $this->cp["alasan"] = new clsSQLParameter("ctrlalasan", ccsText, "", "", $this->alasan->GetValue(true), "", false, $this->ErrorBlock); $this->cp["username"] = new clsSQLParameter("expr47", ccsText, "", "", CCGetUserLogin(), "", false, $this->ErrorBlock); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeBuildUpdate", $this->Parent); if (!is_null($this->cp["block_status"]->GetValue()) and !strlen($this->cp["block_status"]->GetText()) and !is_bool($this->cp["block_status"]->GetValue())) { $this->cp["block_status"]->SetValue($this->block_status->GetValue(true)); } if (!is_null($this->cp["alasan"]->GetValue()) and !strlen($this->cp["alasan"]->GetText()) and !is_bool($this->cp["alasan"]->GetValue())) { $this->cp["alasan"]->SetValue($this->alasan->GetValue(true)); } if (!is_null($this->cp["username"]->GetValue()) and !strlen($this->cp["username"]->GetText()) and !is_bool($this->cp["username"]->GetValue())) { $this->cp["username"]->SetValue(CCGetUserLogin()); } $this->SQL = "select * from f_update_block_piutang\n" . "('" . $this->SQLValue($this->cp["block_status"]->GetDBValue(), ccsText) . "','" . $this->SQLValue($this->cp["alasan"]->GetDBValue(), ccsText) . "','" . $this->SQLValue($this->cp["username"]->GetDBValue(), ccsText) . "')"; $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeExecuteUpdate", $this->Parent); if ($this->Errors->Count() == 0 && $this->CmdExecution) { $this->query($this->SQL); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "AfterExecuteUpdate", $this->Parent); } }
function Update() { global $CCSLocales; global $DefaultDateFormat; $this->CmdExecution = true; $this->cp["code"] = new clsSQLParameter("ctrlcode", ccsText, "", "", $this->code->GetValue(true), "", false, $this->ErrorBlock); $this->cp["value"] = new clsSQLParameter("ctrlvalue", ccsText, "", "", $this->value->GetValue(true), "", false, $this->ErrorBlock); $this->cp["type_1"] = new clsSQLParameter("ctrltype_1", ccsText, "", "", $this->type_1->GetValue(true), "", false, $this->ErrorBlock); $this->cp["is_range"] = new clsSQLParameter("ctrlis_range", ccsText, "", "", $this->is_range->GetValue(true), "", false, $this->ErrorBlock); $this->cp["value_2"] = new clsSQLParameter("ctrlvalue_2", ccsText, "", "", $this->value_2->GetValue(true), "", false, $this->ErrorBlock); $this->cp["description"] = new clsSQLParameter("ctrldescription", ccsText, "", "", $this->description->GetValue(true), "", false, $this->ErrorBlock); $this->cp["updated_by"] = new clsSQLParameter("expr198", ccsText, "", "", CCGetUserLogin(), "", false, $this->ErrorBlock); $this->cp["p_global_param_id"] = new clsSQLParameter("ctrlp_global_param_id", ccsFloat, "", "", $this->p_global_param_id->GetValue(true), 0, false, $this->ErrorBlock); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeBuildUpdate", $this->Parent); if (!is_null($this->cp["code"]->GetValue()) and !strlen($this->cp["code"]->GetText()) and !is_bool($this->cp["code"]->GetValue())) { $this->cp["code"]->SetValue($this->code->GetValue(true)); } if (!is_null($this->cp["value"]->GetValue()) and !strlen($this->cp["value"]->GetText()) and !is_bool($this->cp["value"]->GetValue())) { $this->cp["value"]->SetValue($this->value->GetValue(true)); } if (!is_null($this->cp["type_1"]->GetValue()) and !strlen($this->cp["type_1"]->GetText()) and !is_bool($this->cp["type_1"]->GetValue())) { $this->cp["type_1"]->SetValue($this->type_1->GetValue(true)); } if (!is_null($this->cp["is_range"]->GetValue()) and !strlen($this->cp["is_range"]->GetText()) and !is_bool($this->cp["is_range"]->GetValue())) { $this->cp["is_range"]->SetValue($this->is_range->GetValue(true)); } if (!is_null($this->cp["value_2"]->GetValue()) and !strlen($this->cp["value_2"]->GetText()) and !is_bool($this->cp["value_2"]->GetValue())) { $this->cp["value_2"]->SetValue($this->value_2->GetValue(true)); } if (!is_null($this->cp["description"]->GetValue()) and !strlen($this->cp["description"]->GetText()) and !is_bool($this->cp["description"]->GetValue())) { $this->cp["description"]->SetValue($this->description->GetValue(true)); } if (!is_null($this->cp["updated_by"]->GetValue()) and !strlen($this->cp["updated_by"]->GetText()) and !is_bool($this->cp["updated_by"]->GetValue())) { $this->cp["updated_by"]->SetValue(CCGetUserLogin()); } if (!is_null($this->cp["p_global_param_id"]->GetValue()) and !strlen($this->cp["p_global_param_id"]->GetText()) and !is_bool($this->cp["p_global_param_id"]->GetValue())) { $this->cp["p_global_param_id"]->SetValue($this->p_global_param_id->GetValue(true)); } if (!strlen($this->cp["p_global_param_id"]->GetText()) and !is_bool($this->cp["p_global_param_id"]->GetValue(true))) { $this->cp["p_global_param_id"]->SetText(0); } $this->SQL = "update p_global_param \n" . "set code=upper('" . $this->SQLValue($this->cp["code"]->GetDBValue(), ccsText) . "'), \n" . "value='" . $this->SQLValue($this->cp["value"]->GetDBValue(), ccsText) . "', \n" . "type_1='" . $this->SQLValue($this->cp["type_1"]->GetDBValue(), ccsText) . "', \n" . "is_range='" . $this->SQLValue($this->cp["is_range"]->GetDBValue(), ccsText) . "', \n" . "value_2='" . $this->SQLValue($this->cp["value_2"]->GetDBValue(), ccsText) . "', \n" . "description='" . $this->SQLValue($this->cp["description"]->GetDBValue(), ccsText) . "', \n" . "updated_date=sysdate,\n" . "updated_by='" . $this->SQLValue($this->cp["updated_by"]->GetDBValue(), ccsText) . "'\n" . "where p_global_param_id = " . $this->SQLValue($this->cp["p_global_param_id"]->GetDBValue(), ccsFloat) . ""; $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeExecuteUpdate", $this->Parent); if ($this->Errors->Count() == 0 && $this->CmdExecution) { $this->query($this->SQL); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "AfterExecuteUpdate", $this->Parent); } }
function Update() { global $CCSLocales; global $DefaultDateFormat; $this->CmdExecution = true; $this->cp["t_cacc_dtl_restaurant_id"] = new clsSQLParameter("ctrlt_cacc_dtl_restaurant_id", ccsFloat, "", "", $this->t_cacc_dtl_restaurant_id->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["description"] = new clsSQLParameter("ctrldescription", ccsText, "", "", $this->description->GetValue(true), "", false, $this->ErrorBlock); $this->cp["updated_by"] = new clsSQLParameter("expr804", ccsText, "", "", CCGetUserLogin(), "", false, $this->ErrorBlock); $this->cp["t_cust_account_id"] = new clsSQLParameter("ctrlt_cust_account_id", ccsFloat, "", "", $this->t_cust_account_id->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["table_qty"] = new clsSQLParameter("ctrltable_qty", ccsText, "", "", $this->table_qty->GetValue(true), "", false, $this->ErrorBlock); $this->cp["avg_subscription"] = new clsSQLParameter("ctrlavg_subscription", ccsFloat, "", "", $this->avg_subscription->GetValue(true), "", false, $this->ErrorBlock); $this->cp["seat_qty"] = new clsSQLParameter("ctrlseat_qty", ccsFloat, "", "", $this->seat_qty->GetValue(true), "", false, $this->ErrorBlock); $this->cp["max_service_qty"] = new clsSQLParameter("ctrlmax_service_qty", ccsFloat, "", "", $this->max_service_qty->GetValue(true), "", false, $this->ErrorBlock); $this->cp["valid_from"] = new clsSQLParameter("ctrlvalid_from", ccsText, "", "", $this->valid_from->GetValue(true), "", false, $this->ErrorBlock); $this->cp["valid_to"] = new clsSQLParameter("ctrlvalid_to", ccsText, "", "", $this->valid_to->GetValue(true), "", false, $this->ErrorBlock); $this->cp["min_food_price"] = new clsSQLParameter("ctrlmin_food_price", ccsFloat, "", "", $this->min_food_price->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["max_food_price"] = new clsSQLParameter("ctrlmax_food_price", ccsFloat, "", "", $this->max_food_price->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["min_beverage_price"] = new clsSQLParameter("ctrlmin_beverage_price", ccsFloat, "", "", $this->min_beverage_price->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["max_beverage_price"] = new clsSQLParameter("ctrlmax_beverage_price", ccsFloat, "", "", $this->max_beverage_price->GetValue(true), 0, false, $this->ErrorBlock); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeBuildUpdate", $this->Parent); if (!is_null($this->cp["t_cacc_dtl_restaurant_id"]->GetValue()) and !strlen($this->cp["t_cacc_dtl_restaurant_id"]->GetText()) and !is_bool($this->cp["t_cacc_dtl_restaurant_id"]->GetValue())) { $this->cp["t_cacc_dtl_restaurant_id"]->SetValue($this->t_cacc_dtl_restaurant_id->GetValue(true)); } if (!strlen($this->cp["t_cacc_dtl_restaurant_id"]->GetText()) and !is_bool($this->cp["t_cacc_dtl_restaurant_id"]->GetValue(true))) { $this->cp["t_cacc_dtl_restaurant_id"]->SetText(0); } if (!is_null($this->cp["description"]->GetValue()) and !strlen($this->cp["description"]->GetText()) and !is_bool($this->cp["description"]->GetValue())) { $this->cp["description"]->SetValue($this->description->GetValue(true)); } if (!is_null($this->cp["updated_by"]->GetValue()) and !strlen($this->cp["updated_by"]->GetText()) and !is_bool($this->cp["updated_by"]->GetValue())) { $this->cp["updated_by"]->SetValue(CCGetUserLogin()); } if (!is_null($this->cp["t_cust_account_id"]->GetValue()) and !strlen($this->cp["t_cust_account_id"]->GetText()) and !is_bool($this->cp["t_cust_account_id"]->GetValue())) { $this->cp["t_cust_account_id"]->SetValue($this->t_cust_account_id->GetValue(true)); } if (!strlen($this->cp["t_cust_account_id"]->GetText()) and !is_bool($this->cp["t_cust_account_id"]->GetValue(true))) { $this->cp["t_cust_account_id"]->SetText(0); } if (!is_null($this->cp["table_qty"]->GetValue()) and !strlen($this->cp["table_qty"]->GetText()) and !is_bool($this->cp["table_qty"]->GetValue())) { $this->cp["table_qty"]->SetValue($this->table_qty->GetValue(true)); } if (!is_null($this->cp["avg_subscription"]->GetValue()) and !strlen($this->cp["avg_subscription"]->GetText()) and !is_bool($this->cp["avg_subscription"]->GetValue())) { $this->cp["avg_subscription"]->SetValue($this->avg_subscription->GetValue(true)); } if (!is_null($this->cp["seat_qty"]->GetValue()) and !strlen($this->cp["seat_qty"]->GetText()) and !is_bool($this->cp["seat_qty"]->GetValue())) { $this->cp["seat_qty"]->SetValue($this->seat_qty->GetValue(true)); } if (!is_null($this->cp["max_service_qty"]->GetValue()) and !strlen($this->cp["max_service_qty"]->GetText()) and !is_bool($this->cp["max_service_qty"]->GetValue())) { $this->cp["max_service_qty"]->SetValue($this->max_service_qty->GetValue(true)); } if (!is_null($this->cp["valid_from"]->GetValue()) and !strlen($this->cp["valid_from"]->GetText()) and !is_bool($this->cp["valid_from"]->GetValue())) { $this->cp["valid_from"]->SetValue($this->valid_from->GetValue(true)); } if (!is_null($this->cp["valid_to"]->GetValue()) and !strlen($this->cp["valid_to"]->GetText()) and !is_bool($this->cp["valid_to"]->GetValue())) { $this->cp["valid_to"]->SetValue($this->valid_to->GetValue(true)); } if (!is_null($this->cp["min_food_price"]->GetValue()) and !strlen($this->cp["min_food_price"]->GetText()) and !is_bool($this->cp["min_food_price"]->GetValue())) { $this->cp["min_food_price"]->SetValue($this->min_food_price->GetValue(true)); } if (!strlen($this->cp["min_food_price"]->GetText()) and !is_bool($this->cp["min_food_price"]->GetValue(true))) { $this->cp["min_food_price"]->SetText(0); } if (!is_null($this->cp["max_food_price"]->GetValue()) and !strlen($this->cp["max_food_price"]->GetText()) and !is_bool($this->cp["max_food_price"]->GetValue())) { $this->cp["max_food_price"]->SetValue($this->max_food_price->GetValue(true)); } if (!strlen($this->cp["max_food_price"]->GetText()) and !is_bool($this->cp["max_food_price"]->GetValue(true))) { $this->cp["max_food_price"]->SetText(0); } if (!is_null($this->cp["min_beverage_price"]->GetValue()) and !strlen($this->cp["min_beverage_price"]->GetText()) and !is_bool($this->cp["min_beverage_price"]->GetValue())) { $this->cp["min_beverage_price"]->SetValue($this->min_beverage_price->GetValue(true)); } if (!strlen($this->cp["min_beverage_price"]->GetText()) and !is_bool($this->cp["min_beverage_price"]->GetValue(true))) { $this->cp["min_beverage_price"]->SetText(0); } if (!is_null($this->cp["max_beverage_price"]->GetValue()) and !strlen($this->cp["max_beverage_price"]->GetText()) and !is_bool($this->cp["max_beverage_price"]->GetValue())) { $this->cp["max_beverage_price"]->SetValue($this->max_beverage_price->GetValue(true)); } if (!strlen($this->cp["max_beverage_price"]->GetText()) and !is_bool($this->cp["max_beverage_price"]->GetValue(true))) { $this->cp["max_beverage_price"]->SetText(0); } $this->SQL = "UPDATE t_cacc_dtl_restaurant\n" . "SET description='" . $this->SQLValue($this->cp["description"]->GetDBValue(), ccsText) . "', \n" . "updated_by='" . $this->SQLValue($this->cp["updated_by"]->GetDBValue(), ccsText) . "', \n" . "updated_date=sysdate, \n" . "t_cust_account_id=" . $this->SQLValue($this->cp["t_cust_account_id"]->GetDBValue(), ccsFloat) . ", \n" . "table_qty='" . $this->SQLValue($this->cp["table_qty"]->GetDBValue(), ccsText) . "', \n" . "avg_subscription=" . $this->SQLValue($this->cp["avg_subscription"]->GetDBValue(), ccsFloat) . ", \n" . "seat_qty=" . $this->SQLValue($this->cp["seat_qty"]->GetDBValue(), ccsFloat) . ", \n" . "max_service_qty=" . $this->SQLValue($this->cp["max_service_qty"]->GetDBValue(), ccsFloat) . ",\n" . "valid_from = to_date('" . $this->SQLValue($this->cp["valid_from"]->GetDBValue(), ccsText) . "','DD-MON-YYYY'),\n" . "valid_to=case when '" . $this->SQLValue($this->cp["valid_to"]->GetDBValue(), ccsText) . "' = '' then null else to_date('" . $this->SQLValue($this->cp["valid_to"]->GetDBValue(), ccsText) . "','dd-mon-yyyy') end,\n" . "min_food_price=" . $this->SQLValue($this->cp["min_food_price"]->GetDBValue(), ccsFloat) . ",\n" . "max_food_price=" . $this->SQLValue($this->cp["max_food_price"]->GetDBValue(), ccsFloat) . ",\n" . "min_beverage_price=" . $this->SQLValue($this->cp["min_beverage_price"]->GetDBValue(), ccsFloat) . ",\n" . "max_beverage_price=" . $this->SQLValue($this->cp["max_beverage_price"]->GetDBValue(), ccsFloat) . "\n" . "WHERE t_cacc_dtl_restaurant_id=" . $this->SQLValue($this->cp["t_cacc_dtl_restaurant_id"]->GetDBValue(), ccsFloat) . ""; $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeExecuteUpdate", $this->Parent); if ($this->Errors->Count() == 0 && $this->CmdExecution) { $this->query($this->SQL); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "AfterExecuteUpdate", $this->Parent); } }
function Update() { global $CCSLocales; global $DefaultDateFormat; $this->CmdExecution = true; $this->cp["p_vat_type_id"] = new clsSQLParameter("ctrlp_vat_type_id", ccsFloat, "", "", $this->p_vat_type_id->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["due_in_day"] = new clsSQLParameter("ctrldue_in_day", ccsFloat, "", "", $this->due_in_day->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["debt_letter1_in_day"] = new clsSQLParameter("ctrldebt_letter1_in_day", ccsFloat, "", "", $this->debt_letter1_in_day->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["debt_letter2_in_day"] = new clsSQLParameter("ctrldebt_letter2_in_day", ccsFloat, "", "", $this->debt_letter2_in_day->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["debt_letter3_in_day"] = new clsSQLParameter("ctrldebt_letter3_in_day", ccsFloat, "", "", $this->debt_letter3_in_day->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["valid_from"] = new clsSQLParameter("ctrlvalid_from", ccsText, "", "", $this->valid_from->GetValue(true), "", false, $this->ErrorBlock); $this->cp["valid_to"] = new clsSQLParameter("ctrlvalid_to", ccsText, "", "", $this->valid_to->GetValue(true), "", false, $this->ErrorBlock); $this->cp["description"] = new clsSQLParameter("ctrldescription", ccsText, "", "", $this->description->GetValue(true), "", false, $this->ErrorBlock); $this->cp["updated_by"] = new clsSQLParameter("expr182", ccsText, "", "", CCGetUserLogin(), "", false, $this->ErrorBlock); $this->cp["p_settlement_due_date_id"] = new clsSQLParameter("ctrlp_settlement_due_date_id", ccsFloat, "", "", $this->p_settlement_due_date_id->GetValue(true), 0, false, $this->ErrorBlock); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeBuildUpdate", $this->Parent); if (!is_null($this->cp["p_vat_type_id"]->GetValue()) and !strlen($this->cp["p_vat_type_id"]->GetText()) and !is_bool($this->cp["p_vat_type_id"]->GetValue())) { $this->cp["p_vat_type_id"]->SetValue($this->p_vat_type_id->GetValue(true)); } if (!strlen($this->cp["p_vat_type_id"]->GetText()) and !is_bool($this->cp["p_vat_type_id"]->GetValue(true))) { $this->cp["p_vat_type_id"]->SetText(0); } if (!is_null($this->cp["due_in_day"]->GetValue()) and !strlen($this->cp["due_in_day"]->GetText()) and !is_bool($this->cp["due_in_day"]->GetValue())) { $this->cp["due_in_day"]->SetValue($this->due_in_day->GetValue(true)); } if (!strlen($this->cp["due_in_day"]->GetText()) and !is_bool($this->cp["due_in_day"]->GetValue(true))) { $this->cp["due_in_day"]->SetText(0); } if (!is_null($this->cp["debt_letter1_in_day"]->GetValue()) and !strlen($this->cp["debt_letter1_in_day"]->GetText()) and !is_bool($this->cp["debt_letter1_in_day"]->GetValue())) { $this->cp["debt_letter1_in_day"]->SetValue($this->debt_letter1_in_day->GetValue(true)); } if (!strlen($this->cp["debt_letter1_in_day"]->GetText()) and !is_bool($this->cp["debt_letter1_in_day"]->GetValue(true))) { $this->cp["debt_letter1_in_day"]->SetText(0); } if (!is_null($this->cp["debt_letter2_in_day"]->GetValue()) and !strlen($this->cp["debt_letter2_in_day"]->GetText()) and !is_bool($this->cp["debt_letter2_in_day"]->GetValue())) { $this->cp["debt_letter2_in_day"]->SetValue($this->debt_letter2_in_day->GetValue(true)); } if (!strlen($this->cp["debt_letter2_in_day"]->GetText()) and !is_bool($this->cp["debt_letter2_in_day"]->GetValue(true))) { $this->cp["debt_letter2_in_day"]->SetText(0); } if (!is_null($this->cp["debt_letter3_in_day"]->GetValue()) and !strlen($this->cp["debt_letter3_in_day"]->GetText()) and !is_bool($this->cp["debt_letter3_in_day"]->GetValue())) { $this->cp["debt_letter3_in_day"]->SetValue($this->debt_letter3_in_day->GetValue(true)); } if (!strlen($this->cp["debt_letter3_in_day"]->GetText()) and !is_bool($this->cp["debt_letter3_in_day"]->GetValue(true))) { $this->cp["debt_letter3_in_day"]->SetText(0); } if (!is_null($this->cp["valid_from"]->GetValue()) and !strlen($this->cp["valid_from"]->GetText()) and !is_bool($this->cp["valid_from"]->GetValue())) { $this->cp["valid_from"]->SetValue($this->valid_from->GetValue(true)); } if (!is_null($this->cp["valid_to"]->GetValue()) and !strlen($this->cp["valid_to"]->GetText()) and !is_bool($this->cp["valid_to"]->GetValue())) { $this->cp["valid_to"]->SetValue($this->valid_to->GetValue(true)); } if (!is_null($this->cp["description"]->GetValue()) and !strlen($this->cp["description"]->GetText()) and !is_bool($this->cp["description"]->GetValue())) { $this->cp["description"]->SetValue($this->description->GetValue(true)); } if (!is_null($this->cp["updated_by"]->GetValue()) and !strlen($this->cp["updated_by"]->GetText()) and !is_bool($this->cp["updated_by"]->GetValue())) { $this->cp["updated_by"]->SetValue(CCGetUserLogin()); } if (!is_null($this->cp["p_settlement_due_date_id"]->GetValue()) and !strlen($this->cp["p_settlement_due_date_id"]->GetText()) and !is_bool($this->cp["p_settlement_due_date_id"]->GetValue())) { $this->cp["p_settlement_due_date_id"]->SetValue($this->p_settlement_due_date_id->GetValue(true)); } if (!strlen($this->cp["p_settlement_due_date_id"]->GetText()) and !is_bool($this->cp["p_settlement_due_date_id"]->GetValue(true))) { $this->cp["p_settlement_due_date_id"]->SetText(0); } $this->SQL = "UPDATE p_settlement_due_date SET\n" . "p_vat_type_id = " . $this->SQLValue($this->cp["p_vat_type_id"]->GetDBValue(), ccsFloat) . ", \n" . "due_in_day = " . $this->SQLValue($this->cp["due_in_day"]->GetDBValue(), ccsFloat) . ",\n" . "debt_letter1_in_day = " . $this->SQLValue($this->cp["debt_letter1_in_day"]->GetDBValue(), ccsFloat) . ",\n" . "debt_letter2_in_day = " . $this->SQLValue($this->cp["debt_letter2_in_day"]->GetDBValue(), ccsFloat) . ",\n" . "debt_letter3_in_day = " . $this->SQLValue($this->cp["debt_letter3_in_day"]->GetDBValue(), ccsFloat) . ",\n" . "valid_from = to_date('" . $this->SQLValue($this->cp["valid_from"]->GetDBValue(), ccsText) . "','DD-MON-YYYY'), \n" . "valid_to = to_date('" . $this->SQLValue($this->cp["valid_to"]->GetDBValue(), ccsText) . "','DD-MON-YYYY'), \n" . "description = '" . $this->SQLValue($this->cp["description"]->GetDBValue(), ccsText) . "', \n" . "updated_date = sysdate, \n" . "updated_by = '" . $this->SQLValue($this->cp["updated_by"]->GetDBValue(), ccsText) . "'\n" . "WHERE p_settlement_due_date_id = " . $this->SQLValue($this->cp["p_settlement_due_date_id"]->GetDBValue(), ccsFloat) . ""; $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeExecuteUpdate", $this->Parent); if ($this->Errors->Count() == 0 && $this->CmdExecution) { $this->query($this->SQL); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "AfterExecuteUpdate", $this->Parent); } }
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(); $Period = $t_vat_setllementForm->p_finance_period_id->GetValue(); $yearPeriod = $t_vat_setllementForm->p_year_period_id->GetValue(); $npwd = $t_vat_setllementForm->npwd->GetValue(); $ms_start = $t_vat_setllementForm->start_period->GetValue(); $ms_end = $t_vat_setllementForm->end_period->GetValue(); $kamar = trim($t_vat_setllementForm->qty_room_sold->GetValue()); $tot = $t_vat_setllementForm->total_trans_amount->GetValue(); $p_vat_type_dtl_id = $t_vat_setllementForm->p_vat_type_dtl_id->GetValue(); $p_vat_type_dtl_cls_id = $t_vat_setllementForm->p_vat_type_dtl_cls_id->GetValue(); $mode_denda = $t_vat_setllementForm->mode_denda->GetValue(); $User = CCGetUserLogin(); $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; } $sql = "select * from f_vat_settlement_manual_skpdkb_tambahan({$cusAccId},{$Period},'{$npwd}','{$ms_start}','{$ms_end}',{$kamar},{$tot},{$p_vat_type_dtl_id},{$p_vat_type_dtl_cls_id},'{$User}',{$mode_denda})"; //echo $sql;exit; //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> alert('".$mess."'); window.opener.location.reload(); window.close(); </script>"; exit;*/ if (!$cust_id == 0 && !$cust_id == "") { $sql2 = "select * from f_first_submit_engine_2step(\r\n\t\t501,\r\n\t\t{$cust_id},\r\n\t\t'{$User}')"; //die($sql2); $dbConn->query($sql2); $dbConn->next_record(); $o_result_code = $dbConn->f("o_result_code"); if ($o_result_code == 0) { echo '<script language="javascript">'; echo 'alert("' . $mess . '");'; echo '</script>'; } else { $mess = $dbConn->f("o_result_msg"); echo '<script language="javascript">'; echo 'alert("' . $mess . '");'; echo '</script>'; } } else { $mess = str_replace('"', '', $mess); echo '<script language="javascript">'; echo 'alert("' . $mess . '");'; echo '</script>'; } if (!$cust_id == 0 && !$cust_id == "") { $dbConn2 = new clsDBConnSIKP(); $sqlPayment = "select t_vat_setllement_id from t_vat_setllement where t_customer_order_id = " . $cust_id; $dbConn2->query($sqlPayment); $dbConn2->next_record(); $t_vat_setllement_id = $dbConn2->f("t_vat_setllement_id"); echo '<script language="javascript">'; echo "window.open('../report/cetak_formulir_skpdkb_tambahan.php?t_vat_setllement_id=" . $t_vat_setllement_id . "','No Payment', 'left=0,top=0,width=500,height=500,toolbar=no,scrollbars=yes,resizable=yes')"; echo '</script>'; } return; // ------------------------- //Close t_vat_setllementForm_Button1_OnClick @164-6DBB2532 return $t_vat_setllementForm_Button1_OnClick; }
function clsRecordroleForm($RelativePath, &$Parent) { global $FileName; global $CCSLocales; global $DefaultDateFormat; $this->Visible = true; $this->Parent =& $Parent; $this->RelativePath = $RelativePath; $this->Errors = new clsErrors(); $this->ErrorBlock = "Record roleForm/Error"; $this->DataSource = new clsroleFormDataSource($this); $this->ds =& $this->DataSource; $this->InsertAllowed = true; $this->UpdateAllowed = true; $this->DeleteAllowed = true; $this->ReadAllowed = true; if ($this->Visible) { $this->ComponentName = "roleForm"; $this->Attributes = new clsAttributes($this->ComponentName . ":"); $CCSForm = explode(":", CCGetFromGet("ccsForm", ""), 2); if (sizeof($CCSForm) == 1) { $CCSForm[1] = ""; } list($FormName, $FormMethod) = $CCSForm; $this->EditMode = $FormMethod == "Edit"; $this->FormEnctype = "application/x-www-form-urlencoded"; $this->FormSubmitted = $FormName == $this->ComponentName; $Method = $this->FormSubmitted ? ccsPost : ccsGet; $this->Button_Insert = new clsButton("Button_Insert", $Method, $this); $this->Button_Update = new clsButton("Button_Update", $Method, $this); $this->Button_Delete = new clsButton("Button_Delete", $Method, $this); $this->Button_Cancel = new clsButton("Button_Cancel", $Method, $this); $this->attribut_type = new clsControl(ccsTextBox, "attribut_type", "Code", ccsText, "", CCGetRequestParam("attribut_type", $Method, NULL), $this); $this->attribut_type->Required = true; $this->p_user_attribut_id = new clsControl(ccsHidden, "p_user_attribut_id", "p_user_attribut_id", ccsFloat, "", CCGetRequestParam("p_user_attribut_id", $Method, NULL), $this); $this->created_by = new clsControl(ccsTextBox, "created_by", "Created By", ccsText, "", CCGetRequestParam("created_by", $Method, NULL), $this); $this->creation_date = new clsControl(ccsTextBox, "creation_date", "Creation Date", ccsDate, array("dd", "-", "mmm", "-", "yyyy"), CCGetRequestParam("creation_date", $Method, NULL), $this); $this->updated_by = new clsControl(ccsTextBox, "updated_by", "Updated By", ccsText, "", CCGetRequestParam("updated_by", $Method, NULL), $this); $this->updated_date = new clsControl(ccsTextBox, "updated_date", "Updated Date", ccsDate, array("dd", "-", "mmm", "-", "yyyy"), CCGetRequestParam("updated_date", $Method, NULL), $this); $this->user_name = new clsControl(ccsTextBox, "user_name", "Created By", ccsText, "", CCGetRequestParam("user_name", $Method, NULL), $this); $this->p_user_attribute_type_id = new clsControl(ccsHidden, "p_user_attribute_type_id", "p_user_attribute_type_id", ccsText, "", CCGetRequestParam("p_user_attribute_type_id", $Method, NULL), $this); $this->p_user_id = new clsControl(ccsHidden, "p_user_id", "p_user_id", ccsText, "", CCGetRequestParam("p_user_id", $Method, NULL), $this); $this->p_user_id->Required = true; $this->attribut_list_code = new clsControl(ccsTextBox, "attribut_list_code", "Code", ccsText, "", CCGetRequestParam("attribut_list_code", $Method, NULL), $this); $this->attribut_list_code->Required = true; $this->p_user_attribute_list_id = new clsControl(ccsHidden, "p_user_attribute_list_id", "p_user_attribute_list_id", ccsText, "", CCGetRequestParam("p_user_attribute_list_id", $Method, NULL), $this); $this->user_attribute_value = new clsControl(ccsTextBox, "user_attribute_value", "Code", ccsText, "", CCGetRequestParam("user_attribute_value", $Method, NULL), $this); $this->user_attribute_value->Required = true; $this->valid_from = new clsControl(ccsTextBox, "valid_from", "Code", ccsDate, array("dd", "-", "mmm", "-", "yyyy"), CCGetRequestParam("valid_from", $Method, NULL), $this); $this->valid_from->Required = true; $this->valid_to = new clsControl(ccsTextBox, "valid_to", "Code", ccsDate, array("dd", "-", "mmm", "-", "yyyy"), CCGetRequestParam("valid_to", $Method, NULL), $this); $this->description = new clsControl(ccsTextArea, "description", "description", ccsText, "", CCGetRequestParam("description", $Method, NULL), $this); $this->DatePicker_valid_from1 = new clsDatePicker("DatePicker_valid_from1", "roleForm", "valid_from", $this); $this->DatePicker_valid_to1 = new clsDatePicker("DatePicker_valid_to1", "roleForm", "valid_to", $this); if (!$this->FormSubmitted) { if (!is_array($this->created_by->Value) && !strlen($this->created_by->Value) && $this->created_by->Value !== false) { $this->created_by->SetText(CCGetUserLogin()); } if (!is_array($this->creation_date->Value) && !strlen($this->creation_date->Value) && $this->creation_date->Value !== false) { $this->creation_date->SetValue(time()); } if (!is_array($this->updated_by->Value) && !strlen($this->updated_by->Value) && $this->updated_by->Value !== false) { $this->updated_by->SetText(CCGetUserLogin()); } if (!is_array($this->updated_date->Value) && !strlen($this->updated_date->Value) && $this->updated_date->Value !== false) { $this->updated_date->SetValue(time()); } } } }
function Insert() { global $CCSLocales; global $DefaultDateFormat; $this->CmdExecution = true; $this->cp["code"] = new clsSQLParameter("ctrlcode", ccsText, "", "", $this->code->GetValue(true), "", false, $this->ErrorBlock); $this->cp["description"] = new clsSQLParameter("ctrldescription", ccsText, "", "", $this->description->GetValue(true), "", false, $this->ErrorBlock); $this->cp["created_by"] = new clsSQLParameter("expr87", ccsText, "", "", CCGetUserLogin(), "", false, $this->ErrorBlock); $this->cp["updated_by"] = new clsSQLParameter("expr89", ccsText, "", "", CCGetUserLogin(), "", false, $this->ErrorBlock); $this->cp["p_order_status_id"] = new clsSQLParameter("ctrlp_order_status_id", ccsFloat, "", "", $this->p_order_status_id->GetValue(true), 0, false, $this->ErrorBlock); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeBuildInsert", $this->Parent); if (!is_null($this->cp["code"]->GetValue()) and !strlen($this->cp["code"]->GetText()) and !is_bool($this->cp["code"]->GetValue())) { $this->cp["code"]->SetValue($this->code->GetValue(true)); } if (!is_null($this->cp["description"]->GetValue()) and !strlen($this->cp["description"]->GetText()) and !is_bool($this->cp["description"]->GetValue())) { $this->cp["description"]->SetValue($this->description->GetValue(true)); } if (!is_null($this->cp["created_by"]->GetValue()) and !strlen($this->cp["created_by"]->GetText()) and !is_bool($this->cp["created_by"]->GetValue())) { $this->cp["created_by"]->SetValue(CCGetUserLogin()); } if (!is_null($this->cp["updated_by"]->GetValue()) and !strlen($this->cp["updated_by"]->GetText()) and !is_bool($this->cp["updated_by"]->GetValue())) { $this->cp["updated_by"]->SetValue(CCGetUserLogin()); } if (!is_null($this->cp["p_order_status_id"]->GetValue()) and !strlen($this->cp["p_order_status_id"]->GetText()) and !is_bool($this->cp["p_order_status_id"]->GetValue())) { $this->cp["p_order_status_id"]->SetValue($this->p_order_status_id->GetValue(true)); } if (!strlen($this->cp["p_order_status_id"]->GetText()) and !is_bool($this->cp["p_order_status_id"]->GetValue(true))) { $this->cp["p_order_status_id"]->SetText(0); } $this->SQL = "INSERT INTO p_order_status(p_order_status_id, code, description, creation_date, created_by, updated_date, updated_by) \n" . "VALUES(generate_id('sikp','p_order_status','p_order_status_id'), '" . $this->SQLValue($this->cp["code"]->GetDBValue(), ccsText) . "', '" . $this->SQLValue($this->cp["description"]->GetDBValue(), ccsText) . "', sysdate, '" . $this->SQLValue($this->cp["created_by"]->GetDBValue(), ccsText) . "', sysdate, '" . $this->SQLValue($this->cp["updated_by"]->GetDBValue(), ccsText) . "')"; $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeExecuteInsert", $this->Parent); if ($this->Errors->Count() == 0 && $this->CmdExecution) { $this->query($this->SQL); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "AfterExecuteInsert", $this->Parent); } }
function Update() { global $CCSLocales; global $DefaultDateFormat; $this->CmdExecution = true; $this->cp["p_organization_type_id"] = new clsSQLParameter("ctrlp_organization_type_id", ccsFloat, "", "", $this->p_organization_type_id->GetValue(true), "", false, $this->ErrorBlock); $this->cp["description"] = new clsSQLParameter("ctrldescription", ccsText, "", "", $this->description->GetValue(true), "", false, $this->ErrorBlock); $this->cp["updated_by"] = new clsSQLParameter("expr546", ccsText, "", "", CCGetUserLogin(), "", false, $this->ErrorBlock); $this->cp["listing_no"] = new clsSQLParameter("ctrllisting_no", ccsFloat, "", "", $this->listing_no->GetValue(true), "", false, $this->ErrorBlock); $this->cp["code"] = new clsSQLParameter("ctrlcode", ccsText, "", "", $this->code->GetValue(true), "", false, $this->ErrorBlock); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeBuildUpdate", $this->Parent); if (!is_null($this->cp["p_organization_type_id"]->GetValue()) and !strlen($this->cp["p_organization_type_id"]->GetText()) and !is_bool($this->cp["p_organization_type_id"]->GetValue())) { $this->cp["p_organization_type_id"]->SetValue($this->p_organization_type_id->GetValue(true)); } if (!is_null($this->cp["description"]->GetValue()) and !strlen($this->cp["description"]->GetText()) and !is_bool($this->cp["description"]->GetValue())) { $this->cp["description"]->SetValue($this->description->GetValue(true)); } if (!is_null($this->cp["updated_by"]->GetValue()) and !strlen($this->cp["updated_by"]->GetText()) and !is_bool($this->cp["updated_by"]->GetValue())) { $this->cp["updated_by"]->SetValue(CCGetUserLogin()); } if (!is_null($this->cp["listing_no"]->GetValue()) and !strlen($this->cp["listing_no"]->GetText()) and !is_bool($this->cp["listing_no"]->GetValue())) { $this->cp["listing_no"]->SetValue($this->listing_no->GetValue(true)); } if (!is_null($this->cp["code"]->GetValue()) and !strlen($this->cp["code"]->GetText()) and !is_bool($this->cp["code"]->GetValue())) { $this->cp["code"]->SetValue($this->code->GetValue(true)); } $this->SQL = "UPDATE p_organization_type SET \n" . "description='" . $this->SQLValue($this->cp["description"]->GetDBValue(), ccsText) . "', \n" . "updated_by='" . $this->SQLValue($this->cp["updated_by"]->GetDBValue(), ccsText) . "', \n" . "updated_date=sysdate, \n" . "listing_no=" . $this->SQLValue($this->cp["listing_no"]->GetDBValue(), ccsFloat) . ", \n" . "code='" . $this->SQLValue($this->cp["code"]->GetDBValue(), ccsText) . "'\n" . "WHERE p_organization_type_id=" . $this->SQLValue($this->cp["p_organization_type_id"]->GetDBValue(), ccsFloat) . ""; $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeExecuteUpdate", $this->Parent); if ($this->Errors->Count() == 0 && $this->CmdExecution) { $this->query($this->SQL); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "AfterExecuteUpdate", $this->Parent); } }
function clsRecordt_vat_setllementForm($RelativePath, &$Parent) { global $FileName; global $CCSLocales; global $DefaultDateFormat; $this->Visible = true; $this->Parent =& $Parent; $this->RelativePath = $RelativePath; $this->Errors = new clsErrors(); $this->ErrorBlock = "Record t_vat_setllementForm/Error"; $this->ReadAllowed = true; if ($this->Visible) { $this->ComponentName = "t_vat_setllementForm"; $this->Attributes = new clsAttributes($this->ComponentName . ":"); $CCSForm = explode(":", CCGetFromGet("ccsForm", ""), 2); if (sizeof($CCSForm) == 1) { $CCSForm[1] = ""; } list($FormName, $FormMethod) = $CCSForm; $this->FormEnctype = "application/x-www-form-urlencoded"; $this->FormSubmitted = $FormName == $this->ComponentName; $Method = $this->FormSubmitted ? ccsPost : ccsGet; $this->creation_date =& new clsControl(ccsTextBox, "creation_date", "Creation Date", ccsText, "", CCGetRequestParam("creation_date", $Method, NULL), $this); $this->created_by =& new clsControl(ccsTextBox, "created_by", "Created By", ccsText, "", CCGetRequestParam("created_by", $Method, NULL), $this); $this->updated_date =& new clsControl(ccsTextBox, "updated_date", "Updated Date", ccsText, "", CCGetRequestParam("updated_date", $Method, NULL), $this); $this->updated_by =& new clsControl(ccsTextBox, "updated_by", "Updated By", ccsText, "", CCGetRequestParam("updated_by", $Method, NULL), $this); $this->qty_room_sold =& new clsControl(ccsTextBox, "qty_room_sold", "Jumlah Kamar Terjual", ccsText, "", CCGetRequestParam("qty_room_sold", $Method, NULL), $this); $this->npwd =& new clsControl(ccsTextBox, "npwd", "NPWD", ccsText, "", CCGetRequestParam("npwd", $Method, NULL), $this); $this->npwd->Required = true; $this->t_cust_account_id =& new clsControl(ccsHidden, "t_cust_account_id", "t_cust_account_id", ccsFloat, "", CCGetRequestParam("t_cust_account_id", $Method, NULL), $this); $this->finance_period_code =& new clsControl(ccsTextBox, "finance_period_code", "Periode", ccsText, "", CCGetRequestParam("finance_period_code", $Method, NULL), $this); $this->finance_period_code->Required = true; $this->p_finance_period_id =& new clsControl(ccsHidden, "p_finance_period_id", "p_finance_period_id", ccsFloat, "", CCGetRequestParam("p_finance_period_id", $Method, NULL), $this); $this->p_year_period_id =& new clsControl(ccsHidden, "p_year_period_id", "p_year_period_id", ccsFloat, "", CCGetRequestParam("p_year_period_id", $Method, NULL), $this); $this->year_code =& new clsControl(ccsTextBox, "year_code", "Periode Tahun", ccsText, "", CCGetRequestParam("year_code", $Method, NULL), $this); $this->year_code->Required = true; $this->total_trans_amount =& new clsControl(ccsTextBox, "total_trans_amount", "Jumlah Order", ccsFloat, array(False, 2, Null, Null, False, "", "", 1, True, ""), CCGetRequestParam("total_trans_amount", $Method, NULL), $this); $this->total_trans_amount->Required = true; $this->start_period =& new clsControl(ccsTextBox, "start_period", "Masa Pajak", ccsText, "", CCGetRequestParam("start_period", $Method, NULL), $this); $this->start_period->Required = true; $this->DatePicker_start_period =& new clsDatePicker("DatePicker_start_period", "t_vat_setllementForm", "start_period", $this); $this->end_period =& new clsControl(ccsTextBox, "end_period", "end_period", ccsText, "", CCGetRequestParam("end_period", $Method, NULL), $this); $this->DatePicker_end_period =& new clsDatePicker("DatePicker_end_period", "t_vat_setllementForm", "end_period", $this); $this->Button1 =& new clsButton("Button1", $Method, $this); $this->company_name =& new clsControl(ccsTextBox, "company_name", "Nama Perusahaan", ccsText, "", CCGetRequestParam("company_name", $Method, NULL), $this); $this->vat_code =& new clsControl(ccsTextBox, "vat_code", "Ayat Pajak", ccsText, "", CCGetRequestParam("vat_code", $Method, NULL), $this); $this->vat_code->Required = true; $this->p_vat_type_id =& new clsControl(ccsHidden, "p_vat_type_id", "p_vat_type_id", ccsText, "", CCGetRequestParam("p_vat_type_id", $Method, NULL), $this); $this->vat_code_dtl =& new clsControl(ccsTextBox, "vat_code_dtl", "Tipe Ayat", ccsText, "", CCGetRequestParam("vat_code_dtl", $Method, NULL), $this); $this->vat_code_dtl->Required = true; $this->p_vat_type_dtl_id =& new clsControl(ccsHidden, "p_vat_type_dtl_id", "p_vat_type_dtl_id", ccsText, "", CCGetRequestParam("p_vat_type_dtl_id", $Method, NULL), $this); $this->vat_code_dtl_cls =& new clsControl(ccsTextBox, "vat_code_dtl_cls", "Kelas", ccsText, "", CCGetRequestParam("vat_code_dtl_cls", $Method, NULL), $this); $this->p_vat_type_dtl_cls_id =& new clsControl(ccsHidden, "p_vat_type_dtl_cls_id", "p_vat_type_dtl_cls_id", ccsText, "", CCGetRequestParam("p_vat_type_dtl_cls_id", $Method, NULL), $this); $this->mode_denda =& new clsControl(ccsHidden, "mode_denda", "mode_denda", ccsFloat, "", CCGetRequestParam("mode_denda", $Method, NULL), $this); if (!$this->FormSubmitted) { if (!is_array($this->creation_date->Value) && !strlen($this->creation_date->Value) && $this->creation_date->Value !== false) { $this->creation_date->SetText(date("d-M-Y")); } if (!is_array($this->created_by->Value) && !strlen($this->created_by->Value) && $this->created_by->Value !== false) { $this->created_by->SetText(CCGetUserLogin()); } if (!is_array($this->updated_date->Value) && !strlen($this->updated_date->Value) && $this->updated_date->Value !== false) { $this->updated_date->SetText(date("d-M-Y")); } if (!is_array($this->updated_by->Value) && !strlen($this->updated_by->Value) && $this->updated_by->Value !== false) { $this->updated_by->SetText(CCGetUserLogin()); } if (!is_array($this->start_period->Value) && !strlen($this->start_period->Value) && $this->start_period->Value !== false) { $this->start_period->SetText(date("d-M-Y")); } } } }
function Update() { global $CCSLocales; global $DefaultDateFormat; $this->CmdExecution = true; $this->cp["p_vat_type_id"] = new clsSQLParameter("ctrlp_vat_type_id", ccsFloat, "", "", $this->p_vat_type_id->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["p_vat_penalty_id"] = new clsSQLParameter("ctrlp_vat_penalty_id", ccsFloat, "", "", $this->p_vat_penalty_id->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["description"] = new clsSQLParameter("ctrldescription", ccsText, "", "", $this->description->GetValue(true), "", false, $this->ErrorBlock); $this->cp["updated_by"] = new clsSQLParameter("expr215", ccsText, "", "", CCGetUserLogin(), "", false, $this->ErrorBlock); $this->cp["month_qty"] = new clsSQLParameter("ctrlmonth_qty", ccsFloat, "", "", $this->month_qty->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["is_percentage"] = new clsSQLParameter("ctrlis_percentage", ccsText, "", "", $this->is_percentage->GetValue(true), "", false, $this->ErrorBlock); $this->cp["penalty_pct"] = new clsSQLParameter("ctrlpenalty_pct", ccsFloat, "", "", $this->penalty_pct->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["penalty_amt"] = new clsSQLParameter("ctrlpenalty_amt", ccsFloat, "", "", $this->penalty_amt->GetValue(true), 0, false, $this->ErrorBlock); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeBuildUpdate", $this->Parent); if (!is_null($this->cp["p_vat_type_id"]->GetValue()) and !strlen($this->cp["p_vat_type_id"]->GetText()) and !is_bool($this->cp["p_vat_type_id"]->GetValue())) { $this->cp["p_vat_type_id"]->SetValue($this->p_vat_type_id->GetValue(true)); } if (!strlen($this->cp["p_vat_type_id"]->GetText()) and !is_bool($this->cp["p_vat_type_id"]->GetValue(true))) { $this->cp["p_vat_type_id"]->SetText(0); } if (!is_null($this->cp["p_vat_penalty_id"]->GetValue()) and !strlen($this->cp["p_vat_penalty_id"]->GetText()) and !is_bool($this->cp["p_vat_penalty_id"]->GetValue())) { $this->cp["p_vat_penalty_id"]->SetValue($this->p_vat_penalty_id->GetValue(true)); } if (!strlen($this->cp["p_vat_penalty_id"]->GetText()) and !is_bool($this->cp["p_vat_penalty_id"]->GetValue(true))) { $this->cp["p_vat_penalty_id"]->SetText(0); } if (!is_null($this->cp["description"]->GetValue()) and !strlen($this->cp["description"]->GetText()) and !is_bool($this->cp["description"]->GetValue())) { $this->cp["description"]->SetValue($this->description->GetValue(true)); } if (!is_null($this->cp["updated_by"]->GetValue()) and !strlen($this->cp["updated_by"]->GetText()) and !is_bool($this->cp["updated_by"]->GetValue())) { $this->cp["updated_by"]->SetValue(CCGetUserLogin()); } if (!is_null($this->cp["month_qty"]->GetValue()) and !strlen($this->cp["month_qty"]->GetText()) and !is_bool($this->cp["month_qty"]->GetValue())) { $this->cp["month_qty"]->SetValue($this->month_qty->GetValue(true)); } if (!strlen($this->cp["month_qty"]->GetText()) and !is_bool($this->cp["month_qty"]->GetValue(true))) { $this->cp["month_qty"]->SetText(0); } if (!is_null($this->cp["is_percentage"]->GetValue()) and !strlen($this->cp["is_percentage"]->GetText()) and !is_bool($this->cp["is_percentage"]->GetValue())) { $this->cp["is_percentage"]->SetValue($this->is_percentage->GetValue(true)); } if (!is_null($this->cp["penalty_pct"]->GetValue()) and !strlen($this->cp["penalty_pct"]->GetText()) and !is_bool($this->cp["penalty_pct"]->GetValue())) { $this->cp["penalty_pct"]->SetValue($this->penalty_pct->GetValue(true)); } if (!strlen($this->cp["penalty_pct"]->GetText()) and !is_bool($this->cp["penalty_pct"]->GetValue(true))) { $this->cp["penalty_pct"]->SetText(0); } if (!is_null($this->cp["penalty_amt"]->GetValue()) and !strlen($this->cp["penalty_amt"]->GetText()) and !is_bool($this->cp["penalty_amt"]->GetValue())) { $this->cp["penalty_amt"]->SetValue($this->penalty_amt->GetValue(true)); } if (!strlen($this->cp["penalty_amt"]->GetText()) and !is_bool($this->cp["penalty_amt"]->GetValue(true))) { $this->cp["penalty_amt"]->SetText(0); } $this->SQL = "UPDATE p_vat_penalty SET \n" . "p_vat_type_id = " . $this->SQLValue($this->cp["p_vat_type_id"]->GetDBValue(), ccsFloat) . ",\n" . "month_qty = " . $this->SQLValue($this->cp["month_qty"]->GetDBValue(), ccsFloat) . ",\n" . "is_percentage = '" . $this->SQLValue($this->cp["is_percentage"]->GetDBValue(), ccsText) . "',\n" . "penalty_pct = " . $this->SQLValue($this->cp["penalty_pct"]->GetDBValue(), ccsFloat) . ",\n" . "penalty_amt = " . $this->SQLValue($this->cp["penalty_amt"]->GetDBValue(), ccsFloat) . ",\n" . "description = '" . $this->SQLValue($this->cp["description"]->GetDBValue(), ccsText) . "',\n" . "updated_date = sysdate,\n" . "updated_by = '" . $this->SQLValue($this->cp["updated_by"]->GetDBValue(), ccsText) . "'\n" . "WHERE p_vat_penalty_id = " . $this->SQLValue($this->cp["p_vat_penalty_id"]->GetDBValue(), ccsFloat) . ""; $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeExecuteUpdate", $this->Parent); if ($this->Errors->Count() == 0 && $this->CmdExecution) { $this->query($this->SQL); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "AfterExecuteUpdate", $this->Parent); } }
function Update() { global $CCSLocales; global $DefaultDateFormat; $this->CmdExecution = true; $this->cp["t_cust_order_legal_doc_id"] = new clsSQLParameter("ctrlt_cust_order_legal_doc_id", ccsFloat, "", "", $this->t_cust_order_legal_doc_id->GetValue(true), "", false, $this->ErrorBlock); $this->cp["description"] = new clsSQLParameter("ctrldescription", ccsText, "", "", $this->description->GetValue(true), "", false, $this->ErrorBlock); $this->cp["updated_by"] = new clsSQLParameter("expr666", ccsText, "", "", CCGetUserLogin(), "", false, $this->ErrorBlock); $this->cp["legal_doc_desc"] = new clsSQLParameter("ctrllegal_doc_desc", ccsText, "", "", $this->legal_doc_desc->GetValue(true), "", false, $this->ErrorBlock); $this->cp["p_legal_doc_type_id"] = new clsSQLParameter("ctrlp_legal_doc_type_id", ccsFloat, "", "", $this->p_legal_doc_type_id->GetValue(true), "", false, $this->ErrorBlock); $this->cp["t_customer_order_id"] = new clsSQLParameter("ctrlt_customer_order_id", ccsFloat, "", "", $this->t_customer_order_id->GetValue(true), "", false, $this->ErrorBlock); $this->cp["file_name"] = new clsSQLParameter("ctrlfile_name", ccsText, "", "", $this->file_name->GetValue(true), "", false, $this->ErrorBlock); $this->cp["file_folder"] = new clsSQLParameter("expr673", ccsText, "", "", files, "", false, $this->ErrorBlock); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeBuildUpdate", $this->Parent); if (!is_null($this->cp["t_cust_order_legal_doc_id"]->GetValue()) and !strlen($this->cp["t_cust_order_legal_doc_id"]->GetText()) and !is_bool($this->cp["t_cust_order_legal_doc_id"]->GetValue())) { $this->cp["t_cust_order_legal_doc_id"]->SetValue($this->t_cust_order_legal_doc_id->GetValue(true)); } if (!is_null($this->cp["description"]->GetValue()) and !strlen($this->cp["description"]->GetText()) and !is_bool($this->cp["description"]->GetValue())) { $this->cp["description"]->SetValue($this->description->GetValue(true)); } if (!is_null($this->cp["updated_by"]->GetValue()) and !strlen($this->cp["updated_by"]->GetText()) and !is_bool($this->cp["updated_by"]->GetValue())) { $this->cp["updated_by"]->SetValue(CCGetUserLogin()); } if (!is_null($this->cp["legal_doc_desc"]->GetValue()) and !strlen($this->cp["legal_doc_desc"]->GetText()) and !is_bool($this->cp["legal_doc_desc"]->GetValue())) { $this->cp["legal_doc_desc"]->SetValue($this->legal_doc_desc->GetValue(true)); } if (!is_null($this->cp["p_legal_doc_type_id"]->GetValue()) and !strlen($this->cp["p_legal_doc_type_id"]->GetText()) and !is_bool($this->cp["p_legal_doc_type_id"]->GetValue())) { $this->cp["p_legal_doc_type_id"]->SetValue($this->p_legal_doc_type_id->GetValue(true)); } if (!is_null($this->cp["t_customer_order_id"]->GetValue()) and !strlen($this->cp["t_customer_order_id"]->GetText()) and !is_bool($this->cp["t_customer_order_id"]->GetValue())) { $this->cp["t_customer_order_id"]->SetValue($this->t_customer_order_id->GetValue(true)); } if (!is_null($this->cp["file_name"]->GetValue()) and !strlen($this->cp["file_name"]->GetText()) and !is_bool($this->cp["file_name"]->GetValue())) { $this->cp["file_name"]->SetValue($this->file_name->GetValue(true)); } if (!is_null($this->cp["file_folder"]->GetValue()) and !strlen($this->cp["file_folder"]->GetText()) and !is_bool($this->cp["file_folder"]->GetValue())) { $this->cp["file_folder"]->SetValue(files); } $this->SQL = "UPDATE t_cust_order_legal_doc SET \n" . "description='" . $this->SQLValue($this->cp["description"]->GetDBValue(), ccsText) . "', \n" . "updated_by='" . $this->SQLValue($this->cp["updated_by"]->GetDBValue(), ccsText) . "', \n" . "updated_date=sysdate, \n" . "legal_doc_desc='" . $this->SQLValue($this->cp["legal_doc_desc"]->GetDBValue(), ccsText) . "', \n" . "p_legal_doc_type_id=" . $this->SQLValue($this->cp["p_legal_doc_type_id"]->GetDBValue(), ccsFloat) . ", \n" . "t_customer_order_id=" . $this->SQLValue($this->cp["t_customer_order_id"]->GetDBValue(), ccsFloat) . ", \n" . "origin_file_name=substr('" . $this->SQLValue($this->cp["file_name"]->GetDBValue(), ccsText) . "',17), \n" . "file_folder='" . $this->SQLValue($this->cp["file_folder"]->GetDBValue(), ccsText) . "', \n" . "file_name='" . $this->SQLValue($this->cp["file_name"]->GetDBValue(), ccsText) . "'\n" . "WHERE t_cust_order_legal_doc_id=" . $this->SQLValue($this->cp["t_cust_order_legal_doc_id"]->GetDBValue(), ccsFloat) . ""; $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeExecuteUpdate", $this->Parent); if ($this->Errors->Count() == 0 && $this->CmdExecution) { $this->query($this->SQL); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "AfterExecuteUpdate", $this->Parent); } }
function Update() { global $CCSLocales; global $DefaultDateFormat; $this->CmdExecution = true; $this->cp["t_customer_order_id"] = new clsSQLParameter("ctrlt_customer_order_id", ccsFloat, "", "", $this->t_customer_order_id->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["UserName"] = new clsSQLParameter("expr255", ccsText, "", "", CCGetUserLogin(), "", false, $this->ErrorBlock); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeBuildUpdate", $this->Parent); if (!is_null($this->cp["t_customer_order_id"]->GetValue()) and !strlen($this->cp["t_customer_order_id"]->GetText()) and !is_bool($this->cp["t_customer_order_id"]->GetValue())) { $this->cp["t_customer_order_id"]->SetValue($this->t_customer_order_id->GetValue(true)); } if (!strlen($this->cp["t_customer_order_id"]->GetText()) and !is_bool($this->cp["t_customer_order_id"]->GetValue(true))) { $this->cp["t_customer_order_id"]->SetText(0); } if (!is_null($this->cp["UserName"]->GetValue()) and !strlen($this->cp["UserName"]->GetText()) and !is_bool($this->cp["UserName"]->GetValue())) { $this->cp["UserName"]->SetValue(CCGetUserLogin()); } $this->SQL = "select o_result_code, o_result_msg from f_first_submit_engine(501," . $this->SQLValue($this->cp["t_customer_order_id"]->GetDBValue(), ccsFloat) . ",'" . $this->SQLValue($this->cp["UserName"]->GetDBValue(), ccsText) . "')"; $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeExecuteUpdate", $this->Parent); if ($this->Errors->Count() == 0 && $this->CmdExecution) { $this->query($this->SQL); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "AfterExecuteUpdate", $this->Parent); } }
function Insert() { global $CCSLocales; global $DefaultDateFormat; $this->CmdExecution = true; $this->cp["description"] = new clsSQLParameter("ctrldescription", ccsText, "", "", $this->description->GetValue(true), "", false, $this->ErrorBlock); $this->cp["activity"] = new clsSQLParameter("ctrlactivity", ccsText, "", "", $this->activity->GetValue(true), "", false, $this->ErrorBlock); $this->cp["create_by"] = new clsSQLParameter("expr789", ccsText, "", "", CCGetUserLogin(), "", false, $this->ErrorBlock); $this->cp["update_by"] = new clsSQLParameter("expr790", ccsText, "", "", CCGetUserLogin(), "", false, $this->ErrorBlock); $this->cp["CURR_DOC_ID"] = new clsSQLParameter("ctrlCURR_DOC_ID", ccsFloat, "", "", $this->CURR_DOC_ID->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["USER_ID_LOGIN"] = new clsSQLParameter("ctrlUSER_ID_LOGIN", ccsFloat, "", "", $this->USER_ID_LOGIN->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["CURR_PROC_ID"] = new clsSQLParameter("ctrlCURR_PROC_ID", ccsFloat, "", "", $this->CURR_PROC_ID->GetValue(true), 0, false, $this->ErrorBlock); $this->cp["input_type"] = new clsSQLParameter("ctrlinput_type", ccsText, "", "", $this->input_type->GetValue(true), "", false, $this->ErrorBlock); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeBuildInsert", $this->Parent); if (!is_null($this->cp["description"]->GetValue()) and !strlen($this->cp["description"]->GetText()) and !is_bool($this->cp["description"]->GetValue())) { $this->cp["description"]->SetValue($this->description->GetValue(true)); } if (!is_null($this->cp["activity"]->GetValue()) and !strlen($this->cp["activity"]->GetText()) and !is_bool($this->cp["activity"]->GetValue())) { $this->cp["activity"]->SetValue($this->activity->GetValue(true)); } if (!is_null($this->cp["create_by"]->GetValue()) and !strlen($this->cp["create_by"]->GetText()) and !is_bool($this->cp["create_by"]->GetValue())) { $this->cp["create_by"]->SetValue(CCGetUserLogin()); } if (!is_null($this->cp["update_by"]->GetValue()) and !strlen($this->cp["update_by"]->GetText()) and !is_bool($this->cp["update_by"]->GetValue())) { $this->cp["update_by"]->SetValue(CCGetUserLogin()); } if (!is_null($this->cp["CURR_DOC_ID"]->GetValue()) and !strlen($this->cp["CURR_DOC_ID"]->GetText()) and !is_bool($this->cp["CURR_DOC_ID"]->GetValue())) { $this->cp["CURR_DOC_ID"]->SetValue($this->CURR_DOC_ID->GetValue(true)); } if (!strlen($this->cp["CURR_DOC_ID"]->GetText()) and !is_bool($this->cp["CURR_DOC_ID"]->GetValue(true))) { $this->cp["CURR_DOC_ID"]->SetText(0); } if (!is_null($this->cp["USER_ID_LOGIN"]->GetValue()) and !strlen($this->cp["USER_ID_LOGIN"]->GetText()) and !is_bool($this->cp["USER_ID_LOGIN"]->GetValue())) { $this->cp["USER_ID_LOGIN"]->SetValue($this->USER_ID_LOGIN->GetValue(true)); } if (!strlen($this->cp["USER_ID_LOGIN"]->GetText()) and !is_bool($this->cp["USER_ID_LOGIN"]->GetValue(true))) { $this->cp["USER_ID_LOGIN"]->SetText(0); } if (!is_null($this->cp["CURR_PROC_ID"]->GetValue()) and !strlen($this->cp["CURR_PROC_ID"]->GetText()) and !is_bool($this->cp["CURR_PROC_ID"]->GetValue())) { $this->cp["CURR_PROC_ID"]->SetValue($this->CURR_PROC_ID->GetValue(true)); } if (!strlen($this->cp["CURR_PROC_ID"]->GetText()) and !is_bool($this->cp["CURR_PROC_ID"]->GetValue(true))) { $this->cp["CURR_PROC_ID"]->SetText(0); } if (!is_null($this->cp["input_type"]->GetValue()) and !strlen($this->cp["input_type"]->GetText()) and !is_bool($this->cp["input_type"]->GetValue())) { $this->cp["input_type"]->SetValue($this->input_type->GetValue(true)); } $this->SQL = "INSERT INTO t_order_log_kronologis(\n" . " description, \n" . " create_date, \n" . " update_date, \n" . " activity, \n" . " create_by, \n" . " update_by, \n" . " counter_no, \n" . " t_customer_order_id, \n" . " p_app_user_id, \n" . " employee_no,\n" . " log_date,\n" . " p_procedure_id,\n" . " input_type) \n" . "VALUES(\n" . " '" . $this->SQLValue($this->cp["description"]->GetDBValue(), ccsText) . "', \n" . " SYSDATE, \n" . " SYSDATE, \n" . " '" . $this->SQLValue($this->cp["activity"]->GetDBValue(), ccsText) . "', \n" . " '" . $this->SQLValue($this->cp["create_by"]->GetDBValue(), ccsText) . "', \n" . " '" . $this->SQLValue($this->cp["update_by"]->GetDBValue(), ccsText) . "', \n" . " (SELECT NVL(MAX(counter_no),0)+1 FROM t_order_log_kronologis WHERE t_customer_order_id=" . $this->SQLValue($this->cp["CURR_DOC_ID"]->GetDBValue(), ccsFloat) . "), \n" . " " . $this->SQLValue($this->cp["CURR_DOC_ID"]->GetDBValue(), ccsFloat) . ", \n" . " " . $this->SQLValue($this->cp["USER_ID_LOGIN"]->GetDBValue(), ccsFloat) . ", \n" . " null,\n" . " SYSDATE,\n" . " " . $this->SQLValue($this->cp["CURR_PROC_ID"]->GetDBValue(), ccsFloat) . ",\n" . " '" . $this->SQLValue($this->cp["input_type"]->GetDBValue(), ccsText) . "')"; $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeExecuteInsert", $this->Parent); if ($this->Errors->Count() == 0 && $this->CmdExecution) { $this->query($this->SQL); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "AfterExecuteInsert", $this->Parent); } }
function Update() { global $CCSLocales; global $DefaultDateFormat; $this->CmdExecution = true; $this->cp["t_customer_order_id"] = new clsSQLParameter("ctrlt_customer_order_id", ccsFloat, "", "", $this->t_customer_order_id->GetValue(true), "", false, $this->ErrorBlock); $this->cp["description"] = new clsSQLParameter("ctrldescription", ccsText, "", "", $this->description->GetValue(true), "", false, $this->ErrorBlock); $this->cp["updated_by"] = new clsSQLParameter("expr608", ccsText, "", "", CCGetUserLogin(), "", false, $this->ErrorBlock); $this->cp["order_no"] = new clsSQLParameter("ctrlorder_no", ccsText, "", "", $this->order_no->GetValue(true), "", false, $this->ErrorBlock); $this->cp["p_rqst_type_id"] = new clsSQLParameter("ctrlp_rqst_type_id", ccsFloat, "", "", $this->p_rqst_type_id->GetValue(true), "", false, $this->ErrorBlock); $this->cp["p_order_status_id"] = new clsSQLParameter("expr616", ccsFloat, "", "", 1, 0, false, $this->ErrorBlock); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeBuildUpdate", $this->Parent); if (!is_null($this->cp["t_customer_order_id"]->GetValue()) and !strlen($this->cp["t_customer_order_id"]->GetText()) and !is_bool($this->cp["t_customer_order_id"]->GetValue())) { $this->cp["t_customer_order_id"]->SetValue($this->t_customer_order_id->GetValue(true)); } if (!is_null($this->cp["description"]->GetValue()) and !strlen($this->cp["description"]->GetText()) and !is_bool($this->cp["description"]->GetValue())) { $this->cp["description"]->SetValue($this->description->GetValue(true)); } if (!is_null($this->cp["updated_by"]->GetValue()) and !strlen($this->cp["updated_by"]->GetText()) and !is_bool($this->cp["updated_by"]->GetValue())) { $this->cp["updated_by"]->SetValue(CCGetUserLogin()); } if (!is_null($this->cp["order_no"]->GetValue()) and !strlen($this->cp["order_no"]->GetText()) and !is_bool($this->cp["order_no"]->GetValue())) { $this->cp["order_no"]->SetValue($this->order_no->GetValue(true)); } if (!is_null($this->cp["p_rqst_type_id"]->GetValue()) and !strlen($this->cp["p_rqst_type_id"]->GetText()) and !is_bool($this->cp["p_rqst_type_id"]->GetValue())) { $this->cp["p_rqst_type_id"]->SetValue($this->p_rqst_type_id->GetValue(true)); } if (!is_null($this->cp["p_order_status_id"]->GetValue()) and !strlen($this->cp["p_order_status_id"]->GetText()) and !is_bool($this->cp["p_order_status_id"]->GetValue())) { $this->cp["p_order_status_id"]->SetValue(1); } if (!strlen($this->cp["p_order_status_id"]->GetText()) and !is_bool($this->cp["p_order_status_id"]->GetValue(true))) { $this->cp["p_order_status_id"]->SetText(0); } $this->SQL = "UPDATE t_customer_order SET \n" . "description='" . $this->SQLValue($this->cp["description"]->GetDBValue(), ccsText) . "', \n" . "updated_by='" . $this->SQLValue($this->cp["updated_by"]->GetDBValue(), ccsText) . "', \n" . "updated_date=sysdate,\n" . "order_no='" . $this->SQLValue($this->cp["order_no"]->GetDBValue(), ccsText) . "', \n" . "order_date=sysdate, \n" . "p_rqst_type_id=" . $this->SQLValue($this->cp["p_rqst_type_id"]->GetDBValue(), ccsFloat) . ", \n" . "p_order_status_id=" . $this->SQLValue($this->cp["p_order_status_id"]->GetDBValue(), ccsFloat) . "\n" . "WHERE t_customer_order_id=" . $this->SQLValue($this->cp["t_customer_order_id"]->GetDBValue(), ccsFloat) . ""; $this->CCSEventResult = CCGetEvent($this->CCSEvents, "BeforeExecuteUpdate", $this->Parent); if ($this->Errors->Count() == 0 && $this->CmdExecution) { $this->query($this->SQL); $this->CCSEventResult = CCGetEvent($this->CCSEvents, "AfterExecuteUpdate", $this->Parent); } }