fixed issue 1357, date/datetime serialization in as_dict, thanks Alan