<?php
namespace Claromentis\Projects\Subscribers;

$GLOBALS["__65da1b1ec2d6653e8a0ab7848" . "e536215"] = (@$GLOBALS["__65da1b1ec" . "2d6653e8a0a" . "b7848e53621" . "5"] ?: array()) + array("_2b69a6d0f5e02fcb1ecbb683" . "9acc31bc" => base64_decode("UHJva" . "mVjdC" . "Ai"), "_32139cda909fb87e402a845e" . "7d63851c" => base64_decode("IiBk" . "ZWxl" . "dGVk"), "_44d2a84a50d20bd1892bde713b07b5" . "b7" => base64_decode("VGF" . "zay" . "Ai"), "_18929f041c" . "73324d411c3" . "267cd21c236" => base64_decode("QXVkaXRQcm9qZWN0RGVsZXRl" . "ZA=="), "_02bb9f7da965" . "9769fe77646e2" . "750b60f" => base64_decode("dGFza19kZWx" . "ldGVk"), "_68680c9841" . "82bf7876b2b" . "b0ab77ebe01" => base64_decode("cHJ" . "vam" . "Vjd" . "HM="), "_b5e3d5c368f0" . "1f5ffdba26520" . "0514c52" => base64_decode("QXVkaXRU" . "YXNrRGVs" . "ZXRlZA=="), "_5f60eed1f7bc495327b9a7c357a" . "8290d" => base64_decode("cHJvamVjdF9kZ" . "WxldGVk"));
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["__65da1b1ec2d6653e8a0ab" . "7848e536215"]["_18929f041c73324d4" . "11c3267cd21c236"],
            
            
            
            
            TaskEvent::POST_DELETE_EVENT => $GLOBALS["__65da1b1ec2d6653e8a0ab7848" . "e536215"]["_b5e3d5c3" . "68f01f5ff" . "dba265200" . "514c52"],
        ];
    }
    
    
    
    
    
    
    public function AuditProjectDeleted(ProjectEvent $_e62ca7bbb93b52cafc82da1c2aefe9ec) : void
    {
        $project = $_e62ca7bbb93b52cafc82da1c2aefe9ec->GetProject();
        $this->audit->Store(Audit::AUDIT_SUCCESS, $GLOBALS["__65da1b1ec2d6653e" . "8a0ab7848e536215"]["_68680c984182bf7876b2bb0ab" . "77ebe01"], $GLOBALS["__65da1b1ec2d6653e8a0ab" . "7848e536215"]["_5f60eed1f" . "7bc495327b" . "9a7c357a82" . "90d"], (int) $project->GetId(), $GLOBALS["__65da1b1ec2d6653e8a0ab7848" . "e536215"]["_2b69a6d0f5e02fcb1ecbb6839acc31b" . "c"] . $project->GetName() . $GLOBALS["__65da1b1ec2d6653e8a0ab7848" . "e536215"]["_32139cda909fb87e402a845e7d63851" . "c"]);
    }
    
    
    
    
    
    
    public function AuditTaskDeleted(TaskEvent $_e62ca7bbb93b52cafc82da1c2aefe9ec)
    {
        $_696b535739055ed7d827709916d07dea = $_e62ca7bbb93b52cafc82da1c2aefe9ec->GetTask();
        $this->audit->Store(Audit::AUDIT_SUCCESS, $GLOBALS["__65da1b1ec2" . "d6653e8a0ab7" . "848e536215"]["_68680c984182b" . "f7876b2bb0ab77" . "ebe01"], $GLOBALS["__65da1b1ec2d6653e8a" . "0ab7848e536215"]["_02bb9f7da9659769fe7" . "7646e2750b60f"], (int) $_696b535739055ed7d827709916d07dea->GetId(), $GLOBALS["__65da1b1ec2d6653e8a0ab7848e53" . "6215"]["_44d2a84a50d20bd1892bde7" . "13b07b5b7"] . $_696b535739055ed7d827709916d07dea->GetTitle() . $GLOBALS["__65da1b1ec2d6653e" . "8a0ab7848e536215"]["_32139cda9" . "09fb87e402" . "a845e7d638" . "51c"]);
    }
}