<!DOCTYPE html>
<html lang="en">

<head>

  <meta charset="utf-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
  <meta name="description" content="">
  <meta name="author" content="">

  <title>Pendaftaran Rawat Jalan</title>

  <!-- Custom fonts for this template-->
  <link href="vendor/fontawesome-free/css/all.min.css" rel="stylesheet" type="text/css">
  <link href="https://fonts.googleapis.com/css?family=Nunito:200,200i,300,300i,400,400i,600,600i,700,700i,800,800i,900,900i" rel="stylesheet">

  <!-- Custom styles for this template-->
  <link href="css/sb-admin-2.min.css" rel="stylesheet">


  <link href="https://code.jquery.com/ui/1.10.3/themes/redmond/jquery-ui.css" rel="stylesheet" media="screen">

  <link rel="stylesheet" href="css/bootstrap-datetimepicker.min.css" type="text/css">  

 
  <link href="aset/css/ie10-viewport-bug-workaround.css" rel="stylesheet">

        <!-- Custom styles for this template -->
  
  <script src="aset/js/jquery.min.js"></script>
  <script src="aset/js/ie-emulation-modes-warning.js"></script>

</head>

<body id="page-top">

<?php
include "koneksi.php";
date_default_timezone_set('Asia/Jakarta');


?>

  <!-- Page Wrapper -->
  <div id="wrapper">

   
    <div id="content-wrapper" class="d-flex flex-column">

      <!-- Main Content -->
      <div id="content">

        <!-- Topbar -->
        <nav class="navbar navbar-expand navbar-light bg-white topbar mb-4 static-top shadow">

          <a><img src="images/Logo Kramat.png" width="53" height="50" > RS Kramat 128 </a>
        
        </nav>
        <!-- End of Topbar -->

        <!-- Begin Page Content -->
        <div class="container-fluid">

          <!-- Page Heading -->
          <div class="d-sm-flex align-items-center justify-content-between mb-2">
            <h1 class="h3 mb-0 text-gray-800">Pendaftaran <small>Rawat Jalan</small>
            </h1>
          </div>

          <!-- Content Row -->
          <div class="row">

            <!-- Earnings (Monthly) Card Example -->


            <!-- Earnings (Monthly) Card Example -->
            <div class="col-xl-3 col-md-4 mb-1">
              <div class="card border-left-success shadow h-80 py-2">
                <div class="card-body">
                  <div class="row no-gutters align-items-center">
                    <div class="col mr-2">
                    <div class="text-xs font-weight-bold text-primary text-uppercase mb-1">Silakan Pilih Cara Bayar</div>
                      <div class="dropdown">
            <button class="btn btn-secondary dropdown-toggle" type="button" id="dropdownMenu2" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
              Pilih Cara Bayar
            </button>
            <div class="dropdown-menu" aria-labelledby="dropdownMenu2">
              <a class="dropdown-item" type="button" href="daftar_umum_l.php">Umum</a>
              <a class="dropdown-item" type="button" href="daftar_bpjs_l.php">BPJS</a>
              <a class="dropdown-item" type="button" href="daftar_asuransi_l.php">ASURANSI</a>
            </div>
          </div>
                    </div>
                    <div class="col-auto">
                      
                    </div>
                  </div>
                </div>
              </div>
            </div>

            <!-- Earnings (Monthly) Card Example -->
           

            <!-- Pending Requests Card Example -->
            
          </div>

          <!-- Content Row -->

          <div class="row">

            <!-- Area Chart -->
            <div class="col-xl-8 col-lg-7">
              <div class="card shadow mb-4">
                <!-- Card Header - Dropdown -->
                <div class="card-header py-3 d-flex flex-row align-items-center justify-content-between">
                  <h6 class="m-0 font-weight-bold text-primary">Data Rencana Pelayanan</h6>
                  
                </div>
                <!-- Card Body -->
                <div class="card-body">
                  <form class="form-horizontal" role="form" method="post" action="proses.php?proses=pendaftaran">
                    <div class="col-lg-5">
                      <form role="form">
                        <div class="form-group">                          
                        <input class="form-control" name="tanggal" type="hidden" value="<?php echo date("Y-m-d"); ?>">
                        </div>
                        
                        <div class="form-group">
                        <input class="form-control" name="waktu" type="hidden" value="<?php echo date("H:i:s"); ?>">
                        </div>
                        
                        <div class="form-group">
                        <input class="form-control" name="jpasien" type="hidden" value="Lama" >
                        </div>

                        <div class="form-group">
                        <input class="form-control" name="kodecarabayar" type="hidden" value="B1" >
                        </div>
                        
                        <div class="form-group">
                        <input class="form-control" name="namaasuransi" type="hidden" value="0" >
                        </div>

                        <div class="form-group">
                        <input class="form-control" name="noasuransi" type="hidden" value="0" >
                        </div>

                        <div class="form-group">
                        <input class="form-control" name="nomr" placeholder="No Pasien" required>
                        </div>
                      
                        <div class="form-group">
                        <input class="form-control" placeholder="No KTP/SIM" type="hidden" name="ktp" value="0" required>
                        </div>
                                               
                        <div class="form-group">                        
                        <input class="form-control" placeholder="No Kartu BPJS..." name="nobpjs" required>
                        </div>

                        <div class="form-group">
                        <input class="form-control" placeholder="Nama Lengkap..." name="namapasien" required>
                        </div>
                        
                        <div class="form-group">
                        <input class="form-control" placeholder="Alamat..." name="alamat" required>
                        </div>

                        <div class="form-group">
                        <input class="form-control" placeholder="Tanggal Lahir." name="tanggal_lahir" required>
                        </div>

                        <div class="form-group">                        
                        <input class="form-control" placeholder="No Handphone..." name="nohp" required>
                        </div>
                                                
                        <div class="form-group">
                                            
                                                <select id="namapoli" class="form-control" name="kodepoli">
                                                <option value="">Pilih Poliklinik</option>
                                                <?php
                                                    $query = mysqli_query($koneksi, "SELECT * FROM poliklinik");
                                                    while ($row = mysqli_fetch_array($query)) { ?>

                                                    <option value="<?php echo $row['kodepoli']; ?>">
                                                        <?php echo $row['namapoli']; ?>
                                                    </option>

                                                <?php } ?>
                                            </select>

                                           
                        </div>
                        <div class="form-group">
                                            <select id="namadokter" class="form-control" name="kodedokter">
                                                <option value="">Pilih Dokter</option>
                                                <?php
                                                    $query = mysqli_query($koneksi, "SELECT * FROM dokter INNER JOIN poliklinik ON dokter.kodepoli = poliklinik.kodepoli ");
                                                    while ($row = mysqli_fetch_array($query)) { ?>

                                                    <option id="namadokter" class="<?php echo $row['kodepoli']; ?>" value="<?php echo $row['kodedokter']; ?>">
                                                        <?php echo $row['namadokter']; ?>
                                                    </option>

                                                <?php } ?>
                                            </select>
                                             
                
                                           
                        </div> 
                        <div class="form-group">
                                            <select id="jadwal" class="form-control" name="jadwal">
                                                <option value="">Pilih Jadwal</option>
                                                <?php
                                                    $query = mysqli_query($koneksi, "SELECT * from jadwal inner join dokter on dokter.kodedokter=jadwal.kodedokter");
                                                    while ($row = mysqli_fetch_array($query)) { ?>

                                                    <option id="jadwal" class="<?php echo $row['kodedokter']; ?>" value="<?php echo $row['kodejadwal']; ?>">
                                                        <?php echo $row['hari'].' '.' '.'|'.' '.$row['waktumulai'].' '.'-'.' '.$row['waktuberakhir']; ?>
                                                    </option>

                                                <?php } ?>
                                            </select>
                                             
                
                                           
                        </div> 
                        
                        
                       
                        <div class="form-group">
                          <input type="text" class="form-control" id="dtp" name="waktu_pelayanan" placeholder="Tanggal Pelayanan..." required >
                        </div>

                        <button type="submit "class="btn btn-success btn-icon-split">
                   
                        <span class="text">Daftar</span>
                       </button>
                      </form>
                    </div>
                  </form>
                </div>
              </div>
            </div>

            <!-- Pie Chart -->
       
           
          </div>
          <!-- /.modal-content -->
        </div>
        <!-- /.modal-dialog -->
      </div>

          <!-- Content Row -->
          

      <!-- Footer -->
      
      <!-- End of Footer -->

    </div>
    <!-- End of Content Wrapper -->

  </div>
  <!-- End of Page Wrapper -->

  <!-- Scroll to Top Button-->
 

  <!-- Bootstrap core JavaScript-->
        

  <script src="vendor/jquery/jquery.min.js"></script>
  <script src="vendor/bootstrap/js/bootstrap.bundle.min.js"></script>

  <!-- Core plugin JavaScript-->
  <script src="vendor/jquery-easing/jquery.easing.min.js"></script>

  <!-- Custom scripts for all pages-->
  <script src="js/sb-admin-2.min.js"></script>

  <!-- Page level plugins -->
  <script src="vendor/chart.js/Chart.min.js"></script>

  <!-- Page level custom scripts -->
  <script src="js/demo/chart-area-demo.js"></script>
  <script src="js/demo/chart-pie-demo.js"></script>

<script src="js/jquery.js"></script>

    <!-- Bootstrap Core JavaScript -->
    <script src="js/bootstrap.min.js"></script>

   
    <script>
    $('.carousel').carousel({
        interval: 5000 //changes the speed
    })
    </script>

    <script src="https://code.jquery.com/jquery.js"></script>
    <!-- jQuery UI -->
    <script src="https://code.jquery.com/ui/1.10.3/jquery-ui.js"></script>
    <!-- Include all compiled plugins (below), or include individual files as needed -->
    <script src="bootstrap/js/bootstrap.min.js"></script>

    <script src="vendors/form-helpers/js/bootstrap-formhelpers.min.js"></script>

    <script src="vendors/select/bootstrap-select.min.js"></script>

    <script src="vendors/tags/js/bootstrap-tags.min.js"></script>

    <script src="vendors/mask/jquery.maskedinput.min.js"></script>

    <script src="vendors/moment/moment.min.js"></script>

    <script src="vendors/wizard/jquery.bootstrap.wizard.min.js"></script>

     <!-- bootstrap-datetimepicker -->
    <link href="vendors/bootstrap-datetimepicker/datetimepicker.css" rel="stylesheet">
    <script src="vendors/bootstrap-datetimepicker/bootstrap-datetimepicker.js"></script> 


    <link href="//cdnjs.cloudflare.com/ajax/libs/x-editable/1.5.0/bootstrap3-editable/css/bootstrap-editable.css" rel="stylesheet">
    <script src="//cdnjs.cloudflare.com/ajax/libs/x-editable/1.5.0/bootstrap3-editable/js/bootstrap-editable.min.js"></script>

    <script src="js/custom.js"></script>
    <script src="js/forms.js"></script>
     <!-- js untuk jquery -->
    <script src="js/jquery-1.11.2.min.js"></script>
    <!-- js untuk bootstrap -->
    <script src="js/bootstrap.js"></script>
    <!-- js untuk moment -->
    <script src="js/moment.js"></script>
    <!-- js untuk bootstrap datetimepicker -->
    <script src="js/bootstrap-datetimepicker.min.js"></script>

    <script type="text/javascript">
        $(document).ready(function()
        {
           $('#dtp').datetimepicker({
                format : 'DD-MM-YYYY'
             });

        });
    </script>
    
    
        <script src="aset/js/jquery-chained.min.js"></script>
        <!-- IE10 viewport hack for Surface/desktop Windows 8 bug -->
        <script src="aset/js/ie10-viewport-bug-workaround.js"></script>
        <script>
            $(document).ready(function() {
                $("#namadokter").chained("#namapoli");
                $("#jadwal").chained("#namadokter");
                
            });
        </script>
  </body>
</html>
