Figure 1 shows the value of the variable printed before $http is sent; Figure 2 shows the value captured when $http is sent.
Can I prevent it from automatically converting to UTC and keep 2016-12-15?
欢迎选择我的课程,让我们一起见证您的进步~~
Thanks for the invitation.
Your data itself is a time object, but if you want to post, its data format is forced to be converted to the related type of string.
It is recommended that you format the data into a corresponding string before posting.
You can use the date built-in filter in angular
app.controller('myCtrl', function($scope, $filter) { console.log($filter('date')(new Date(), 'yyyy-MM-dd')) });
Thanks for the invitation.
Your data itself is a time object, but if you want to post, its data format is forced to be converted to the related type of string.
It is recommended that you format the data into a corresponding string before posting.
You can use the date built-in filter in angular