Module: BotMob::Rails::SlackHelper
- Defined in:
- app/helpers/bot_mob/rails/slack_helper.rb
Constant Summary collapse
- URL =
'https://slack.com/oauth/authorize'
Instance Method Summary collapse
Instance Method Details
#slack_button(*scopes) ⇒ Object
6 7 8 9 10 11 12 13 |
# File 'app/helpers/bot_mob/rails/slack_helper.rb', line 6 def (*scopes) params = URI.encode_www_form({ client_id: ENV['SLACK_CLIENT_ID'], scope: scopes.join(' ') }) content_tag(:a, , href: "#{URL}?#{params}", class: 'slack_button').html_safe end |