<?php
include "../../root.class.php";
$db = new db_safeguard();

$date = date("Y-m-d H:i", strtotime("+2 Hours"));
var_dump($_POST);

$style_id = $db->query("style_breakdown","INSERT INTO `style_breakdown`(`receiving_batch_no`, `date` , `style_0`, `style_1`, `style_1s`, `style_4xl`, `style_4l`,`style_4`, `style_5`, `style_6`, `style_7`, `style_1c`, `style_1cs`, `style_4c`) VALUES ('{$_POST['receiving_batch_no']}','{$date}','{$_POST['style_0']}','{$_POST['style_1']}','{$_POST['style_1s']}','{$_POST['style_4xl']}','{$_POST['style_4l']}','{$_POST['style_4']}','{$_POST['style_5']}','{$_POST['style_6']}','{$_POST['style_7']}','{$_POST['style_1c']}','{$_POST['style_1cs']}','{$_POST['style_4c']}')");

$nut_progess = $db->query("nut_analysis_report","UPDATE `nut_analysis_report` SET `status` = 'DONE' WHERE `receiving_batch_no` = '{$_POST['receiving_batch_no']}'");

echo "
<script>
window.location.href = 'style_breakdown.php';
</script>
";