|
|
|
@ -239,8 +239,10 @@ class Journal < ActiveRecord::Base
|
|
|
|
|
|
|
|
|
|
#缺陷回复微信模板消息
|
|
|
|
|
def issue_wechat_message
|
|
|
|
|
ws = WechatService.new
|
|
|
|
|
content = strip_html self.notes.html_safe, 200
|
|
|
|
|
ws.comment_template self.issue.author_id, "issues", self.journalized_id, "#{l(:label_issue_comment_template)}", self.user.try(:realname), format_time(self.created_on), content
|
|
|
|
|
if !self.notes.nil? && self.notes.gsub(' ','') != ''
|
|
|
|
|
ws = WechatService.new
|
|
|
|
|
content = strip_html self.notes.html_safe, 200
|
|
|
|
|
ws.comment_template self.issue.author_id, "issues", self.journalized_id, "#{l(:label_issue_comment_template)}", self.user.try(:realname), format_time(self.created_on), content
|
|
|
|
|
end
|
|
|
|
|
end
|
|
|
|
|
end
|
|
|
|
|