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

MVC的Param中是否可以增加对自定义时间格式的解析呢? #1267

elkan1788 opened this Issue May 25, 2017 · 0 comments


None yet
2 participants

elkan1788 commented May 25, 2017

问题的起源: MVC的Param中遇到自定义时间格式问题


// Thu May 25 2017 07:16:32 GMT+0800 (CST)

String tmp = "Thu May 25 2017 07:16:32 GMT+0800 (CST)";
// 增加个地区就可以正常解析
SimpleDateFormat format = new SimpleDateFormat("EEE MMM dd yyyy hh:mm:ss 'GMT'Z (z)", Locale.ENGLISH);

目前的解决方案是直接用String类型,然后实际使用中再进行转换,不知这个需求是否要以扩展一下呢, 谢谢。

@wendal wendal closed this in 2684091 May 25, 2017

@wendal wendal added this to the 1.r.62 milestone May 25, 2017

@wendal wendal added the Mvc label May 25, 2017

@wendal wendal self-assigned this May 25, 2017

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