This isn't currently used and won't be used in this way even once we
start using it.
Change-Id: Iba86bd4da6e7a7b08d5a73066f74994dbc667e51
Reviewed-on: https://gerrit.instructure.com/12596
Reviewed-by: Jon Jensen <jon@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
fix issue where flash notice is pinned to the left while it slides down
and then jumps to the middle. there seems to be a difference in how
browsers treat auto margins wrt widths and nested relative elements. we
just make sure everything that might need it gets an auto margin
test plan:
1. do something that generates a flash notice or error (e.g. send a
message in conversations)
2. it should slide down from the top middle
3. this should work in all supported browsers (ie/ff/chrome/etc)
Change-Id: I6835b932bf057ec6083899a94fefb680b6836419
Reviewed-on: https://gerrit.instructure.com/12585
Reviewed-by: Ryan Shaw <ryan@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
since we have already "validated" the email (by virtue of them receiving
it and clicking on a link), we don't need to validate it here. fixes an
issue where users with non-email pseudonyms could not get past this page
also tweak form so that pseudonym can be specified if it needs to be set
(for example, the email was already taken by another user)
test plan:
1. as an admin create a new user with a login other than their email
address
2. check the user's /messages URL to see the email that was sent to the
user
3. copy and paste the URL that was sent in the email and navigate to it
4. the registration page should allow you to proceed and the label should
say "Login"
Change-Id: I563b53b16b950bd7f6dafc456349db74fd97b294
Reviewed-on: https://gerrit.instructure.com/12569
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Zach Pendleton <zachp@instructure.com>
fixes#9642
test plan:
1. go to the default account
2. click sub accounts on left side nav
3. add a new sub account under the default
4. go into the sub account
5. click settings on the left side nav
6. click "External Tools" tab
7. notice new wording on page
Change-Id: Iea1fa43340c910dcbfede4eab7e1ba8c42ff553c
Reviewed-on: https://gerrit.instructure.com/12517
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Bracken Mosbacker <bracken@instructure.com>
Testing notes:
* using IE, visit the /profile/notifications page and verify that the
table caption does not display.
Change-Id: I6c9c5cac38380f07eae00ff12487d4173c1d0a51
Reviewed-on: https://gerrit.instructure.com/12561
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Ryan Shaw <ryan@instructure.com>
test plan:
0. Start with a user with no birthdate stored
1. go to the profile page
- click Edit
- leave the birthdate fields alone
- click Update
- profile should save
2. click Edit again
- choose some, but not all birth date fields
(i.e., leave year, month, and/or day blank, but not all three)
- press Update
- you should get prompt(s) telling you to fill in the missing
birthdate field(s)
3. fill in the missing field(s)
- press Update
- profile should save
4. click Edit again
- verify that you cannot blank out any of the three
birthdate fields
Change-Id: I4eab732b9bd03b85b468100a8e803996f3cf0eb2
Reviewed-on: https://gerrit.instructure.com/12486
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Jon Jensen <jon@instructure.com>
Test plan:
* save your profile page with a row of blank links
* the blank row should not get saved
Change-Id: I81372e653295298a6cee4e418a02da2fb616ac31
Reviewed-on: https://gerrit.instructure.com/12573
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Jon Jensen <jon@instructure.com>
fixes#9674
with more than one level of sub-account branding, the branding
was being included in the wrong order for certain pages.
test plan:
- make sure global includes and sub-account includes are enabled
on the root account
- make a sub account (S1) and enable sub-account includes
- make a sub account of that sub account (SS1)
- add custom branding on both sub accounts, where the branding on
SS1 is meant to override the branding on S1
- the css should override in the right order
Change-Id: I7579a885e057ce06843bb0b73f2f297391466afa
Reviewed-on: https://gerrit.instructure.com/12567
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Cody Cutrer <cody@instructure.com>
fixes#7332
when user is editing a grade in gradebook2 and clicks outside of
slickgrid, the editing interface isn't closed and slickgrid doesn't
post the new grade to canvas.
this commit adds a faux blur event to slickgrid to capture and
send these changes.
test plan:
* open gradebook2;
* click a cell and enter a grade;
* click in empty space on the page and verify that the editing
interface closes;
* reload the page and verify that the new grade has been saved.
Change-Id: Ie97dee1159e2808cb177bd45129ecb025a1693cc
Reviewed-on: https://gerrit.instructure.com/12461
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Mark Ericksen <marke@instructure.com>
test plan:
* open gradebook2 in a course with 50+ students (more
than will fit in one slickgrid view);
* click gradebook2 menu, select "hide student names;"
* verify that student names and email addresses are
hidden;
* open menu and select "show student names;"
* verify that names and email addresses are again visible;
Change-Id: I68e0abc35ca6cec53020dce71d862c802617bb40
Reviewed-on: https://gerrit.instructure.com/12472
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Ryan Florence <ryanf@instructure.com>
refs #9321
This is fixed in Rails 3.x but the code has completely changed so this
isn't a backport so much as a re-implementation.
test plan: fire up script/server, make an api request with access_token
in the query string, and verify the token isn't logged anywhere (except
in the AR query if you're debug logging, that's still a TODO)
Change-Id: Ibeb97b5caa35b842fe5ad82127439c6b14f73e75
Reviewed-on: https://gerrit.instructure.com/12033
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Simon Williams <simon@instructure.com>
no user visible behavior change
test plan:
* make sure existing wiki contents haven't disappeared
* make sure a new course gets a wiki that functions correctly
* make sure wiki rss feeds are still functional
* try to access the wiki from a new course from multiple requests
simultaneously; it should get a single wiki that's not conflated
Change-Id: I339b56c39d7868dbdec3df4007291a429272b1cf
Reviewed-on: https://gerrit.instructure.com/12432
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Brian Palmer <brianp@instructure.com>
when a collection becomes private, it can no longer be followed and so all
existing followers are removed. if it is then set back to public, these
followers are NOT restored.
test plan:
- set a public collection with followers to private
- the collection should no longer have any followers
Change-Id: Ia57937a1fdfaab9d01137f33b2a59f332a124cfb
Reviewed-on: https://gerrit.instructure.com/12490
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Brian Palmer <brianp@instructure.com>
submissions_api_controller wasn't sending all the
submissions that were updated so the JS didn't
know what to update besides the user being graded
test plan:
1. create a group assignment where students are
not graded individually
2. go to gradebook2 and give a student a grade
3. observe that when the xhr is finished all the
students in the group get their grade updated
4. make sure this doesn't happen for non-group
assignments
Change-Id: Icac1b211c23ea4dee8d381876d511f19cf57239d
Reviewed-on: https://gerrit.instructure.com/12581
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Jon Jensen <jon@instructure.com>
test plan:
* migration should apply on mysql
Change-Id: I1710a054d6d13cd3ba357ef74ae8e3e4823399e0
Reviewed-on: https://gerrit.instructure.com/12560
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
test plan:
* create files and folders with only a parent folder id (no context)
Change-Id: I76420c4481e1ddd4a201f281a5b8dd83feb09dd2
Reviewed-on: https://gerrit.instructure.com/12554
Reviewed-by: Bracken Mosbacker <bracken@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
So that MySQL can add the indexes
Change-Id: I32ad7185cdf5cfb7f59d76e734add95fcf545237
Reviewed-on: https://gerrit.instructure.com/12559
Reviewed-by: Cody Cutrer <cody@instructure.com>
Reviewed-by: Jon Jensen <jon@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
when saving notification preferences, show a spinny icon rather than
(potentially) stacking flash notices
test plan:
1. go to the new notifications page
2. change a preference
3. note the spinner in the top right
Change-Id: I155f3a7c9383c2cac51b2c277ddf529311343ea0
Reviewed-on: https://gerrit.instructure.com/12531
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Zach Wily <zach@instructure.com>
fixes#9509
test plan: on a test cluster, visit the course analytics page and click
on the course link to take you back to the course home page. verify you
aren't redirected to a production domain (and forced to re-login if
you're not logged into production)
Change-Id: I7ea45ed40782e4cd83d50a4a06d08572c8b8aeb0
Reviewed-on: https://gerrit.instructure.com/12418
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Zach Pendleton <zachp@instructure.com>
users have a new profile page that displays a
custom bio, links, and contact methods as well as
how the viewing user knows them.
this profile can be a part of any page and is
displayed on the user in a course pages as well.
profiles are found at /about/:user_id
Change-Id: I3339144135d67415af9068d18776b691320c1938
Reviewed-on: https://gerrit.instructure.com/12298
Reviewed-by: Jon Jensen <jon@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
refs #7768
updating the deferred logic to not use vars that could be overwritten
Change-Id: Id9c28d2ef175cf3722d281935008e319f4abd4f0
Reviewed-on: https://gerrit.instructure.com/12520
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Jon Jensen <jon@instructure.com>
fixes page error when using html_notice-style notifications. currently the
only place we do this is when you click around in a course without having
accepted the invitation
test plan:
1. as a teacher create a couple of modules with content as module items
2. as a student who has not yet accepted the course invitation, move
through the modules using the next and previous arrows or by clicking
links
3. you should not get page errors
Change-Id: Iacabc9c433ec999776e22f4d623350f074bd825c
Reviewed-on: https://gerrit.instructure.com/12536
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Zach Pendleton <zachp@instructure.com>
allow courses to be updated through the api.
test plan:
* as an account admin, make a put to
/api/v1/accounts/:account_id/courses/:id
and verify that the course is updated;
* as a teacher with course update permissions, attempt
to update a course's sis id and verify that it is
not updated (should just be ignored);
* as a non-authorized user (e.g. a student), attempt to
update a course and verify that 401 is returned.
Change-Id: I903081abac74db3ae2d941e105423dce2d5c4f8a
Reviewed-on: https://gerrit.instructure.com/12438
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
fixes#7405
when a student submits a media submission for an assignment, this
commit adds an icon to it in gradebook2 so that it is easy to see
which students have submissions for the assignment.
test plan:
* create an assignment that accepts media submissions and create
a submission;
* view the submission in gradebook2 and verify that an icon appears.
Change-Id: I79a4ff7bbeaf5547a8e5dd35743534492941bdf5
Reviewed-on: https://gerrit.instructure.com/12515
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Ryan Shaw <ryan@instructure.com>
Test Plan:
* Import a moodle package
* It should work
Change-Id: I850d4a6cc80229ab30ad372e49986a001ef3e068
Reviewed-on: https://gerrit.instructure.com/12519
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Simon Williams <simon@instructure.com>
fix login box in IE (now a dark gradient). ensure page background is
textured (light gray, not white)
test plan:
1. go to the login page in any browser
2. the page background should be a light gray texture
3. go to the login page in IE
4. the login box should have a dark gray gradient
Change-Id: I957e2ccbd717976207404107e655d4ef7a430644
Reviewed-on: https://gerrit.instructure.com/12489
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Ryan Florence <ryanf@instructure.com>
test plan:
* configure parallel sis imports
* start a massive import
* kill the job
* in script/console, reset the batch's workflow_state to 'created',
and call process on it
* when it completes, the counts should be accurate, and not
doubly include what was processed the first time before it was
killed
Change-Id: Ib49a5b56fa9db88908ab386aa869614972ae66eb
Reviewed-on: https://gerrit.instructure.com/12420
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Brian Palmer <brianp@instructure.com>
fixes#7882
when a user submitted a quiz as a result of the due date for the
quiz being reached, gradebook2 was improperly showing the quiz
submission as late.
test plan:
* create a quiz with a due date and time;
* as a student, take the quiz and wait to submit the quiz until
the "Time's Up!" dialog box is displayed;
* as a teacher, view gradebook2 and verify that the quiz submission
is not displayed as late.
Change-Id: I00e830ba27265cf602c6cadaf6f754ea28c6fd48
Reviewed-on: https://gerrit.instructure.com/12454
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Ryan Florence <ryanf@instructure.com>
autocomplete can now be set up by adding "autocomplete" to
data-behaviors and passing a JSON object of configuration to
data-autocomplete-options.
test plan:
* visit /accounts/:id;
* type at least four letters into the "Find a Course" text
box and verify that it works as expected;
* run js specs with rake js:test.
Change-Id: I66a1492d639fe2aa0fa6aa767baf7a4a2607fec8
Reviewed-on: https://gerrit.instructure.com/12388
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Ryan Florence <ryanf@instructure.com>
The student needs submitting query was omitting needs_grading_count which is
returned in the assignment json if the user is a teacher in the course.
fixes#9621
test plan: enroll as both a teacher and student in the same course.
create an assignment due in the next couple days, with online turn in.
hit the /api/v1/users/self/todo endpoint, and verify that you get back
that assignment as a needs submitting todo, without any error.
Change-Id: Ic049dab07be5ab8863d22e1f2df98cd6873ea594
Reviewed-on: https://gerrit.instructure.com/12505
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Simon Williams <simon@instructure.com>
when masquerading, the only visual cue was the presence of the [Stop
Masquerading] link in the identity bar in the header. this change moves that
link to a button in a fixed footer bar that is always present at the bottom of
the window and also contains a warning message as a reminder that you are
masquerading. Additionally, if avatars are enabled, the avatar of the user
being masqueraded as will be shown.
test plan:
- masquerade as someone
- you should get a fixed bottom bar
- the top right bar should say "As: other_person" and the other person's name
should be highlighted
- the stop bottom should work
Change-Id: Ifb92b8a7d4b4dcada30ae505d99f9f01c59293ed
Reviewed-on: https://gerrit.instructure.com/12260
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Jon Jensen <jon@instructure.com>
* don't list accounts to search that the admin doesn't actually have
permission to search
* don't show user information for an arbitrary id if the admin
doesn't have permissions to that user
test plan:
* create an admin in a non-default account, and merge him with a
normal user in another account
* log in as that admin, and go to /users/<admin id>/admin_merge
* it should only list the account the user is actually an admin in
to merge, NOT the account he's only a normal user in
* enter the id of another user in the account the admin is a normal
user in
* it should just re-show the same page, NOT show the details of
the other user
Change-Id: I97577846479ae461c45045d49e122f79394ccecf
Reviewed-on: https://gerrit.instructure.com/12419
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Brian Palmer <brianp@instructure.com>
This fixes two cases that were missed before. Sometimes the
webct relative resource id starts with a '/' and sometimes
not, this accounts for that.
Also, finding a file by a relative path was trying to find it
by the URI escaped version instead of the unescaped one. And
sometimes webct data has differently-cased file paths in the
QTI, so this tries finding files in all lower case.
Test Plan:
* Import a webct course that has files in quizzes
* All the images should import correctly into canvas. (meaning the url should be like /courses/:id/files/:id/preview)
closes#9520
Change-Id: I110c7f1968ae5a050fbd6b4e21332e8168481a15
Reviewed-on: https://gerrit.instructure.com/12474
Reviewed-by: Simon Williams <simon@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
fixes#9601
Test plan:
* fill out the 'Add Course Users' section in course settings.
* try to add existing users and new users.
* make sure everything looks OK.
Change-Id: I688d3a583fda663c737e78dfa33973e1b3a7497d
Reviewed-on: https://gerrit.instructure.com/12471
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Zach Pendleton <zachp@instructure.com>
Adds 'title' and 'bio' information to the profile api endpoint. Also
optionally includes user_service and user_profile_link information.
Also includes a new update_profile API endpoint for updating profile
information (short_name, bio, title) , user_profile_links, and
user_service visibility.
The update_profile endpoint should replace the ProfileController#update
action as soon as we move that (when the User settings page is re-done).
Test plan:
* make API calls to update/query the profile information OR
wait for the new profile page which will exercise the new
{user_profile,user_service,user_profile_link}_json methods
Change-Id: Ia4d902bf190ca51085216b71c5c9215d0dbf2f98
Reviewed-on: https://gerrit.instructure.com/12323
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Zach Pendleton <zachp@instructure.com>
ensure error (or success) flash notice contents do not overflow
test plan:
1. trigger an action that causes an alert with a lot of text (or in the
js console do something like $.flashError('long message here...') )
2. ensure that the text doesn't overflow the box
Change-Id: I6e241086b7ce860ff5ce5eb6f66a808327c73078
Reviewed-on: https://gerrit.instructure.com/12483
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Zach Pendleton <zachp@instructure.com>
fixes#9610
test plan: since this is a race condition manual testing is difficult,
when uploading a lot of large sis batches none should fail to process
because of a nil attachment (and stickiness/batch mode settings should
always apply).
Change-Id: Iee9d1f48d8f9ab147409361ac19ccbca9df4fe97
Reviewed-on: https://gerrit.instructure.com/12478
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
test plan:
* visit calendar2 page;
* drag an undated event to a day on the calendar;
* verify that it correctly displays on the day.
Change-Id: I463a157c343b3615cc816fc7e285a448aa44435b
Reviewed-on: https://gerrit.instructure.com/12422
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Cameron Matheson <cameron@instructure.com>
the index condition and the query condition didn't quite line up,
forcing it to do table scans
test plan:
* notifications should work
* delayed job query that finds files to notify for should not
do a full table scan
Change-Id: I86930ef6b4ec450bdd325bb96651fc0f88967836
Reviewed-on: https://gerrit.instructure.com/12451
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Cody Cutrer <cody@instructure.com>
fixes#9559
The quiz statistics page was attaching the submitter's name to essay
question responses for graded quizzes.
Test plan:
* make a graded survey quiz with an essay question
* submit the quiz as a user
* go to the the quiz statistics page as the teacher
* clicking on the student's essay answer should not reveal their
username
Change-Id: I6f08ce3132479fb86495165f8eff4cecd3cc6ab9
Reviewed-on: https://gerrit.instructure.com/12462
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Simon Williams <simon@instructure.com>
test plan:
1. go to the sis imports page
2. do an import that generates an error (e.g. don't select a file for
upload)
3. confirm that the error box has the ui-state-error styles and the text
is legible (white on red)
Change-Id: I76e4a450cec9d463e2b890cde9251e7edccad048
Reviewed-on: https://gerrit.instructure.com/12447
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Cody Cutrer <cody@instructure.com>
Implementing the re-designed Notification Preferences page.
Testing plan:
=========
* Verify that expected preferences can be set.
* Verify that it supports accessibility (screen readers) for blind users
* Verify that mobile users (iPad at least) can smoothly interact.
Change-Id: I2b98f2477932d800d2ec3de580e47a95f827616b
Reviewed-on: https://gerrit.instructure.com/12356
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Jon Jensen <jon@instructure.com>
A bug in the spec (b was never saved) was hiding another case where an
root_attachment_id loop could be created.
fixes#9252
test plan: Set up a course A with at least one file. Clone course A to
make course B. Then copy course B back into course A. Also try copying a
course into itself. None of these actions should cause loading
/courses/A/files or /courses/B/files to break. You can also check the db
directly to verify that root_attachment_id doesn't equal id for any of
the rows.
Change-Id: I114bc888067bf0308cc9c8a6a926438734f1e06f
Reviewed-on: https://gerrit.instructure.com/12450
Reviewed-by: Bracken Mosbacker <bracken@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
test plan:
1. go to the dashboard
2. you should see checkbox/calendar/etc. icons next to any "To Do" or
"Coming Up" items
Change-Id: Id6ecc40ffb108a741a54f6cba24c12ec2c4fc27c
Reviewed-on: https://gerrit.instructure.com/12445
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Ryan Shaw <ryan@instructure.com>
This plugin allows canvas to import course backups from
moodle 1.9. The backup file is first converted to a
canvas-flavored common cartridge file then imported
Test Plan:
* Import some moodle backup files
* The should look awesome
Change-Id: Ibc9478bbd9bbf91ac2a6c9fa1c2ce1ce6a3cdda7
Reviewed-on: https://gerrit.instructure.com/12411
Reviewed-by: Simon Williams <simon@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>