1
This commit is contained in:
parent
b46f1d1902
commit
f32c02b76a
@ -7,19 +7,29 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
type app struct {
|
type app struct {
|
||||||
|
initCb func()
|
||||||
|
unInitCb func()
|
||||||
}
|
}
|
||||||
|
|
||||||
func (this *app) GetPkgName() string {
|
func (this *app) GetPkgName() string {
|
||||||
return "adminserver"
|
return "adminserver"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (this *app) Run(initCb func(), unInitCb func()) {
|
||||||
|
this.initCb = initCb
|
||||||
|
this.unInitCb = unInitCb
|
||||||
|
f5.Run(this)
|
||||||
|
}
|
||||||
|
|
||||||
func (this *app) Init() {
|
func (this *app) Init() {
|
||||||
f5.LoadMetaTable(mt.Table)
|
f5.LoadMetaTable(mt.Table)
|
||||||
this.registerDataSources()
|
this.registerDataSources()
|
||||||
//ginMgr.init()
|
//ginMgr.init()
|
||||||
|
this.initCb()
|
||||||
}
|
}
|
||||||
|
|
||||||
func (this *app) UnInit() {
|
func (this *app) UnInit() {
|
||||||
|
this.unInitCb()
|
||||||
//ginMgr.unInit()
|
//ginMgr.unInit()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user