This project does not seem to handle request data directly as such no vulnerable execution paths were found.
include
, or for example
via PHP's auto-loading mechanism.
These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more
1 | <?php |
||
2 | |||
3 | /* |
||
4 | * This file is part of the zibios/wrike-php-jmsserializer package. |
||
5 | * |
||
6 | * (c) Zbigniew Ślązak |
||
7 | * |
||
8 | * For the full copyright and license information, please view the LICENSE |
||
9 | * file that was distributed with this source code. |
||
10 | */ |
||
11 | |||
12 | namespace Zibios\WrikePhpJmsserializer\Model\CustomField; |
||
13 | |||
14 | use JMS\Serializer\Annotation as SA; |
||
15 | use Zibios\WrikePhpJmsserializer\Model\AbstractModel; |
||
16 | use Zibios\WrikePhpJmsserializer\Model\ResourceModelInterface; |
||
17 | |||
18 | /** |
||
19 | * Custom Field Resource Model. |
||
20 | */ |
||
21 | View Code Duplication | class CustomFieldResourceModel extends AbstractModel implements ResourceModelInterface |
|
0 ignored issues
–
show
|
|||
22 | { |
||
23 | /** |
||
24 | * Custom Field ID. |
||
25 | * |
||
26 | * Comment: Custom Field ID |
||
27 | * |
||
28 | * @SA\Type("string") |
||
29 | * @SA\SerializedName("id") |
||
30 | * |
||
31 | * @var string|null |
||
32 | */ |
||
33 | protected $id; |
||
34 | |||
35 | /** |
||
36 | * Account ID. |
||
37 | * |
||
38 | * Comment: Account ID |
||
39 | * |
||
40 | * @SA\Type("string") |
||
41 | * @SA\SerializedName("accountId") |
||
42 | * |
||
43 | * @var string|null |
||
44 | */ |
||
45 | protected $accountId; |
||
46 | |||
47 | /** |
||
48 | * Custom field title. |
||
49 | * |
||
50 | * @SA\Type("string") |
||
51 | * @SA\SerializedName("title") |
||
52 | * |
||
53 | * @var string|null |
||
54 | */ |
||
55 | protected $title; |
||
56 | |||
57 | /** |
||
58 | * Custom field type |
||
59 | * Type of custom field, Enum: Text, DropDown, Numeric, Money, Percentage, Date, Duration, Checkbox. |
||
60 | * |
||
61 | * @see \Zibios\WrikePhpLibrary\Enum\CustomFieldTypeEnum |
||
62 | * |
||
63 | * @SA\Type("string") |
||
64 | * @SA\SerializedName("type") |
||
65 | * |
||
66 | * @var string|null |
||
67 | */ |
||
68 | protected $type; |
||
69 | |||
70 | /** |
||
71 | * List of user IDs, who share the custom field. |
||
72 | * |
||
73 | * Comment: Contact ID list |
||
74 | * |
||
75 | * @SA\Type("array<string>") |
||
76 | * @SA\SerializedName("sharedIds") |
||
77 | * |
||
78 | * @var array|string[]|null |
||
79 | */ |
||
80 | protected $sharedIds; |
||
81 | |||
82 | /** |
||
83 | * Deleted flag is present and set to true, if custom field is deleted/hidden. |
||
84 | * |
||
85 | * @SA\Type("boolean") |
||
86 | * @SA\SerializedName("deleted") |
||
87 | * |
||
88 | * @var bool|null |
||
89 | */ |
||
90 | protected $deleted; |
||
91 | |||
92 | /** |
||
93 | * @return string|null |
||
94 | */ |
||
95 | 1 | public function getId() |
|
96 | { |
||
97 | 1 | return $this->id; |
|
98 | } |
||
99 | |||
100 | /** |
||
101 | * @param string|null $id |
||
102 | * |
||
103 | * @return $this |
||
104 | */ |
||
105 | 1 | public function setId($id) |
|
106 | { |
||
107 | 1 | $this->id = $id; |
|
108 | |||
109 | 1 | return $this; |
|
110 | } |
||
111 | |||
112 | /** |
||
113 | * @return string|null |
||
114 | */ |
||
115 | 1 | public function getAccountId() |
|
116 | { |
||
117 | 1 | return $this->accountId; |
|
118 | } |
||
119 | |||
120 | /** |
||
121 | * @param string|null $accountId |
||
122 | * |
||
123 | * @return $this |
||
124 | */ |
||
125 | 1 | public function setAccountId($accountId) |
|
126 | { |
||
127 | 1 | $this->accountId = $accountId; |
|
128 | |||
129 | 1 | return $this; |
|
130 | } |
||
131 | |||
132 | /** |
||
133 | * @return string|null |
||
134 | */ |
||
135 | 1 | public function getTitle() |
|
136 | { |
||
137 | 1 | return $this->title; |
|
138 | } |
||
139 | |||
140 | /** |
||
141 | * @param string|null $title |
||
142 | * |
||
143 | * @return $this |
||
144 | */ |
||
145 | 1 | public function setTitle($title) |
|
146 | { |
||
147 | 1 | $this->title = $title; |
|
148 | |||
149 | 1 | return $this; |
|
150 | } |
||
151 | |||
152 | /** |
||
153 | * @return null|string |
||
154 | */ |
||
155 | 1 | public function getType() |
|
156 | { |
||
157 | 1 | return $this->type; |
|
158 | } |
||
159 | |||
160 | /** |
||
161 | * @param null|string $type |
||
162 | * |
||
163 | * @return $this |
||
164 | */ |
||
165 | 1 | public function setType($type) |
|
166 | { |
||
167 | 1 | $this->type = $type; |
|
168 | |||
169 | 1 | return $this; |
|
170 | } |
||
171 | |||
172 | /** |
||
173 | * @return array|string[]|null |
||
174 | */ |
||
175 | 1 | public function getSharedIds() |
|
176 | { |
||
177 | 1 | return $this->sharedIds; |
|
178 | } |
||
179 | |||
180 | /** |
||
181 | * @param array|string[]|null $sharedIds |
||
182 | * |
||
183 | * @return $this |
||
184 | */ |
||
185 | 1 | public function setSharedIds($sharedIds) |
|
186 | { |
||
187 | 1 | $this->sharedIds = $sharedIds; |
|
188 | |||
189 | 1 | return $this; |
|
190 | } |
||
191 | |||
192 | /** |
||
193 | * @return bool|null |
||
194 | */ |
||
195 | 1 | public function getDeleted() |
|
196 | { |
||
197 | 1 | return $this->deleted; |
|
198 | } |
||
199 | |||
200 | /** |
||
201 | * @param bool|null $deleted |
||
202 | * |
||
203 | * @return $this |
||
204 | */ |
||
205 | 1 | public function setDeleted($deleted) |
|
206 | { |
||
207 | 1 | $this->deleted = $deleted; |
|
208 | |||
209 | 1 | return $this; |
|
210 | } |
||
211 | } |
||
212 |
Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.
You can also find more detailed suggestions in the “Code” section of your repository.