1
|
|
|
<?php |
2
|
|
|
|
3
|
|
|
namespace Modules\Entitizer\Definition { |
4
|
|
|
|
5
|
|
|
use Modules\Entitizer; |
6
|
|
|
|
7
|
|
|
class Page extends Entitizer\Utils\Definition { |
8
|
|
|
|
9
|
|
|
use Entitizer\Common\Page; |
10
|
|
|
|
11
|
|
|
# Define presets |
12
|
|
|
|
13
|
|
|
protected function define() { |
14
|
|
|
|
15
|
|
|
# Add params |
16
|
|
|
|
17
|
|
|
$this->params->integer ('visibility', true, 1, true, VISIBILITY_DRAFT); |
18
|
|
|
$this->params->integer ('access', true, 1, true, ACCESS_PUBLIC); |
19
|
|
|
$this->params->boolean ('locked', true); |
20
|
|
|
$this->params->textual ('slug', true, 255, false, ''); |
21
|
|
|
$this->params->textual ('name', true, 255, false, ''); |
22
|
|
|
$this->params->textual ('title', true, 255, false, ''); |
23
|
|
|
$this->params->textual ('contents', false, 0, false, ''); |
24
|
|
|
$this->params->textual ('description', false, 0, false, ''); |
25
|
|
|
$this->params->textual ('keywords', false, 0, false, ''); |
26
|
|
|
$this->params->boolean ('robots_index', false); |
27
|
|
|
$this->params->boolean ('robots_follow', false); |
28
|
|
|
$this->params->integer ('time_created', false, 10, true, 0); |
29
|
|
|
$this->params->integer ('time_modified', false, 10, true, 0); |
30
|
|
|
|
31
|
|
|
# Add indexes |
32
|
|
|
|
33
|
|
|
$this->indexes->add ('visibility'); |
34
|
|
|
$this->indexes->add ('access'); |
35
|
|
|
$this->indexes->add ('slug'); |
36
|
|
|
$this->indexes->add ('name'); |
37
|
|
|
$this->indexes->add ('title'); |
38
|
|
|
$this->indexes->add ('time_created'); |
39
|
|
|
$this->indexes->add ('time_modified'); |
40
|
|
|
} |
41
|
|
|
} |
42
|
|
|
} |
43
|
|
|
|