Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DateTimeOffset as string in Model #123

Open
farfush opened this issue Oct 4, 2017 · 2 comments
Open

DateTimeOffset as string in Model #123

farfush opened this issue Oct 4, 2017 · 2 comments

Comments

@farfush
Copy link

farfush commented Oct 4, 2017

Hi All,

Once again, thanks for the great library. Have question. What do you think about adding CLR DateTimeOffset type as string-date-time to swagger primitives mapping?

{ typeof(DateTime), new Primitive("string", "date-time") },

For swagger, this type should be treated the same as regular DateTime.

Thoughts? If you accept such a change - I will love to send a PR.

Cheers

@jnallard
Copy link
Collaborator

jnallard commented Oct 4, 2017

I don't see anything wrong with it.

(You could also add a SwaggerTypeMapping from DateTimeOffset to DateTime in the meantime)

@yahehe
Copy link
Owner

yahehe commented Oct 4, 2017

Sounds good to me!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants