<?php
session_start();

	if(!isset($_SESSION['linkarisecrm']))
	{
		header('Location: index.php');
		return;
	}
	date_default_timezone_set("Asia/Singapore");
	 $mdate1= date('Y-m-d');
	 $mdatetime= date('Y-m-d H:i:s');
	 $cdatetime= date('Y-m-d H:i:s');

	
	$umid = $_SESSION['linkariseumid'];


	include("connect.php");

	 
	 $jobworkdid=$_POST['jobworkdid'];
	 $jobworkmid=$_POST['jobworkmid'];
    $trolleyreceivedgrossweight=$_POST['trolleyreceivedgrossweight'];
	
		 $eve1 = "UPDATE res_jobwork_detail set trolleyreceivedgrossweight='$trolleyreceivedgrossweight',trolleyreceived=1 where jobworkdid=$jobworkdid";
		 if ($conn->query($eve1) === TRUE)
		{
			$last_id = $conn->insert_id;
				
			$_SESSION['msg'] = "Trolley Verified Weight Addded";
			

		}
		else
		{
			$_SESSION['msg1'] = "Item Not Addded";
			
		}
	
	
	 
	header("Location: jobworkreceivedetail.php?id=$jobworkmid"); 

?>
