|
@@ -424,21 +424,6 @@ func GenIndexApi(p *Project) error {
|
|
// G.Id(fmt.Sprintf(`FilterHandle("../api/%s/filters")`, p.Package)),
|
|
// G.Id(fmt.Sprintf(`FilterHandle("../api/%s/filters")`, p.Package)),
|
|
// ))
|
|
// ))
|
|
|
|
|
|
- statments = append(statments, G.Line().Comment("Debug eventstream").Line().Id("app").Dot("Get").Call(
|
|
|
|
- G.Lit("/debug"),
|
|
|
|
- G.Id(`apply("debug", Debug.EventStream())`),
|
|
|
|
- // G.Func().Params(G.Id("ctx").Qual(IRIS_CTX, "Context")).Block(
|
|
|
|
-
|
|
|
|
- // G.Id(`
|
|
|
|
- // if err = asyncTaskManagerService.Hub.UpgradeConnection(
|
|
|
|
- // ctx,
|
|
|
|
- // fmt.Sprintf("async.task.%s", asyncTaskId),
|
|
|
|
- // ); err != nil {
|
|
|
|
- // ctx.
|
|
|
|
- // }
|
|
|
|
- // `),
|
|
|
|
- // ),
|
|
|
|
- ))
|
|
|
|
// Cria a funcao que trata os metodos options
|
|
// Cria a funcao que trata os metodos options
|
|
statments = append(statments, G.Line().Comment("Options request").Line().Id("app").Dot("Options").Call(
|
|
statments = append(statments, G.Line().Comment("Options request").Line().Id("app").Dot("Options").Call(
|
|
G.Lit("/{url:path}"),
|
|
G.Lit("/{url:path}"),
|
|
@@ -447,6 +432,10 @@ func GenIndexApi(p *Project) error {
|
|
),
|
|
),
|
|
))
|
|
))
|
|
|
|
|
|
|
|
+ statments = append(statments, G.Line().Comment("Debug eventstream").Line().Id("app").Dot("Get").Call(
|
|
|
|
+ G.Lit("/api/v1/debug"),
|
|
|
|
+ G.Id(`apply("debug", Debug.EventStream())`),
|
|
|
|
+ ))
|
|
// Cria a funcao que registra as urls da api no arquivo api_index_gen.go
|
|
// Cria a funcao que registra as urls da api no arquivo api_index_gen.go
|
|
Index.Func().Id("Register").Params(
|
|
Index.Func().Id("Register").Params(
|
|
G.Id("app").Op("*").Qual(IRIS, "Application"),
|
|
G.Id("app").Op("*").Qual(IRIS, "Application"),
|