I want to convert my date to this YYYY-MM-DDTHH:MM:SS format. So I tired to use below code,
var date = new Date(Date.UTC(2016, 05, 12, 07, 0, 0));
document.write(date.toISOString());
But output of this code is
2016-06-12T07:00:00.000Z
Again I removed after last dot index values, finally I got expected output. Is it possible to covert directly with out removing any values?