forked from spatie/laravel-settings
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsettings.php
66 lines (57 loc) · 2.08 KB
/
settings.php
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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
<?php
return [
/*
* You can register all the settings classes here.
*/
'settings' => [
],
/*
* When you create a new settings migration via the `make:settings-migration`
* command the package will store these migrations in this directory.
*/
'migrations_path' => database_path('settings'),
/*
* When no repository was set for a settings class this repository will be
* used for loading and saving settings.
*/
'default_repository' => 'database',
/*
* Settings will be stored and loaded from these repositories. There are
* two types of repositories: database and Redis. But its always
* possible to create your specific types of repositories.
*/
'repositories' => [
'database' => [
'type' => Spatie\LaravelSettings\SettingsRepositories\DatabaseSettingsRepository::class,
'model' => null,
'connection' => null,
],
'redis' => [
'type' => Spatie\LaravelSettings\SettingsRepositories\RedisSettingsRepository::class,
'connection' => null,
'prefix' => null,
],
],
/*
* When the package discovers a setting with a type other than the PHP built
* in types, it should be cast. These casts will automatically cast types
* when they occur in a settings class.
*/
'global_casts' => [
DateTimeInterface::class => Spatie\LaravelSettings\SettingsCasts\DateTimeInterfaceCast::class,
DateTimeZone::class => Spatie\LaravelSettings\SettingsCasts\DateTimeZoneCast::class,
Spatie\DataTransferObject\DataTransferObject::class => Spatie\LaravelSettings\SettingsCasts\DtoCast::class,
],
/*
* The package will look for settings in these paths and automatically
* register them.
*/
'auto_discover_settings' => [
app()->path(),
],
/*
* When in production, it is advised to cache the automatically discovered
* and registered setting classes will be cached in this path.
*/
'cache_path' => storage_path('app/laravel-settings'),
];