1
0
mirror of https://github.com/beego/bee.git synced 2024-11-21 18:40:54 +00:00

update version

This commit is contained in:
astaxie 2014-06-20 12:01:58 +08:00
parent 22f4c92022
commit d30c68e72f

View File

@ -49,7 +49,7 @@ var rootapi swagger.ResourceListing
var apilist map[string]*swagger.ApiDeclaration
func init() {
basepath := "/v1"
basepath := "{{.version}}"
err := json.Unmarshal([]byte(rootinfo), &rootapi)
if err != nil {
beego.Error(err)
@ -150,6 +150,7 @@ func generateDocs(curpath string) {
case *ast.AssignStmt:
for _, l := range smtp.Rhs {
f, params := analisysNewNamespace(l.(*ast.CallExpr))
globalDocsTemplate = strings.Replace(globalDocsTemplate, "{{.version}}", f, -1)
for _, p := range params {
switch pp := p.(type) {
case *ast.CallExpr: