lib/parker/announcement.rb
# Generates the body of the hipchat message for priority 1 issues
# @return [String] containing html formatted hipchat message
Generates the body of the hipchat message for priority 1 issues
Generates the body of the hipchat message for priority 1 issues
def p1_announcement(client)
      p1s = issue_handler.p1_issues
      case client
      when 'hipchat'
        html = "There are currently <b>#{p1s.count}</b> #{ENV['P1_LABEL']} bugs open.<br>"
        html += issue_handler.hipchat_issues_info(p1s)
      when 'slack'
        html = "There are currently *#{p1s.count}* #{ENV['P1_LABEL']} bugs open.\n"
        html += issue_handler.slack_issues_info(p1s)
      end
      html
    end
def p1_announcement ( client ) p1s = issue_handler . p1_issues case client when 'hipchat' html = "There are currently <b>#{p1s.count}</b> #{ENV['P1_LABEL']} bugs open.<br>" html += issue_handler . hipchat_issues_info ( p1s ) when 'slack' html = "There are currently *#{p1s.count}* #{ENV['P1_LABEL']} bugs open.\n" html += issue_handler . slack_issues_info ( p1s ) end html end
Generates the body of the hipchat message for priority 1 issues
Generates the body of the hipchat message for priority 1 issues
containing html formatted hipchat message
containing html formatted hipchat message
String
client
<not_specific>