Passed
Push — dependabot/npm_and_yarn/microm... ( e84ba6...f2f212 )
by
unknown
10:03
created

CBlogTask   A

Complexity

Total Complexity 13

Size/Duplication

Total Lines 103
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
eloc 39
c 1
b 0
f 1
dl 0
loc 103
rs 10
wmc 13

13 Methods

Rating   Name   Duplication   Size   Complexity  
A getTaskId() 0 3 1
A getIid() 0 3 1
A setDescription() 0 5 1
A setTitle() 0 5 1
A getTitle() 0 3 1
A setColor() 0 5 1
A getColor() 0 3 1
A setTaskId() 0 5 1
A isSystemTask() 0 3 1
A setBlog() 0 5 1
A getBlog() 0 3 1
A getDescription() 0 3 1
A setSystemTask() 0 5 1
1
<?php
2
3
declare(strict_types=1);
4
5
/* For licensing terms, see /license.txt */
6
7
namespace Chamilo\CourseBundle\Entity;
8
9
use Doctrine\ORM\Mapping as ORM;
10
11
#[ORM\Table(name: 'c_blog_task')]
12
#[ORM\Entity]
13
class CBlogTask
14
{
15
    #[ORM\Column(name: 'iid', type: 'integer')]
16
    #[ORM\Id]
17
    #[ORM\GeneratedValue]
18
    protected ?int $iid = null;
19
20
    #[ORM\Column(name: 'task_id', type: 'integer', nullable: false)]
21
    protected int $taskId;
22
23
    #[ORM\Column(name: 'title', type: 'string', length: 250, nullable: false)]
24
    protected string $title;
25
26
    #[ORM\Column(name: 'description', type: 'text', nullable: false)]
27
    protected string $description;
28
29
    #[ORM\Column(name: 'color', type: 'string', length: 10, nullable: false)]
30
    protected string $color;
31
32
    #[ORM\Column(name: 'system_task', type: 'boolean', nullable: false)]
33
    protected bool $systemTask;
34
35
    #[ORM\ManyToOne(targetEntity: CBlog::class)]
36
    #[ORM\JoinColumn(name: 'blog_id', referencedColumnName: 'iid', onDelete: 'CASCADE')]
37
    protected ?CBlog $blog = null;
38
39
    public function getIid(): ?int
40
    {
41
        return $this->iid;
42
    }
43
44
    public function getTaskId(): int
45
    {
46
        return $this->taskId;
47
    }
48
49
    public function setTaskId(int $taskId): self
50
    {
51
        $this->taskId = $taskId;
52
53
        return $this;
54
    }
55
56
    public function getTitle(): string
57
    {
58
        return $this->title;
59
    }
60
61
    public function setTitle(string $title): self
62
    {
63
        $this->title = $title;
64
65
        return $this;
66
    }
67
68
    public function getDescription(): string
69
    {
70
        return $this->description;
71
    }
72
73
    public function setDescription(string $description): self
74
    {
75
        $this->description = $description;
76
77
        return $this;
78
    }
79
80
    public function getColor(): string
81
    {
82
        return $this->color;
83
    }
84
85
    public function setColor(string $color): self
86
    {
87
        $this->color = $color;
88
89
        return $this;
90
    }
91
92
    public function isSystemTask(): bool
93
    {
94
        return $this->systemTask;
95
    }
96
97
    public function setSystemTask(bool $systemTask): self
98
    {
99
        $this->systemTask = $systemTask;
100
101
        return $this;
102
    }
103
104
    public function getBlog(): ?CBlog
105
    {
106
        return $this->blog;
107
    }
108
109
    public function setBlog(?CBlog $blog): self
110
    {
111
        $this->blog = $blog;
112
113
        return $this;
114
    }
115
}
116