Class: CanvasSync::Jobs::SyncAccountsJob
- Inherits:
-
ReportStarter
- Object
- ActiveJob::Base
- CanvasSync::Job
- ReportStarter
- CanvasSync::Jobs::SyncAccountsJob
- Defined in:
- lib/canvas_sync/jobs/sync_accounts_job.rb
Instance Attribute Summary
Attributes inherited from CanvasSync::Job
Instance Method Summary collapse
-
#perform(options) ⇒ Object
Starts a provisioning report for just accounts.
Methods inherited from CanvasSync::Job
#create_job_log, #report_checker_wait_time, #update_or_create_model
Instance Method Details
#perform(options) ⇒ Object
Starts a provisioning report for just accounts.
Provisioning reports do not scope accounts by term, so when we are running provisioning by term we sync users first so we don’t duplicate the work of syncing all accounts for each term.
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 |
# File 'lib/canvas_sync/jobs/sync_accounts_job.rb', line 11 def perform() unless [:root_account] == false acc_params = CanvasSync.get_canvas_sync_client(batch_context).account("self") update_or_create_model(Account, acc_params) end super( "proservices_provisioning_csv", merge_report_params(, { accounts: true, include_deleted: true, }, term_scope: false), CanvasSync::Processors::ProvisioningReportProcessor.to_s, { models: ["accounts"] }, ) end |