William Cheng
7968349991
go server - use tabs instead of spaces ( #14740 )
2023-02-18 00:37:53 +08:00
Rodrigo Cebrián González
612dc4dbcb
[BUG][Go] Remove "null" body value when body is empty #13927 ( #13934 )
...
* only write reponse body if not nil
* update go samples
* golang style convention
2023-02-18 00:29:12 +08:00
Sebastian Cevallos
8540c82d30
Add handling for parsing optional bool params & regenerate samples ( #14550 )
2023-01-30 16:35:19 +08:00
Ian Cubbon
74073df27c
[GO][Client] Use a *os.File
for the API Client when uploading and downloading ( #14340 )
...
* Change the return type of a file back to a pointer
* Change the api template to handle not double pointer-ing return types of os.File
* Fix unit tests
* Couple more unit test fixes
2023-01-16 16:51:04 +08:00
Ian Cubbon
63629ad51c
[Go] File Download Fix Return Type ( #14046 )
...
* Changes manually cherry-picked (for the most part) from https://github.com/OpenAPITools/openapi-generator/pull/12685/files
* Examples updated post changes
* Missed a change in the mustache template
* Update examples after last fix
* Missed dereference for required files
* Update unit tests
* Missed another test case update
* `f := *f` isn't quite the same as `*f, err = ...`
2022-12-06 12:21:39 +08:00
Aliaksei Zhuk
9c3d4ef2a6
Parse integer array query parameters. Fix typos ( #11105 )
2022-01-04 17:55:18 +08:00
Nathan Baulch
5d68bd6a03
Fix thousands of spelling typos ( #10272 )
2021-08-28 22:58:24 +08:00
Ween Jiann
3b8f66cd1f
[go-server] Fix: param names clash with variables, added suffix ( #10243 )
...
* Postfix "Param" to param names in controller
* Regen samples
2021-08-27 13:07:31 +08:00
William Cheng
0204bf4ae2
Squashed commit of the following:
...
commit c5a0d0f7394aa742fa336fff7e7c1d3049761868
Merge: 8c4991ba3ed f8ff8c87609
Author: William Cheng <wing328hk@gmail.com>
Date: Tue Aug 17 18:28:12 2021 +0800
Merge branch 'mustache-linting' of https://github.com/NathanBaulch/openapi-generator into NathanBaulch-mustache-linting
commit f8ff8c87609b1ca36fa26fb8474806999638195e
Author: Nathan Baulch <nathan.baulch@gmail.com>
Date: Thu Aug 5 14:12:47 2021 +1000
Reorder tags that handle missing values
commit f5d8a33709d6a3f846a9fe4520b78c3d637051d9
Author: Nathan Baulch <nathan.baulch@gmail.com>
Date: Thu Aug 5 14:08:59 2021 +1000
Use dot notation where possible
commit 493d14921e2333f3ae19ef6fc89318b7e263a80c
Author: Nathan Baulch <nathan.baulch@gmail.com>
Date: Thu Aug 5 14:10:49 2021 +1000
Remove empty tags
commit 32480dc53f48227d55531b94e307d72671373737
Author: Nathan Baulch <nathan.baulch@gmail.com>
Date: Thu Aug 5 10:41:58 2021 +1000
Remove redundant sections
commit a8edabd722c34aa094b4aeb11c22664529c3a219
Author: Nathan Baulch <nathan.baulch@gmail.com>
Date: Wed Aug 4 22:02:22 2021 +1000
Trim extra EOF new lines
commit e89bd7458e3594bf0d30e580bc9408e45b018a57
Author: Nathan Baulch <nathan.baulch@gmail.com>
Date: Wed Aug 4 21:59:26 2021 +1000
Trim trailing whitespace
2021-08-17 18:37:51 +08:00
Ween Jiann
11d29eb22b
[go-server] Feat: add required assertions to models ( #10068 )
...
* Add RequiredError
* Add IsZeroValue helper
* Add AssertRequired method to all models
* Add AssertRequired call for body param
* Regenerate files
* Add DisallowUnknownFields
* Regenerate samples
* Use hasRequired in model to remove unnecessary code
* Revert disallowUnknownFields
* Use isAdditionalPropertiesTrue for disallowing unknown fields
* Updated samples
* Fix indent
* Add require checks for nested slices
* Add new tests
* Regenerate samples
* Regenerate samples after merging
2021-08-07 21:29:14 +08:00
Nathan Baulch
c1c5775271
[go] More idiomatic godoc comments ( #10044 )
...
* [go] More idiomatic godoc comments
* [go] Mark deprecated fields and functions
* [go] Minor mustache readability/consistency fixes
* [go] Mark deprecated operation parameters
* [go] Deprecate a petstore component property for testing
* [go] Apply deprecated godoc in Go servers also
2021-08-03 17:11:16 +08:00
Ween Jiann
870ef3a87a
[go-server] Allow user to specify how errors are handled ( #9764 )
...
* Added error.go
* Updated controller to use error
* Fix redeclared func
* Add generated files
* Merge
* Added docs
* Remove variadic
* Regenerate files
* Updated go doc to meet standard
* Updated doc to meet go standard
* Updated
2021-07-28 17:19:47 +08:00
Max Goltzsche
2e85ccdec8
[go-server] fix addResponseHeaders tpl option typo ( #9814 )
...
According to the [documentation](https://openapi-generator.tech/docs/generators/go-server ) the go-server generator should support an `addResponseHeaders` option but a template uses an `addResponseHeader` option in some places which this PR fixes.
Closes #9795
Signed-off-by: Max Goltzsche <max.goltzsche@gmail.com>
2021-06-21 11:46:51 +08:00
Ween Jiann
77e1ca56cf
[go-server] Add go-chi generator to go-server via a router
property ( #9748 )
...
* Add go-chi generator to go-server
* Add go-chi configs
* Add go-chi generated output
* Updated docs
* Add some javadocs
* Fix import issue
* Regen files
2021-06-16 16:53:20 +08:00