Sha256: a130a12e826afdb8ff9d2a553356bd4c8a7cba27a802caf4fbeb839e7f7c1d78
Contents?: true
Size: 1.01 KB
Versions: 31
Compression:
Stored size: 1.01 KB
Contents
# frozen_string_literal: true module Decidim module Admin # Custom ApplicationJob scoped to the admin panel. # class ImportParticipatorySpacePrivateUserCsvJob < ApplicationJob queue_as :exports def perform(email, user_name, privatable_to, current_user) return if email.blank? || user_name.blank? params = { name: user_name, email: email.downcase.strip } private_user_form = ParticipatorySpacePrivateUserForm.from_params(params, privatable_to: privatable_to) .with_context( current_user: current_user, current_particiaptory_space: privatable_to ) Decidim::Admin::CreateParticipatorySpacePrivateUser.call(private_user_form, current_user, privatable_to, via_csv: true) end end end end
Version data entries
31 entries across 31 versions & 1 rubygems