Test Failed
Push — master ( e7eea4...33f872 )
by Julien
09:37 queued 04:42
created

AbstractProfile::setUpdatedBy()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 2
dl 0
loc 5
ccs 0
cts 3
cp 0
rs 10
c 1
b 0
f 0
cc 1
nc 1
nop 1
crap 2
1
<?php
2
3
/**
4
 * This file is part of the Zemit Framework.
5
 *
6
 * (c) Zemit Team <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE.txt
9
 * file that was distributed with this source code.
10
 *
11
 * --------------------------------------------------------------
12
 *
13
 * New BSD License
14
 *
15
 * Copyright (c) 2017-present, Zemit CMS Team
16
 * All rights reserved.
17
 *
18
 * Redistribution and use in source and binary forms, with or without
19
 * modification, are permitted provided that the following conditions are met:
20
 *     * Redistributions of source code must retain the above copyright
21
 *       notice, this list of conditions and the following disclaimer.
22
 *     * Redistributions in binary form must reproduce the above copyright
23
 *       notice, this list of conditions and the following disclaimer in the
24
 *       documentation and/or other materials provided with the distribution.
25
 *     * Neither the name of the Zemit nor the
26
 *       names of its contributors may be used to endorse or promote products
27
 *       derived from this software without specific prior written permission.
28
 *
29
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
30
 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
31
 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
32
 * DISCLAIMED. IN NO EVENT SHALL ZEMIT FRAMEWORK TEAM BE LIABLE FOR ANY
33
 * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
34
 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
35
 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
36
 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
37
 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
38
 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
39
 */
40
41
namespace Zemit\Models\Abstracts;
42
43
/**
44
 * AbstractProfile
45
 * 
46
 * @package Zemit\Models\Abstracts
47
 * @autogenerated by Phalcon Developer Tools
48
 * @date 2024-02-29, 01:55:19
49
 */
50
abstract class AbstractProfile extends \Zemit\Models\AbstractModel
51
{
52
53
    /**
54
     *
55
     * @var integer
56
     */
57
    protected $id;
58
59
    /**
60
     *
61
     * @var integer
62
     */
63
    protected $userId;
64
65
    /**
66
     *
67
     * @var integer
68
     */
69
    protected $deleted;
70
71
    /**
72
     *
73
     * @var string
74
     */
75
    protected $createdAt;
76
77
    /**
78
     *
79
     * @var integer
80
     */
81
    protected $createdBy;
82
83
    /**
84
     *
85
     * @var integer
86
     */
87
    protected $createdAs;
88
89
    /**
90
     *
91
     * @var string
92
     */
93
    protected $updatedAt;
94
95
    /**
96
     *
97
     * @var integer
98
     */
99
    protected $updatedBy;
100
101
    /**
102
     *
103
     * @var integer
104
     */
105
    protected $updatedAs;
106
107
    /**
108
     *
109
     * @var string
110
     */
111
    protected $deletedAt;
112
113
    /**
114
     *
115
     * @var integer
116
     */
117
    protected $deletedAs;
118
119
    /**
120
     *
121
     * @var integer
122
     */
123
    protected $deletedBy;
124
125
    /**
126
     *
127
     * @var string
128
     */
129
    protected $restoredAt;
130
131
    /**
132
     *
133
     * @var integer
134
     */
135
    protected $restoredBy;
136
137
    /**
138
     * Method to set the value of field id
139
     *
140
     * @param integer $id
141
     * @return $this
142
     */
143
    public function setId($id)
144
    {
145
        $this->id = $id;
146
147
        return $this;
148
    }
149
150
    /**
151
     * Method to set the value of field user_id
152
     *
153
     * @param integer $userId
154
     * @return $this
155
     */
156
    public function setUserId($userId)
157
    {
158
        $this->userId = $userId;
159
160
        return $this;
161
    }
162
163
    /**
164
     * Method to set the value of field deleted
165
     *
166
     * @param integer $deleted
167
     * @return $this
168
     */
169
    public function setDeleted($deleted)
170
    {
171
        $this->deleted = $deleted;
172
173
        return $this;
174
    }
175
176
    /**
177
     * Method to set the value of field created_at
178
     *
179
     * @param string $createdAt
180
     * @return $this
181
     */
182
    public function setCreatedAt($createdAt)
183
    {
184
        $this->createdAt = $createdAt;
185
186
        return $this;
187
    }
188
189
    /**
190
     * Method to set the value of field created_by
191
     *
192
     * @param integer $createdBy
193
     * @return $this
194
     */
195
    public function setCreatedBy($createdBy)
196
    {
197
        $this->createdBy = $createdBy;
198
199
        return $this;
200
    }
201
202
    /**
203
     * Method to set the value of field created_as
204
     *
205
     * @param integer $createdAs
206
     * @return $this
207
     */
208
    public function setCreatedAs($createdAs)
209
    {
210
        $this->createdAs = $createdAs;
211
212
        return $this;
213
    }
214
215
    /**
216
     * Method to set the value of field updated_at
217
     *
218
     * @param string $updatedAt
219
     * @return $this
220
     */
221
    public function setUpdatedAt($updatedAt)
222
    {
223
        $this->updatedAt = $updatedAt;
224
225
        return $this;
226
    }
227
228
    /**
229
     * Method to set the value of field updated_by
230
     *
231
     * @param integer $updatedBy
232
     * @return $this
233
     */
234
    public function setUpdatedBy($updatedBy)
235
    {
236
        $this->updatedBy = $updatedBy;
237
238
        return $this;
239
    }
240
241
    /**
242
     * Method to set the value of field updated_as
243
     *
244
     * @param integer $updatedAs
245
     * @return $this
246
     */
247
    public function setUpdatedAs($updatedAs)
248
    {
249
        $this->updatedAs = $updatedAs;
250
251
        return $this;
252
    }
253
254
    /**
255
     * Method to set the value of field deleted_at
256
     *
257
     * @param string $deletedAt
258
     * @return $this
259
     */
260
    public function setDeletedAt($deletedAt)
261
    {
262
        $this->deletedAt = $deletedAt;
263
264
        return $this;
265
    }
266
267
    /**
268
     * Method to set the value of field deleted_as
269
     *
270
     * @param integer $deletedAs
271
     * @return $this
272
     */
273
    public function setDeletedAs($deletedAs)
274
    {
275
        $this->deletedAs = $deletedAs;
276
277
        return $this;
278
    }
279
280
    /**
281
     * Method to set the value of field deleted_by
282
     *
283
     * @param integer $deletedBy
284
     * @return $this
285
     */
286
    public function setDeletedBy($deletedBy)
287
    {
288
        $this->deletedBy = $deletedBy;
289
290
        return $this;
291
    }
292
293
    /**
294
     * Method to set the value of field restored_at
295
     *
296
     * @param string $restoredAt
297
     * @return $this
298
     */
299
    public function setRestoredAt($restoredAt)
300
    {
301
        $this->restoredAt = $restoredAt;
302
303
        return $this;
304
    }
305
306
    /**
307
     * Method to set the value of field restored_by
308
     *
309
     * @param integer $restoredBy
310
     * @return $this
311
     */
312
    public function setRestoredBy($restoredBy)
313
    {
314
        $this->restoredBy = $restoredBy;
315
316
        return $this;
317
    }
318
319
    /**
320
     * Returns the value of field id
321
     *
322
     * @return integer
323
     */
324
    public function getId()
325
    {
326
        return $this->id;
327
    }
328
329
    /**
330
     * Returns the value of field userId
331
     *
332
     * @return integer
333
     */
334
    public function getUserId()
335
    {
336
        return $this->userId;
337
    }
338
339
    /**
340
     * Returns the value of field deleted
341
     *
342
     * @return integer
343
     */
344
    public function getDeleted()
345
    {
346
        return $this->deleted;
347
    }
348
349
    /**
350
     * Returns the value of field createdAt
351
     *
352
     * @return string
353
     */
354
    public function getCreatedAt()
355
    {
356
        return $this->createdAt;
357
    }
358
359
    /**
360
     * Returns the value of field createdBy
361
     *
362
     * @return integer
363
     */
364
    public function getCreatedBy()
365
    {
366
        return $this->createdBy;
367
    }
368
369
    /**
370
     * Returns the value of field createdAs
371
     *
372
     * @return integer
373
     */
374
    public function getCreatedAs()
375
    {
376
        return $this->createdAs;
377
    }
378
379
    /**
380
     * Returns the value of field updatedAt
381
     *
382
     * @return string
383
     */
384
    public function getUpdatedAt()
385
    {
386
        return $this->updatedAt;
387
    }
388
389
    /**
390
     * Returns the value of field updatedBy
391
     *
392
     * @return integer
393
     */
394
    public function getUpdatedBy()
395
    {
396
        return $this->updatedBy;
397
    }
398
399
    /**
400
     * Returns the value of field updatedAs
401
     *
402
     * @return integer
403
     */
404
    public function getUpdatedAs()
405
    {
406
        return $this->updatedAs;
407
    }
408
409
    /**
410
     * Returns the value of field deletedAt
411
     *
412
     * @return string
413
     */
414
    public function getDeletedAt()
415
    {
416
        return $this->deletedAt;
417
    }
418
419
    /**
420
     * Returns the value of field deletedAs
421
     *
422
     * @return integer
423
     */
424
    public function getDeletedAs()
425
    {
426
        return $this->deletedAs;
427
    }
428
429
    /**
430
     * Returns the value of field deletedBy
431
     *
432
     * @return integer
433
     */
434
    public function getDeletedBy()
435
    {
436
        return $this->deletedBy;
437
    }
438
439
    /**
440
     * Returns the value of field restoredAt
441
     *
442
     * @return string
443
     */
444
    public function getRestoredAt()
445
    {
446
        return $this->restoredAt;
447
    }
448
449
    /**
450
     * Returns the value of field restoredBy
451
     *
452
     * @return integer
453
     */
454
    public function getRestoredBy()
455
    {
456
        return $this->restoredBy;
457
    }
458
459
    /**
460
     * Initialize method for model.
461
     */
462
    public function initialize() :void
463
    {
464
        parent::initialize();
465
        // $this->setSchema("zemit_core");
466
        $this->setSource("profile");
467
    }
468
469
    /**
470
     * Allows to query a set of records that match the specified conditions
471
     *
472
     * @param mixed $parameters
473
     * @return AbstractProfile[]|AbstractProfile|\Phalcon\Mvc\Model\ResultSetInterface
474
     */
475
    public static function find($parameters = null): \Phalcon\Mvc\Model\ResultsetInterface
476
    {
477
        return parent::find($parameters);
478
    }
479
480
    /**
481
     * Allows to query the first record that match the specified conditions
482
     *
483
     * @param mixed $parameters
484
     * @return AbstractProfile|\Phalcon\Mvc\Model\ResultInterface|\Phalcon\Mvc\ModelInterface|null
485
     */
486
    public static function findFirst($parameters = null): ?\Phalcon\Mvc\ModelInterface
487
    {
488
        return parent::findFirst($parameters);
489
    }
490
491
    /**
492
     * Independent Column Mapping.
493
     * Keys are the real names in the table and the values their names in the application
494
     *
495
     * @return array
496
     */
497
    public function columnMap()
498
    {
499
        return [
500
            'id' => 'id',
501
            'user_id' => 'userId',
502
            'deleted' => 'deleted',
503
            'created_at' => 'createdAt',
504
            'created_by' => 'createdBy',
505
            'created_as' => 'createdAs',
506
            'updated_at' => 'updatedAt',
507
            'updated_by' => 'updatedBy',
508
            'updated_as' => 'updatedAs',
509
            'deleted_at' => 'deletedAt',
510
            'deleted_as' => 'deletedAs',
511
            'deleted_by' => 'deletedBy',
512
            'restored_at' => 'restoredAt',
513
            'restored_by' => 'restoredBy'
514
        ];
515
    }
516
517
}
518