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 Doctrine\ORM\Mapping as ORM; |
10
|
|
|
use DateTime; |
11
|
|
|
|
12
|
|
|
/** |
13
|
|
|
* Conference Activity entity. |
14
|
|
|
*/ |
15
|
|
|
#[ORM\Table(name: 'conference_activity')] |
16
|
|
|
#[ORM\Entity] |
17
|
|
|
class ConferenceActivity |
18
|
|
|
{ |
19
|
|
|
#[ORM\Id] |
20
|
|
|
#[ORM\GeneratedValue] |
21
|
|
|
#[ORM\Column(type: 'integer')] |
22
|
|
|
protected int $id; |
23
|
|
|
|
24
|
|
|
#[ORM\ManyToOne(targetEntity: ConferenceMeeting::class)] |
25
|
|
|
#[ORM\JoinColumn(name: 'meeting_id', referencedColumnName: 'id', onDelete: 'CASCADE')] |
26
|
|
|
protected ?ConferenceMeeting $meeting = null; |
27
|
|
|
|
28
|
|
|
#[ORM\ManyToOne(targetEntity: User::class)] |
29
|
|
|
#[ORM\JoinColumn(name: 'participant_id', referencedColumnName: 'id', onDelete: 'CASCADE')] |
30
|
|
|
protected ?User $participant = null; |
31
|
|
|
|
32
|
|
|
#[ORM\Column(name: 'in_at', type: 'datetime', nullable: true)] |
33
|
|
|
protected ?DateTime $inAt = null; |
34
|
|
|
|
35
|
|
|
#[ORM\Column(name: 'out_at', type: 'datetime', nullable: true)] |
36
|
|
|
protected ?DateTime $outAt = null; |
37
|
|
|
|
38
|
|
|
#[ORM\Column(name: 'close', type: 'boolean')] |
39
|
|
|
protected bool $close = false; |
40
|
|
|
|
41
|
|
|
#[ORM\Column(name: 'type', type: 'string', length: 50)] |
42
|
|
|
protected string $type = ''; |
43
|
|
|
|
44
|
|
|
#[ORM\Column(name: 'event', type: 'string', length: 255)] |
45
|
|
|
protected string $event = ''; |
46
|
|
|
|
47
|
|
|
#[ORM\Column(name: 'activity_data', type: 'text', nullable: true)] |
48
|
|
|
protected ?string $activityData = null; |
49
|
|
|
|
50
|
|
|
#[ORM\Column(name: 'signature_file', type: 'string', length: 255, nullable: true)] |
51
|
|
|
protected ?string $signatureFile = null; |
52
|
|
|
|
53
|
|
|
#[ORM\Column(name: 'signed_at', type: 'datetime', nullable: true)] |
54
|
|
|
protected ?DateTime $signedAt = null; |
55
|
|
|
|
56
|
|
|
public function __construct() |
57
|
|
|
{ |
58
|
|
|
$this->close = false; |
59
|
|
|
$this->type = ''; |
60
|
|
|
$this->event = ''; |
61
|
|
|
$this->activityData = null; |
62
|
|
|
$this->signatureFile = null; |
63
|
|
|
$this->inAt = new DateTime(); |
64
|
|
|
$this->outAt = null; |
65
|
|
|
$this->signedAt = null; |
66
|
|
|
} |
67
|
|
|
|
68
|
|
|
public function getId(): int |
69
|
|
|
{ |
70
|
|
|
return $this->id; |
71
|
|
|
} |
72
|
|
|
|
73
|
|
|
public function getMeeting(): ?ConferenceMeeting |
74
|
|
|
{ |
75
|
|
|
return $this->meeting; |
76
|
|
|
} |
77
|
|
|
|
78
|
|
|
public function setMeeting(?ConferenceMeeting $meeting): self |
79
|
|
|
{ |
80
|
|
|
$this->meeting = $meeting; |
81
|
|
|
|
82
|
|
|
return $this; |
83
|
|
|
} |
84
|
|
|
|
85
|
|
|
public function getParticipant(): ?User |
86
|
|
|
{ |
87
|
|
|
return $this->participant; |
88
|
|
|
} |
89
|
|
|
|
90
|
|
|
public function setParticipant(?User $participant): self |
91
|
|
|
{ |
92
|
|
|
$this->participant = $participant; |
93
|
|
|
|
94
|
|
|
return $this; |
95
|
|
|
} |
96
|
|
|
|
97
|
|
|
public function getInAt(): ?DateTime |
98
|
|
|
{ |
99
|
|
|
return $this->inAt; |
100
|
|
|
} |
101
|
|
|
|
102
|
|
|
public function setInAt(?DateTime $inAt): self |
103
|
|
|
{ |
104
|
|
|
$this->inAt = $inAt; |
105
|
|
|
|
106
|
|
|
return $this; |
107
|
|
|
} |
108
|
|
|
|
109
|
|
|
public function getOutAt(): ?DateTime |
110
|
|
|
{ |
111
|
|
|
return $this->outAt; |
112
|
|
|
} |
113
|
|
|
|
114
|
|
|
public function setOutAt(?DateTime $outAt): self |
115
|
|
|
{ |
116
|
|
|
$this->outAt = $outAt; |
117
|
|
|
|
118
|
|
|
return $this; |
119
|
|
|
} |
120
|
|
|
|
121
|
|
|
public function isClose(): bool |
122
|
|
|
{ |
123
|
|
|
return $this->close; |
124
|
|
|
} |
125
|
|
|
|
126
|
|
|
public function setClose(bool $close): self |
127
|
|
|
{ |
128
|
|
|
$this->close = $close; |
129
|
|
|
|
130
|
|
|
return $this; |
131
|
|
|
} |
132
|
|
|
|
133
|
|
|
public function getType(): string |
134
|
|
|
{ |
135
|
|
|
return $this->type; |
136
|
|
|
} |
137
|
|
|
|
138
|
|
|
public function setType(string $type): self |
139
|
|
|
{ |
140
|
|
|
$this->type = $type; |
141
|
|
|
|
142
|
|
|
return $this; |
143
|
|
|
} |
144
|
|
|
|
145
|
|
|
public function getEvent(): string |
146
|
|
|
{ |
147
|
|
|
return $this->event; |
148
|
|
|
} |
149
|
|
|
|
150
|
|
|
public function setEvent(string $event): self |
151
|
|
|
{ |
152
|
|
|
$this->event = $event; |
153
|
|
|
|
154
|
|
|
return $this; |
155
|
|
|
} |
156
|
|
|
|
157
|
|
|
public function getActivityData(): ?string |
158
|
|
|
{ |
159
|
|
|
return $this->activityData; |
160
|
|
|
} |
161
|
|
|
|
162
|
|
|
public function setActivityData(?string $activityData): self |
163
|
|
|
{ |
164
|
|
|
$this->activityData = $activityData; |
165
|
|
|
|
166
|
|
|
return $this; |
167
|
|
|
} |
168
|
|
|
|
169
|
|
|
public function getSignatureFile(): ?string |
170
|
|
|
{ |
171
|
|
|
return $this->signatureFile; |
172
|
|
|
} |
173
|
|
|
|
174
|
|
|
public function setSignatureFile(?string $signatureFile): self |
175
|
|
|
{ |
176
|
|
|
$this->signatureFile = $signatureFile; |
177
|
|
|
|
178
|
|
|
return $this; |
179
|
|
|
} |
180
|
|
|
|
181
|
|
|
public function getSignedAt(): ?DateTime |
182
|
|
|
{ |
183
|
|
|
return $this->signedAt; |
184
|
|
|
} |
185
|
|
|
|
186
|
|
|
public function setSignedAt(?DateTime $signedAt): self |
187
|
|
|
{ |
188
|
|
|
$this->signedAt = $signedAt; |
189
|
|
|
|
190
|
|
|
return $this; |
191
|
|
|
} |
192
|
|
|
} |
193
|
|
|
|