Documentation ¶
Index ¶
- func GetMgoValue(d tk.M, fieldName string) interface{}
- func PrepareConnection() (dbox.IConnection, error)
- type BaseController
- func (b *BaseController) CloseDb()
- func (b *BaseController) Delete(m orm.IModel, id interface{}, column_name ...string) error
- func (b *BaseController) GetById(m orm.IModel, id interface{}, column_name ...string) error
- func (b *BaseController) GetDataSource(dataSourceFolder string) ([]os.FileInfo, string)
- func (b *BaseController) GetDataSourceDirect(dataSourceFolder string) ([]os.FileInfo, string)
- func (b *BaseController) GetLatest(collection string, project string, turbine string) (latest time.Time)
- func (b *BaseController) GetProjectList()
- func (b *BaseController) GetTurbineScada()
- func (b *BaseController) Insert(result []tk.M, m orm.IModel, wg *sync.WaitGroup)
- func (b *BaseController) InsertBulk(result []tk.M, m orm.IModel, wg *sync.WaitGroup)
- func (b *BaseController) PrepareDataReff()
- func (b *BaseController) SetCollectionLatestTime()
- func (b *BaseController) Truncate(m orm.IModel) error
- func (b *BaseController) Update(m orm.IModel, id interface{}, column_name ...string) error
- func (b *BaseController) WriteLog(msg interface{})
- type IBaseController
- type LatestData
- type TurbineLatest
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetMgoValue ¶
func PrepareConnection ¶
func PrepareConnection() (dbox.IConnection, error)
Types ¶
type BaseController ¶
type BaseController struct { Ctx *orm.DataContext LatestData LatestData RefTurbines tk.M RefAlarms tk.M CapacityPerMonth map[string]float64 TotalTurbinePerMonth map[string]float64 ProjectList []ProjectOut Log *tk.LogEngine // contains filtered or unexported fields }
func (*BaseController) CloseDb ¶
func (b *BaseController) CloseDb()
func (*BaseController) Delete ¶
func (b *BaseController) Delete(m orm.IModel, id interface{}, column_name ...string) error
func (*BaseController) GetById ¶
func (b *BaseController) GetById(m orm.IModel, id interface{}, column_name ...string) error
func (*BaseController) GetDataSource ¶
func (b *BaseController) GetDataSource(dataSourceFolder string) ([]os.FileInfo, string)
func (*BaseController) GetDataSourceDirect ¶
func (b *BaseController) GetDataSourceDirect(dataSourceFolder string) ([]os.FileInfo, string)
func (*BaseController) GetProjectList ¶
func (b *BaseController) GetProjectList()
func (*BaseController) GetTurbineScada ¶
func (b *BaseController) GetTurbineScada()
func (*BaseController) InsertBulk ¶
func (*BaseController) PrepareDataReff ¶
func (b *BaseController) PrepareDataReff()
func (*BaseController) SetCollectionLatestTime ¶
func (b *BaseController) SetCollectionLatestTime()
func (*BaseController) Update ¶
func (b *BaseController) Update(m orm.IModel, id interface{}, column_name ...string) error
func (*BaseController) WriteLog ¶
func (b *BaseController) WriteLog(msg interface{})
type IBaseController ¶
type IBaseController interface { }
type LatestData ¶
type LatestData struct { Alarm []TurbineLatest EventDown []TurbineLatest ScadaData []TurbineLatest ScadaDataOEM []TurbineLatest ScadaSummaryDaily []TurbineLatest MapAlarm map[string]time.Time MapEventDown map[string]time.Time MapScadaData map[string]time.Time MapScadaDataOEM map[string]time.Time MapScadaSummaryDaily map[string]time.Time }
type TurbineLatest ¶
type TurbineLatest struct {
// contains filtered or unexported fields
}
Click to show internal directories.
Click to hide internal directories.