Module: SupportCenter::Helpers

Defined in:
lib/support_center/server/helpers.rb

Instance Method Summary collapse

Instance Method Details

#field_idsObject



20
21
22
# File 'lib/support_center/server/helpers.rb', line 20

def field_ids
  @field_ids ||= SupportCenter.config.custom_ticket_fields
end


14
15
16
17
18
# File 'lib/support_center/server/helpers.rb', line 14

def see_more_faqs_link
  if params[:faq_link]
    "<a class='all_faq_link' href=#{params[:faq_link]}>See All FAQs ...</a>"
  end
end

#support_clientObject



3
4
5
6
7
8
9
10
11
12
# File 'lib/support_center/server/helpers.rb', line 3

def support_client
  @support_client ||= ZendeskAPI::Client.new do |config|
    settings = SupportCenter.config.config_service_adapter['support_center']

    config.url      = settings['url']
    config.username = settings['username']
    config.password = settings['password']
    config.retry    = true
  end
end