Commit Graph

1759 Commits

Author SHA1 Message Date
Jon Jensen 04855677a0 show number of recipients in course/group
also ported activesupport pluralizations to javascript (useful for
i18n en/default fu)

Change-Id: I9c46c29663b7d73f89732cad5b017e176e9920c4
Reviewed-on: https://gerrit.instructure.com/5291
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Jacob Fugal <jacob@instructure.com>
2011-08-29 16:25:07 -06:00
Jon Jensen b2b21a794b account-level question banks, closes #5025
phased out AssessmentQuestion#context, did some ground work for #5026
and #5027

Change-Id: Ice4567a0f069dd49da8ce57bf0c8325b0b062115
Reviewed-on: https://gerrit.instructure.com/5303
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Jacob Fugal <jacob@instructure.com>
Reviewed-by: Brian Whitmer <brian@instructure.com>
2011-08-29 16:24:49 -06:00
Brian Palmer 7fa0ff9663 conversations are teacher interactions, fixes #5437
Change-Id: I03aebdee626ae8300acf0973a97d0ba69f5098f5
Reviewed-on: https://gerrit.instructure.com/5326
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
2011-08-29 14:03:50 -06:00
Jon Jensen 432283d3e7 bump question_data size, limit possible combinations. fixes #4953
Change-Id: Ic716425680c2c50a0c960d391104fc5502d4fafd
Reviewed-on: https://gerrit.instructure.com/5282
Reviewed-by: Jacob Fugal <jacob@instructure.com>
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
2011-08-29 13:37:09 -06:00
Zach Wily 59c15dc864 render the icons on the tinymce editor toolbar better for quiz questions
Change-Id: I9a29c197be0575532dac60b3da94313590eac92a
Reviewed-on: https://gerrit.instructure.com/5297
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Cody Cutrer <cody@instructure.com>
2011-08-29 12:55:18 -06:00
Zach Wily f394576f82 expire the home menu html cache after 15 minutes
This means there may be a delay of up to 15 minutes between when a course
starts and when it shows up in the dropdown for a student. This will be fixed
when we have a central cache and better invalidation.

Change-Id: I377a22609963979ade9fae7e0ced4b7c2c48a368
Reviewed-on: https://gerrit.instructure.com/5315
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Brian Palmer <brianp@instructure.com>
Reviewed-by: Cody Cutrer <cody@instructure.com>
2011-08-29 12:54:32 -06:00
Cody Cutrer a580766f90 add singleton support to DelayedJob
Change-Id: I4ec34f8a025d11c3198ca990bb3586a947f04dcc
Reviewed-on: https://gerrit.instructure.com/5319
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Brian Palmer <brianp@instructure.com>
2011-08-29 12:10:46 -06:00
Brian Palmer ba7be770fa support fractional values in grading schemes, closes #5397
this required changing the data format, so a version column is added to
the table and backwards compatibility code is included. import/export is
aware of this as well.

Change-Id: I753060a6886e3896cbfbad69d16bcc2f1310d466
Reviewed-on: https://gerrit.instructure.com/5296
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
2011-08-29 12:04:28 -06:00
Brian Palmer dfa6a9b6c9 editing grade standard multiple times lost data, fixes #5431
Change-Id: I03c1467cd0f2d977c1d9a0ccfdc412eac02d1bcc
Reviewed-on: https://gerrit.instructure.com/5320
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
2011-08-29 11:05:25 -06:00
Brian Palmer 188ace58f0 don't error out if a stream item's assignment is hard deleted
Change-Id: I1b7976a68b5e2bebf7fe6b5d7db065024e3141ec
Reviewed-on: https://gerrit.instructure.com/5317
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Cody Cutrer <cody@instructure.com>
2011-08-29 11:05:16 -06:00
Brian Palmer 2570dae41a fix letter grade rounding of fractional grades, fixes #4879
Change-Id: I17e89fc8705795541375139e4e3b934abaea136c
Reviewed-on: https://gerrit.instructure.com/5286
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
2011-08-29 11:05:06 -06:00
Jacob Fugal 0e359b5f14 parse in user timezone on discussion topic update
fixes #5398

Change-Id: I139ce3d148ffe841a764c852b7431fd3798fd84a
Reviewed-on: https://gerrit.instructure.com/5312
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Zach Wily <zach@instructure.com>
Reviewed-by: JT Olds <jt@instructure.com>
2011-08-28 20:24:29 -06:00
Cody Cutrer 7ec1eed536 only touch courses once when updating terms and overrides
refs #4996

Change-Id: I9e269753619fe1af5595f552ab57bf55b768247a
Reviewed-on: https://gerrit.instructure.com/5305
Reviewed-by: Zach Wily <zach@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
2011-08-26 22:55:03 -06:00
Zach Wily 8570bdf250 invalidate enrollment date restrictions based on course
Previously we had to touch every enrollment in a term when the dates changed,
which was too much database activity. Now we just do courses, with the
downside being a little more work loading the course to do the enrollment
check (hopefully it's normally loaded anyway).

Change-Id: Idc3500c141b2e09c1940bc30f51880b59e064c83
Reviewed-on: https://gerrit.instructure.com/5304
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: JT Olds <jt@instructure.com>
Reviewed-by: Cody Cutrer <cody@instructure.com>
2011-08-26 22:17:17 -06:00
Brian Palmer 0460765570 set a max-height on conversations body text area, fixes #5313
Without a max-height, elastic.js will just keep growing the textarea
indefinitely, growing it right off the bottom of the screen (and
scrolling is disabled on the page, so you can't scroll around it).

Change-Id: I361bab4b0cab42f70d2fdd26c21136b78838d6f4
Reviewed-on: https://gerrit.instructure.com/5301
Reviewed-by: Jon Jensen <jon@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
2011-08-26 16:55:35 -06:00
Brian Palmer b4d0163f2c fix race condition with unzipped files' tmp files
the tmp file was getting closed before FileInContext does its thing.

Change-Id: Ib2145552e18f9162c0ae87e5626bb5c6a12a3a0b
Reviewed-on: https://gerrit.instructure.com/4772
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Bracken Mosbacker <bracken@instructure.com>
2011-08-26 16:18:01 -06:00
Cody Cutrer 805d605d5c optimize sub_accounts page
Avoid n queries for sub_account counts and course counts; instead do
a single query of each type for all visible accounts (if necessary;
sub_account count might be inferred from loaded sub_accounts)

Change-Id: I46aa607f485eda8e48effefe0c5ae72ee383ac80
Reviewed-on: https://gerrit.instructure.com/5295
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Brian Palmer <brianp@instructure.com>
2011-08-26 16:16:56 -06:00
Brian Palmer 36fa28ed5e typo making html neutral comments editable, fixes #5418
Change-Id: I0da1c491dd8f228b0edbf0494ccc82f2c809609d
Reviewed-on: https://gerrit.instructure.com/5298
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Zach Wily <zach@instructure.com>
2011-08-26 15:51:27 -06:00
Zach Wily ef43714e82 fall back to term dates when an override exists but has nil dates
Change-Id: I4f7e81e4bd8e72bbaf6cc5128575e3841ee2f259
Reviewed-on: https://gerrit.instructure.com/5289
Reviewed-by: Brian Palmer <brianp@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
2011-08-26 11:46:13 -06:00
Ryan Shaw 60b63648df don't show crumbs on dashboard
Change-Id: If63cf2ad12dfce81d8647ed9ac8e39d9f5168e8f
Reviewed-on: https://gerrit.instructure.com/5080
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Brian Whitmer <brian@instructure.com>
2011-08-26 10:15:12 -06:00
Brian Whitmer ec01d52a6e html5 uploads for chrome
Change-Id: Ie4336e2bd31a86176608977b68ec1f610e9abde7
Reviewed-on: https://gerrit.instructure.com/5259
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Ryan Shaw <ryan@instructure.com>
2011-08-26 09:37:45 -06:00
Cody Cutrer 1f8d6ce158 :read_reports should control access to access reports
fixes #5096

Change-Id: I4b08c11dfb385ea4ddd36680a7f239a127edcb55
Reviewed-on: https://gerrit.instructure.com/5275
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Zach Wily <zach@instructure.com>
2011-08-26 08:03:00 -06:00
Cody Cutrer 54d6fe4b2c fix some permissions checks refs #4952
need specific :manage_courses to change course's term or department
rather than generic :manage

Change-Id: I0bc841d4cb1f948abad26a37759957c43f7f564b
Reviewed-on: https://gerrit.instructure.com/5274
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Zach Wily <zach@instructure.com>
2011-08-26 08:02:52 -06:00
Jacob Fugal c6dd22a4c3 show course items aligned to account outcomes
when displaying the aligned items to an outcome at the account level,
include items defined in any courses associated with the account.

also, finish killing off vestigial alignment reordering at the account
level

fixes #5140

Change-Id: I7ce8250d707f8a1283b130801f1d7c0ca7e0fe26
Reviewed-on: https://gerrit.instructure.com/5276
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
2011-08-25 16:43:55 -06:00
Jon Jensen f9c88ae0da case-insensitive lookups when adding users to course, fixes #4980
Change-Id: I676ce5c7e2735a3d240dcd53ec5021140edaf945
Reviewed-on: https://gerrit.instructure.com/5277
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
2011-08-25 15:24:33 -06:00
Jon Jensen 1247d10f30 wimba advanced settings link, closes #5291
Change-Id: I63b00d6ca1dc5bd949e07084cbf11057201917fa
Reviewed-on: https://gerrit.instructure.com/5264
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Jacob Fugal <jacob@instructure.com>
2011-08-25 15:11:52 -06:00
Cody Cutrer 556b5cdc66 allow teachers access according to course OR term dates
refs #4996

Change-Id: Ia20b265eb098195280f1ab07340925c47532f4ac
Reviewed-on: https://gerrit.instructure.com/5269
Reviewed-by: Brian Palmer <brianp@instructure.com>
Reviewed-by: Zach Wily <zach@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
2011-08-25 14:08:03 -06:00
Bracken Mosbacker 15c6635af0 allow importing question bank packages with the same ids
A qti-specific import allowed this before, but now it can
be configured for other migration types

closes #5044

Change-Id: I96e63725ca42937980c73f80f794848848cd59b1
Reviewed-on: https://gerrit.instructure.com/5268
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Brian Palmer <brianp@instructure.com>
2011-08-25 14:00:31 -06:00
Zach Wily cffaa78cd9 add a few useful indexes
These were found missing by watching the log of unindexed queries.

Change-Id: I1823eeb5e5e7dfc4351ced92a5a354aac05d97eb
Reviewed-on: https://gerrit.instructure.com/5261
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Jon Jensen <jon@instructure.com>
Reviewed-by: Brian Palmer <brianp@instructure.com>
2011-08-25 13:58:01 -06:00
Brian Palmer 8fb11bd39c update oauth docs for new web app flow
Change-Id: I3f75a7439b86ed458b001a960204b67d3b70a266
Reviewed-on: https://gerrit.instructure.com/5263
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Mark Suman <marks@instructure.com>
2011-08-25 10:41:35 -06:00
Brian Palmer 158fe8c10d fix respondus qti imports feedback positioning, closes #5302
put it on the individual answer or the question as appropriate, and
don't put the correct answer feedback on both the correct and incorrect
question feedback.

Change-Id: I63671d2c6ee6caa63e0e17b0d37c13ad3725cfef
Reviewed-on: https://gerrit.instructure.com/5251
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Bracken Mosbacker <bracken@instructure.com>
2011-08-24 20:51:58 -06:00
Jon Jensen 032f40765d account-level option to disable eportfolios, closes #5169
also tweaked named_context_url to work better with UserProfile
contexts

Change-Id: If16ef16db507c8713436d0d88a1867f206ecdf48
Reviewed-on: https://gerrit.instructure.com/5225
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Jon Jensen <jon@instructure.com>
2011-08-24 17:38:06 -06:00
Jon Jensen f97772ae0d fix wrong hostname in message emails
root account is now tracked as the ConversationMessage#context

this also fixes a bug where these emails didn't include the footer

Change-Id: If5db3839f65fc68625497a7c8d2ee0f0be682115
Reviewed-on: https://gerrit.instructure.com/5246
Reviewed-by: Zach Wily <zach@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
2011-08-24 15:30:37 -06:00
Brian Palmer 9aad6b193f fix safefiles not setting session permissions properly
The specs didn't catch this because our user_session spec helper stubs
out PseudonymSession, so you'll have the user session available even if
you make a request to a different domain name, so the normal user
permissions were being applied. I've upgraded the specs to make sure
that the user isn't getting logged in on the safefiles
request.

Change-Id: I01b64a87bb51fbf2e947f5c2a1ae5471d1f1e216
Reviewed-on: https://gerrit.instructure.com/5244
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Zach Wily <zach@instructure.com>
2011-08-24 15:17:20 -06:00
Brian Palmer ff5fd14f1d include context info in stream item api, closes #5377
Change-Id: I3e4f716c3676fe2546c7df7501716efddd997075
Reviewed-on: https://gerrit.instructure.com/5227
Reviewed-by: Mark Suman <marks@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Zach Wily <zach@instructure.com>
2011-08-24 15:16:25 -06:00
Brian Palmer 99d4540804 limit maximum per_page in api calls
Change-Id: Ia22e751b9430fd8f019bff7fcd406340c0532c2f
Reviewed-on: https://gerrit.instructure.com/5194
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Zach Wily <zach@instructure.com>
2011-08-24 15:16:16 -06:00
Brian Palmer 68d6b13d7f fix twitter poller x-ratelimit-reset handling
Change-Id: I2b1362c7a00329b6d425d94a3123b7ff065c8ff5
Reviewed-on: https://gerrit.instructure.com/4955
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Zach Wily <zach@instructure.com>
2011-08-24 15:15:41 -06:00
Jon Jensen 8f8e7be519 prevent arbitrary profile viewing
Change-Id: I9db2ed670e4d7089149c07136ae9f12cea5d1502
Reviewed-on: https://gerrit.instructure.com/5249
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Zach Wily <zach@instructure.com>
2011-08-24 15:07:01 -06:00
Zach Wily ef4282b4df fix looking up enrollment status with no course or section; refs #4996
Change-Id: I98b0dfd2ba641e996843a1c2ec9f2872ea91c081
Reviewed-on: https://gerrit.instructure.com/5248
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
2011-08-24 14:30:15 -06:00
Cody Cutrer 167738fd16 really fix creating new terms
refs #4996

Change-Id: I978707ca64ffef39b650ed3d78a267af600427a5
Reviewed-on: https://gerrit.instructure.com/5245
Reviewed-by: Zach Wily <zach@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
2011-08-24 14:10:16 -06:00
Cody Cutrer 540eb74e58 fix saving new terms refs #4996
Change-Id: Icae6cbd57d9f7c724e0f94c33b3c9cf27fc897de
Reviewed-on: https://gerrit.instructure.com/5240
Reviewed-by: Zach Wily <zach@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
2011-08-24 12:38:48 -06:00
Cody Cutrer b6be7f19e7 clear out the wiki when resetting course content refs #4583
need to delete the WikiNamespace and the cached ref to the particular
wiki on the course.

Change-Id: Ia71b34b7a72974ddb2a8c1fb3f02538184f09160
Reviewed-on: https://gerrit.instructure.com/5239
Reviewed-by: Zach Wily <zach@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
2011-08-24 12:37:04 -06:00
Bryan Madsen 01a7fcc2fd added and modified selenium tests to include sales demo user interactions
Change-Id: I6be0694d62ca904358b2de9b2792b4d3ada90018
Reviewed-on: https://gerrit.instructure.com/4932
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Bryan Madsen <bryan@instructure.com>
2011-08-24 11:16:16 -06:00
Cody Cutrer caae827136 alerts, closes #4317
* Daily job to evaluate alerts
   * Spawns a new job for each root account (for parallelization).
     It could be broken down to per-course level if needed (i.e.
     if there is a *huge* root account).
   * Evaluating criteria at a course level using efficient queries.
 * UI for CRUD on alerts
   * Render existing alerts
   * Delete existing alerts
   * Create a new alert
   * CRUD for criteria, recipients, repetition
   * Validations
 * Improve instructure_helper's formErrors to support passing errors
   for specific elements
 * Improve Rails' :include to be able to :exclude an :include
   inherited from a named scope
 * Specs!!
 * Note that we want to slowly roll this out, so there is a setting on
   root accounts to enable it

So I ran an alert with just an interaction criterion on a test
cluster against 50,000 courses, and it took less than 10 minutes
without any parallelization.  That seems like acceptable
performance to me (since there are only just over 3000 courses
in production that would even be elligible to have alerts sent
right now).  Of course, that's probably skewed because I'm sure
a bunch of those 50,000 courses were essentially empty.

Change-Id: Ie028ef206c9155b9a72fb2a820f3e0e516de562a
Reviewed-on: https://gerrit.instructure.com/4799
Reviewed-by: Jon Jensen <jon@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
2011-08-24 10:19:44 -06:00
Brian Palmer dbe0d239e9 add html/image support to quiz question/answer feedback
closes #5284

Change-Id: I51aad86e8b389ab1f3d6b700ebcef968803f0b10
Reviewed-on: https://gerrit.instructure.com/5097
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Bracken Mosbacker <bracken@instructure.com>
2011-08-24 10:09:22 -06:00
Cody Cutrer 9c491b5ee1 speed up accounts' courses tab
don't load all associated courses into memory just for a count

Change-Id: I9d67d8297fcaf8c5289ff1f85cc4613e6c9b50c7
Reviewed-on: https://gerrit.instructure.com/5235
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: JT Olds <jt@instructure.com>
2011-08-24 10:00:31 -06:00
Zach Wily 1a9edb352f make datetime_field() idempotent
There are some places where we might call datetime_field() on a field twice.
That causes the field to double its date when it's submitted. We can also just
be careful when calling datetime_field(), but I'm not sure there's a valid use
case for calling it twice, given how much it jacks up the control.

fixes #3818

Change-Id: I79987486efeb5c77497183a41251a6990747fd52
Reviewed-on: https://gerrit.instructure.com/2291
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Brian Palmer <brianp@instructure.com>
Reviewed-by: Brian Whitmer <brian@instructure.com>
Tested-by: Zach Wily <zach@instructure.com>
2011-08-23 22:29:17 -06:00
Zach Wily 455cb264d6 don't stop processing incoming email on a failure
Change-Id: I9c8aef5a3e71bcedc179eb0172c2c4c8bc80cd85
Reviewed-on: https://gerrit.instructure.com/5230
Reviewed-by: Jon Jensen <jon@instructure.com>
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Hudson <hudson@instructure.com>
2011-08-23 22:11:11 -06:00
Brian Palmer 9562579b6c don't render un-sanitized html during edits, closes #5361
Change-Id: I3b99c418b9feebf1b3cfe1226a682c9fe8864f06
Reviewed-on: https://gerrit.instructure.com/5218
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Zach Wily <zach@instructure.com>
2011-08-23 17:27:56 -06:00
Brian Palmer c8f7529d4e oauth2 web app flow, refs #5029
accepts a redirect_uri to return the code to, in addition to the OOB uri
support. matches the redirect_uri domain host against the one stored on
the developer key.

this doesn't yet include a UI for registering developer keys.

Change-Id: I6fbfe6ff3dbd6ebea9c2f9fc5ce3e45447a1cbc8
Reviewed-on: https://gerrit.instructure.com/4963
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Zach Wily <zach@instructure.com>
2011-08-23 17:27:47 -06:00