2019-11-11 16:06:20 -05:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2020-02-19 13:09:10 -05:00
|
|
|
class GroupExportWorker # rubocop:disable Scalability/IdempotentWorker
|
2019-11-11 16:06:20 -05:00
|
|
|
include ApplicationWorker
|
|
|
|
include ExceptionBacktrace
|
|
|
|
|
2020-01-28 04:09:06 -05:00
|
|
|
feature_category :importers
|
2019-11-11 16:06:20 -05:00
|
|
|
|
|
|
|
def perform(current_user_id, group_id, params = {})
|
|
|
|
current_user = User.find(current_user_id)
|
2020-01-28 04:09:06 -05:00
|
|
|
group = Group.find(group_id)
|
2019-11-11 16:06:20 -05:00
|
|
|
|
|
|
|
::Groups::ImportExport::ExportService.new(group: group, user: current_user, params: params).execute
|
|
|
|
end
|
|
|
|
end
|