/
TopicsSettings.php
82 lines (70 loc) · 1.58 KB
/
TopicsSettings.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
<?php
namespace Concrete\Core\Entity\Attribute\Key\Settings;
use Concrete\Core\Entity\Attribute\Value\Value\TopicsValue;
use Concrete\Core\Tree\Tree;
use Doctrine\ORM\Mapping as ORM;
/**
* @ORM\Entity
* @ORM\Table(name="atTopicSettings")
*/
class TopicsSettings extends Settings
{
/**
* @ORM\Column(type="integer")
*/
protected $akTopicParentNodeID = 0;
/**
* @ORM\Column(type="integer")
*/
protected $akTopicTreeID = 0;
/**
* @ORM\Column(type="boolean", options={"default":true})
*/
protected $akTopicAllowMultipleValues = true;
/**
* @return mixed
*/
public function getTopicTreeID()
{
return $this->akTopicTreeID;
}
/**
* @param mixed $topicTreeID
*/
public function setTopicTreeID($topicTreeID)
{
$this->akTopicTreeID = $topicTreeID;
}
/**
* @return mixed
*/
public function getParentNodeID()
{
return $this->akTopicParentNodeID;
}
/**
* @param mixed $parentNodeID
*/
public function setParentNodeID($parentNodeID)
{
$this->akTopicParentNodeID = $parentNodeID;
}
public function getTopicTreeObject()
{
return Tree::getByID($this->akTopicTreeID);
}
/**
* @return bool
*/
public function allowMultipleValues()
{
return $this->akTopicAllowMultipleValues;
}
/**
* @param bool $allowMultipleValues
*/
public function setAllowMultipleValues($allowMultipleValues)
{
$this->akTopicAllowMultipleValues = $allowMultipleValues;
}
}