blob: 5e71e539c11d277544a8a86f3595b7b4ce0254f5 (
plain)
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
|
<?php
Prado::using('Application.db.ActiveRecord');
Prado::using('Application.model.Calendar');
class Category extends ActiveRecord {
const TABLE = 'categories';
public $ID;
public $Name;
public static $COLUMN_MAPPING = [
'id' => 'ID',
'name' => 'Name'
];
public static $RELATIONS = [
'Calendars' => [self::HAS_MANY, 'Calendar', '_category']
];
public static function finder($className=__CLASS__) {
return parent::finder($className);
}
}
?>
|