Sha256: 3c39e33f8f1cb009163dba778ff895fa70ddf1566c038adc5b088130c752f03a

Contents?: true

Size: 845 Bytes

Versions: 23

Compression:

Stored size: 845 Bytes

Contents

module CanvasSync
  module Jobs
    class SyncSubmissionsJob < ReportStarter
      # Syncs Submissions
      #
      # Starts a report processor for the submission report
      # (the proserv_student_submissions_csv report must be enabled)
      #
      # @param job_chain [Hash]
      # @param options [Hash]
      def perform(job_chain, _options)
        report_params = if job_chain[:global_options][:canvas_term_id].present?
                          { "parameters[enrollment_term_id]" => job_chain[:global_options][:canvas_term_id] }
                        else
                          {}
                        end

        super(
          job_chain,
          "proserv_student_submissions_csv",
          report_params,
          CanvasSync::Processors::SubmissionsProcessor.to_s,
          {},
        )
      end
    end
  end
end

Version data entries

23 entries across 23 versions & 1 rubygems

Version Path
canvas_sync-0.9.0 lib/canvas_sync/jobs/sync_submissions_job.rb
canvas_sync-0.8.4 lib/canvas_sync/jobs/sync_submissions_job.rb
canvas_sync-0.8.3 lib/canvas_sync/jobs/sync_submissions_job.rb
canvas_sync-0.8.2 lib/canvas_sync/jobs/sync_submissions_job.rb
canvas_sync-0.8.1 lib/canvas_sync/jobs/sync_submissions_job.rb
canvas_sync-0.8.0 lib/canvas_sync/jobs/sync_submissions_job.rb
canvas_sync-0.7.3 lib/canvas_sync/jobs/sync_submissions_job.rb
canvas_sync-0.7.2 lib/canvas_sync/jobs/sync_submissions_job.rb
canvas_sync-0.7.1 lib/canvas_sync/jobs/sync_submissions_job.rb
canvas_sync-0.7.0 lib/canvas_sync/jobs/sync_submissions_job.rb
canvas_sync-0.6.4 lib/canvas_sync/jobs/sync_submissions_job.rb
canvas_sync-0.6.3 lib/canvas_sync/jobs/sync_submissions_job.rb
canvas_sync-0.6.2 lib/canvas_sync/jobs/sync_submissions_job.rb
canvas_sync-0.6.1 lib/canvas_sync/jobs/sync_submissions_job.rb
canvas_sync-0.6.0 lib/canvas_sync/jobs/sync_submissions_job.rb
canvas_sync-0.5.4 lib/canvas_sync/jobs/sync_submissions_job.rb
canvas_sync-0.5.3 lib/canvas_sync/jobs/sync_submissions_job.rb
canvas_sync-0.5.2 lib/canvas_sync/jobs/sync_submissions_job.rb
canvas_sync-0.5.1 lib/canvas_sync/jobs/sync_submissions_job.rb
canvas_sync-0.4.1 lib/canvas_sync/jobs/sync_submissions_job.rb