You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This thread has been automatically locked because it has not had recent activity. Please open a new issue for related bugs and link to relevant comments in this thread.
lockbot
locked as resolved and limited conversation to collaborators
May 4, 2018
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
发生问题的环境是:
您做了什么?
通过 this.props.form.getFieldsValue()取form中的值,直接序列化为json,提交后台保存。
代码如下:
您期待的结果是:
DatePicker 中的值和序列化后的时间一样。
实际上的结果是:
现在DatePicker中取值是monment对象返回,序列化为json后少了8个小时,是时区的问题吗?
![image](https://cloud.githubusercontent.com/assets/19165238/18653934/1498b88c-7f10-11e6-8e70-80683b6e05ff.png)
建议this.props.form.getFieldsValue()直接DatePicker返回字符串,对象返回后操作起来复杂化了,易用性下降。
可重现的在线演示
The text was updated successfully, but these errors were encountered: