Sha256: 903285acc6b073bd91771ffdc78aff1cfc005331b996e5b07e16f70b80da937d
Contents?: true
Size: 663 Bytes
Versions: 19
Compression:
Stored size: 663 Bytes
Contents
module Actions class DeliverLongRunningTasksNotification < EntryAction def plan(report) return if report.task_uuids.empty? plan_self report: report end def run report = OpenStruct.new(input[:report]) tasks = ForemanTasks::Task.where(id: report.task_uuids) report.user = User.current report.tasks = tasks ::UINotifications::Tasks::TasksRunningLong.new(report).deliver! TasksMailer.long_tasks(report).deliver_now end def humanized_name _('Deliver notifications about long running tasks') end def rescue_strategy_for_self ::Dynflow::Action::Rescue::Skip end end end
Version data entries
19 entries across 19 versions & 1 rubygems