33 lines
642 B
Go
33 lines
642 B
Go
package dbservice
|
|
|
|
import (
|
|
"go_dreamfactory/comm"
|
|
"go_dreamfactory/lego/core"
|
|
"go_dreamfactory/modules"
|
|
)
|
|
|
|
func NewModule() core.IModule {
|
|
m := new(DBService)
|
|
return m
|
|
}
|
|
|
|
type DBService struct {
|
|
modules.ModuleBase
|
|
db_comp *DB_Comp
|
|
}
|
|
|
|
func (this *DBService) Init(service core.IService, module core.IModule, options core.IModuleOptions) (err error) {
|
|
err = this.ModuleBase.Init(service, module, options)
|
|
|
|
return
|
|
}
|
|
|
|
func (this *DBService) GetType() core.M_Modules {
|
|
return comm.SM_LogModelModule
|
|
}
|
|
|
|
func (this *DBService) OnInstallComp() {
|
|
this.ModuleBase.OnInstallComp()
|
|
this.db_comp = this.RegisterComp(new(DB_Comp)).(*DB_Comp)
|
|
}
|