增加自动化代码选择业务库功能,增加无边框页面功能。 (#1264)
* feat:增加无边框页面路由 * 更改基础页面文字说明 * 修复安装插件路径穿越漏洞 * 添加业务库数据库选择功能 Co-authored-by: dzwvip <dzwvip@qq.com> Co-authored-by: znonymous <fly1029@yeah.net>
This commit is contained in:
@@ -12,6 +12,7 @@ type Server struct {
|
||||
// gorm
|
||||
Mysql Mysql `mapstructure:"mysql" json:"mysql" yaml:"mysql"`
|
||||
Pgsql Pgsql `mapstructure:"pgsql" json:"pgsql" yaml:"pgsql"`
|
||||
Oracle Oracle `mapstructure:"oracle" json:"oracle" yaml:"oracle"`
|
||||
DBList []SpecializedDB `mapstructure:"db-list" json:"db-list" yaml:"db-list"`
|
||||
// oss
|
||||
Local Local `mapstructure:"local" json:"local" yaml:"local"`
|
||||
|
14
server/config/gorm_oracle.go
Normal file
14
server/config/gorm_oracle.go
Normal file
@@ -0,0 +1,14 @@
|
||||
package config
|
||||
|
||||
type Oracle struct {
|
||||
GeneralDB `yaml:",inline" mapstructure:",squash"`
|
||||
}
|
||||
|
||||
func (m *Oracle) Dsn() string {
|
||||
return "oracle://" + m.Username + ":" + m.Password + "@" + m.Path + ":" + m.Port + "/" + m.Dbname + "?" + m.Config
|
||||
|
||||
}
|
||||
|
||||
func (m *Oracle) GetLogMode() string {
|
||||
return m.LogMode
|
||||
}
|
Reference in New Issue
Block a user