Sha256: 51a2d05787ae18f027b5e6f41afd63e32145f5f79b3749fe8b4f96aade93d85d

Contents?: true

Size: 415 Bytes

Versions: 12

Compression:

Stored size: 415 Bytes

Contents

class ActivityLogChannel < ApplicationCable::Channel
  def subscribed
    stream_from "messages"
  end

  def unsubscribed
    # Any cleanup needed when channel is unsubscribed
  end

  def receive(data)
    ActionCable.server.broadcast("messages", {message: "ActionCable is connected and received: #{data["message"]}", topic: data["topic"].presence || "general"}) if data["namespace"] == "subscriptions"
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
thecore_backend_commons-3.2.4 app/channels/activity_log_channel.rb
thecore_backend_commons-3.2.3 app/channels/activity_log_channel.rb
thecore_backend_commons-3.2.2 app/channels/activity_log_channel.rb
thecore_backend_commons-3.2.1 app/channels/activity_log_channel.rb
thecore_backend_commons-3.2.0 app/channels/activity_log_channel.rb
thecore_backend_commons-3.1.9 app/channels/activity_log_channel.rb
thecore_backend_commons-3.1.8 app/channels/activity_log_channel.rb
thecore_backend_commons-3.1.7 app/channels/activity_log_channel.rb
thecore_backend_commons-3.1.6 app/channels/activity_log_channel.rb
thecore_backend_commons-3.1.5 app/channels/activity_log_channel.rb
thecore_backend_commons-3.1.4 app/channels/activity_log_channel.rb
thecore_backend_commons-3.1.3 app/channels/activity_log_channel.rb