Skip to content
This repository has been archived by the owner on Jan 7, 2020. It is now read-only.

Track progress of Assignment #242

Merged
merged 2 commits into from
Aug 24, 2016
Merged

Track progress of Assignment #242

merged 2 commits into from
Aug 24, 2016

Conversation

shaunanoordin
Copy link
Member

Features

  • When a logged-in user has an active Assignment, the number of classifications she/he has made, and the number required by the Assignment (if any), are displayed.
  • When a logged-in user with an active Assignment makes a Classification, the Assignment store is updated to account for the progress.
  • If there is no active Assignment (i.e. default workflow) there will be no progress counter.

Features TODO:

  • Currently, I am unable to figure out what's the number for "my classifications" for each Assignment when I start the app. (i.e. I don't know how to ask the EduAPI how many Classifications I've already done. )
    • This is due to some confusion with the JSON data, and needs discussion.
    • For the moment, I've made the number for "my classifications" to default to an obviously incorrect 999999 at app start.
    • You can still see the numbers increase correctly as you make Classifications, though.

Features to Discuss:

For reference, the code to change would be in app/stores/assignments-store.coffee, function onIncrementClassificationProgress(), e.g.:

onIncrementClassificationProgress: () ->
  newState = _.assign {}, @data
  if newState.activeAssignment
    newState.activeAssignment.myClassificationCount++

    targetCount = parseInt(newState.activeAssignment.classificationTarget)
    if !isNaN(targetCount) && targetCount <= newState.activeAssignment.myClassificationCount
      alert('Good job! You've finished your assignment, maybe do something else now?')

Supercedes #241, fixes #240

@simoneduca , let's talk about this tomorrow.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Assignment dropdown is massive on Firefox
1 participant