add date shifting to copy course page

The new migration UI left one of the course copy workflows
without a dateshift option. This adds the date shifting
to the copy page.

Also removed intro sentence on new migration UI; it wasn't
useful.

Test Plan:
 * go to course settings -> copy this course
   * fill in the date shift options (test day substitutions too)
   * date shifting should happen as set
 * in the new migration UI, do a migration of any type with date subs
   * they should work

closes CNVS-6971

Change-Id: I8d14860ca3118663e9d8e8c2d8c0cb0cf38262e6
Reviewed-on: https://gerrit.instructure.com/22620
Tested-by: Jenkins <jenkins@instructure.com>
QA-Review: Clare Strong <clare@instructure.com>
Reviewed-by: James Williams  <jamesw@instructure.com>
Product-Review: Bracken Mosbacker <bracken@instructure.com>
fix content migration file select for IE

test plan:
* using IE, use the new content migration ui
to select a file and import it

fixes #CNVS-7105

Change-Id: I5a3ecc50f5ba71a0398f2c150cf38be849eef969
Reviewed-on: https://gerrit.instructure.com/22637
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Bracken Mosbacker <bracken@instructure.com>
Product-Review: Bracken Mosbacker <bracken@instructure.com>
QA-Review: August Thornton <august@instructure.com>
disable query cache when iterating over the psql cursor

The query string is the same each time, so AR was returning the cached
results.

fixes CNVS-7117

test plan:
* in script/console on your dev box, run:
    User.connection.cache { User.transaction { User.find_each(batch_size: 1) { |u| puts u } } }
  it should print out each user, rather than getting stuck in an infinite loop

Change-Id: Ib30b085618917dad8bf8d6bcc04687e04ac12340
Reviewed-on: https://gerrit.instructure.com/22645
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
Product-Review: Brian Palmer <brianp@instructure.com>
QA-Review: Brian Palmer <brianp@instructure.com>
return time zone in user profile api

fixes CNVS-6280

refactors User#time_zone and Account#default_time_zone to return actual
time zone objects instead of strings.
Assignments to the fields accept both forms; reading the field prefers
to return a Rails friendly name, but the IANA name is easily accessible
from that object. Continue to use Rails names for the UI, but use
IANA names for the API.

test plan:
 * in the UI, ensure that you can change timezones and it persists
   correctly in the following locations:
   * user profile as the user
   * root account settings
   * user page as an admin
 * check the API responses for /api/v1/users/self/profile and
   /api/v1/accounts/self; the time zone should be listed as an
   IANA name (i.e. America/Denver, not Mountain Time)
 * Update an account (PUT /api/v1/accounts/self) to change the
   default time zone; ensure both friendly names and IANA names
   are accepted on input, but on output the IANA name is returned

Change-Id: Ib976e7e1b2dde2639ff6fd478a59b38fdb0d07c0
Reviewed-on: https://gerrit.instructure.com/22563
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Jacob Fugal <jacob@instructure.com>
QA-Review: Jeremy Putnam <jeremyp@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
remove old compiled css from permissions page

compiled css was added as a fix for bootstrap. Its
no longer needed.

Change-Id: If8eef2f0832f47697ec48df79477d003d8083f10
Reviewed-on: https://gerrit.instructure.com/18975
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Ryan Florence <ryanf@instructure.com>
QA-Review: August Thornton <august@instructure.com>
Product-Review: Bracken Mosbacker <bracken@instructure.com>
allow adding course users by sis id

test plan:
* create a user and login with a sis id
* confirm that the user can be added to a course
through the course 'People' page, by including
their sis id in the list (just as with the login id)

closes #CNVS-7086

Change-Id: Ia4369ba5e78083c233b3921aa1b9246f2db6824e
Reviewed-on: https://gerrit.instructure.com/22647
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Jeremy Stanley <jeremy@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>
QA-Review: Clare Strong <clare@instructure.com>
don't 500 when nothing is passed at all to logins api

test plan:
 * POST /api/v1/accounts/self/logins with no parameters, but
   a valid access token
 * it should not 500

Change-Id: Id543ef443492b4a518aadbdb363c8e177f15aaff
Reviewed-on: https://gerrit.instructure.com/22652
Tested-by: Jenkins <jenkins@instructure.com>
QA-Review: Jeremy Putnam <jeremyp@instructure.com>
Reviewed-by: Brian Palmer <brianp@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
fix course people page with enrollments in deleted sections

(also prevent non-empty sections from being deleted through
sis batch so it doesn't occur again)

test plan:
* create a course
* in the console, enter the following commands
(substiuting [COURSE_ID] with the course's id):

c = Course.find [COURSE_ID]
c.course_sections.first.destroy

* visit the course's people page
* should finish loading

fixes #CNVS-6934

Change-Id: I2b79b4cfaeaf26b91d79cecaa22966794af47b1f
Reviewed-on: https://gerrit.instructure.com/22403
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Cody Cutrer <cody@instructure.com>
QA-Review: August Thornton <august@instructure.com>
Reviewed-by: Bracken Mosbacker <bracken@instructure.com>
Product-Review: Bracken Mosbacker <bracken@instructure.com>
fix user search handling of cross-shard db ids

fixes CNVS-7082

test plan:
* create a user on shard B, and enroll them in a course on shard A
* from shard A, you should be able to search for that user by global id
  both in the course roster and the account admin tools

Change-Id: I34fc52f5d7f392e107d3ae7ea805eaf23f30235c
Reviewed-on: https://gerrit.instructure.com/22616
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Cody Cutrer <cody@instructure.com>
QA-Review: Jeremy Putnam <jeremyp@instructure.com>
Product-Review: Brian Palmer <brianp@instructure.com>
implement view filter on conversations beta

fixes CNVS-6977

test plan:
 - make sure on page load the view filter is set to "Inbox" and
   the inbox view is applied to the conversations list.
 - change view filter drop down to all the options and make sure
   the conversations list is reloaded with the appropriate
   conversations.
 - after changing the view filter, no conversation should be
   currently selected.

Change-Id: I8b6d072cc45c10b1d97972d86ac4b4f900f789e1
Reviewed-on: https://gerrit.instructure.com/22611
Reviewed-by: Zach Pendleton <zachp@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
QA-Review: Cam Theriault <cam@instructure.com>
Product-Review: Jon Willesen <jonw@instructure.com>
don't try to pull an index from /api/v1/groups from GroupCollection

fixes CNVS-7065

test plan
- ensure that when making a new collaboration, groups show up in
 the collaborator picker

Change-Id: I59ae67513ba060530ff5ad71a544824286636171
Reviewed-on: https://gerrit.instructure.com/22638
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Jon Willesen <jonw@instructure.com>
QA-Review: Cam Theriault <cam@instructure.com>
Product-Review: Joel Hough <joel@instructure.com>
load submission needs grading notification

test plan:
  - As a teacher, create a quiz with an essay question and publish the
    quiz. Set your notification preferences for grading to
    "Immediately".
  - As a student, take the quiz.
  - As the teacher, you should get a notification that the submission
    needs reviewing.

fixes CNVS-6524

Change-Id: I185a10175fcc9528100a1157049ecca5ffcccff5
Reviewed-on: https://gerrit.instructure.com/22642
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Derek DeVries <ddevries@instructure.com>
QA-Review: Myller de Araujo <myller@instructure.com>
Product-Review: Stanley Stuart <stanley@instructure.com>
minor fixes for HasContentTags

refs CNVS-6947

 * don't look for them on folders
 * don't do updates if no tags were found

test plan:
 * from the UI, download a zip of a folder
 * check the log for the ContentZipper job that created the zip
 * there shouldn't be a query against content_tags

Change-Id: I51097956a2ee4d77f42f2019c6e563280af8f296
Reviewed-on: https://gerrit.instructure.com/22410
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Jacob Fugal <jacob@instructure.com>
QA-Review: Jeremy Putnam <jeremyp@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
request scribd re-render when no preview available

test plan:
 1. work in an account with scribd enabled
    and google doc previews disabled
    (in console, add "-google_docs_previews" to the
     Accounts's allowed_services)
 2. upload a scribd-previewable file type in the files tab
    (it needs to be a new file that is not already in
     the canvas instance)
 3. make sure it previews properly (it may take a minute
    after uploading for the scribd rendering to complete)
 4. delete the file
 5. undelete the file (/courses/X/undelete)
 6. reload the files tab, and click on the filename on the
    left side.
    - on the right, you should see a message like
      "the preview for this document is unavailable;
       please try again later".
 7. reload the files tab again, then click on the filename.
    - if the scribd rendering has completed, you should see
      a scribd preview.  if you don't, wait a few minutes and
      reload the files page again, to give scribd some time.
 8. test other areas documents can be previewed.  (it's
    permissible to simply delete the scribd_doc in the console
    via attachment.delete_scribd_doc, then try to preview,
    see that a "try again later" message appears, and the
    scribd preview appears in later page views.)
   a. documents embedded in rich text via the wiki sidebar
   b. student submissions, as viewed by the student
      ("submission details" button, "preview" icon)
   c. student submissions, as viewed by the teacher
      in SpeedGrader(TM)

fixes CNVS-7019

Change-Id: I37be820a776637252e14b6a28a1be389b718ff9f
Reviewed-on: https://gerrit.instructure.com/22438
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Bracken Mosbacker <bracken@instructure.com>
QA-Review: August Thornton <august@instructure.com>
Product-Review: Matt Goodwin <mattg@instructure.com>
update item groups in styleguide to use h2 for headers

fixes CNVS-7004

test plan
  - headers in both item groups and condensed style should be h2 elements
    to make them easier to browse through using a screen reader
  - the item group header was changed to the new style in:
    1. styleguide, 2. quizzes, 3. discussions. 4. assignments
  - visual display of the item group headers should be identical as to before.

Change-Id: I6410d183e74f2b8c742562a3cc138361d5f300b6
Reviewed-on: https://gerrit.instructure.com/22498
Tested-by: Jenkins <jenkins@instructure.com>
QA-Review: Myller de Araujo <myller@instructure.com>
Reviewed-by: Ryan Florence <ryanf@instructure.com>
Product-Review: Derek DeVries <ddevries@instructure.com>
Updated zh translation
Updated ar translation
Updated zh translation
Updated ja translation
Updated es translation