Add datetime handling

Without the DjangoJSONEncoder you can't include datetime objects in the generated output.