go_dreamfactory/modules/story/api.go

32 lines
612 B
Go

package story
import (
"go_dreamfactory/lego/core"
"go_dreamfactory/modules"
)
const (
StoryGetListResp = "getlist"
StoryChallengeResp = "challenge"
)
type apiComp struct {
modules.MCompGate
service core.IService
module *Story
}
//组件初始化接口
func (this *apiComp) Init(service core.IService, module core.IModule, comp core.IModuleComp, options core.IModuleOptions) (err error) {
err = this.MCompGate.Init(service, module, comp, options)
this.module = module.(*Story)
this.service = service
return
}
func (this *apiComp) Start() (err error) {
err = this.MCompGate.Start()
return
}