digitalepidemiologylab / crowdbreaks

Crowdsourced tracking of health trends
https://www.crowdbreaks.org/
MIT License
12 stars 1 forks source link

Date serialization in SyncS3 #92

Closed utanashati closed 2 years ago

utanashati commented 2 years ago
# models/local_batch_job.rb -> results_to_csv
# models/mturk_batch_job.rb -> results_to_csv
# models/project.rb -> results_to_csv

m.results.last.attributes.values_at(*model_cols).map { |x| x.to_s }
=> ["1058172", "119", "322", "1582276305445261312", "39", "408491", "default", "2022-11-03 05:57:55 UTC"]
m.results.last.attributes.values_at(*model_cols).map { |x| x.as_json }
=> [1058172, 119, 322, 1582276305445261312, 39, 408491, "default", "2022-11-03T05:57:55.403Z"]