32 lines
1.1 KiB
Go
32 lines
1.1 KiB
Go
|
|
package model
|
|
import (
|
|
"github.com/flipped-aurora/gin-vue-admin/server/global"
|
|
"time"
|
|
)
|
|
|
|
// MonitorConfig 监控配置 结构体
|
|
type MonitorConfig struct {
|
|
global.GVA_MODEL
|
|
BusinessDB *string `json:"businessDB" form:"businessDB" gorm:"column:business_db;comment:;" binding:"required"` //业务库名
|
|
Database *string `json:"database" form:"database" gorm:"column:database;comment:;" binding:"required"` //数据库名
|
|
Table *string `json:"table" form:"table" gorm:"column:table;comment:;" binding:"required"` //表名
|
|
Columns *string `json:"columns" form:"columns" gorm:"column:columns;comment:;" binding:"required"` //字段
|
|
IsEnable *bool `json:"isEnable" form:"isEnable" gorm:"column:is_enable;comment:;" binding:"required"` //是否启用
|
|
StartTime *time.Time `json:"startTime" form:"startTime" gorm:"column:start_time;comment:;"` //开始时间
|
|
EndTime *time.Time `json:"endTime" form:"endTime" gorm:"column:end_time;comment:;"` //结束时间
|
|
}
|
|
|
|
|
|
// TableName 监控配置 MonitorConfig自定义表名 monitor_config
|
|
func (MonitorConfig) TableName() string {
|
|
return "monitor_config"
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|