<?php 
session_start();
include('../includes/dbcon.php');

$str=" ";

$error=0;

$edate=date("Y-m-d");
$userid=$_SESSION['hrm_id'];

//$item_id= trim($_POST['item_id']);
$tran_no= trim($_POST['tran_no']);
//echo $itemid;
	


if (mysqli_query($con,"delete from stock_adjust_temp_detail where tran_id='$tran_no'  ")or die(mysqli_error($con)))
				{
				
if (mysqli_query($con,"delete from stock_adjust_temp_header where tran_id='$tran_no'  ")or die(mysqli_error($con))) {


				//echo "<script type='text/javascript'>alert('Successfully Deleted!');</script>";
				echo "<script>document.location='stock_adjust.php'</script>";
			}
				
				}
?>