<?php
$GLOBALS["__65da1b1ec2d6653e8a0ab7848e536" . "215"] = (@$GLOBALS["__65da1b1ec2d6653e8a0" . "ab7848e536215"] ?: array()) + array("_ec5afe0f121e" . "0a954bdec5112" . "45f9908" => base64_decode("d29ya2Zsb3cucmVjb3JkLmNvdWxkbnRfbG9hZF9ldmVudF93aXRob3V" . "0X2RvYw=="), "_0c5123aa744" . "f69bbc0e8b3e" . "a2f6e847d" => base64_decode("bG1zZw" . "=="), "_4975a71859" . "87494ab5fba" . "07221fe7c5e" => base64_decode("d29ya2Zsb3cucmVjb3JkLmNvdWxkbnRfbG9hZF9ldmVudF93aXRob3V0X3NlbmRlcl9v" . "YmplY3Q="), "_74e41c4ef5b123b2461e" . "e8900608a4cc" => base64_decode("ZXZlbnRfZGF" . "0ZQ=="), "_2ca57dc3" . "61a241b0f" . "c185e2a6d" . "746ce9" => base64_decode("c2VuZGVyX2lkPWludD" . "pzZW5kZXJfaWQ="), "_a5b8a957b" . "6bb889a65d" . "0110f7df85" . "ff0" => base64_decode("RE" . "VT" . "Qw" . "=="), "_4d707fab93beb" . "b00bbe69e81596" . "97c90" => base64_decode(""), "_5eead4149d3" . "c45122e81254" . "b7eae2410" => base64_decode("d29ya2Zsb3cucmVjb3JkLmNvdWxkbnRfbG9hZF9ldmVu" . "dF9saXN0"), "_80ceb262c709070323dcedc7" . "dbd30c3e" => base64_decode("c3RhdGVfcmVjb3JkX2lkPWludDpzdGF0ZV9yZWNvcmRfaWQ" . "gQU5EIGRvY19pZD1pbnQ6ZG9jX2lk"));




abstract class WFEventRecord extends DBObject
{
    protected $id;
    protected $state_record_id;
    
    
    protected $doc_id;
    protected $sender_id;
    
    
    protected $event_type;
    protected $event_data;
    protected $event_date;
    protected $user_id;
    protected $commentary;
    
    
    
    
    
    
    
    
    
    
    
    
    
    public function __construct($_c81a475ecdc9121925813756400e25f9, $_c122cf02b563ba442340c5715f54e1c6, $_f3c6503ca6d913adb51076e07b9a7a35, $_cb79122298a792a3d87c64dfdd0f3af1, $_55d3c75af03093e4e61a38a65c80ff45, $user_id = 0)
    {
        $this->TABLE_NAME = $_c81a475ecdc9121925813756400e25f9;
        $this->DATE_FIELDS = array($GLOBALS["__65da1b1ec2d6653e8a0ab7848e5362" . "15"]["_74e41c4ef5b123b" . "2461ee8900608a4c" . "c"]);
        $this->SetOrderFields(array($GLOBALS["__65da1b1ec2d6653e8" . "a0ab7848e536215"]["_74e41c4ef5b123b2461ee890060" . "8a4cc"] => $GLOBALS["__65da1b1ec2d6653e8a0ab7848" . "e536215"]["_a5b8a957b6b" . "b889a65d0110" . "f7df85ff0"]));
        $_50eb88f32296e9d31eb6e8c8f50e9ea0 = new Date();
        $this->id = -1;
        $this->state_record_id = $_c122cf02b563ba442340c5715f54e1c6;
        $this->doc_id = $_55d3c75af03093e4e61a38a65c80ff45;
        $this->sender_id = $_f3c6503ca6d913adb51076e07b9a7a35;
        $this->event_type = $_cb79122298a792a3d87c64dfdd0f3af1;
        $this->event_data = $GLOBALS["__65da1b1ec2d6" . "653e8a0ab7848e" . "536215"]["_4d707fab93bebb00bbe6" . "9e8159697c90"];
        $this->event_date = $_50eb88f32296e9d31eb6e8c8f50e9ea0->getDate();
        $this->user_id = $user_id;
        $this->commentary = $GLOBALS["__65da1b1ec2d6653e8a0ab784" . "8e536215"]["_4d707fab" . "93bebb00b" . "be69e8159" . "697c90"];
    }
    
    
    
    
    
    
    public function GetSameByStateRecord()
    {
        if (!$this->state_record_id) {
            return $this->SetErrMsg($GLOBALS["__65da1b1ec2d6653e8" . "a0ab7848e536215"]["_0c5123aa744f69bbc0e8b3ea2f6e8" . "47d"]($GLOBALS["__65da1b1ec2d6653e8a0ab7848e5" . "36215"]["_5eead4149d3c45122e81254" . "b7eae2410"]));
        }
        if (!$this->doc_id) {
            return $this->SetErrMsg($GLOBALS["__65da1b1ec2d6653e8a0ab78" . "48e536215"]["_0c5123aa744f6" . "9bbc0e8b3ea2f6" . "e847d"]($GLOBALS["__65da1b1" . "ec2d6653e" . "8a0ab7848" . "e536215"]["_ec5afe0f121e" . "0a954bdec5112" . "45f9908"]));
        }
        $_03e9164d0a343b742df4793268b80767 = $this->GenerateSelect();
        $_03e9164d0a343b742df4793268b80767->AddWhereAndClause($GLOBALS["__65da1b1ec2d6653e8a0ab7848e5362" . "15"]["_80ceb262c709070323dcedc7dbd30c" . "3e"], $this->state_record_id, $this->doc_id);
        return parent::GetAll($_03e9164d0a343b742df4793268b80767);
    }
    
    
    
    
    
    
    public function GetSameBySender()
    {
        if (!$this->sender_id) {
            return $this->SetErrMsg($GLOBALS["__65da1b1" . "ec2d6653e" . "8a0ab7848" . "e536215"]["_0c5123aa7" . "44f69bbc0e" . "8b3ea2f6e8" . "47d"]($GLOBALS["__65da1b1ec2d6653e8a0ab7848e53" . "6215"]["_4975a7185987494ab5fba07221fe7c" . "5e"]));
        }
        $_03e9164d0a343b742df4793268b80767 = $this->GenerateSelect();
        $_03e9164d0a343b742df4793268b80767->AddWhereAndClause($GLOBALS["__65da1b1ec2d66" . "53e8a0ab7848e53" . "6215"]["_2ca57dc361a241b0fc18" . "5e2a6d746ce9"], $this->sender_id);
        return parent::GetAll($_03e9164d0a343b742df4793268b80767);
    }
    
    
    
    
    
    
    
    
    
    public function GetId()
    {
        return $this->id;
    }
    
    
    
    
    
    
    public function GetSenderId()
    {
        return $this->sender_id;
    }
    
    
    
    
    
    
    public function GetDocId()
    {
        return $this->doc_id;
    }
    
    
    
    
    
    
    public function GetEventType()
    {
        return $this->event_type;
    }
    
    
    
    
    
    
    public function GetEventData()
    {
        return $this->event_data;
    }
    
    
    
    
    
    
    
    public function SetEventData($_590accd9bf5cabf9360e50157b7f12e8)
    {
        $this->event_data = $_590accd9bf5cabf9360e50157b7f12e8;
        return true;
    }
    
    
    
    
    
    
    public function GetUserId()
    {
        return $this->user_id;
    }
    
    
    
    
    
    
    public function GetComment()
    {
        return $this->commentary;
    }
    
    
    
    
    
    
    
    public function SetComment($_01ac09884885313c2535784cc6eae952)
    {
        $this->commentary = $_01ac09884885313c2535784cc6eae952;
        return true;
    }
    
    
    
    
    
    
    public function GetEventDate()
    {
        return new Date($this->event_date);
    }
    public function GetUser()
    {
        $_24e0e36600d6af77406a44bb618a6253 = new User($this->GetUserId());
        $_24e0e36600d6af77406a44bb618a6253->Load();
        return $_24e0e36600d6af77406a44bb618a6253;
    }
}