db

package
v0.0.0-...-03eec91 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 27, 2019 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Client *gorm.DB

Client 默认数据库实例

Functions

func Conn

func Conn() (*gorm.DB, error)

Conn 用配置文件的默认参数连接数据库

func Connect

func Connect(prePath string) (*gorm.DB, error)

Connect 用配置文件连接数据库

func ConnectDB

func ConnectDB(dataSourceName string) (*gorm.DB, error)

ConnectDB 用连接字符串连接数据库

func Init

func Init() (*gorm.DB, error)

Init 默认初始化

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL