1 | <?php |
||
18 | * @author Flipbox Factory <[email protected]> |
||
19 | * @since 1.0.0 |
||
20 | */ |
||
21 | class ApplicationKeyConnection extends AbstractSaveableConnection implements SavableConnectionInterface |
||
22 | { |
||
23 | /** |
||
24 | * @var string |
||
25 | */ |
||
26 | public $key; |
||
27 | |||
28 | /** |
||
29 | * @var string |
||
30 | */ |
||
31 | public $hubId; |
||
32 | |||
33 | /** |
||
34 | * Returns the display name of this class. |
||
35 | * |
||
36 | * @return string The display name of this class. |
||
37 | */ |
||
38 | public static function displayName(): string |
||
42 | |||
43 | /** |
||
44 | * @inheritdoc |
||
45 | * @throws \Twig_Error_Loader |
||
46 | * @throws \yii\base\Exception |
||
47 | */ |
||
48 | public function getSettingsHtml() |
||
57 | |||
58 | /** |
||
59 | * @inheritdoc |
||
60 | */ |
||
61 | public function rules() |
||
62 | { |
||
63 | return array_merge( |
||
64 | parent::rules(), |
||
65 | [ |
||
66 | [ |
||
67 | [ |
||
68 | 'key', |
||
69 | 'hubId' |
||
70 | ], |
||
71 | 'required' |
||
72 | ], |
||
73 | [ |
||
74 | [ |
||
75 | 'key', |
||
76 | 'hubId' |
||
77 | ], |
||
78 | 'safe', |
||
79 | 'on' => [ |
||
80 | static::SCENARIO_DEFAULT |
||
81 | ] |
||
138 |