Advertisement
Guest User

Untitled

a guest
May 18th, 2018
183
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 7.64 KB | None | 0 0
  1. <form action="" method="post">
  2. <p style="font-weight:bold; font-family:Verdana, Arial, Helvetica, sans-serif; margin-left:50px">DAFTAR LAPORAN NOTA KENA PPH 2%</p>
  3. <fieldset style="margin-left:50px; padding-left:20px; width:auto">
  4. <table style="font-family:Verdana, Arial, Helvetica, sans-serif;" >
  5. <tr><td>Filter Berdasarkan Nama PT. Gabungan</td><td>:</td>
  6. <td>
  7. <select name="angkutan" >
  8. <option>- Pilih -</option>
  9.                 <?php
  10.                 $sql = mysql_query("select * from angkutan where jnspjk like 2 order by nama ASC ") or die (mysql_error());
  11.                 $cek = mysql_num_rows($sql);
  12.                 while($data = mysql_fetch_array($sql))
  13.                     {
  14.                         $id     = $data["id"];
  15.                         $nama   = $data["nama"];
  16.                 ?>
  17. <option value="<?php echo $id;?>"><?php echo $nama;?></option>
  18.                <?php }?>
  19. </select>
  20. </td>
  21. <td><input type="submit" value="Laksanakan"></td>
  22. </tr>
  23. </table>
  24. </fieldset>
  25. </form>
  26. <form action="ubah_status_pph.php" method="post">
  27. <fieldset style="margin-left:50px; padding-left:20px; width:auto">
  28. <div  class="tbl-header">
  29. <table border="1px solid #000" style="font-family:Verdana, Arial, Helvetica, sans-serif; font-size:14px;border-collapse:collapse;">
  30.     <tr align="center" style="font-weight:bold; padding-left:5px; padding-right:5px;background-color:#fc0; ">
  31.         <td>No.</td>
  32.         <td width="89px">Tanggal</td>
  33.         <td width="60px">No DM</td>
  34.         <td width="150px">Nama</td>
  35.         <td width="210px">ID</td>
  36.         <td width="100px">Nilai PPH</td>
  37.         <td width="116px">Status</td>
  38.         <td width="80px">Perlakuan</td>
  39.         <td width="123px">Masa Pajak</td>
  40.         <td width="165px">No Pajak</td>
  41.     </tr>
  42. </table>
  43. </div>
  44. <div  class="tbl-content">  
  45. <table border="1px solid #000" style="font-family:Verdana, Arial, Helvetica, sans-serif; font-size:14px;border-collapse:collapse;">
  46. <?php
  47.     if (isset($_POST['angkutan']))
  48.     {
  49.         $tabel  = "select * from pembayaran p inner join gd_total gd on p.id_tx = gd.id_tx WHERE gd.status_byr='Telah di Cek' and p.id = ".$_POST['angkutan'];
  50.         $i=1;
  51.         $c = 0;
  52.         $total = 0;
  53.         $totalnya = 0;
  54.         $totalnya2 = 0;
  55.         $jdtotalnya = 0;
  56.         $jdtotalnya2 = 0;
  57.  
  58.         $result = mysql_query($tabel) or die('Error, daftar angkutan failed. ' . mysql_error());  
  59.        
  60.         if (mysql_num_rows($result) == 0)
  61.             {  
  62.                 echo '<p></p><p style="font-family:Verdana, Arial, Helvetica, sans-serif"><b>Pencarian tidak ditemukan</b></p>';  
  63.             }
  64.         else
  65.             {  
  66.                 echo '<p></p>'; ?>
  67.                    
  68.         <?php
  69.             while ($row = mysql_fetch_array($result))
  70.                 {  
  71.                     extract($row);
  72.                     $tglinput       = $row['tgl_input'];
  73.                             $tgl        = explode('-',$tglinput);
  74.                             $tanggal    = $tgl[2].'-'.$tgl[1].'-'.$tgl[0];
  75.                             $cb = $tgl[1];
  76.                             $bln = array("01"=>"I","02"=>"II","03"=>"III","04"=>"IV","05"=>"V","06"=>"VI","07"=>"VII","08"=>"VIII","09"=>"IX","10"=>"X","11"=>"XI","12"=>"XII");
  77.                             $cbx = $bln["$cb"];
  78.                     $id_datatruk    = sprintf('%04d',$row["id_datatruk"]);
  79.                     $id_dttruk      = sprintf('%04d',$id_datatruk);
  80.                     $ket8           = "$id_dttruk/NOTA-KMSMG/$cbx/$tgl[0]";
  81.                     $c = $c + 1;
  82.                     $idx = $row['id_pa'];
  83.                     $id_detail = $row['id_pem'];
  84.                     $tgl_muat = $row['tglmuat'];
  85.                     $tgl = explode('-',$tgl_muat);
  86.                             $tanggal = $tgl[2].'-'.$tgl[1].'-'.$tgl[0];
  87.                     $pph = number_format($row["nilaipjk"],0,',','.');
  88.                     $pphx = $row["nilaipjk"];
  89.                     $total += $pphx;
  90.                     $totalx = number_format($total,0,',','.');
  91.                     $nodm =  $row["nodm"];
  92.                     $status =  $row["status_setorpjk"];
  93.                     $nopjkx =  $row["nopjk"];
  94.                     $nopjk  = sprintf('%03d',$nopjkx);
  95.                         if($status == "Belum di Setor")
  96.                             {    if(true)
  97.                                     {   $pphnya = $row["nilaipjk"];
  98.                                         $totalnya += $pphnya;
  99.                                         $jdtotalnya = number_format($totalnya,0,',','.'); } }
  100.                                  
  101.                         else
  102.                             {    $pphnya2 = $row["nilaipjk"];
  103.                                  $totalnya2 += $pphnya2;
  104.                                  $jdtotalnya2 = number_format($totalnya2,0,',','.'); }
  105.  
  106.    ?>
  107.    <tr>
  108.     <td width="20px"><?php echo $c; ?>.</td>
  109.     <td><?php echo "$tanggal"; ?></td>
  110.     <td align="center" width="60px"><?php echo "$nodm"; ?></td>
  111.     <td width="150px"><?php echo $row['nama']; ?></td>
  112.     <td width="210px"><?php echo $ket8; ?></td>
  113.     <td align="right" style="padding-right:5px" width="100px">Rp <?php echo "$pph"; ?></td>
  114.     <td align="right" style="padding-right:5px" width="110px"><?php echo "$status"; ?></td>
  115.     <td align="right" style="padding-right:5px" width="75px">
  116.     <input name="kode" type="hidden" value="<?php echo "$id_detail";?>" />
  117.     <input name="id" type="hidden" value="<?php echo "$idx";?>" />
  118.     <input name="id" type="hidden" value="<?php echo "$idx";?>" />
  119.     <input name="id_tempnm" type="text" value="<?php echo $row['id_tx'];?>" />
  120.     <?php
  121.     if($status == "Telah di Setor")
  122.         {?>Beres<input name="" type="checkbox" value="" checked  disabled="disabled" style="background-color:#99FF00"/>
  123.     <?php   }
  124.     else
  125.         {?>
  126.             Setor<input name="status[]" type="checkbox" value="<?php echo "$id_detail";?>" />
  127.         <?php }?>
  128.     </td>
  129.     <td align="right" style="padding-right:5px" width="120px">
  130.     <?php
  131.     if($status == "Telah di Setor")
  132.         {      
  133.         $masapjk = $row["masapjk"];
  134.         $masa = explode('-',$masapjk);
  135.         $ms = $masa[0].'-'.$masa[1];
  136.         $cb = $masa[0];
  137.         $bln = array("01"=>"I","02"=>"II","03"=>"III","04"=>"IV","05"=>"V","06"=>"VI","07"=>"VII","08"=>"VIII","09"=>"IX","10"=>"X","11"=>"XI","12"=>"XII");
  138.         $cbx = $bln["$cb"];
  139.  echo "$masapjk"; ?>
  140.     <?php   }
  141.     else
  142.         {?>
  143.             <select name="bln[]">
  144.             <option>01</option>
  145.             <option>02</option>
  146.             <option>03</option>
  147.             <option>04</option>
  148.             </select>.
  149.             <select name="thn[]">
  150.             <option>2018</option>
  151.             <option>2019</option>
  152.             <option>2020</option>
  153.             </select>
  154.            
  155.            
  156.         <?php }?>
  157.     </td>
  158.     <td align="right" style="padding-right:5px" width="160px">
  159.     <?php
  160.     if($status == "Telah di Setor")
  161.         {?> <?php echo "$nopjk/PAJB-SMG/$cbx/$masa[1]"; ?>
  162.     <?php   }
  163.     else
  164.         {
  165.         ?><input name="nopjk[]" type="hidden" value="" />
  166.         <?php }?>
  167.  
  168.     </td>
  169.    </tr>
  170.  
  171.   <?php
  172.                 }  
  173.  ?> </table></div>
  174. <table border="1px solid #000" style="font-family:Verdana, Arial, Helvetica, sans-serif; font-size:14px;border-collapse:collapse; margin-left:5px">  
  175. <tr >
  176.    <td align="right" width="541px"><b>Total Keseluruhan :</b></td>
  177.     <td align="right" style="padding-right:5px; float:"> <b>Rp <?php echo $totalx; ?></b></td>
  178. </tr>
  179. <tr>
  180.    <td align="right" bgcolor='#FF9900'><b>Total PPh yg blm di Setor :</b></td>
  181.     <td align="right" style="padding-right:5px; float:" bgcolor="#FF9900"> <b>Rp <?php echo $jdtotalnya; ?></b></td>
  182. </tr>
  183. <tr>
  184.    <td align="right"><b>Total PPh yg Sdh di Setor :</b></td>
  185.     <td align="right" style="padding-right:5px; float:"> <b>Rp <?php echo $jdtotalnya2; ?></b></td>
  186. </tr>
  187.    
  188. <?php
  189.  }}
  190. ?>
  191. <tr>
  192.     <td colspan="6" align="right" style="padding-right:10px">Simpan Perubahan <b>STATUS</b></td>
  193.     <td align="center"><input name="simpan" type="image" src="simpan.png" width="100px" value="simpan" title="Simpan perubahan status"/></td>
  194. </tr>
  195.  </table>
  196.  </p>
  197. </fieldset>
  198. </form>
  199. <p style="margin-left:50px">
  200. <fieldset style="margin-left:50px; padding-left:20px; width:auto">
  201. <table style="font-family:Verdana, Arial, Helvetica, sans-serif">
  202. <tr>
  203. <td>Print data Pajak yang mau di setor :</td>
  204. <td style="margin-left:50px">
  205. <input type='image' src='print.jpg' width='55' value='print' onclick="window.open('printpph.php?token=<?php echo $idx; ?>','nama_window_pop_up','size=800,height=800,scrollbars=yes,resizeable=no')" title="Print"></td>
  206. <td ><input style="margin-left:30px" type='image' src='back.png' width='80' value='back' onclick="history.back(-1)" title="Kembali ke halaman sebelumnya"></td>
  207. </tr></table>
  208. </fieldset>
  209. </p>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement