<?php include "layouts/menu.php"; ?>
 <script>
	function autocomplet() {
	var min_length = 0; // min caracters to display the autocomplete
	var keyword = $('#did').val();
	if (keyword.length >= min_length) {
		$.ajax({
			url: 'ajax_refresh.php',
			type: 'POST',
			data: {keyword:keyword},
			success:function(data){
				$('#country_list_id').show();
				$('#country_list_id').html(data);
			}
		});
	} else {
		$('#country_list_id').hide();
	}
}
function set_item(item) {
	// change input value
	$('#did').val(item);
	// hide proposition list
	$('#country_list_id').hide();
}
	</script>
	 <script>
	function autocomp() {
	var min_length = 0; // min caracters to display the autocomplete
	var keyword = $('#didn').val();
	if (keyword.length >= min_length) {
		$.ajax({
			url: 'ajax_sname.php',
			type: 'POST',
			data: {keyword:keyword},
			success:function(data){
				$('#dname').show();
				$('#dname').html(data);
			}
		});
	} else {
		$('#dname').hide();
	}
}

// set_item : this function will be executed when we select an item
function set_itemm(item) {
	// change input value
	$('#didn').val(item);
	// hide proposition list
	$('#dname').hide();
}
	</script>
 <script>
	function autocomplett() {
	var min_length = 0; // min caracters to display the autocomplete
	var keyword = $('#zxcvb').val();
	if (keyword.length >= min_length) {
		$.ajax({
			url: 'ajax_refreshq.php',
			type: 'POST',
			data: {keyword:keyword},
			success:function(data){
				$('#qwertyu').show();
				$('#qwertyu').html(data);
			}
		});
	} else {
		$('#qwertyu').hide();
	}
}
// set_item : this function will be executed when we select an item
function set_itemmm(item) {
	// change input value
	$('#zxcvb').val(item);
	// hide proposition list
	$('#qwertyu').hide();
}
	</script>
  <div class="right_col" role="main">
            <div class="row">
                 <!-- page header -->
                
                <!--end page header -->
            </div>
            <div class="row">
                <div class="col-lg-12">
				<a href="pending.php"><button class="btn btn-primary">Overal Pending Report</button></a>&nbsp;&nbsp;
                    <!-- Form Elements -->
                    <div class="panel panel-default">
                      
                        <div class="panel-body">
           <div class="col-lg-6">                                          
                            <div class="row">
   <div class="alert alert-info">Pending List Area Wise</div>
   <form name="form1" class="form-horizontal" method="post" action="" enctype="multipart/form-data">
   <div class="form-group">
    <label for="inputPassword3" class="col-sm-2 control-label">Area</label>
    <div class="col-sm-4">
      <select type="text" class="form-control" id="inputPassword3" name="area" placeholder="E.g 1008" required>
     <option value="dd">All Area</option>
	<?php 
$qry=mysqli_query($conn, "select * from msarea order by name asc");
	while($row2=mysqli_fetch_array($qry))
						{ ?><option><?php echo $row2['name'];?></option>
						<?php } ?> </select>
    </div>
  </div>	
   <div class="form-group">
    <label for="inputPassword3" class="col-sm-2 control-label">Due From</label>
    <div class="col-sm-4">
      <input type="text" class="form-control" id="inputPassword3" name="due" value="" placeholder="E.g 1008" required>


    </div>
  </div>
 <div class="form-group">
    <label for="inputPassword3" class="col-sm-2 control-label">Due to</label>
    <div class="col-sm-4">
      <input type="text" class="form-control" id="inputPassword3" name="due2" value="" placeholder="E.g 1008" required>


    </div>
  </div>  
   <div class="form-group">
    <label for="inputPassword3" class="col-sm-2 control-label">Address Option</label>
    <div class="col-sm-4">
      <select type="text" class="form-control" id="inputPassword3" name="add" value="" placeholder="E.g 1008" required>
     <option value="0">Without Address</option>
	 <option value="1">With Address</option> 	 <option value="2">With Address+ Gr</option>
 </select>
    </div> </div> 
  <div class="form-group">
    <div class="col-sm-offset-2 col-sm-10">
      <button type="submit" class="btn btn-danger" name="s3645">Search It</button>
    </div>
  </div>
      <div class="alert alert-success">
	  <?php
								if(isset($_POST['s3645']))
								{
									extract($_POST);
									if($add == 1){
									if($area == 'dd') {
									header("location:sspenddue.php?due=$due&due2=$due2");
									}
									else {
									header("location:sspend00.php?due=$due&due2=$due2&area=$area"); }
									}
									elseif($add == 2){
									if($area == 'dd') {
									header("location:sspenddue.php?due=$due&due2=$due2");
									}
									else {
									header("location:sspendg00.php?due=$due&due2=$due2&area=$area"); }
									}
									else {
									if($area == 'dd') {
									header("location:sspenddue.php?due=$due&due2=$due2");
									} else {
									header("location:sspend001.php?due=$due&due2=$due2&area=$area");	}
									}
									
								}
							?>
	  </div>
</form>
</div>

 <div class="row">
   <div class="alert alert-info">Pending List Vehicle Wise</div>

   
<form name="form45577" class="form-horizontal" method="post" action="" enctype="multipart/form-data">
    <div class="form-group has-error has-feedback">
    <label for="inputPassword3" class="col-sm-2 control-label">Area</label>
    <div class="col-sm-4">
      <select type="text" class="form-control"  id="areaf" name="area" value="" placeholder="" required>
	  <option>Select</option>
	  <?php $sql33 = mysqli_query($conn, "select * from msarea order by name asc");
	  while($row33 = mysqli_fetch_array($sql33)) { ?>
	   <option><?php echo $row33['name']; ?></option>
	  <?php } ?> </select>
	  <span class="glyphicon glyphicon-phone-alt form-control-feedback"></span>
    </div>
  </div>
   <div class="form-group has-error has-feedback">
    <label for="inputPassword3" class="col-sm-2 control-label">Vehicle Name</label>
    <div class="col-sm-4">
      <select type="text" class="form-control"  id="vname" name="vname" value="" placeholder="" required>
	  <option>Select</option>
	  <?php $sql33 = mysqli_query($conn, "select * from mveh order by name asc");
	  while($row33 = mysqli_fetch_array($sql33)) { ?>
	   <option><?php echo $row33['name']; ?></option>
	  <?php } ?> </select>
	  <span class="glyphicon glyphicon-phone-alt form-control-feedback"></span>
    </div>
  </div>
  <div class="form-group">
    <div class="col-sm-offset-2 col-sm-10">
      <button type="submit" class="btn btn-danger" name="s45566">Search It</button>
    </div>
  </div>
      <div class="alert alert-success">
      <?php
								if(isset($_POST['s45566']))
								{
									extract($_POST);
								
										header("location:pendvn.php?area=$area&vname=$vname");
								}
							?>
	  </div>
</form>	

</div>
   
</div>
<div class="col-lg-6">   
  <div class="row">
   <div class="alert alert-info">Pending List AREA GROUP</div>
   <form name="form1" class="form-horizontal" method="post" action="" enctype="multipart/form-data">
   <div class="form-group">
    <label for="inputPassword3" class="col-sm-2 control-label">Area</label>
    <div class="col-sm-4">
      <select type="text" class="form-control" id="inputPassword3" name="area" value="" placeholder="E.g 1008" required>
     <option>Select</option>
	<?php 
$qry=mysqli_query($conn, "select * from marea order by name asc");
	while($row2=mysqli_fetch_array($qry))
						{ ?> <option><?php echo $row2['name'];?></option>
						<?php } ?> </select>
    </div>
  </div>	
   <div class="form-group">
    <label for="inputPassword3" class="col-sm-2 control-label">Due From</label>
    <div class="col-sm-4">
      <input type="text" class="form-control" id="inputPassword3" name="due" value="" placeholder="E.g 1008" required>


    </div>
  </div>
 <div class="form-group">
    <label for="inputPassword3" class="col-sm-2 control-label">Due to</label>
    <div class="col-sm-4">
      <input type="text" class="form-control" id="inputPassword3" name="due2" value="" placeholder="E.g 1008" required>


    </div>
  </div>  
   <div class="form-group">
    <label for="inputPassword3" class="col-sm-2 control-label">Address Option</label>
    <div class="col-sm-4">
      <select type="text" class="form-control" id="inputPassword3" name="add" value="" placeholder="E.g 1008" required>
     <option value="0">Without Address</option>
	 <option value="1">With Address</option> 
 </select>
    </div> </div> 
  <div class="form-group">
    <div class="col-sm-offset-2 col-sm-10">
      <button type="submit" class="btn btn-danger" name="s3649">Search It</button>
    </div>
  </div>
      <div class="alert alert-success">
	  <?php
								if(isset($_POST['s3649']))
								{
									extract($_POST);
									if($add == 0){
										header("location:sspend00g.php?due=$due&due2=$due2&area=$area");
									}
									else {
										header("location:sspend00gg.php?due=$due&due2=$due2&area=$area");
									}
									
									
								}
							?>
	  </div>
</form>
</div>
 <div class="row">
   <div class="alert alert-info">Pending List Area Wise Without Address</div>
   <form name="form1" class="form-horizontal" method="post" action="" enctype="multipart/form-data">
   <div class="form-group">
    <label for="inputPassword3" class="col-sm-2 control-label">Area</label>
    <div class="col-sm-4">
      <select type="text" class="form-control" id="inputPassword3" name="area" value="" placeholder="E.g 1008" required>
     <option>Select</option>
	<?php 
$qry=mysqli_query($conn, "select * from msarea order by name asc");
	while($row2=mysqli_fetch_array($qry))
						{ ?> <option><?php echo $row2['name'];?></option>
						<?php } ?> </select>
    </div>
  </div>	
   <div class="form-group">
    <label for="inputPassword3" class="col-sm-2 control-label">Due Date</label>
    <div class="col-sm-4">
      <input type="text" class="form-control" id="inputPassword3" name="due" value="" placeholder="E.g 05" required>


    </div>
  </div>
 
  <div class="form-group">
    <div class="col-sm-offset-2 col-sm-10">
      <button type="submit" class="btn btn-danger" name="s36411">Search It</button>
    </div>
  </div>
      <div class="alert alert-success">
	  <?php
								if(isset($_POST['s36411']))
								{
									extract($_POST);
									
										header("location:sspend0011.php?due=$due&area=$area");
									
									
								}
							?>
	  </div>
</form>
</div>



</div></div>
<div class="col-lg-12">   
 <div class="row">
   <div class="alert alert-info">Pending List A/C NO WISE</div>
 <form name="form132" class="form-horizontal" method="post" action="" enctype="multipart/form-data">
   <div class="form-group">
    <label for="inputPassword3" class="col-sm-2 control-label">A/C No's Separate by Comma</label>
    <div class="col-sm-8">
      <textarea cols="15" rows="6" type="text" class="form-control" id="inputPassword3" name="hpl" value="" placeholder="E.g 1008" required></textarea>
    </div>
  </div>
 <div class="form-group">
    <label for="inputPassword3" class="col-sm-2 control-label">Address Option</label>
    <div class="col-sm-4">
      <select type="text" class="form-control" id="inputPassword3" name="add" value="" placeholder="E.g 1008" required>
     <option value="0">Without Address</option>
	 <option value="1">With Address</option>
	 	 <option value="2">With Address + GR</option>
 </select>
    </div>
  </div>  
   <div class="form-group">
    <label for="inputPassword3" class="col-sm-2 control-label">Area Wise</label>
    <div class="col-sm-4">
      <select type="text" class="form-control" id="inputPassword3" name="areaa" value="" placeholder="E.g 1008" required>
 
	 <option value="1">Area Wise</option>
	     <option value="0">Normal</option>
 </select>
    </div>
  </div>  
  <div class="form-group">
    <div class="col-sm-offset-2 col-sm-10">
      <button type="submit" class="btn btn-danger" name="s834">Search It</button>
    </div>
  </div>
      <div class="alert alert-success">
	  <?php
								if(isset($_POST['s834']))
								{
									extract($_POST);
									if($add == 0) {
										if($areaa == 0) {
										header("location:pendhh.php?hpl=$hpl");
										}
										else {
										header("location:pendhh66.php?hpl=$hpl");
										}
									}
									elseif($add == 2) {
										if($areaa == 0) {
										header("location:pendhhg.php?hpl=$hpl");
										}
										else {
										header("location:pendhhg.php?hpl=$hpl");
										}
										
									}
									else {
										if($areaa == 0) {
										header("location:pendhh2.php?hpl=$hpl");
										}
										else {
										header("location:pendhh22.php?hpl=$hpl");
										}
									}								
								}
							?>
	  </div>
</form></div>
</div>
</div></div></div> <?php include "layouts/footer.php"; ?></body></html>
