<?php
namespace Claromentis\Projects\Subscribers;

$GLOBALS["__65da1b1ec2d6653e8a0ab7848e" . "536215"] = (@$GLOBALS["__65da1b1ec2d6653e8a0a" . "b7848e536215"] ?: array()) + array("_68680c984182bf7876b" . "2bb0ab77ebe01" => base64_decode("cHJvam" . "VjdHM="), "_32139cda909fb87" . "e402a845e7d63851" . "c" => base64_decode("IiBk" . "ZWxl" . "dGVk"), "_18929f041c73324" . "d411c3267cd21c23" . "6" => base64_decode("QXVkaXRQcm9qZWN0RGVsZ" . "XRlZA=="), "_5f60eed1f7bc495327b9a7c3" . "57a8290d" => base64_decode("cHJvamVjdF9kZWxldG" . "Vk"), "_b5e3d5c368f01f5ffdba26520051" . "4c52" => base64_decode("QXVkaXRUYXNrRGV" . "sZXRlZA=="), "_2b69a6d0f5e02fcb1ec" . "bb6839acc31bc" => base64_decode("UHJvamVjd" . "CAi"), "_02bb9f7da9659769fe776" . "46e2750b60f" => base64_decode("dGFza19kZWxldG" . "Vk"), "_44d2a84a50d2" . "0bd1892bde713" . "b07b5b7" => base64_decode("VGFzayA" . "i"));
use Claromentis\Core\Audit\Audit;
use Claromentis\Core\Event\EventSubscriberInterface;
use Claromentis\Projects\Event\ProjectEvent;
use Claromentis\Projects\Event\ProjectPostDeletedEvent;
use Claromentis\Projects\Event\TaskEvent;
class AuditSubscriber implements EventSubscriberInterface
{
    
    
    
    
    private $audit;
    
    
    
    
    
    
    public function __construct(Audit $audit)
    {
        $this->audit = $audit;
    }
    
    
    
    
    public static function getSubscribedEvents()
    {
        return [
            
            
            
            
            ProjectPostDeletedEvent::NAME => $GLOBALS["__65da1b1ec2d6653e8a0ab78" . "48e536215"]["_18929f041c733" . "24d411c3267cd2" . "1c236"],
            
            
            
            
            TaskEvent::POST_DELETE_EVENT => $GLOBALS["__65da1b1ec2d6653e8a0ab7848e" . "536215"]["_b5e3d5c368f" . "01f5ffdba265" . "200514c52"],
        ];
    }
    
    
    
    
    
    
    public function AuditProjectDeleted(ProjectEvent $_e62ca7bbb93b52cafc82da1c2aefe9ec) : void
    {
        $project = $_e62ca7bbb93b52cafc82da1c2aefe9ec->GetProject();
        $this->audit->Store(Audit::AUDIT_SUCCESS, $GLOBALS["__65da1b1ec2d6653e8a0ab7848e5" . "36215"]["_68680c984182bf" . "7876b2bb0ab77eb" . "e01"], $GLOBALS["__65da1b1ec2d6653e8a" . "0ab7848e536215"]["_5f60eed" . "1f7bc495" . "327b9a7c" . "357a8290" . "d"], (int) $project->GetId(), $GLOBALS["__65da1b1ec2d6653e8a0ab" . "7848e536215"]["_2b69a6d0f5e02fcb1ecbb" . "6839acc31bc"] . $project->GetName() . $GLOBALS["__65da1b1ec2d6653e8a0ab7848e53" . "6215"]["_32139cda909fb87e402a845e7d63" . "851c"]);
    }
    
    
    
    
    
    
    public function AuditTaskDeleted(TaskEvent $_e62ca7bbb93b52cafc82da1c2aefe9ec)
    {
        $_696b535739055ed7d827709916d07dea = $_e62ca7bbb93b52cafc82da1c2aefe9ec->GetTask();
        $this->audit->Store(Audit::AUDIT_SUCCESS, $GLOBALS["__65da1b1ec2d6653" . "e8a0ab7848e536215"]["_68680c984182bf7876b" . "2bb0ab77ebe01"], $GLOBALS["__65da1b1ec2d6653e8a0ab7848e53" . "6215"]["_02bb9f7d" . "a9659769f" . "e77646e27" . "50b60f"], (int) $_696b535739055ed7d827709916d07dea->GetId(), $GLOBALS["__65da1b1ec2d6653e8a0ab7848e536" . "215"]["_44d2a84a50d20bd1892bde713b07" . "b5b7"] . $_696b535739055ed7d827709916d07dea->GetTitle() . $GLOBALS["__65da1b1ec2d66" . "53e8a0ab7848e53" . "6215"]["_32139cda909fb" . "87e402a845e7d6" . "3851c"]);
    }
}