@@ 20-31 (lines=12) @@ | ||
17 | * |
|
18 | * @return void |
|
19 | */ |
|
20 | public function up() |
|
21 | { |
|
22 | /* @var \Anomaly\Streams\Platform\Field\Contract\FieldInterface $field */ |
|
23 | $field = $this->fields()->findBySlugAndNamespace('user', 'preferences'); |
|
24 | ||
25 | $field->config = [ |
|
26 | 'mode' => 'lookup', |
|
27 | 'related' => 'Anomaly\UsersModule\User\UserModel', |
|
28 | ]; |
|
29 | ||
30 | $field->save(); |
|
31 | } |
|
32 | ||
33 | /** |
|
34 | * Reverse the migrations. |
|
@@ 38-49 (lines=12) @@ | ||
35 | * |
|
36 | * @return void |
|
37 | */ |
|
38 | public function down() |
|
39 | { |
|
40 | /* @var \Anomaly\Streams\Platform\Field\Contract\FieldInterface $field */ |
|
41 | $field = $this->fields()->findBySlugAndNamespace('user', 'preferences'); |
|
42 | ||
43 | $field->config = [ |
|
44 | 'mode' => 'lookup', |
|
45 | 'relation' => 'Anomaly\UsersModule\User\UserModel', |
|
46 | ]; |
|
47 | ||
48 | $field->save(); |
|
49 | } |
|
50 | } |
|
51 |