<?php
include "koneksi.php";
if (!isset($_SESSION["UserID"])) {
	header("location:login.php?p=3");
}
$id = mysqli_real_escape_string($conn, $_GET["id"]);
$q = "SELECT * FROM data_karyawan WHERE id='$id'";
//echo "query karyyawan : " . $q .  "</br>";
$res = mysqli_query($conn, $q);
$data = mysqli_fetch_assoc($res);
//$ids=mysqli_real_escape_string($conn,$_GET["ids"]);
?>
<!DOCTYPE html>
<link rel="stylesheet" type="text/css" href="style.css">
<html>

<head>
	<meta http-equiv=”Content-Type” content=”text/html; charset=utf-8″ />
	<title> PT. MULTI HYDRACHROM BALIKPAPAN </title>
				<?php
			include "part/menu2.php";
			?>
	 <link rel=”stylesheet” href=”http://aplikasikita.com/styles/style.css&#8221; type=”text/css” />
    <link rel=”icon” href=”mhb.jpg”>
	<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 class="alert alert-info" style='color:#FFD700' href="#">
            <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 class="alert alert-info" align='center'>
				<h2 align="center">TAMBAH DEMOSI</h2>

				<?php
				if (isset($_GET["p"])) {
					$p = mysqli_real_escape_string($conn, $_GET["p"]);
					if ($p == "1") {
				?>
						<div class="alert alert-primary" role="alert">
							Berhasil
						</div>
					<?php
					} else if ($p == "2") {
					?>
						<div class="alert alert-primary" role="alert">
							Gagal
						</div>
				<?php
					}
				}
				?>

				<form method="POST" action="simpanTambahDemosi.php?id=<?php echo $id; ?>">
					<div class="form-group">
					<label for="exampleInputPassword1">TANGGAL PENGAJUAN</label>
						<input type="text" readonly class="form-control" value="<?php echo date('d / m / yy'); ?>" name="tanggal_pengajuan_promosi" placeholder="">
						
						
						<h3 align="center">Data Karyawan</h3>
						
						<label for="exampleInputPassword1">NIK</label>
						<input type="text" readonly class="form-control" value="<?php echo $data["nik"]; ?>" name="nik" placeholder="">

						<label for="exampleInputPassword1">NAMA KARYAWAN</label>
						<input type="text" readonly class="form-control" value="<?php echo $data["nama_karyawan"]; ?>" name="nama_karyawan" placeholder="">
						
						<label for="exampleInputPassword1">ASAL PENERIMAAN</label>
						<input type="text" readonly class="form-control" value="<?php echo $data["asal_penerimaan"]; ?>" name="asal_penerimaan" placeholder="">

                        <label for="exampleInputPassword1">JABATAN</label>
						<input type="text" readonly class="form-control" value="<?php echo $data["departement"]; ?>" name="departement" placeholder="">

						<label for="exampleInputPassword1">DEPARTEMENT</label>
						<input type="text" readonly class="form-control" value="<?php echo $data["jabatan"]; ?>" name="jabatan" placeholder="">

						<label for="exampleInputPassword1">TANGGAL MULAI KERJA</label>
						<input type="text" readonly class="form-control" value="<?php echo $data["tanggal_masuk"]; ?>" name="tanggal_masuk" placeholder="">

				

                        <h3 align="center">Data Yang Bertanggung Jawab</h3>
						
						<label for="exampleInputPassword1">NAMA</label>
						<input type="text" class="form-control" name="nama_penanggung_jawab" placeholder="">
						
						<label for="exampleInputPassword1">JABATAN</label>
						<input type="text" class="form-control" name="jabatan_penanggung_jawab" placeholder="">
						
						
						
						<h3 align="center">Akan di Promosikan menjadi</h3>
						
						<label for="exampleInputPassword1">JABATAN BARU</label>
						<input type="text" class="form-control" name="jabatan_baru" placeholder="">
						
						<label for="exampleInputPassword1">DEVISI / DEPARTEMENT BARU</label>
						<input type="text" class="form-control" name="departement_baru" placeholder="">
						
						
						
						

					<br>
					</br>
					<input type="submit" value="Simpan" class="btn btn-primary"></input>
					| <a href="spDemosi.php"><button type="button" class="btn btn-danger">Kembali</button></a>


				</form>
			</div>


</body>

</html>