<?php

if($_POST["sdate"] && $_POST["inam"] && $_POST["user"] && $_POST["orderID"])
{   
  $time= $_POST['confrv'];  
  $orderID= $_POST['orderID'];
  $iname= $_POST['inam'];
 
  require_once"labClass.php";
  $con=new labClass();
  $Q= $con->getThisItemPorder($orderID,$iname);
  if($Q->rowCount()>0)
    {
   $rQ= $con->delPurchOrderItem($orderID,$iname);
    //print_r($rQ->ErrorInfo());
   if($rQ->rowCount()>0)
      { 
      ?>
      <h6 class="text-success">Deleted</h6>
      <?php
       }
     else{
       ?>
        <h6 class="text-danger">Deleting failed!..</h6>
       <?php
        }
        }
    else{
       ////////////////////////
       ?>
        <h6 class="text-danger">Order do not exist!..</h6>
       <?php
       }
       }
  else{
       ?>
       <h6 class="text-danger">All field required!..</h6>
       <?php
       }
?>