<?php 
	include("../config.php");
	$module    	= $_POST['module'];
	$branch    	= $_POST['branch'];
	$start    	= $_POST['start_sr_no'];
	$end    	= $_POST['end_sr_no'];

	$select  = "SELECT * FROM `document_mst` WHERE module = '".$module."' AND branch = '".$branch."' AND start_sr_no >= '".$start."' AND end_sr_no <= '".$end."' ORDER BY id asc";
	$result  = mysqli_query($conn,$select);
	
	if(mysqli_num_rows($result) == 0) {
		$data = array('status' => 0);
	} else {
		$data = array('status' => 1);
	}

	echo json_encode($data);
	die();
?>