Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[webui]patchinfo-editor #39

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 14 additions & 9 deletions src/webui/app/controllers/patchinfo_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -155,13 +155,15 @@ def save
relogin = params[:relogin]
reboot = params[:reboot]
zypp_restart_needed = params[:zypp_restart_needed]
issues = Array.new
params[:issue].each_with_index do |new_issue, index|
issue = Array.new
issue << new_issue
issue << params[:issuetracker][index]
issue << params[:issuesum][index]
issues << issue
if params[:issue]
issues = Array.new
params[:issue].each_with_index do |new_issue, index|
issue = Array.new
issue << new_issue
issue << params[:issuetracker][index]
issue << params[:issuesum][index]
issues << issue
end
end
rating = params[:rating]
node = Builder::XmlMarkup.new(:indent=>2)
Expand All @@ -176,8 +178,10 @@ def save
end
end
node.packager packager
issues.each do |issue|
node.issue(issue[2], :tracker=>issue[1], :id=>issue[0])
if issues
issues.each do |issue|
node.issue(issue[2], :tracker=>issue[1], :id=>issue[0])
end
end
node.category params[:category]
node.rating rating
Expand Down Expand Up @@ -294,6 +298,7 @@ def get_issue_sum(issueid, tracker)
end
@issuesum = result.summary.text if result.summary
@issuesum = "" if !result.summary
@issuesum.gsub!(/\\|'/) { |c| "" }
else
@issuesum = "invalid"
end
Expand Down