FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
wn-multidb-plugin/models/Setting.php at main · phpiando/wn-multidb-plugin · GitHub
phpiando
/
wn-multidb-plugin
Public
Notifications
You must be signed in to change notification settings
Fork
1
Star
1
Code
Issues
0
Pull requests
0
Actions
Projects
Security and quality
0
Insights
Additional navigation options
Code
Issues
Pull requests
Actions
Projects
Security and quality
Insights
Expand file tree
Breadcrumbs
wn-multidb-plugin
/
models
/
Setting.php
Copy path
More file actions
More file actions
Latest commit
History
History
History
57 lines (50 loc) · 1.24 KB
Breadcrumbs
wn-multidb-plugin
/
models
/
Setting.php
Copy path
File metadata and controls
57 lines (50 loc) · 1.24 KB
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
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
<?php
namespace
Sommer
\
Multidb
\
Models
;
use
Sommer
\
MultiDB
\
Constants
\
SettingConstants
;
use
Winter
\
Storm
\
Database
\
Model
;
use
System
\
Models
\
PluginVersion
;
/**
* @class Setting Model
* @package Sommer\MultiDB\Models
* @since 1.0.0
* @author Roni Sommerfeld<roni@4tech.mobi>
*
* @property string $database_prefix
* @property string $database_rule_to_name
* @property array $plugins
* @property bool $database_queue_on_create
*/
class
Setting
extends
Model
{
use
\
Sommer
\
MultiDB
\
Traits
\UsesMainConnection;
/**
* Behaviors implemented by this model.
*
* @var array
*/
public
$
implement
= [
'
System.Behaviors.SettingsModel
'
];
/**
* A unique code for this model.
*
* @var string
*/
public
$
settingsCode
= SettingConstants::
SETTINGS_CODE
;
/**
* Reference to field configuration.
*
* @var string
*/
public
$
settingsFields
=
'
fields.yaml
'
;
/**
* Returns the options for the database name fields.
*
* @return array
*/
public
function
getDatabaseRuleToNameOptions
():
array
{
return
SettingConstants::
DB_NAME_OPTIONS
;
}
public
function
getPluginsOptions
():
array
{
return
PluginVersion::
lists
(
'
code
'
,
'
code
'
);
}
}
Back
|
FazBrowse Home
|
New Git URL