Completed
Push — master ( 1d5aab...1362ac )
by Yannick
02:39 queued 01:44
created

TicketPriority::getAccessUrl()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 1
nc 1
nop 0
dl 0
loc 3
rs 10
c 0
b 0
f 0
1
<?php
2
3
declare(strict_types=1);
4
5
/* For licensing terms, see /license.txt */
6
7
namespace Chamilo\CoreBundle\Entity;
8
9
use DateTime;
10
use Doctrine\ORM\Mapping as ORM;
11
12
/**
13
 * Priority.
14
 */
15
#[ORM\Table(name: 'ticket_priority')]
16
#[ORM\Entity]
17
class TicketPriority
18
{
19
    #[ORM\Column(name: 'id', type: 'integer')]
20
    #[ORM\Id]
21
    #[ORM\GeneratedValue]
22
    protected ?int $id = null;
23
24
    #[ORM\Column(name: 'title', type: 'string', length: 255, nullable: false)]
25
    protected string $title;
26
27
    #[ORM\Column(name: 'code', type: 'string', length: 255, nullable: false)]
28
    protected string $code;
29
30
    #[ORM\Column(name: 'description', type: 'text', nullable: true)]
31
    protected ?string $description = null;
32
33
    #[ORM\Column(name: 'color', type: 'string', nullable: false)]
34
    protected string $color;
35
36
    #[ORM\Column(name: 'urgency', type: 'string', nullable: false)]
37
    protected string $urgency;
38
39
    #[ORM\Column(name: 'sys_insert_user_id', type: 'integer')]
40
    protected int $insertUserId;
41
42
    #[ORM\Column(name: 'sys_insert_datetime', type: 'datetime')]
43
    protected DateTime $insertDateTime;
44
45
    #[ORM\Column(name: 'sys_lastedit_user_id', type: 'integer', nullable: true, unique: false)]
46
    protected ?int $lastEditUserId = null;
47
48
    #[ORM\Column(name: 'sys_lastedit_datetime', type: 'datetime', nullable: true, unique: false)]
49
    protected ?DateTime $lastEditDateTime = null;
50
51
    #[ORM\ManyToOne(targetEntity: AccessUrl::class)]
52
    #[ORM\JoinColumn(name: 'access_url_id', referencedColumnName: 'id', nullable: true)]
53
    protected ?AccessUrl $accessUrl = null;
54
55
    public function __construct()
56
    {
57
        $this->insertDateTime = new DateTime();
58
        $this->color = '';
59
        $this->urgency = '';
60
    }
61
62
    /**
63
     * @return int
64
     */
65
    public function getId()
66
    {
67
        return $this->id;
68
    }
69
70
    /**
71
     * @return string
72
     */
73
    public function getTitle()
74
    {
75
        return $this->title;
76
    }
77
78
    public function setTitle(string $title): self
79
    {
80
        $this->title = $title;
81
82
        return $this;
83
    }
84
85
    /**
86
     * @return string
87
     */
88
    public function getCode()
89
    {
90
        return $this->code;
91
    }
92
93
    public function setCode(string $code): self
94
    {
95
        $this->code = $code;
96
97
        return $this;
98
    }
99
100
    /**
101
     * @return string
102
     */
103
    public function getDescription()
104
    {
105
        return $this->description;
106
    }
107
108
    public function setDescription(string $description): self
109
    {
110
        $this->description = $description;
111
112
        return $this;
113
    }
114
115
    /**
116
     * @return string
117
     */
118
    public function getColor()
119
    {
120
        return $this->color;
121
    }
122
123
    public function setColor(string $color): self
124
    {
125
        $this->color = $color;
126
127
        return $this;
128
    }
129
130
    /**
131
     * @return string
132
     */
133
    public function getUrgency()
134
    {
135
        return $this->urgency;
136
    }
137
138
    public function setUrgency(string $urgency): self
139
    {
140
        $this->urgency = $urgency;
141
142
        return $this;
143
    }
144
145
    /**
146
     * @return int
147
     */
148
    public function getInsertUserId()
149
    {
150
        return $this->insertUserId;
151
    }
152
153
    public function setInsertUserId(int $insertUserId): self
154
    {
155
        $this->insertUserId = $insertUserId;
156
157
        return $this;
158
    }
159
160
    /**
161
     * @return DateTime
162
     */
163
    public function getInsertDateTime()
164
    {
165
        return $this->insertDateTime;
166
    }
167
168
    public function setInsertDateTime(DateTime $insertDateTime): self
169
    {
170
        $this->insertDateTime = $insertDateTime;
171
172
        return $this;
173
    }
174
175
    /**
176
     * @return int
177
     */
178
    public function getLastEditUserId()
179
    {
180
        return $this->lastEditUserId;
181
    }
182
183
    public function setLastEditUserId(int $lastEditUserId): self
184
    {
185
        $this->lastEditUserId = $lastEditUserId;
186
187
        return $this;
188
    }
189
190
    /**
191
     * @return DateTime
192
     */
193
    public function getLastEditDateTime()
194
    {
195
        return $this->lastEditDateTime;
196
    }
197
198
    public function setLastEditDateTime(DateTime $lastEditDateTime): self
199
    {
200
        $this->lastEditDateTime = $lastEditDateTime;
201
202
        return $this;
203
    }
204
205
    public function getAccessUrl(): ?AccessUrl
206
    {
207
        return $this->accessUrl;
208
    }
209
210
    public function setAccessUrl(?AccessUrl $accessUrl): self
211
    {
212
        $this->accessUrl = $accessUrl;
213
214
        return $this;
215
    }
216
}
217