1
0
mirror of https://github.com/muety/wakapi.git synced 2023-08-10 21:12:56 +03:00

chore: minor fixes

This commit is contained in:
Ferdinand Mütsch
2022-02-13 10:59:14 +01:00
parent e7f3432113
commit e21788b8b5
8 changed files with 633 additions and 577 deletions

View File

@ -1,13 +1,14 @@
// Package docs GENERATED BY THE COMMAND ABOVE; DO NOT EDIT
// GENERATED BY THE COMMAND ABOVE; DO NOT EDIT
// This file was generated by swaggo/swag
package docs
import (
"bytes"
"encoding/json"
"strings"
"text/template"
"github.com/alecthomas/template"
"github.com/swaggo/swag"
)
@ -15,7 +16,7 @@ var doc = `{
"schemes": {{ marshal .Schemes }},
"swagger": "2.0",
"info": {
"description": "{{escape .Description}}",
"description": "{{.Description}}",
"title": "{{.Title}}",
"contact": {
"name": "Ferdinand Mütsch",
@ -191,7 +192,7 @@ var doc = `{
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/v1.HeartbeatEntry"
"$ref": "#/definitions/v1.HeartbeatsResult"
}
},
"400": {
@ -1340,6 +1341,9 @@ var doc = `{
"machine_name_id": {
"type": "string"
},
"modified_at": {
"type": "string"
},
"project": {
"type": "string"
},
@ -1357,6 +1361,26 @@ var doc = `{
}
}
},
"v1.HeartbeatsResult": {
"type": "object",
"properties": {
"data": {
"type": "array",
"items": {
"$ref": "#/definitions/v1.HeartbeatEntry"
}
},
"end": {
"type": "string"
},
"start": {
"type": "string"
},
"timezone": {
"type": "string"
}
}
},
"v1.Project": {
"type": "object",
"properties": {
@ -1703,13 +1727,6 @@ func (s *s) ReadDoc() string {
a, _ := json.Marshal(v)
return string(a)
},
"escape": func(v interface{}) string {
// escape tabs
str := strings.Replace(v.(string), "\t", "\\t", -1)
// replace " with \", and if that results in \\", replace that with \\\"
str = strings.Replace(str, "\"", "\\\"", -1)
return strings.Replace(str, "\\\\\"", "\\\\\\\"", -1)
},
}).Parse(doc)
if err != nil {
return doc
@ -1724,5 +1741,5 @@ func (s *s) ReadDoc() string {
}
func init() {
swag.Register("swagger", &s{})
swag.Register(swag.Name, &s{})
}