16f1e516
mzavalniuk
add artbox-catalo...
|
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
29
30
31
32
33
|
<?php
/**
* Created by PhpStorm.
* User: stes
* Date: 13.07.17
* Time: 17:11
*/
namespace artbox\catalog\models;
use yii\db\ActiveRecord;
use artbox\core\behaviors\LanguageBehavior;
use yii\behaviors\TimestampBehavior;
class Event extends ActiveRecord
{
public static function tableName()
{
return 'event';
}
public function behaviors()
{
return [
'language' => [
'class' => LanguageBehavior::className(),
],
];
}
public function getEventLangs()
{
return $this->hasMany(EventLang::className(), [ 'event_id' => 'id' ]);
}
}
|