<?php

namespace App\Listeners;

use App\Events\PO_Complete;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Queue\InteractsWithQueue;

use DB;
class UpdateRequisationPO
{
    /**
     * Create the event listener.
     */
    public function __construct()
    {
        //
    }

    /**
     * Handle the event.
     */
    public function handle(PO_Complete $event): void
    {
          DB::SELECT("DELETE from PO_items_lists WHERE POCtrlNum = ?",[$event->ControlNum]);
          //DB::SELECT("DELETE from modrequisations WHERE Quantity = 0");
    }
}
