Damon Wang
974a2b9137
Merge f4b992174c
into 77acc749e4
2017-02-17 03:55:49 +00:00
tangshancheng
b0928f186f
fix #338 failed to generate swagger doc
2016-12-14 23:57:59 +08:00
Sergey Lanzman
cfc8658ab2
fix bug with generate swagger.
2016-12-12 22:35:39 +02:00
Faissal Elamraoui
03f2057eb0
Added PreRun phase to Command struct
...
Now each command has a PreRun function that will execute before calling
the Run() function. This allows to show the banner and do some pre-check
work. Also moved parsePackagesFromDir() to the main function to avoid
getting called each time 'bee' is invoked.
2016-11-20 22:28:52 +01:00
Faissal Elamraoui
ab39926c41
Enhances the package dir parser
...
The function parsePackagesFromDir() was panicing when it encounter some
"invalid" Go files. Instead, this will allow it to display a warning and
continue the execution of the command.
2016-11-20 11:46:42 +01:00
hcrgm
63b5a81104
Update g_docs.go
2016-11-14 19:07:22 +08:00
Faissal Elamraoui
cf7aef47f0
Implementing the new logging infrastructure
...
Moved logging to the new logging infrastructure by removing the use of
ColorLog() function. Added more documentation. Also fixed some typos in
comments and function names.
2016-11-13 15:14:48 +01:00
astaxie
04c0f9d7b4
output error
2016-11-10 16:51:50 +08:00
Zhang Qiang
3199a019d7
Swagger: support default value columns for @Param
...
This patch support default value after 'type' column if total
columns is six.
This enhancement also is compatiable with old five columns.
2016-11-03 23:18:05 +08:00
Konstantin
7c7e75435c
Update g_docs.go
2016-10-10 19:49:33 +03:00
Konstantin
e8f85a57c2
Add types error handler (log)
...
the usual warning not panic
2016-10-10 17:36:51 +03:00
Konstantin
31406ebe5a
Default values in structure
...
Swagger default value for golang stucture.
format:
doc:"default(my_defaul_value)"
type MyStruct struct {
Template string `json:"template" doc:"default(<h1>Hello, {{ name }}! </h1>)"`
Name string `json:"name"`
MyNumber int64 `json:"temp" doc:"default(10)"`
MyBool bool `json:"bl" doc:"default(true)"`
MyFloat float64 `json:"fl" doc:"default(12.1234)"`
}
2016-10-08 11:35:26 +03:00
Sergey Lanzman
d93e9a4271
Update g_docs.go
2016-09-27 18:20:01 +03:00
Sergey Lanzman
4ebf7eab65
add support multi package with gaoling way myPackage.struct
2016-09-25 01:34:26 +03:00
astaxie
29c9e1bab7
fix the map type generate
2016-09-22 23:04:58 +08:00
astaxie
205428abce
fix the licence issue
2016-09-22 22:26:39 +08:00
Sergey Lanzman
1b75ccb9fe
Improve swagger (Main params,yaml
2016-09-15 00:09:54 +03:00
astaxie
eb64d25e4a
Merge pull request #264 from beego/master
...
Develop update
2016-08-30 00:15:44 +08:00
Sergey Lanzman
004778c662
swagger add embedded struct
2016-08-29 11:04:47 +02:00
Konstantin
7e60509231
Separate and add @Description with @Summary params
...
@Description -> is "descriptions" in swagger
@Summary -> is "summary" in swagger
this different options.
2016-08-25 19:32:39 +03:00
astaxie
28f6abc3a0
merge master
2016-08-24 11:07:57 +08:00
astaxie
f813e990c0
hotfix: schema init
2016-08-24 10:54:54 +08:00
tnextday
07ca4481b0
add todo
2016-08-22 16:11:06 +08:00
tnextday
c3ff72ae77
Add support for query param array format.
...
exmple:
// @Param app query []string true support multipil app params
Update support for responses object format.
exmple:
// @Success 200 success
// @Success 200 {object} int64 success count
// @Success 200 {object} []int64 success ids
// @Success 200 {array} int64 success ids
2016-08-20 15:12:15 +08:00
tnextday
df9f5a77da
Merge commit '5309c72ef751bd4edb45d1702996eb279033b281' into develop
2016-08-20 11:18:46 +08:00
tnextday
ca2f60c72d
add array type support in comment param
2016-08-20 11:17:30 +08:00
astaxie
5309c72ef7
support success response array objects
2016-08-20 00:14:39 +08:00
astaxie
55fc8e535c
Merge pull request #245 from tnextday/develop
...
Use first NewNamespace prefix as swagger `BasePath`
2016-08-19 00:13:23 +08:00
tnextday
b160eb35b5
Use first NewNamespace prefix as swagger BasePath
2016-08-18 23:31:09 +08:00
astaxie
42f8892a81
Merge pull request #243 from tnextday/develop
...
fix swagger array items crash bug
2016-08-18 23:30:34 +08:00
tnextday
1e247452ff
update swagger
2016-08-18 22:29:38 +08:00
tnextday
3ccffe087e
update swagger array items define
2016-08-18 21:30:57 +08:00
tnextday
2f85185bcc
Print warnning only if param location is wrong
2016-08-18 21:03:27 +08:00
tnextday
07df26c7b6
add param location checker in generate gocs
2016-08-18 18:21:23 +08:00
Konstantin
c08afc129e
Update g_docs.go
...
Only you pass the model name, but do not pass the location.
Although getModel() function again trying to split ( strs := strings.Split(str, ".") ) the parameter to the location and name.
2016-08-18 12:58:36 +03:00
tnextday
985c18a314
go format
2016-08-18 17:40:59 +08:00
tnextday
ac1bf161fc
generate gocs support go buildin type in comment param
2016-08-18 17:38:26 +08:00
astaxie
11571b4af2
fix beego#2016
2016-08-17 23:48:38 +08:00
astaxie
fd7742863d
urlReplace all the paths
2016-08-17 08:02:21 +08:00
astaxie
525d2b0901
support object ref model
2016-08-16 23:32:13 +08:00
astaxie
0e240214ad
generator models
2016-08-13 14:45:12 +08:00
astaxie
743348ae1e
init the maps
2016-08-08 20:48:51 +08:00
astaxie
d9f182c84f
bee support swagger2.0
2016-08-08 16:44:49 +08:00
astaxie
adb346811d
Merge branch 'develop' of https://github.com/beego/bee into develop
2016-08-01 14:40:46 +08:00
astaxie
083fa9fd4b
swagger 2
2016-08-01 14:40:43 +08:00
Sergey Lanzman
bc963e0070
go lint
2016-07-23 02:05:01 +03:00
Damon Wang
f4b992174c
Update g_docs.go
...
add parase datatype in params
2016-07-06 14:32:36 +08:00
astaxie
76eb064e69
Merge pull request #128 from itcbx/patch-1
...
修改生成文档时,@Success 第三个参数解析错误的问题
2016-03-03 10:00:56 +08:00
astaxie
0acdf2e816
fix the rename in beego
2016-01-15 14:45:56 +08:00
astaxie
0ee483de97
fix the typo
2016-01-06 13:59:49 +08:00