Class: Decidim::Conferences::Admin::PublishConference
- Inherits:
-
Admin::ParticipatorySpace::Publish
- Object
- Admin::ParticipatorySpace::Publish
- Decidim::Conferences::Admin::PublishConference
- Defined in:
- app/commands/decidim/conferences/admin/publish_conference.rb
Overview
A command that sets a Conference as published.
Instance Method Summary collapse
Instance Method Details
#call ⇒ Object
8 9 10 11 12 13 14 15 16 17 |
# File 'app/commands/decidim/conferences/admin/publish_conference.rb', line 8 def call return broadcast(:invalid) if participatory_space.nil? || participatory_space.published? Decidim.traceability.perform_action!(:publish, participatory_space, user, **) do participatory_space.publish! end send_notification broadcast(:ok, participatory_space) end |