Skip to content

Instantly share code, notes, and snippets.

@acwio
Created July 22, 2015 18:16
Show Gist options
  • Save acwio/3cab0b67021b81436872 to your computer and use it in GitHub Desktop.
Save acwio/3cab0b67021b81436872 to your computer and use it in GitHub Desktop.
Classification model.
var Classification = Backbone.Model.extend({
url:"https://panoptes-staging.zooniverse.org/api/classifications",
// Specify default values for the model.
defaults: function(){
return {
'completed': false,
'annotations': [{
'task': 'transcription',
'value': {}
}],
'metadata': {
'workflow_version': '1',
'started_at': (new Date).toISOString(),
'user_agent': navigator.userAgent,
'user_language': 'en',
'utc_offset': ((new Date).getTimezoneOffset() * 60).toString()
},
'links': {
'user': '-1',
'project': '-1',
'workflow': '-1',
'subjects': []
}
}
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment