Module: Qywx::Client::GroupRobotClient::NotifyMarkdown
- Included in:
- Qywx::Client::GroupRobotClient
- Defined in:
- lib/qywx/client/group_robot_client/notify_markdown.rb
Instance Method Summary collapse
Instance Method Details
#notify_markdown(code, title, **options) { ... } ⇒ Object
11 12 13 14 15 16 17 18 19 20 21 22 |
# File 'lib/qywx/client/group_robot_client/notify_markdown.rb', line 11 def notify_markdown(code, title, **, &block) .with_defaults!( template_file: code ) token_code = code.to_sym token = fetch_token(token_code) title = String(title) template_file = String([:template_file]) content = get_markdown_content(template_file, &block) body = get_markdown_body(title, content) notify(token, body) end |