<?php 
include "koneksi.php";
if (!isset($_SESSION["UserID"]))
{
	header("location:login.php?p=3");
}
$idPr = $_GET['id'];
?>
<!DOCTYPE html>
<link rel="stylesheet" type="text/css" href="style.css">
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery.mask/1.14.15/jquery.mask.min.js"></script>
<html>
  <head>
	<title> PT MULTI HYDRACHROM BALIKPAPAN </title>
	<?php
						include "part/menu2.php";
					?>
	<meta name="viewport" content="width=device-width, initial-scale=1.0">
	<?php
		include "part/jss.php";
	?>
	
  </head>
  <body>
	
	<div style="width:1280px; height:100px" class="container">
	
			<div ">
            <div style="display: block; margin-left: auto; margin-right: auto; width: 1000px;  height:100px;"><img style="width: 1000px;  height:180px;" src="images/hd.jpg"></div>
            <div>
                <center>
                    <h1>PT. MULTI HIDRACHROM BALIKPAPAN</h1>
                </center>
            </div>
            <div>
                <center>
                    <h4>PROFESIONAL INFORMATION SYSTEM</h4>
                </center>
            </div>
        </div>
					
					
				
		<div >
			 <h3 align="center">TAHAP PROSES PURCHASING REQUEST</h3>
			 
			 <?php
				if (isset($_GET["p"]))
				{
					$p=mysqli_real_escape_string($conn,$_GET["p"]);
					if ($p=="1")
					{
						?>
							<div class="alert alert-primary" role="alert">
							  PR Berhasil Ditambah!
							</div>
						<?php
					}
					else if ($p=="2")
					{
						?>
							<div class="alert alert-danger" role="alert">
								sistem gagal!
							</div>
						<?php
					}
					else if ($p=="3")
					{
						?>
							<div class="alert alert-danger" role="alert">
								gagal, isi dengan berurut!
							</div>
						<?php
					}
				}

				if (isset($_GET['pesan'])) {
					if ($_GET['pesan'] == "berhasilInput") {
						echo "<div class='alert alert-success' role='alert'> Berhasil Input DB. </div>";
					}
					// if ($_GET['pesan'] == "berhasilInput") {
					// 	echo "<div class='alert alert-danger' role='alert'> Berhasil Input DB. </div>";
					// }
				}
				?>
			 <form method="POST" action="simpanPrProsesHarga.php?id=<?php echo $idPr; ?>">
			 
			 <div class="form-group" align="center">
				  <h5 align="center" color="rgb(239, 255, 255)" >"memproses data barang yang diajukan dengan memilih harga dan vendor"</h5>
				  
				  <?php
				   echo "PO Date / ".date('d - m - Y');
				   $tanggal = date('d - m - Y');
				  ?>
				  
				  <p>
				  </p>
				  <p>
				  </p>
				  <h3 align="center">DATA USER</h3>
				    <P>
					</P>
		
					<?php
					    
					
					    $q="SELECT * FROM data_purchasing_requisition WHERE id='". $_GET["id"] ."'";
						$res=mysqli_query($conn,$q);
						$dataUser=mysqli_fetch_assoc($res);
					
						$nik = $dataUser["user_request"];
						echo "NIK :".$nik;
						
					?>
					<p>
					<p>
					<?php
					    $d="SELECT * FROM data_karyawan WHERE nik=".$nik;
						$resi=mysqli_query($conn,$d);
						$dataUser1=mysqli_fetch_assoc($resi);				
						$nama = $dataUser1["nama_karyawan"];
						$departement = $dataUser1["departement"];
						
						$pr_no = $dataUser["pr_no"];
						$type_of_material = $dataUser["type_of_material"];
						$purchase_request_type = $dataUser["purchase_request_type"];
						$description = $dataUser["description"];
						$part_no = $dataUser["part_no"];
						$quantity = $dataUser["quantity"];
						$unit = $dataUser["unit"];
						$due_date = $dataUser["acc_code"];
						$no_wo = $dataUser["matr_master"];
						$consumable;
						if ($type_of_material == 1)
						{
							$consumable = "Consumable";
						}
						else if ($type_of_material == 2)
						{
							$consumable = "Non - Consumable";
						}
						
						$normal;
						if ($purchase_request_type == 1)
						{
							$normal = "Normal";
						}
						else if ($purchase_request_type == 2)
						{
							$normal = "Urgent";
						}
						else if ($purchase_request_type == 3)
						{
							$normal = "TOP Urgent";
						}
						
						echo "NAMA :".$nama."<br>";
						echo "DEPARTEMENT :".$departement;
						
					?>
							 
					
					
					<P>
					</P>
					 <h3 align="center">DATA PR</h3>
					 <label for="exampleInputPassword1">Document No.</label>
					<input readonly type="text/css" class="form-control" name="document_no" placeholder="MHB-FR-PRC-001-01">
					<P>
					</P>
					<label for="exampleInputPassword1">PR No.</label>
					<input type="text/css" readonly class="form-control" name="pr_no" placeholder=<?php echo $pr_no; ?> >
					<P>
					</P>
					<label for="exampleInputPassword1">No.WO</label>
					<input type="text/css" readonly class="form-control" name="no_wo" placeholder=<?php echo $no_wo; ?> >
					<P>
					</P>
					<label for="exampleInputPassword1">TYPE OF MATERIAL</label>
					<input type="text/css" readonly class="form-control" name="type_of_material" placeholder=<?php echo $consumable; ?> >
					<P>
					</P>
					<label for="exampleInputPassword1">PURCHASE REQUEST TYPE</label>
					<input type="text/css" readonly class="form-control" name="purchase_request_type" placeholder=<?php echo $normal; ?> >
					<P>
					</P>
					<label for="exampleInputPassword1">QUOTE No.</label>
					<input type="text/css" class="form-control" name="quote" placeholder='' >
					<P>
					</P>
					<label for="exampleInputPassword1">DUE DATE USER</label>
					<input type="text/css" readonly class="form-control" name="due_date" placeholder=<?php echo $due_date; ?> >
					<P>
					</P>
					<label for="exampleInputPassword1">DELIFERY PO DATE</label>
					<input type="date" class="form-control" name="dpo" placeholder='' >
					<P>
					</P>
					<label for="cars">ACC CODE</label>
<select id="accode" name="accode" size="4" multiple>
  <option value="1-400">1-400 --PERSEDIAAN--</option>
  <option value="1-401">1-401 Pekerjaan Dalam Proses / Persediaan</option>
  <option value="1-402">1-402 Persediaan Material</option>
  <option value="1-403">1-403 Persediaan Sparepart</option>
  <option value="1-404">1-404 Persediaan Consumable</option>
  
  <option value="1-500">1-500 --BIAYA DIBAYAR DIMUKA</option>
  <option value="1-501">1-501 PPH 23 Dibayar Dimuka</option>
  <option value="1-502">1-502 Sewa Dibayar Dimuka</option>
  <option value="1-503">1-503 Asuransi DIbayar Dimuka</option>
  <option value="1-504">1-504 Uang Muka</option>
  <option value="1-505">1-505 PPN Dibayar Muka</option>
  
  <option value="1-600">1-600 --HARTA TETAP BERWUJUD--</option>
  <option value="1-601">1-601Tanah</option>
  <option value="1-602">1-602 Bangunan</option>
  <option value="1-603">1-603 Kendaraan</option>
  <option value="1-604">1-604 Mesin - Mesin</option>
  <option value="1-605">1-605 Peralatan Tools</option>
  <option value="1-606">1-606 Peralatan Kantor & Mebel</option>
  <option value="1-607">1-607 Software</option>
  <option value="1-608">1-608 Asset Dalam Proses - BPN</option>
  <option value="1-609">1-609 Asset Dalam Proses - Berau</option>
  <option value="1-661">1-661 Akumulasi Penyusutan Bangunan</option>
  <option value="1-662">1-662 Akumulasi Penyusutan Kendaraan</option>
  <option value="1-663">1-663 Akumulasi Penyusutan Mesin - Mesin</option>
  <option value="1-664">1-664 Akumulasi Penyusutan Peralatan Tools</option>
  <option value="1-665">1-665 Akumulasi Penyusutan Peralatan Kantor & Mebel</option>
  <option value="1-666">1-666 Akumulasi Penyusutan Software</option>
  <option value="1-667">1-667 Akumulasi Penyusutan Harta Lainnya</option>
  
  <option value="1-700">1-700 --HARTA TETAP TIDAK BERWUJUD--</option>
  <option value="1-701">1-701 Hak Merk</option>
  <option value="1-702">1-702 Hak Cipta</option>
  <option value="1-703">1-703 Good Will</option>
  
  <option value="1-800">1-800 --HARTA LAINNYA--</option>
  <option value="1-801">1-801 Biaya Pra Operasi dan Operasi</option>
  <option value="1-802">1-802 Akumilasi Amortisasi Pra Operasi dan Operasi</option>
  
  <option value="2-100">2-100 --HUTANG LANCAR--</option>
  <option value="2-102x">2-102x Hutang Usaha (USD) Exchange</option>
  <option value="2-103">2-103 Hutang Pajak Penghsilan</option>
  <option value="2-104">2-104 Hutang PPN</option>
  <option value="2-105">2-105 Hutang Leasing</option>
  <option value="2-106">2-106 Hutang Bunga Palembang</option>
  <option value="2-107">2-107 Hutang Bunga Tjoa Yanndi/Khongwa</option>
  <option value="2-108">2-108 Hutang Pajak Penjualan</option>
  
  <option value="2-109">2-109 --Hutang Operasional</option>
  <option value="2-110">2-110 Hutang Pihak Ke-3</option>
  <option value="2-111">2-111 Hutang Lain - Lain</option>
  
  <option value="2-112">2-112 --Hutang Komisi Penjualan--</option>
  <option value="2-113">2-113 Hutang Sewa</option>
  <option value="2-114">2-114 Credit Card</option>
  
  <option value="3-100">3-100 --HUTANG OPERASIONAL--</option>
  <option value="3-101">3-101 Pendapatan Reparasi</option>
  <option value="3-102">3-102 Pendapatan Supplay Barang & Sewa</option>
  <option value="3-103">3-103 Pendapatan Lainnya</option>
  <option value="3-104">3-104 Potongan Penjualan</option>
  <option value="3-105">3-105 Pendapatan Denda Keterlambatan</option>
  <option value="3-106">3-106 Pendapatan Claim Kerugian</option>
  <option value="3-205">3-107 Pajak Final</option>
  
  <option value="4-100">4-100 --BIAYA PRODUKSI--</option>
  <option value="4-101">4-101 Gaji Karyawan Penjualan</option>
  <option value="4-102">4-102 Pemakaian Material</option>
  <option value="4-103">4-103 Pemakaian Sparepart</option>
  <option value="4-104">4-104 Bahan Pembantu/Consumable</option>
  <option value="4-105">4-105 Peti Kemas</option>
  <option value="4-106">4-106 PPE (Safety Diri)</option>
  <option value="4-107">4-107 BBM</option>
  <option value="4-108">4-108 Jasa Service</option>
  <option value="4-109">4-109 Biaya Atas Pengiriman Barang</option>
  <option value="4-110">4-110 Perjalanan Dinas Pengiriman Barang</option>
  <option value="4-111">4-111 Sewa Kendaraan / Alat Produksi</option>
  
  <option value="4-150">4-150 --BIAYA LAIN--</option>
  <option value="4-151">4-151 Kerugian Piutang</option>
  <option value="4-152">4-152 Biaya Denda Keterlambatan</option>
  <option value="4-153">4-153 Kerusakan dan Kegagalan Material</option>
  
  <option value="4-200">4-150 --BIAYA OPERASIONAL--</option> 
  <option value="4-201">4-201 Gaji Karyawan</option>
  <option value="4-202">4-202 Gaji Direksi</option>
  <option value="4-203">4-203 Lembur Karyawan</option>
  <option value="4-204">4-204 Listrik</option>
  <option value="4-205">4-205 Air</option>
  <option value="4-206">4-206 Telpon, Fax & Internet</option>
  <option value="4-207">4-207 Web Mail</option>
  <option value="4-208">4-208 Legal Dokumen Perusahaan</option>
  <option value="4-209">4-209 Alat Tulis & Form Percetakan</option>
  <option value="4-210">4-210 Perjalanan Dinas & Akomodasi</option>
  <option value="4-211">4-211 STNK & Pajak Kendaraan / Iuran / Retribusi Resmi</option>
  <option value="4-212">4-212 Perlengkapan Kantor</option>
  <option value="4-213">4-213 Perlengkapan Workshop/Tools</option>
  <option value="4-214">4-214 R & M Peralatan Kantor</option>
  <option value="4-215">4-215 R & M Mesin - Mesin</option>
  <option value="4-216">4-216 Tools</option>
  <option value="4-217">4-217 Kendaraan</option>
  <option value="4-218">4-218 Gedung</option>
  <option value="4-219">4-219 Biaya Sewa Mobil</option>
  <option value="4-220">4-220 Biaya Sewa Rumah</option>
  <option value="4-221">4-221 Biaya Sewa Peralatan/Lahan</option>
  <option value="4-222">4-222 Materai</option>
  <option value="4-223">4-223 Promosi dan Iklan</option>
  <option value="4-224">4-224 Pengiriman Dokumen / Barang /  Cargo</option>
  <option value="4-225">4-225 Pengobatan Karyawan Kantor / Medical Claim</option>
  <option value="4-226">4-226 BPJS Kesehatan</option>
  <option value="4-227">4-227 BPJS Ketenagakerjaan</option>
  <option value="4-228">4-228 Profesional Fee / Konsultan</option>
  <option value="4-229">4-229 Komisi Penjualan / Fee / Bonus</option>
  <option value="4-230">4-230 Pesangon / Jasa Masa Kerja</option>
  <option value="4-231">4-231 Biaya Penerimaan & Training Karyawan</option>
  <option value="4-232">4-232 Makan Minum Karyawan Kantor</option>
  <option value="4-233">4-233 Entertaiment</option>
  <option value="4-234">4-234 Entertaiment Karyawan</option>
  <option value="4-235">4-235 Kebersihan & Dapur Kotor</option>
  <option value="4-236">4-236 Asuransi Kesehatan Karyawan</option>
  <option value="4-237">4-237 Asuransi Bangunan</option>
  <option value="4-238">4-238 Asuransi Lainnya</option>
  <option value="4-239">4-239 Pengelolaan Lingkungan / Limbah</option>
  <option value="4-240">4-240 Parkir Resmi</option>
  <option value="4-241">4-241 Seragam Kantor</option>
  <option value="4-242">4-242 Pajak Bumi & Bangunan</option>
  <option value="4-243">4-243 BBM Kendaraan Kantor</option>
  <option value="4-244">4-244 Sumbangan & Iuran Bulanan</option>
  <option value="4-245">4-245 Biaya Olahraga</option>
  <option value="4-246">4-256 Biaya Mess</option>
  <option value="4-247">4-247 Biaya Administrasi & Umum</option>
  <option value="4-248">4-248 Biaya Keamanan</option>
  <option value="4-249">4-249 PPH 21</option>
  <option value="4-250">4-250 PPH 25/29</option>
  <option value="4-251">4-251 Denda Keterlambatan Pembayaran</option>
  <option value="4-238">4-238 Denda Pajak</option>
  
  <option value="4-302">4-302 Penyusutan Kendaraan</option>
  <option value="4-303">4-303 Penyusutan Peralatan</option>
  <option value="4-304">4-304 Penysutan Mesin - Mesin</option>
  <option value="4-305">4-305 Penyusutan Mabel dan ATK</option>
  <option value="4-306">4-306 Penyusutan Software</option>
  <option value="4-307">4-307 Penyusutan Harta Lainnya</option>
  <option value="4-308">4-308 Amortisasi Pra Operasi dan Operasi</option>
  
  <option value="4-400">4-400 --PENDAPATAN DILUAR USAHA--</option>
  <option value="4-401">4-401 Laba Rugi Selisih Kurs</option>
  <option value="4-402">4-402 Jasa Giro</option>
  
  <option value="3-200">3-200 --PENDAPATAN DILUAR USAHA--</option>
  <option value="3-201">3-201 Biaya Bunga Bank</option>
  <option value="3-201.1">3-201.1 Bunga & Pokok (Sementara)</option>
  <option value="3-202">3-202 Jasa Bank / BY ADM</option>
  <option value="3-203">3-203 Bunga CIMB</option>
  <option value="3-204">3-204 Biaya Bunga Leasing, dll</option>
  <option value="3-205">3-205 Bunga Palembang</option>
  <option value="3-206">3-206 Bunga Tjoa Yanndi/Khongwa</option>
  
  <option value="3-999">3-99 Bunga Lainnya</option>
  <option value="C1">C1 --BY ADM PIUTANG CUST--</option>
  
  
  
</select>
					<P>
					</P>
				    <h3 color="yellow" align="center">PILIH SUPLIER</h3>
					<select class="form-control" name="suplier">
							<?php

							$b = "SELECT *
							FROM data_suplier";

							$res = mysqli_query($conn, $b);
							while ($row = mysqli_fetch_assoc($res)) 
							{
								$selected = "";
							?>
								<option <?php echo $selected; ?> value="<?php echo $row["id"]; ?>">
									<?php
									echo $row["nama_suplier"];
									?>
								</option>
							<?php
							}
							?>
						</select>
						<p>
						</p>
						<html>
  
  <label for="exampleInputPassword1">DISCONT %</label>
  <input type="text" class="form-control" name="discont" placeholder="0" >
  <body>
     <form action="" method="post">
	 <label for="exampleInputPassword1">PPN 10% :</label>
        <input name="ppnya" type="checkbox" value="1" /> YA
		<input name="ppntidak" type="checkbox" value="0" /> TIDAK
     </form>
  </body>
</html>


						<br>
						
						<h3 color="yellow" align="center">NO. PURCHASE ORDER</h3>
						<input style="resize:none;width:100px;height:20px;" type="text/css" class="form-control" name="no_po" placeholder="No.">
				
					<P>
					</P>
				  <h3 color="yellow" align="center">DATA BARANG</h3>
				  <input style="resize:none;width:20px;height:20px;" readonly type="text/css" class="form-control" name="nomor1" placeholder="1."> <input style="resize:none;width:250px;height:20px;" type="text/css" readonly class="form-control" name="description1" placeholder="<?php echo $description; ?>">  	<input style="resize:none;width:120px;height:20px;" type="text/css" readonly class="form-control" name="part_no1" placeholder="<?php echo $part_no; ?>">  	<input style="resize:none;width:40px;height:20px;" type="text/css" readonly class="form-control" name="qty1" placeholder="<?php echo $quantity; ?>">  	<input style="resize:none;width:70px;height:20px;" type="text/css" readonly class="form-control" name="unit1" placeholder="<?php echo $unit; ?>">  	<input style="resize:none;width:200px;height:20px;" type="text/css" class="form-control" name="harga" placeholder="Rp.">     
				  <p>
				  </p>
				  
					
					
			
				 <br>
				 </br>
					
				 <br>
				 </br>
				  <button type="submit" class="btn btn-warning">Simpan</button> 
				  <a href="prDiterimaPrc.php" class="btn btn-danger">Kembali</a>
				
				</form>
				<br>
				 </br>
				 <br>
				 </br>
				 <br>
				 </br>
			
		<center><h5 class="form-signin">Copyright &copy; <a href="#" data-toggle="modal" data-target="#contact">SatrioPringgondani</a></h5></center>  
	</div>	  
  </body>
</html>



