Commit Graph

8 Commits

Author SHA1 Message Date
Michael Nomitch 8a59a3769d change symbol array syntax for ruby 1.9
Change-Id: I5ca2eb4e8d12aa91413cd4214f3fb91e60c72265
Reviewed-on: https://gerrit.instructure.com/49765
Reviewed-by: Benjamin Porter <bporter@instructure.com>
Tested-by: Jenkins
Product-Review: Mike Nomitch <mnomitch@instructure.com>
QA-Review: Mike Nomitch <mnomitch@instructure.com>
2015-03-03 20:47:03 +00:00
Michael Nomitch dd4c2006b8 bucketing assignment index api
fixes CNVS-17809

test plan:
  - make a request to the assignments index api
    with the param bucket=
    - "ungraded"
    - "upcoming"
    - "future"
    - "past"
    - "overdue"
  - as a student, the assignments in each bucket
    accurately reflect assignment overrides for
    this student
  - as a teacher, default assignment due dates
    are applied
  - as an observer watching a single student, buckets
    reflect that student's submissions
  - as a full course observer, due dates reflect which
    section they are in

Change-Id: I69ed0fe063173324a2e848f4b3b49ea42d843744
Reviewed-on: https://gerrit.instructure.com/47437
Tested-by: Jenkins
Reviewed-by: Simon Williams <simon@instructure.com>
QA-Review: Adam Stone <astone@instructure.com>
Product-Review: Hilary Scharton <hilary@instructure.com>
2015-03-02 20:04:53 +00:00
Ethan Vizitei 173ab80f3a needs_grading by section for mobile
fixes CNVS-14375

Previously grading counts were only available
aggregated as a count for the assignment. This
lets you consume them split out by section
rather than.

needs_grading_count_by_section is the flag
to send.  This also splits out the needs_grading
query off into it's own object to reduce the
cognitive load of working in the assignment model.

TEST PLAN:
 - setup a course with multiple sections and
    assignments that need grading for students in
    each
 - hit the assignments API index with the
    "needs_grading_count_by_section" parameter set
    to true
 - the JSON response should include a
     "needs_grading_count_by_section" key for
     each assignment and it should have a hash
     of section ids and counts

Change-Id: I290a080b5f657996423798cacfb37660f5ed427c
Reviewed-on: https://gerrit.instructure.com/39627
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Mike Nomitch <mnomitch@instructure.com>
Reviewed-by: Cameron Matheson <cameron@instructure.com>
Product-Review: Hilary Scharton <hilary@instructure.com>
QA-Review: Amber Taniuchi <amber@instructure.com>
2014-09-08 13:21:31 +00:00
Joel Hough 5dfe5bc96f make "Upcoming Assignments" lists vdd aware
fixes CNVS-1220

test plan
when checking for an assignment listed as upcoming, check:
- the "Coming Up" sidebar on the right of the user's or course's
  "Recent Activity" page
- the "Upcoming Assignments" sidebar on the right of the user's
  or course's Assignments page
- the "Upcoming Assignments" section on the main listing on the
  user's or course's Assignments page

ensure assignments can be overridden to be upcoming
- create an assignment that is due more than one week from now
- as a student, ensure the assignment is not listed as upcoming
- create an override that applies to the student that makes the
  assignment's due date less than one week from now
- As a student, ensure that the assignment is listed as upcoming

ensure assignments can be overridden to not be upcoming
- create an assignment that is due less than one week from now
- as a student, ensure the assignment is listed as upcoming
- create an override that applies to the student that makes the
  assignment's due date more than one week from now
- As a student, ensure that the assignment is not listed as upcoming

Change-Id: Ia517d87f0a8ed48f6ce3ca466258e7ad8ebe650c
Reviewed-on: https://gerrit.instructure.com/17168
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Stanley Stuart <stanley@instructure.com>
QA-Review: Marc LeGendre <marc@instructure.com>
2013-02-06 13:21:58 -07:00
Dave Donahue 6ab15d087b bug: if override due date is before default due date on an assignment, it is not applied
fixes #CNVS-2309

Problem:
Overriding a due date to be earlier than the default was having no
effect because the default date was getting lumped in with the overrides
and treated the same way when deciding which to use.

Solution:
If there are applicable overrides, don't take the default into account.

Notes:
The issue was happening as a result of the way the VariedDueDate class
indiscriminately lumped due dates together and returned the last one.
Part of the solution was removing the VariedDueDate class and instead
relying on the override methods on an Assignment. This was done not
only to fix the bug at hand but also to move toward a more consistent
interface for handling varied due dates.

Change-Id: If9d24725a19b134d5d92d3a5c08d6794f466fa9c
Reviewed-on: https://gerrit.instructure.com/16406
QA-Review: Myller de Araujo <myller@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Simon Williams <simon@instructure.com>
2013-01-09 09:37:00 -07:00
Stanley Stuart aa64f1c91b add presenters folder
Added a presenters folder so that complex view logic that doesn't fit
within the scope of a helper can have its own place in the project tree.

Change-Id: Ibd4caa969b94b33b10f0a5afd1f2dd7163bc8bf7
Reviewed-on: https://gerrit.instructure.com/15347
Reviewed-by: Stanley Stuart <stanley+gerrit@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
2012-11-29 16:08:47 -07:00
Stanley Stuart 53431cda5a fix submitted assignments randomly showing as overdue
fixes #11953

This fixes a typo in sorts_assignments which got the wrong key out of
the passed hash in SortsAssignments.by_varied_due_date.

The spec has been updated as well to take a list of submissions. It
now also checks that #by_varied_due_date will raise an error if any
fields it requires are missing.

test plan:
  create an assignment with an overdue due date ( due_at < Time.now )
  create an assignment with a non-overdue due date ( due_at > Time.now )
  as a student in the course, visit the Course Asssignment page
  make sure that the overdue assignment appears under "Overdue
  Assignments"
  make sure that the non-overdue assignment is not in the "Overdue
  Assignments" section on the page.

Change-Id: I74bc99521e4675b5f4f92bfdfa7c175daa99b3aa
Reviewed-on: https://gerrit.instructure.com/15586
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Simon Williams <simon@instructure.com>
2012-11-26 16:27:21 -07:00
Stanley Stuart 1a2779eb12 add varied due date functionality to the main assignments page
test plan:
  REFERENCE:
    * "Main Assignments Page": "localhost:3000/assignments", or click on
    "Assignments" in the menu bar near the top of the page.
    * "Right Side Bar": Go to the Main Assignments Page, it's on your
    right.
    * "Course Assignments Page": Hover over "Courses" in the menu bar
    * near the top of the page, click on the course you set up. Once
    that page loads, click on "Assignments" tab on the left hand side.
  STEPS:
    * https://gist.github.com/f12b3694016f3dcc979e

Change-Id: I9a5884ec1057f196ba5b731a2978c874141bec5b
Reviewed-on: https://gerrit.instructure.com/15006
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Amber Taniuchi <amber@instructure.com>
Reviewed-by: Simon Williams <simon@instructure.com>
2012-11-09 23:21:44 -07:00