123456789101112131415161718192021222324252627282930 |
- package models
- import (
- "eta_gn/eta_chart_lib/global"
- "time"
- )
- type ChartSeriesEdbMapping struct {
- ChartSeriesEdbMappingId int `gorm:"column:chart_series_edb_mapping_id;primaryKey" description:"系列指标映射ID" orm:"column(chart_series_edb_mapping_id);pk"`
- ChartSeriesId int `gorm:"column:chart_series_id" description:"系列ID"`
- ChartInfoId int `gorm:"column:chart_info_id" description:"图表ID"`
- EdbInfoId int `gorm:"column:edb_info_id" description:"指标id"`
- DateConfName string `gorm:"column:date_conf_name" description:"引用日期配置名称"`
- DateConfType int `gorm:"column:date_conf_type" description:"日期类型,0指标最新日期,1引用日期"`
- DateConf string `gorm:"column:date_conf" description:"日期配置名称"`
- ModifyTime time.Time `gorm:"column:modify_time" description:"修改时间"`
- CreateTime time.Time `gorm:"column:create_time" description:"创建时间"`
- }
- func (c *ChartSeriesEdbMapping) TableName() string {
- return "chart_series_edb_mapping"
- }
- func GetChartSeriesEdbByChartInfoId(chartInfoId int) (items []*ChartSeriesEdbMapping, err error) {
- o := global.DmSQL["data"]
- sql := "SELECT * FROM chart_series_edb_mapping WHERE chart_info_id = ?"
- err = o.Raw(sql, chartInfoId).Scan(&items).Error
- return
- }
|