##// END OF EJS Templates
Fixed: error on history atom feed when there's no notes on an issue change...
Jean-Philippe Lang -
r463:2f1d8630f153
parent child
Show More
@@ -1,28 +1,28
1 xml.instruct!
1 xml.instruct!
2 xml.feed "xmlns" => "http://www.w3.org/2005/Atom" do
2 xml.feed "xmlns" => "http://www.w3.org/2005/Atom" do
3 xml.title @title
3 xml.title @title
4 xml.link "rel" => "self", "href" => url_for(:controller => 'feeds', :action => 'history', :format => 'atom', :only_path => false)
4 xml.link "rel" => "self", "href" => url_for(:controller => 'feeds', :action => 'history', :format => 'atom', :only_path => false)
5 xml.link "rel" => "alternate", "href" => url_for(:controller => 'welcome', :only_path => false)
5 xml.link "rel" => "alternate", "href" => url_for(:controller => 'welcome', :only_path => false)
6 xml.id url_for(:controller => 'welcome', :only_path => false)
6 xml.id url_for(:controller => 'welcome', :only_path => false)
7 xml.updated CGI.rfc1123_date(@journals.first.created_on) if @journals.any?
7 xml.updated CGI.rfc1123_date(@journals.first.created_on) if @journals.any?
8 xml.author { xml.name "#{Setting.app_title}" }
8 xml.author { xml.name "#{Setting.app_title}" }
9 @journals.each do |journal|
9 @journals.each do |journal|
10 issue = journal.issue
10 issue = journal.issue
11 xml.entry do
11 xml.entry do
12 xml.title "#{issue.project.name} - #{issue.tracker.name} ##{issue.id}: #{issue.subject}"
12 xml.title "#{issue.project.name} - #{issue.tracker.name} ##{issue.id}: #{issue.subject}"
13 xml.link "rel" => "alternate", "href" => url_for(:controller => 'issues' , :action => 'show', :id => issue, :only_path => false)
13 xml.link "rel" => "alternate", "href" => url_for(:controller => 'issues' , :action => 'show', :id => issue, :only_path => false)
14 xml.id url_for(:controller => 'issues' , :action => 'show', :id => issue, :only_path => false)
14 xml.id url_for(:controller => 'issues' , :action => 'show', :id => issue, :only_path => false)
15 xml.updated CGI.rfc1123_date(journal.created_on)
15 xml.updated CGI.rfc1123_date(journal.created_on)
16 xml.author { xml.name journal.user.name }
16 xml.author { xml.name journal.user.name }
17 xml.summary journal.notes
17 xml.summary journal.notes
18 xml.content "type" => "html" do
18 xml.content "type" => "html" do
19 xml.text! journal.notes
19 xml.text! journal.notes if journal.notes
20 xml.text! "<ul>"
20 xml.text! "<ul>"
21 journal.details.each do |detail|
21 journal.details.each do |detail|
22 xml.text! "<li>" + show_detail(detail, false) + "</li>"
22 xml.text! "<li>" + show_detail(detail, false) + "</li>"
23 end
23 end
24 xml.text! "</ul>"
24 xml.text! "</ul>"
25 end
25 end
26 end
26 end
27 end
27 end
28 end No newline at end of file
28 end
General Comments 0
You need to be logged in to leave comments. Login now