biz

package
v0.0.0-...-4c2a98a Latest Latest
Warning

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

Go to latest
Published: May 13, 2023 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	DbName string
)

Functions

func ColumnAndType

func ColumnAndType(table_schema []*core.Column) string

func ColumnWithPostfix

func ColumnWithPostfix(columns []string, Postfix, sep string) string

func DBInit

func DBInit(dbms, dbName, user, password, host, port string) (err error)

func ExportColumn

func ExportColumn(columnName string) string

func ExportLabel

func ExportLabel(columnName string) template.HTML

func FirstCharLower

func FirstCharLower(str string) string

func FirstCharUpper

func FirstCharUpper(str string) string

func HumpStructName

func HumpStructName(tableName string) string

func IsExist

func IsExist(path string) bool

判断是否存在文件或者目录

func IsUUID

func IsUUID(str string) bool

func Join

func Join(a []string, sep string) string

func MakeQuestionMarkList

func MakeQuestionMarkList(num int) string

func ModelGenerate

func ModelGenerate(importName, tableName string, tplFile string) error

func Tags1

func Tags1(columnName string) template.HTML

func Tags3

func Tags3(columnName string) template.HTML

func TypeConvert

func TypeConvert(st core.SQLType) string

func Unescaped

func Unescaped(x string) interface{}

Types

type ModelInfo

type ModelInfo struct {
	*core.Table
	BDName          string
	DBConnection    string
	TableName       string
	ExportModelName string
	ImportName      string
	PackageName     string
	ModelName       string
	Columns         []*core.Column
	TableComment    string
}

Jump to

Keyboard shortcuts

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