Category::__construct()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 8
Code Lines 6

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 6
dl 0
loc 8
rs 10
c 1
b 0
f 0
cc 1
nc 1
nop 0
1
<?php
2
3
namespace XoopsModules\Extcal;
4
5
/*
6
 * You may not change or alter any portion of this comment or credits
7
 * of supporting developers from this source code or any supporting source code
8
 * which is considered copyrighted (c) material of the original comment or credit authors.
9
 *
10
 * This program is distributed in the hope that it will be useful,
11
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
13
 */
14
15
/**
16
 * @copyright    {@link https://xoops.org/ XOOPS Project}
17
 * @license      {@link https://www.gnu.org/licenses/gpl-2.0.html GNU GPL 2 or later}
18
 * @package      extcal
19
 * @since
20
 * @author       XOOPS Development Team,
21
 */
22
23
// require_once __DIR__ . '/ExtcalPersistableObjectHandler.php';
24
//require_once __DIR__ . '/perm.php';
25
//require_once __DIR__ . '/time.php';
26
27
/**
28
 * Class Category.
29
 */
30
class Category extends \XoopsObject
31
{
32
    public $externalKey = [];
33
34
    /**
35
     * Category constructor.
36
     */
37
    public function __construct()
38
    {
39
        $this->initVar('cat_id', \XOBJ_DTYPE_INT, null, false);
40
        $this->initVar('cat_name', \XOBJ_DTYPE_TXTBOX, null, true, 255);
41
        $this->initVar('cat_desc', \XOBJ_DTYPE_TXTAREA, null, false);
42
        $this->initVar('cat_color', \XOBJ_DTYPE_TXTBOX, '000000', false, 255);
43
        $this->initVar('cat_weight', \XOBJ_DTYPE_INT, 0, false);
44
        $this->initVar('cat_icone', \XOBJ_DTYPE_TXTBOX, '', false, 50);
45
    }
46
}
47