Changing datetime format for history