Passed
Push — master ( 727abb...ceefce )
by Yannick
07:55 queued 14s
created

TicketPriority::setTitle()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 2
nc 1
nop 1
dl 0
loc 5
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
    public function __construct()
52
    {
53
        $this->insertDateTime = new DateTime();
54
        $this->color = '';
55
        $this->urgency = '';
56
    }
57
58
    /**
59
     * @return int
60
     */
61
    public function getId()
62
    {
63
        return $this->id;
64
    }
65
66
    /**
67
     * @return string
68
     */
69
    public function getTitle()
70
    {
71
        return $this->title;
72
    }
73
74
    public function setTitle(string $title): self
75
    {
76
        $this->title = $title;
77
78
        return $this;
79
    }
80
81
    /**
82
     * @return string
83
     */
84
    public function getCode()
85
    {
86
        return $this->code;
87
    }
88
89
    public function setCode(string $code): self
90
    {
91
        $this->code = $code;
92
93
        return $this;
94
    }
95
96
    /**
97
     * @return string
98
     */
99
    public function getDescription()
100
    {
101
        return $this->description;
102
    }
103
104
    public function setDescription(string $description): self
105
    {
106
        $this->description = $description;
107
108
        return $this;
109
    }
110
111
    /**
112
     * @return string
113
     */
114
    public function getColor()
115
    {
116
        return $this->color;
117
    }
118
119
    public function setColor(string $color): self
120
    {
121
        $this->color = $color;
122
123
        return $this;
124
    }
125
126
    /**
127
     * @return string
128
     */
129
    public function getUrgency()
130
    {
131
        return $this->urgency;
132
    }
133
134
    public function setUrgency(string $urgency): self
135
    {
136
        $this->urgency = $urgency;
137
138
        return $this;
139
    }
140
141
    /**
142
     * @return int
143
     */
144
    public function getInsertUserId()
145
    {
146
        return $this->insertUserId;
147
    }
148
149
    public function setInsertUserId(int $insertUserId): self
150
    {
151
        $this->insertUserId = $insertUserId;
152
153
        return $this;
154
    }
155
156
    /**
157
     * @return DateTime
158
     */
159
    public function getInsertDateTime()
160
    {
161
        return $this->insertDateTime;
162
    }
163
164
    public function setInsertDateTime(DateTime $insertDateTime): self
165
    {
166
        $this->insertDateTime = $insertDateTime;
167
168
        return $this;
169
    }
170
171
    /**
172
     * @return int
173
     */
174
    public function getLastEditUserId()
175
    {
176
        return $this->lastEditUserId;
177
    }
178
179
    public function setLastEditUserId(int $lastEditUserId): self
180
    {
181
        $this->lastEditUserId = $lastEditUserId;
182
183
        return $this;
184
    }
185
186
    /**
187
     * @return DateTime
188
     */
189
    public function getLastEditDateTime()
190
    {
191
        return $this->lastEditDateTime;
192
    }
193
194
    public function setLastEditDateTime(DateTime $lastEditDateTime): self
195
    {
196
        $this->lastEditDateTime = $lastEditDateTime;
197
198
        return $this;
199
    }
200
}
201