Advertisement
oodz

Untitled

May 19th, 2018
237
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 7.57 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 = 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.                     $tglinput       = $row['tgl_input'];
  72.                             $tgl        = explode('-',$tglinput);
  73.                             $tanggal    = $tgl[2].'-'.$tgl[1].'-'.$tgl[0];
  74.                             $cb = $tgl[1];
  75.                             $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");
  76.                             $cbx = $bln["$cb"];
  77.                     $id_dttruk      = sprintf('%04d',$id_gd);
  78.                     $ket8           = "$id_dttruk/NOTA-PAJBSMG/$cbx/$tgl[0]";
  79.                     $c = $c + 1;
  80.                     $idx = $row['id_pa'];
  81.                     $id_detail = $row['id_pem'];
  82.                     $i = $id_detail;
  83.                     $tgl_muat = $row['tglmuat'];
  84.                     $tgl = explode('-',$tgl_muat);
  85.                             $tanggal = $tgl[2].'-'.$tgl[1].'-'.$tgl[0];
  86.                     $pph = number_format($row["nilaipjk"],0,',','.');
  87.                     $pphx = $row["nilaipjk"];
  88.                     $total += $pphx;
  89.                     $totalx = number_format($total,0,',','.');
  90.                     $nodm =  $row["nodm"];
  91.                     $status =  $row["status_setorpjk"];
  92.                     $nopjkx =  $row["nopjk"];
  93.                     $nopjk  = sprintf('%03d',$nopjkx);
  94.                         if($status == "Belum di Setor")
  95.                             {    if(true)
  96.                                     {   $pphnya = $row["nilaipjk"];
  97.                                         $totalnya += $pphnya;
  98.                                         $jdtotalnya = number_format($totalnya,0,',','.'); } }
  99.                                  
  100.                         else
  101.                             {    $pphnya2 = $row["nilaipjk"];
  102.                                  $totalnya2 += $pphnya2;
  103.                                  $jdtotalnya2 = number_format($totalnya2,0,',','.'); }
  104.  
  105.   ?>
  106.   <tr>
  107.    <td width="20px"><?php echo $c; ?>.</td>
  108.     <td><?php echo "$tanggal"; ?></td>
  109.     <td align="center" width="60px"><?php echo "$nodm"; ?></td>
  110.    <td width="150px"><?php echo $row['nama']; ?></td>
  111.     <td width="210px"><?php echo $ket8; ?></td>
  112.     <td align="right" style="padding-right:5px" width="100px">Rp <?php echo "$pph"; ?></td>
  113.     <td align="right" style="padding-right:5px" width="110px"><?php echo "$status"; ?></td>
  114.     <td align="right" style="padding-right:5px" width="75px">
  115.     <input name="kode" type="hidden" value="<?php echo "$id_detail";?>" />
  116.     <input name="id" type="hidden" value="<?php echo "$idx";?>" />
  117.     <input name="id_tempnm[<?php $i; ?>]" type$="text" value="<?php echo $row['id_tx'];?>" />
  118.     <?php
  119.     if($status == "Telah di Setor")
  120.         {?>Beres<input name="" type="checkbox" value="" checked  disabled="disabled" style="background-color:#99FF00"/>
  121.     <?php   }
  122.     else
  123.         {?>
  124.             Setor<input name="status[<?php $i; ?>]" type="checkbox" value="<?php echo "$id_detail";?>" />
  125.         <?php }?>
  126.     </td>
  127.     <td align="right" style="padding-right:5px" width="120px">
  128.     <?php
  129.     if($status == "Telah di Setor")
  130.         {      
  131.         $masapjk = $row["masapjk"];
  132.         $masa = explode('-',$masapjk);
  133.         $ms = $masa[0].'-'.$masa[1];
  134.         $cb = $masa[0];
  135.         $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");
  136.         $cbx = $bln["$cb"];
  137.  echo "$masapjk"; ?>
  138.     <?php   }
  139.     else
  140.         {?>
  141.             <select name="bulan[<?php $i; ?>]">
  142.             <option>01</option>
  143.             <option>02</option>
  144.             <option>03</option>
  145.             <option>04</option>
  146.             </select>.
  147.             <select name="tahun[<?php $i; ?>]">
  148.             <option>2018</option>
  149.             <option>2019</option>
  150.             <option>2020</option>
  151.             </select>
  152.            
  153.            
  154.         <?php }?>
  155.     </td>
  156.     <td align="right" style="padding-right:5px" width="160px">
  157.     <?php
  158.     if($status == "Telah di Setor")
  159.         {?> <?php echo "$nopjk/PAJBSMG/$cbx/$masa[1]"; ?>
  160.     <?php   }
  161.     else
  162.         {
  163.         ?><input name="nopjk[<?php $i; ?>]" type="hidden" value="" />
  164.         <?php }?>
  165.  
  166.     </td>
  167.    </tr>
  168.  
  169.   <?php
  170.                 }  
  171.  ?> </table></div>
  172. <table border="1px solid #000" style="font-family:Verdana, Arial, Helvetica, sans-serif; font-size:14px;border-collapse:collapse; margin-left:5px">  
  173. <tr >
  174.    <td align="right" width="541px"><b>Total Keseluruhan :</b></td>
  175.     <td align="right" style="padding-right:5px; float:"> <b>Rp <?php echo $totalx; ?></b></td>
  176. </tr>
  177. <tr>
  178.    <td align="right" bgcolor='#FF9900'><b>Total PPh yg blm di Setor :</b></td>
  179.     <td align="right" style="padding-right:5px; float:" bgcolor="#FF9900"> <b>Rp <?php echo $jdtotalnya; ?></b></td>
  180. </tr>
  181. <tr>
  182.    <td align="right"><b>Total PPh yg Sdh di Setor :</b></td>
  183.     <td align="right" style="padding-right:5px; float:"> <b>Rp <?php echo $jdtotalnya2; ?></b></td>
  184. </tr>
  185.    
  186. <?php
  187.  }}
  188. ?>
  189. <tr>
  190.     <td colspan="6" align="right" style="padding-right:10px">Simpan Perubahan <b>STATUS</b></td>
  191.     <td align="center"><input name="simpan" type="image" src="simpan.png" width="100px" value="simpan" title="Simpan perubahan status"/></td>
  192. </tr>
  193.  </table>
  194.  </p>
  195. </fieldset>
  196. </form>
  197. <p style="margin-left:50px">
  198. <fieldset style="margin-left:50px; padding-left:20px; width:auto">
  199. <table style="font-family:Verdana, Arial, Helvetica, sans-serif">
  200. <tr>
  201. <td>Print data Pajak yang mau di setor :</td>
  202. <td style="margin-left:50px">
  203. <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>
  204. <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>
  205. </tr></table>
  206. </fieldset>
  207. </p>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement