Class: ActiveAdminExcelUpload::ExcelChannel

Inherits:
ApplicationCable::Channel
  • Object
show all
Defined in:
app/channels/active_admin_excel_upload/excel_channel.rb

Instance Method Summary collapse

Instance Method Details

#speakObject



16
17
# File 'app/channels/active_admin_excel_upload/excel_channel.rb', line 16

def speak
end

#subscribedObject



3
4
5
6
7
8
9
10
# File 'app/channels/active_admin_excel_upload/excel_channel.rb', line 3

def subscribed
  # stream_from "some_channel"
  if ActiveAdminExcelUpload.configuration.use_default_connecion_authentication
    stream_from "excel_channel_#{current_admin_user.id}"
  else
    stream_from "excel_channel_#{self.send(ActiveAdminExcelUpload.configuration.connection_identifier).send(:id)}"
  end
end

#unsubscribedObject



12
13
14
# File 'app/channels/active_admin_excel_upload/excel_channel.rb', line 12

def unsubscribed
  # Any cleanup needed when channel is unsubscribed
end