9
10
11
12
13
14
15
16
17
18
19
20
|
# File 'app/jobs/command_tower/messaging/communications/produce_recipient_job.rb', line 9
def perform(user_id, attrs)
attrs = attrs.stringify_keys
CommandTower::Workflows::Messaging::Communications::ProduceRecipientWorkflow.call_from_job(
user_id:,
notification_type_key: attrs.fetch("notification_type_key"),
campaign_identity: attrs.fetch("campaign_identity"),
title: attrs.fetch("title"),
body: attrs.fetch("body"),
platform_enabled_channels: Array(attrs["platform_enabled_channels"]),
metadata: attrs["metadata"],
)
end
|