<?php
defined('BASEPATH') OR exit('No direct script access allowed');
?>
      <div class="main my-0">
        <div class="row mt-3 mx-0">
          <div class="col-md-9">
            <h3>Pending Work</h3>
          </div>
          <div class="col-md-3 text-right">
            
          </div>
        </div>

        <div class="row mt-3 mx-0">
          <div class="col-md-4">
            <h5>Cancellation Bills<br>&nbsp;</h5>
            <?php
            if(is_array($results["cancellationrequests"]))
            {
            ?>
            <ul class="pre-scrollable list-styles">
			<?php
				foreach($results["cancellationrequests"] as $row)
				{
					echo '<li>' . $row["fld_billno"] . " - " . date("d-M-Y", strtotime($row["fld_billdate"])) . " - " . $row["outletname"] . '</li>';
				}
			?>
            </ul>
            <?php
			}
			else
			{
				echo "No bills for cancellation";
			}
            ?>
          </div>
          <div class="col-md-4">
            <h5>Pending Transfers<br>&nbsp;</h5>
            <?php
            if(is_array($results["acknowledgements"]))
            {
            ?>
            <ul class="pre-scrollable list-styles">
			<?php
				foreach($results["acknowledgements"] as $row)
				{
					$name = "";
					if($row["fld_type"]=="w2w") $name = $row["fromwarehousename"] . " to " . $row["towarehousename"];
					elseif($row["fld_type"]=="stockout") $name = $row["fromwarehousename"] . " to " . $row["tooutletname"];
					elseif($row["fld_type"]=="o2o") $name = $row["fromoutletname"] . " to " . $row["tooutletname"];
					elseif($row["fld_type"]=="o2w") $name = $row["fromoutletname"] . " to " . $row["fromwarehousename"];
					echo '<li>' . $row["fld_refno"] . " - " . date("d-M-Y", strtotime($row["fld_refdate"])) . " - " . $name . '</li>';
				}
			?>
            </ul>
            <?php
			}
			else
			{
				echo "No pending transfer found!";
			}
            ?>
          </div>
          <div class="col-md-4">
            <h5>Items with Missing Price <a href="account/exportitemswithmissingprice">EXPORT</a><br><a href="account/pendingworkmissitems">Eport Outlet Wise</a></h5>
            <?php
            if(is_array($results["productsmissingprice"]))
            {
            ?>
            <ul class="pre-scrollable list-styles">
			<?php
				foreach($results["productsmissingprice"] as $row)
				{
					echo '<li>' . $row["fld_name"] . " - " . $row["fld_type"] . '</li>';
				}
			?>
            </ul>
            <?php
			}
			else
			{
				echo "No item missing for price found!";
			}
            ?>
          </div>
        </div>
        
        
         
                 
	         <div class="clearfix"></div>
          
        </div>

            
        </div>

