common

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Feb 1, 2024 License: MulanPSL-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MODULE_NAME_SHOP = "icd/cms/shop"
	MODULE_NAME_HRMS = "icd/hrms"

	MODULE_NAME_NOW = "icd/hub/shop"
	MODULE_NAME_NEW = MODULE_NAME_HRMS
)
@Title    文件名称: factroy_consts.go
@Description  描述: 代码工厂常量文件

@Author  作者: leijianming@163.com  时间(2024-01-31 22:38:21)
@Update  作者: leijianming@163.com  时间(2024-01-31 22:38:21)

根据这个切换不同系统的代码生成

View Source
const (
	DB_TYPE_MYSQL     = "mysql"
	DB_TYPE_POSTGRES  = "postgres"
	DB_TYPE_COCKROACH = "cockroach"
)
View Source
const (
	TEMPLATE_PATH = "/factroy/template/"

	OUTPUT_DIR = "/factroy/output/"

	LOG_FILE = "/opt/logs/factroy.log"
)

Variables

View Source
var Module = hrms

Functions

This section is empty.

Types

type Config

type Config struct {
	BasePath   string
	ConfigFile string
	Datasource struct {
		Dbtype string `yaml:"dbtype"`
		Dbname string `yaml:"dbname"`
		Host   string `yaml:"host"`
		Port   int    `yaml:"port"`

		Username string `yaml:"username"`
		Password string `yaml:"password"`
		Charset  string `yaml:"charset"`
	}
}

func (*Config) ReadConfig

func (config *Config) ReadConfig()

func (*Config) ReadConfigBy

func (config *Config) ReadConfigBy(basePath string, configFile string)

func (*Config) String

func (entity *Config) String() string

type ModuleDefine

type ModuleDefine struct {
	DbName    string
	ModelPath string
	TestPath  string
}
   @Title    文件名称: module_define.go
   @Description  描述: 代码工厂模块定义文件

   @Author  作者: leijianming@163.com  时间(2024-01-31 22:38:21)
   @Update  作者: leijianming@163.com  时间(2024-01-31 22:38:21)

	统一GO代码多层生成工具,
	author: leijianming
	2024-01-22
var (
	System *ModuleDefine = &ModuleDefine{
		"system",
		"icd/system",
		"icd/system-test",
	}
)

Jump to

Keyboard shortcuts

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