1 | <?php |
||
19 | class CreateProvider extends CreateRecord |
||
20 | { |
||
21 | use PopulateSettingsTrait; |
||
22 | |||
23 | /** |
||
24 | * @inheritdoc |
||
25 | */ |
||
26 | public $validBodyParams = [ |
||
27 | 'handle', |
||
28 | 'clientId', |
||
29 | 'clientSecret', |
||
30 | 'scopes', |
||
31 | 'class', |
||
32 | 'enabled' |
||
33 | ]; |
||
34 | |||
35 | /** |
||
36 | * @param ActiveRecord|Provider $record |
||
37 | * @return ActiveRecord |
||
38 | */ |
||
39 | protected function populate(ActiveRecord $record): ActiveRecord |
||
46 | |||
47 | /** |
||
48 | * @inheritdoc |
||
49 | * @return Provider |
||
50 | */ |
||
51 | protected function newRecord(array $config = []): ActiveRecord |
||
63 | } |
||
64 |