Commit Graph

17458 Commits

Author SHA1 Message Date
Jeremy Stanley 4a078f97b0 publish selected provisional grades
test plan:
 - have a moderated assignment and add some users to moderation
   (leave some users out of the moderation set)
 - as two separate TAs, create provisional grades
   for the students in the moderation set
 - also create one provisional grade for each student that
   is not in the moderation set (eventually speedgrader will
   prevent you from creating more than one)
 - as a moderator, select provisional grades on the moderation
   page
 - ensure that the correct provisional grades are published:
   - for students in the moderation set, the grade selected
     by radio button
   - for students not in the moderation set, the one and only
     provisional grade

fixes CNVS-23036

Change-Id: Icf0919d65648e48e31322e09318bff00a1e98949
Reviewed-on: https://gerrit.instructure.com/63313
Tested-by: Jenkins
Reviewed-by: Dan Minkevitch <dan@instructure.com>
Reviewed-by: James Williams  <jamesw@instructure.com>
QA-Review: Jahnavi Yetukuri <jyetukuri@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>
2015-09-18 19:49:53 +00:00
Clay Diffrient 8e76ab59e1 Adds publish button and header for moderated grading
This also slightly modifies permissions checks in
the show_moderate action to make a little more sense
and be less repetitive.

closes CNVS-22746

Test Plan:
  - Activate Moderated Grading feature flag
  - Create an assignment that is moderated
  - Submit a few assignments as students
  - Go to speedgrader on those assignments and give
    an initial grade
  - Go to the assignment page as the teacher and
    click the "Moderate" button
  - Click the "Publish" button
  - A confirmation box should appear
  - Cancelling should do nothing
  - Confirming should then flash a green success flash message
  - The grades should now be published to the gradebook.

Change-Id: I71861476d9bc11aeb143860c76929b8412fd6552
Reviewed-on: https://gerrit.instructure.com/62339
QA-Review: Jahnavi Yetukuri <jyetukuri@instructure.com>
Reviewed-by: Jeremy Stanley <jeremy@instructure.com>
Reviewed-by: Dan Minkevitch <dan@instructure.com>
Tested-by: Jenkins
Product-Review: Clay Diffrient <cdiffrient@instructure.com>
2015-09-18 17:10:18 +00:00
Clay Diffrient 8b95023ffb Add redux-thunk and redux-promise to help with redux development
Change-Id: I096b6a750c5ae265ecbeddb92723abbdab7d8a1d
Reviewed-on: https://gerrit.instructure.com/63457
Tested-by: Jenkins
Reviewed-by: Jon Willesen <jonw@instructure.com>
Product-Review: Clay Diffrient <cdiffrient@instructure.com>
QA-Review: Clay Diffrient <cdiffrient@instructure.com>
2015-09-18 16:51:33 +00:00
Clay Diffrient 6dbe13d4dc Add redux library
This makes redux available via requireJS build in Canvas.

Test Plan:
  - Nothing really to test at this point, just adding a lib.

Change-Id: Iac6110f5e633fd81f07572a38d5fce344c334504
Reviewed-on: https://gerrit.instructure.com/63452
Tested-by: Jenkins
Reviewed-by: Jon Willesen <jonw@instructure.com>
Product-Review: Clay Diffrient <cdiffrient@instructure.com>
QA-Review: Clay Diffrient <cdiffrient@instructure.com>
2015-09-18 16:50:10 +00:00
Nathan Mills f4171754cf add split secret support for lti 2
fixes PLAT-1134

test-plan:
install an LTI 2 tool  using the test tool
the secret should be 256 char long
the enabled capability on the tool proxy should have Oauth.splitSecret

Change-Id: I0641f17b9b52207362dfa7437d440feae2ef8f3e
Reviewed-on: https://gerrit.instructure.com/57292
Tested-by: Jenkins
Reviewed-by: Brad Humphrey <brad@instructure.com>
QA-Review: August Thornton <august@instructure.com>
Product-Review: Nathan Mills <nathanm@instructure.com>
2015-09-18 16:41:04 +00:00
Pam Hiett 083cc04990 Remove reference to ic-brand-secondary in global nav and make secondary
buttons neutral

Fixes: CNVS-23057

Test Plan:
- as a teacher/admin using the new UI
- note no changes to colors in global nav (and subnav overlay)
- note that the default secondary button color is now #333 instead of #34444f

Change-Id: I0474b9b58e18f7a68e18cd577c9debaf8d06ea4e
Reviewed-on: https://gerrit.instructure.com/62808
Tested-by: Jenkins
Reviewed-by: Colleen Palmer <colleen@instructure.com>
Product-Review: Colleen Palmer <colleen@instructure.com>
QA-Review: Myller de Araujo <myller@instructure.com>
2015-09-18 14:34:41 +00:00
Jeremy Stanley 5069966a8f spec: fix better file browsing / move folder spec
Change-Id: I845db749ec5d3266dfc60b640507a302c81df74f
Reviewed-on: https://gerrit.instructure.com/63567
Reviewed-by: Dan Minkevitch <dan@instructure.com>
Tested-by: Jenkins
Product-Review: Jeremy Stanley <jeremy@instructure.com>
QA-Review: Jeremy Stanley <jeremy@instructure.com>
2015-09-18 03:10:18 +00:00
Davis McClellan a6a14926c6 Added warning message to quiz previews
Made it so the "Once you have submitted an answer, you will not
be able to change it later" message appears when trying to preview
a quiz with the ock questions after answering switch ON.

fixes CNVS-22772

test plan:
- On an OQAAT quiz enable Lock Questions after Answering.
- Start the quiz in preview mode as a teacher.
- Observe the "Once you have submitted an answer, you will not
  be able to change it later" message.

Change-Id: I3d4bc55bbfb7d2bec5f31270fe73d128d3b4d939
Reviewed-on: https://gerrit.instructure.com/61992
Tested-by: Jenkins
Reviewed-by: John Corrigan <jcorrigan@instructure.com>
QA-Review: Michael Hargiss <mhargiss@instructure.com>
Product-Review: Jason Sparks <jsparks@instructure.com>
2015-09-18 00:00:24 +00:00
Cody Cutrer 2c2e687e59 qualified names fixes for migrations
refs CNVS-21900

Change-Id: I6b7e323e3c700aee3a7c86cb8f06fce78e5606df
Reviewed-on: https://gerrit.instructure.com/63384
Tested-by: Jenkins
Reviewed-by: Jacob Fugal <jacob@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
2015-09-17 22:03:28 +00:00
Rob Orton dbf007afca don't show deleted groups in admin page
fixes CNVS-23225

test plan
 - see ticket

Change-Id: Ib688992ef51df89b19aacbef0bdd8a4dc0891367
Reviewed-on: https://gerrit.instructure.com/63417
Tested-by: Jenkins
Reviewed-by: Cody Cutrer <cody@instructure.com>
QA-Review: August Thornton <august@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
2015-09-17 22:03:15 +00:00
Simon Williams 5941f7bd58 api: correct course users docs to allow array param
fixes gh-653

test plan:
- generate the api documentation
- look at the "List users in course" section
- it should indicate "enrollment_type[]" which means it can be treated
  like an array of values

Change-Id: Ia1eba7cb7336ccfc56cc3ad31922a6ad3fa1c363
Reviewed-on: https://gerrit.instructure.com/59567
Tested-by: Jenkins
QA-Review: August Thornton <august@instructure.com>
Reviewed-by: Jacob Fugal <jacob@instructure.com>
Product-Review: Simon Williams <simon@instructure.com>
2015-09-17 21:13:28 +00:00
Dylan Ross 55c4224b87 accessibility fixes for grading scheme dialog
closes CNVS-20765

Change-Id: I28f38225f03875ef35e0ba690e0222ffc0fdcb58
Reviewed-on: https://gerrit.instructure.com/63412
Reviewed-by: Derek Bender <djbender@instructure.com>
Tested-by: Jenkins
QA-Review: Amber Taniuchi <amber@instructure.com>
Product-Review: Dylan Ross <dross@instructure.com>
2015-09-17 20:59:24 +00:00
Brian Palmer 31250a9a3a disable caching our custom headers in Rack::Cache
this was causing problems with our logging infrastructure, since hundreds of
requests were getting the same request id. instead, we'll treat this as
basically a static asset request.

fixes CNVS-23023

test plan:

without this commit, a GET /browserconfig.xml will always return the same
X-Request-Context-Id and other headers. with this commit, these headers will be
omitted completely from the generated response.

normally Rack::Cache isn't enabled in development mode, but you can turn it on by setting config.action_controller.perform_caching = true in config/environments/development.rb

Change-Id: I5e1164074d8c6977672364680a76888f561fa588
Reviewed-on: https://gerrit.instructure.com/63454
Tested-by: Jenkins
Reviewed-by: Cody Cutrer <cody@instructure.com>
Reviewed-by: Ryan Shaw <ryan@instructure.com>
QA-Review: August Thornton <august@instructure.com>
Product-Review: Brian Palmer <brianp@instructure.com>
2015-09-17 20:40:01 +00:00
Chris Hart 43f1fc23fa (NUI) Add term to course in course navigation panel
Fixes: CNVS-22427

Test plan:
- Turn on the new UI and clear cache
- Make sure at least one of your courses has a
  specified term (beyond the Default Term) via
  the course settings
- Click on the Courses link in the primary nav
- Any course with a specified term should now
  display the term beneath the link in gray text
  http://screencast.com/t/aw3aH8Dvvaa
- Please also test the Accounts, Groups and
  Account panels in the primary nav, to make sure
  they're working as usual (I made some small CSS
  improvements)

Change-Id: I03b10a18fe52d02a3e6e2a1a1dc74dc257aeec3f
Reviewed-on: https://gerrit.instructure.com/63206
Reviewed-by: Jennifer Stern <jstern@instructure.com>
Product-Review: Jennifer Stern <jstern@instructure.com>
Tested-by: Jenkins
QA-Review: August Thornton <august@instructure.com>
2015-09-17 19:56:34 +00:00
Josh Orr dd185220bf Add group favorites
Adds group context to user's favorites.  Adds favorite_for_user? method to groups.
Adds get "users/self/favorites/groups"
     post "users/self/favorites/groups/:id"
     delete "users/self/favorites/groups/:id"
     delete "users/self/favorites/groups"
endpoints to favorites api.

Corrected get "users/self/favorites/groups" to return all user's groups if no groups are favorited.

Adds ?include[]=favorites option to groups api.

Fixes PLAT-1213

test-plan:
Using PostMan or other API test tool:
List group favorites using either the Group or favorite endpoint, verify that the test user has no group favorites
Add 4 groups and make the test user a member of 3 of them
Use the favorites endpoint to add 3 of the test group as  favorites.
List group favorites using the endpoint not used above.  Verify that 3 of the groups are favorites and one is not.
Use the favorites api to remove one of the groups from favorites
List group favorites and ensure that the 2 correct groups are marked as favorites
Use the favorites api to clear all group favorites
List group favorites to ensure that there are no group favorites

Change-Id: Id7b92126f9c2a34b3a301640e925aa26c494c26a
Reviewed-on: https://gerrit.instructure.com/62301
Reviewed-by: Brad Horrocks <bhorrocks@instructure.com>
Tested-by: Jenkins
QA-Review: August Thornton <august@instructure.com>
Product-Review: Matthew Rice <mrice@instructure.com>
2015-09-17 19:22:54 +00:00
Cody Cutrer 2e5d300041 some optimizations for DiscussionTopics#index
avoid an unnecssary join, and an unnecessary round-trip through ruby

test plan:
  * load discussions page for a course

Change-Id: I22f7cecb9a83e2112bddb9ed0f1e4fa0e17f83b1
Reviewed-on: https://gerrit.instructure.com/63419
Tested-by: Jenkins
QA-Review: August Thornton <august@instructure.com>
Reviewed-by: Ethan Vizitei <evizitei@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
2015-09-17 16:15:56 +00:00
Amber Taniuchi 863a1e45c3 spec: add spec to verify new canvadoc annotation settings
Test Plan:
- pass Jenkins
- check for syntax errors
- make sure new test_ids match up to an existing test case in TestRails

Change-Id: Ia23848d653f68812e8de3bf1c2242597e5a427e1
Reviewed-on: https://gerrit.instructure.com/63114
Tested-by: Jenkins
Reviewed-by: Caleb Guanzon <cguanzon@instructure.com>
Product-Review: Caleb Guanzon <cguanzon@instructure.com>
QA-Review: Caleb Guanzon <cguanzon@instructure.com>
2015-09-17 14:43:38 +00:00
Jeremy Stanley 6e7fd49619 spec: fix gradeable_students spec failure
caused by unfortunate timing wrt merging of
I7dde803439efac7287b225bd2d60c468f90cdec0
and
Ib79f8f04bd455575c4ae2e99c37763094f062982

Change-Id: I756afb11a0cd20790556769f604df7ce7bac0ef8
Reviewed-on: https://gerrit.instructure.com/63456
Reviewed-by: Dan Minkevitch <dan@instructure.com>
Product-Review: James Williams  <jamesw@instructure.com>
QA-Review: James Williams  <jamesw@instructure.com>
Tested-by: James Williams  <jamesw@instructure.com>
2015-09-17 14:42:04 +00:00
James Williams bcc34adb97 spec: fix account_admin_developer_keys_spec
Change-Id: I1046221a9230dc54f745bf288cc76b697d51b2b0
Reviewed-on: https://gerrit.instructure.com/63483
Tested-by: Jenkins
Reviewed-by: Jeremy Stanley <jeremy@instructure.com>
Product-Review: James Williams  <jamesw@instructure.com>
QA-Review: James Williams  <jamesw@instructure.com>
2015-09-17 14:39:25 +00:00
Jennifer Stern cb77097f4c Fix theme editor preview and flash notices
fixes CNVS-23167

Note: https://gerrit.instructure.com/#/c/61285 caused a bug where
navigating anywhere other than the main theme editor page during
preview results in a blank page
(ArgumentError Exception: wrong number of arguments (1 for 2).

Meanwhile, https://gerrit.instructure.com/#/c/61890/ made it so
that the offending code was never run, but also prevented the flash
notices from appearing in preview mode. This fixes both of these issues.

When navigating to any page (other than the theme editor page) while in theme
preview mode, you should see the following flash notice and the
'Theme Editor' link should take you to the theme editor view for the
current account:

* Within the theme editor: http://cl.ly/image/072l0M3z3R3g
* Outside the theme editor: http://cl.ly/image/1X281e2i3O2W

The theme editor page should display this notice in preview mode:
http://cl.ly/image/3Y3p0b0i091h

Change-Id: I124d722c2b4257c80cf08b20700147799c304f8e
Reviewed-on: https://gerrit.instructure.com/62982
Reviewed-by: Mike Nomitch <mnomitch@instructure.com>
Reviewed-by: Ryan Shaw <ryan@instructure.com>
Tested-by: Jenkins
Product-Review: Colleen Palmer <colleen@instructure.com>
QA-Review: Myller de Araujo <myller@instructure.com>
2015-09-17 14:37:08 +00:00
Steven Burnett d22d70b323 fixes screenreader not reading points possible
fixes CNVS-22898

Test Plan:
-Create and publish several assignments in the future
-On the dashboard navigate to these assignments under
 the todo on the right
-Notice the screenreader reads them
-repeat with nvda and jaws

Change-Id: Ide73124cbad495e32e612fa6bc1791438f136e68
Reviewed-on: https://gerrit.instructure.com/63184
Tested-by: Jenkins
Reviewed-by: Jonathan Featherstone <jfeatherstone@instructure.com>
QA-Review: Adam Stone <astone@instructure.com>
Product-Review: Steven Burnett <sburnett@instructure.com>
2015-09-17 14:07:08 +00:00
Chris Hart dd0d7e7eaa (NUI) Remove watermark image from login screens
Fixes: CNVS-23172

Bug example: http://screencast.com/t/c281LmQ1he

Test plan:
- Enable the new UI clear your cache
- Go to Theme Editor and make sure you have a
  watermark image uploaded, from inside the
  Watermarks & Other Images tab
- Log out. You should no longer see the watermark
  on the login screen.

Change-Id: I75c9ca5667a3f2abd9b9baf964f988544e2fec53
Reviewed-on: https://gerrit.instructure.com/63423
Reviewed-by: Jennifer Stern <jstern@instructure.com>
Product-Review: Jennifer Stern <jstern@instructure.com>
Tested-by: Jenkins
QA-Review: Myller de Araujo <myller@instructure.com>
2015-09-17 13:46:22 +00:00
Pam Hiett 1e07838b18 address $ic-brand-secondary used on pages previous and next buttons
for revisions

Fixes: CNVS-23250

Test Plan:
- as an admin using old or new ui,,, navigate to a course
- click the pages link from the left-hand navigation
- click an existing page or create a new one (this is where it gets
  fun... you will need to edit this page multiple times - enough to
  get the "previous and/or next" buttons to show at the bottom of
  the revisions right-hand sidebar)
- the "previous and next" options should now be using #333

Change-Id: I1b652c0d01a4ef03c0530338ef271a5128e002b4
Reviewed-on: https://gerrit.instructure.com/63399
Tested-by: Jenkins
Reviewed-by: Jennifer Stern <jstern@instructure.com>
Product-Review: Jennifer Stern <jstern@instructure.com>
QA-Review: Myller de Araujo <myller@instructure.com>
2015-09-17 13:22:28 +00:00
Transifreq f2cbb3e76e Updated zh_Hant translation
Change-Id: I428000ea8f98fb0c3ad3d88272f8566dfc43d979
2015-09-17 05:26:36 -06:00
Transifreq 9ab70066fd Updated zh translation
Change-Id: Ia5d76a2f5e5c45356d730215f830883b573ee09c
2015-09-17 05:25:27 -06:00
Transifreq d861ceca74 Updated fa-IR translation
Change-Id: Ibe8649aabccde44178d2e2abe51bbb3017decaaa
2015-09-17 05:13:20 -06:00
Dan Minkevitch f33b11be65 Users with manage_admin_users permissions fix
fixes CNVS-22978

Test Plan:
* Create a role based on Teacher and enable all permissions except "Add/remove students for the course"
* Create another role based on Teacher and enable all permissions
* From within a course add two users, one with the role whose permission to add/remove students enabled and the other with the permission to add/remove students disabled.
* Masquerade as the Instructor with the add/remove student permission disabled and select the gear icon for the other instructor in the course.
* Observe the option to "remove from course" is available

Change-Id: Ic0cf06c78e24d8d737ff4ec90a614c23390b7e8d
Reviewed-on: https://gerrit.instructure.com/63373
Tested-by: Jenkins
Reviewed-by: Jeremy Stanley <jeremy@instructure.com>
QA-Review: Clare Strong <clare@instructure.com>
Product-Review: Dan Minkevitch <dan@instructure.com>
2015-09-16 23:15:42 +00:00
Jeremy Stanley 44df31d2a9 make unique page titles in API documentation
test plan: render API docs and ensure pages include
the subject in the title (i.e., click on "Admins" and the
browser tab should show "Admins - Canvas API ..."
instead of just "Canvas API ...")

fixes CNVS-22171

Change-Id: Ideccae141869cb3c37c91fc986eb402866897138
Reviewed-on: https://gerrit.instructure.com/62904
Tested-by: Jenkins
Reviewed-by: James Williams  <jamesw@instructure.com>
QA-Review: Jahnavi Yetukuri <jyetukuri@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>
2015-09-16 22:01:03 +00:00
Pam Hiett 38277e84c0 within jquery dialog replace reference to ic-brand-secondary to
ic-color-dark

Fixes: CNVS-23195

Test Plan:
- as an admin using the new or old ui
- navigate to a course - then click into modules from there click
  the + module button to launch the modal
- inspect the large gray background which is .ui-widget-overlay
- the background should be a lightened version of #333 (which will
  read as rgba(51, 51, 51, 0.75)

Change-Id: I5c40a4b4c0f34db60e97b629752b27a80bfa9cde
Reviewed-on: https://gerrit.instructure.com/63202
Reviewed-by: Chris Hart <chart@instructure.com>
Product-Review: Chris Hart <chart@instructure.com>
Tested-by: Jenkins
QA-Review: Myller de Araujo <myller@instructure.com>
2015-09-16 21:57:16 +00:00
Zach Wily 9eba534ba3 fix ordering when adding a discussion reply; scroll to new threaded reply
For some reason, we were placing discussion replies at the top of the
reply list when adding a reply to a non-threaded discussion. For
example, imagine the following flat discussion:

 Topic
   1st reply
     1st subreply
     2nd subreply
     + "Add Reply"

If you want to add a subreply to "1st reply", you start typing in the
"Add Reply" field at the bottom of the list. Then when you submit,
here's where it shows up:

 Topic
   1st reply
     3rd subreply <--- new reply you just made
     1st subreply
     2nd subreply

Uhh... Then when you reload, it will show up at the bottom, like this:

 Topic
   1st reply
     1st subreply
     2nd subreply
     3rd subreply <--- your new reply

This does not happen on threaded discussions - with those, your reply is
added to the bottom of the reply list like it should.

This doesn't make any sense for 2 reasons:

 1) When you reload, the entry shows at the bottom of the list. So it's
    being put where it won't show up in the real view. This is super
    confusing for users replying to discussions.

 2) With non-threaded discussions you reply at the bottom of the
    reply chain. This would put your reply at the top of the reply
    so you often wouldn't even see it at all! This results in lots
    of people responding multiple times, thinking their reply is
    not working.

I traced down the history of this code. In 2013, it looks like the logic
was inverted - it used to do this behavior on threaded discussions only.
This actually makes slightly more sense, in that it negates point #2
above - when responding to a post, you hit "Reply" directly below the
post (no matter how many replies there are), and then it would put your
reply there right where you can see it. The ordering was still wrong -
your reply would be put at the bottom on a reload. However, at least it
didn't look like your reply disappeared.

The behavior we have now is the worst of both worlds - replies don't
show up where you made them, and you don't see them when you make them.
This change makes it so at least the reply goes where it should go. It
also adds a "scroll into view" when adding replies to threaded
discussions. Since you compose those at the TOP of the children list,
and your reply (correctly) goes to the BOTTOM of the children list,
oftentimes you don't see it. Now we scroll your newly added comment into
view.

test plan:
 * Make a non-threaded discussion.
 * Add a reply to it
 * Add a reply to that reply
 * Keep adding replies to the first reply, and see how they correctly
   show up at the bottom of the list.

 * Make a threaded discussion.
 * Add a reply to it
 * Add a bunch of replies (longer than the page) to the reply from above
 * Verify that when adding new replies, the window scrolls to the newly
   added reply.

Change-Id: I5c0da85962352b5453b09526413b3c68f0a86695
Reviewed-on: https://gerrit.instructure.com/63435
Reviewed-by: John Corrigan <jcorrigan@instructure.com>
Reviewed-by: Ethan Vizitei <evizitei@instructure.com>
QA-Review: Michael Hargiss <mhargiss@instructure.com>
Tested-by: Jenkins
Product-Review: Zach Wily <zach@instructure.com>
2015-09-16 21:39:27 +00:00
Cody Cutrer aba0de7b96 rename some locales
fixes CNVS-19910
fixes CNVS-23061

 * zh_Hant => zh-Hant (dash according to IETF standard)
 * zh => zh-Hans (it's really simplified Chinese)
 * fa-IR => fa (so that it will apply for _any_ Persian locale,
   not just Iran)

also handle fallbacks for deprecated languages

test plan:
 * _before_ applying this commit, change your language to one of
   the locales being renamed
 * apply the commit, but don't run the migration
 * ensure that your Canvas is still translated, both normal and
   JS translations
 * run the migration
 * you should still be translated, and in your user settings it shows
   the correct language translation

Change-Id: If02793fce1db57856895899804f1389076093d0a
Reviewed-on: https://gerrit.instructure.com/57111
Reviewed-by: Jon Jensen <jon@instructure.com>
Tested-by: Jenkins
QA-Review: August Thornton <august@instructure.com>
Product-Review: Dan Minkevitch <dan@instructure.com>
2015-09-16 21:36:58 +00:00
Zach Wily 65fa886acb make selenium docker-compose service commented out by default
Building the Selenium image, and running the selenium container, is
pretty resource heavy. Therefore, we'll require you to uncomment it
when you want to use it. Hopefully Docker Compose will provide a more
elegant way to do this in the future.

Change-Id: I1ea2ccbd4dd384cc5dcdb973c09caf9d36367015
Reviewed-on: https://gerrit.instructure.com/63380
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Jenkins
Product-Review: Zach Wily <zach@instructure.com>
QA-Review: Zach Wily <zach@instructure.com>
2015-09-16 21:23:03 +00:00
Spencer Olson 187b395052 dont include unpublished assignments in badge count
the badge count that shows next to 'Grades' will no longer include
counts for submissions that are attached to unpublished
assignments. this is a fix to correct badge counts for existing
unpublished assignments with submissions in production. since
assignments can no longer be unpublished if they have submissions,
this should not be an issue going forward.

closes CNVS-22921

1. create an assignment as a teacher
2. sign in as a student and submit a submission for the assignment
3. grade the assignment as a teacher
4. sign back in as a student and notice there is a blue badge
  showing '1' next to 'Grades'. DON'T click on 'Grades'.
4. unpublish the assignment (you'll need to do this via the
  rails console):
  $ bundle exec rails console
  $ assignment = Assignment.find(1) #use the actual assignment id
  $ assignment.update_attribute(:workflow_state, 'unpublished')
  $ assignment.updated_at = 10.days.ago
  (you need to do that ^ or else you'd need to wait a half hour)
  $ assignment.save
5. sign back in as the student and verify the blue badge showing
  the '1' is no longer there.

Change-Id: I7daae6782df27b9fb315e516a9e596a58d6150a1
Reviewed-on: https://gerrit.instructure.com/62425
Tested-by: Jenkins
Reviewed-by: Keith T. Garner <kgarner@instructure.com>
QA-Review: Jason Carter <jcarter@instructure.com>
Product-Review: Spencer Olson <solson@instructure.com>
2015-09-16 20:56:20 +00:00
Clay Diffrient b5714744fd Converts FilesApp to JSX
refs CNVS-22335

Test Plan:
  - Files should load up without problems and work

Change-Id: I0838451d6674de1d366bf24967c874e42a837c93
Reviewed-on: https://gerrit.instructure.com/61763
Reviewed-by: Dan Minkevitch <dan@instructure.com>
Tested-by: Jenkins
QA-Review: Jahnavi Yetukuri <jyetukuri@instructure.com>
Product-Review: Clay Diffrient <cdiffrient@instructure.com>
2015-09-16 20:47:04 +00:00
Chris Hart 09518ce1f4 Add brandable logo to dashboard right sidebar
Fixes: CNVS-22703

This commit adds the ability to add a logo to the
top of the right sidebar on the dashboard screen
only (per Blake and the UI team).

This feature is only available in the New UI via
the Theme Editor.

Test plan:

- Fully recompile Canvas assets and clear your
  browser cache
- Turn on the new UI feature flag
- Go to the Theme Editor
- Under the Watermarks & Other Images dropdown,
  you should see a new Right Sidebar Logo option
- Add a logo (there is no default image - the default
  Canvas theme doesn't show this logo; it's for
  customers who want more branding)
- Click Preview Changes
- Click on the Dashboard link on the primary nav
- You should now see your logo in the right
  sidebar, above the content
- Note the recommendation in the Theme Editor that
  the ideal image dimensions are 360 x 140 pixels.
  The styles will handle images of any size, to
  ensure they don't break the layout. However,
  images that are taller than they are wide will
  not look great.

Change-Id: Ie68fd7fdb86ab7f0bdd620f33ce8ffa966df7ecf
Reviewed-on: https://gerrit.instructure.com/62952
Reviewed-by: Jennifer Stern <jstern@instructure.com>
Product-Review: Jennifer Stern <jstern@instructure.com>
Tested-by: Jenkins
QA-Review: Jeremy Putnam <jeremyp@instructure.com>
2015-09-16 19:41:20 +00:00
Cameron Matheson 1358bbca5b submit powerpoint files to turnitin
closes CNVS-21734

Test plan:
  * enable turnitin for an assignment
  * submit a powerpoint file (ppt and/or pptx)
  * get a turnitin score

Change-Id: I29e56094a507600a8d14a449dc6d9d7b5cbfeb6d
Reviewed-on: https://gerrit.instructure.com/62655
Tested-by: Jenkins
Reviewed-by: Josh Simpson <jsimpson@instructure.com>
QA-Review: Jason Carter <jcarter@instructure.com>
Product-Review: Cameron Matheson <cameron@instructure.com>
2015-09-16 19:12:33 +00:00
James Williams ae670bc460 add final provisional grade marks
moderators should eventually be able to see and
edit the same provisional grade mark

closes #CNVS-23200

Change-Id: I7dde803439efac7287b225bd2d60c468f90cdec0
Reviewed-on: https://gerrit.instructure.com/63230
Tested-by: Jenkins
Reviewed-by: Jeremy Stanley <jeremy@instructure.com>
Product-Review: James Williams  <jamesw@instructure.com>
QA-Review: James Williams  <jamesw@instructure.com>
2015-09-16 19:03:13 +00:00
Dan Minkevitch bdf8d64fb8 Fix undefined error for search results files preview
fixes CNVS-22731

Test Plan:
* Go to any course's Files page
* Search for an existing file
* You should be able to click the file's name and
  view a preview of the file
* You should be able to navigate throughout the files after
  previewing the file

Change-Id: I62b2cef64a82fb5c15e0eeac369d66db287fac74
Reviewed-on: https://gerrit.instructure.com/63368
Tested-by: Jenkins
Reviewed-by: Clay Diffrient <cdiffrient@instructure.com>
QA-Review: Jahnavi Yetukuri <jyetukuri@instructure.com>
Product-Review: Dan Minkevitch <dan@instructure.com>
2015-09-16 18:58:38 +00:00
Alex Boyd 2957135958 Hide recurring calendar events feature flag
Fixes CNVS-23267

Test plan:
 - As an account admin who is not also a site admin, view the
   account's feature flags and make sure that recurring calendar
   events does not show up in the list
 - As a site admin, view the feature flags again and make sure
   that recurring calendar events shows up this time

Change-Id: I881632535e7d295b388c14d84d82246c4d8a38fa
Reviewed-on: https://gerrit.instructure.com/63398
Reviewed-by: Steven Burnett <sburnett@instructure.com>
Tested-by: Jenkins
QA-Review: Adrian Russell <arussell@instructure.com>
Product-Review: Matthew Wheeler <mwheeler@instructure.com>
2015-09-16 18:48:11 +00:00
Brad Horrocks 1aff77fe8b allow deactivating developer keys
Fixes PLAT-1232

test plan:
* go to developer keys UI
* you should be to deactive and reactivate keys
* deactivate a key that you have a token for
* the token should no longer work, even though it's not expired

Change-Id: I7388226c710ab0841692902886a49146a037e615
Reviewed-on: https://gerrit.instructure.com/50008
Tested-by: Jenkins
Reviewed-by: Nathan Mills <nathanm@instructure.com>
QA-Review: August Thornton <august@instructure.com>
Product-Review: Brad Horrocks <bhorrocks@instructure.com>
2015-09-16 18:31:33 +00:00
Heath Hales 2f4f788fa7 Shared examples setup with test case 68936 as template for more profile pics tests
Change-Id: I0cf96a8086c8fe1bb275cfa629aed2c52f7dc247
Reviewed-on: https://gerrit.instructure.com/63327
Reviewed-by: Caleb Guanzon <cguanzon@instructure.com>
Tested-by: Jenkins
Product-Review: Caleb Guanzon <cguanzon@instructure.com>
QA-Review: Caleb Guanzon <cguanzon@instructure.com>
2015-09-16 16:55:57 +00:00
Jeremy Stanley c4fc2b6922 list-gradeable-students endpoint
test plan:
 - look at Submissions API docs for "List gradeable students"
   endpoint
 - confirm it returns the list of students who can submit the
   assignment
 - add the (currently) undocumented include[]=provisional_grades
   parameter and ensure:
   0. the call fails if the caller doesn't have moderate_grades
      permission
   1. in_moderation_set is returned for each student
      (currently false)
   2. selected_provisional_grade_id is returned for each student
      (currently nil)
   3. a list of provisional grades is returned for each student

fixes CNVS-23027
fixes CNVS-23133
fixes CNVS-23148

Change-Id: Ib79f8f04bd455575c4ae2e99c37763094f062982
Reviewed-on: https://gerrit.instructure.com/63092
Tested-by: Jenkins
Reviewed-by: Cameron Matheson <cameron@instructure.com>
QA-Review: Jahnavi Yetukuri <jyetukuri@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>
2015-09-16 16:55:14 +00:00
James Williams 88b5e8e101 improve outcome results controller performance for large numbers
avoids large queries when the course has a lot of outcomes

test plan:
* regression test outcome results api

closes #CNVS-12716

Change-Id: I9752ebcc605f52eaee81d934308a7b0850032abe
Reviewed-on: https://gerrit.instructure.com/62260
Tested-by: Jenkins
Reviewed-by: Jeremy Stanley <jeremy@instructure.com>
QA-Review: Deepeeca Soundarrajan <dsoundarrajan@instructure.com>
Product-Review: James Williams  <jamesw@instructure.com>
2015-09-16 16:28:21 +00:00
Andrew Huff df632b6020 ensure turnitin assignment names are unique
fixes CNVS-22602

This modifies assignment titles by appending their canvas id to the
title on the assignment model that we send to turnitin. This ensures
that turnitin will always see a unique title, which should fix the bug
that has caused a few recent support weeks. (see JIRA ticket for
details)

Also, cleans up some specs as per betterspecs.org

Also, fixes some specs that didn't work as intended

Test plan:
  * As the teacher, create a turnitin assignment
  * As the student, submit a submission to this assignment. (make sure
    it's fairly lengthy or turnitin will silently fail to process it)
  * As the teacher, wait for turnitin to process the submission
  * View the submission in turnitin
  * Verify that the assignment title in turnitin's interface has the
    assignment's ID between the assignment's name and the assignment's
    due date (for example, it might be called "My Assignment - 123 - DUE
    AUG 21 2015".)

Change-Id: If9dde5846499c3fa9692eb903894343be7cec584
Reviewed-on: https://gerrit.instructure.com/61524
Tested-by: Jenkins
Reviewed-by: Keith T. Garner <kgarner@instructure.com>
QA-Review: Jason Carter <jcarter@instructure.com>
Product-Review: Josh Simpson <jsimpson@instructure.com>
2015-09-16 16:03:59 +00:00
Derek Bender fcac48c8d1 add selection table for moderated grading
closes: CNVS-22001

test plan:
1. run migrations
2. the table moderated_grading_selection should exist with the following columns:
  - assignment_id
  - student_id
  - selected_provisional_grade_id
3. in rails console, the class (model) ModeratedGrading::Selection should exist.

Change-Id: I137ad648e044d00cc9ba426d327f6cc91982e2b8
Reviewed-on: https://gerrit.instructure.com/63027
Tested-by: Jenkins
QA-Review: Clare Strong <clare@instructure.com>
Reviewed-by: James Williams  <jamesw@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>
2015-09-16 15:52:28 +00:00
August Thornton d5cd841aba account admin developer keys spec
moved account_admin_auth_config_spec to a more logical
directory and removed some unused cruft from accounts_spec

Change-Id: Iff823df200731a037c2c52d0da1e12e5e3030c62
Reviewed-on: https://gerrit.instructure.com/63194
Reviewed-by: Derek Hansen <dhansen@instructure.com>
Tested-by: Jenkins
Product-Review: August Thornton <august@instructure.com>
QA-Review: August Thornton <august@instructure.com>
2015-09-16 15:52:24 +00:00
Sterling Cobb 7361855bb4 add list of students to moderated grade page
refs CNVS-22742

Test Plan
Given you have an assignment with moderated grading enabled
And you are moderating it
You should see a list of students that have submitted an assignment
And the first mark should show up in the list if a mark has been given
If no first mark has been given filler text "Speed Grader" should appear
Change-Id: I12fc1985ac72e485c0724f673913ba00b29ef8c5
Reviewed-on: https://gerrit.instructure.com/61933
Tested-by: Jenkins
Reviewed-by: Clay Diffrient <cdiffrient@instructure.com>
QA-Review: Jahnavi Yetukuri <jyetukuri@instructure.com>
Product-Review: Clay Diffrient <cdiffrient@instructure.com>
2015-09-16 15:16:13 +00:00
Jeremy Stanley c2dbe29362 fix broken images after migration with '?' in folder name
test plan:
 1. create a folder with a question mark in its name
 2. put an image in that folder
 3. embed that image in a wiki page
 4. copy the course
 5. verify that the image isn't broken in the destination course

fixes CNVS-22543

Change-Id: Ifaeb06b60b6312e939964ec50703c0f3eeab3285
Reviewed-on: https://gerrit.instructure.com/62667
Reviewed-by: James Williams  <jamesw@instructure.com>
Tested-by: Jenkins
QA-Review: Jahnavi Yetukuri <jyetukuri@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>
2015-09-16 14:53:38 +00:00
Pam Hiett bcb805cc88 remove reference to $ic-brand-secondary from the styleguide
Fixes: CNVS-23109

Test Plan:
- navigate to /styleguide
- click into style from the top nav
- click colors
- you should no longer see a reference to $ic-brand-secondary
  after $ic-brand-primary
- inspect the header class - Sg-header (it should now be #333
  vs the #34444f that was ic-brand-secondary)

Change-Id: I31b2f1459ebd7b4b26f5feffae28f056add4424c
Reviewed-on: https://gerrit.instructure.com/63188
Tested-by: Jenkins
Reviewed-by: Jennifer Stern <jstern@instructure.com>
Product-Review: Jennifer Stern <jstern@instructure.com>
QA-Review: Myller de Araujo <myller@instructure.com>
2015-09-16 14:49:07 +00:00
Pam Hiett 13f3101b8b switch ic-toggle and super-toggle from ic-brand-secondary to canvas
neutral gray (#333)

Fixes: CNVS-23075

Test Plan:
- as a student or admin using the new ui
- navigate to the dashboard where you can view the dashcards
- the toggle toswitch between grid/dashcard view and list view
  should now be rendered using the canvas dark gray (#333) vs
  the brand-secondary blue gray (#34444F)

Change-Id: I30902b9088732819430041056d7289e3a2ebaada
Reviewed-on: https://gerrit.instructure.com/62843
Reviewed-by: Jennifer Stern <jstern@instructure.com>
Product-Review: Jennifer Stern <jstern@instructure.com>
Tested-by: Jenkins
QA-Review: Myller de Araujo <myller@instructure.com>
2015-09-16 14:49:00 +00:00