<?php require_once('includes/check-login.php'); ?>
<?php require_once('includes/header.php'); ?>
<?php require_once('includes/menu.php'); 
	  require('includes/config.php'); ?>
<div class="content-wrapper">
        <ol class="breadcrumb">
            <li><a href="#"><i class="fa fa-dashboard"></i> Home</a></li>                    
            <li class="active"><a href="users.php">Job Request</a></li>           
        </ol>                
    <div class="box box-form"><p></p>
		<?php
		$id 	= 1002; 
		$reqId 	= 2; 
		$sql = "SELECT user_id,name,phone,email FROM user_details WHERE user_id =".$id ;
		$result = $con->query($sql);
			if ($result->num_rows > 0) {
			    while($row = $result->fetch_assoc()) {
			    	print_r($row);
			    }
			}
		?>
		<div class="row">
			<div class=" col-sm-4"></div>
			<div class=" col-sm-4">
				<h4>service provider </h4>
				<form id="rejectionList">
					<input type="hidden" id="id_Sp" name="id_Sp" value="<?php echo $id; ?>">
					<input type="hidden" id="id_req" name="id_req" value="<?php echo $reqId; ?>">
					<input type="text" id="description" name="description" ><br /><br />
					<input type="button" class="btn btn-primary" value="accept">
					<input type="button" class="btn btn-warning rejectJob" value="reject">
				</form>
			</div>
			<div class=" col-sm-4"></div>
		</div>
	</div>
</div>
<script>
	$(document).on('click','.rejectJob',function(){
		var type = "jobReject";
		$.get("job-reject.php?type="+type,$("#rejectionList").serialize(),function(data){
			alert(data)
		});
	});
</script>  
<script src="js/common.js"></script>     
<script src="js/users/script.js"></script>     
<?php require_once('includes/footer.php'); ?>