2018-07-07 17:31:18 +05:30
|
|
|
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
|
|
|
|
namespace common\models;
|
|
|
|
|
|
|
|
use yii\behaviors\TimestampBehavior;
|
|
|
|
use yii\db\ActiveRecord;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Fields:
|
|
|
|
* @property int $id
|
|
|
|
* @property string $url
|
|
|
|
* @property string|null $secret
|
2020-06-14 03:50:31 +05:30
|
|
|
* @property string[] $events
|
2018-07-07 17:31:18 +05:30
|
|
|
* @property int $created_at
|
|
|
|
*
|
|
|
|
* Behaviors:
|
|
|
|
* @mixin TimestampBehavior
|
|
|
|
*/
|
|
|
|
class WebHook extends ActiveRecord {
|
|
|
|
|
|
|
|
public static function tableName(): string {
|
2020-06-14 03:50:31 +05:30
|
|
|
return 'webhooks';
|
2018-07-07 17:31:18 +05:30
|
|
|
}
|
|
|
|
|
|
|
|
public function behaviors(): array {
|
|
|
|
return [
|
|
|
|
[
|
|
|
|
'class' => TimestampBehavior::class,
|
|
|
|
'updatedAtAttribute' => false,
|
|
|
|
],
|
|
|
|
];
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|