X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/28d5074cdf748cd4da9e98d6202925fdbbf678cc..408e81ed610fa238229150e4a47f457139fcf867:/apps/workbench/app/views/application/_report_error.html.erb diff --git a/apps/workbench/app/views/application/_report_error.html.erb b/apps/workbench/app/views/application/_report_error.html.erb index f79a76905a..ab0fd67d3a 100644 --- a/apps/workbench/app/views/application/_report_error.html.erb +++ b/apps/workbench/app/views/application/_report_error.html.erb @@ -1,17 +1,35 @@ +<%# Copyright (C) The Arvados Authors. All rights reserved. + +SPDX-License-Identifier: AGPL-3.0 %> + +<% + popup_params = { + popup_type: 'report', + current_location: request.url, + current_path: request.fullpath, + action_method: 'post', + } + if error_type == "api" + popup_params.merge!( + api_error_request_url: api_error.andand.request_url || "", + api_error_response: api_error.andand.api_response || "", + ) + else + popup_params.merge!(error_message: error_message) + end +%> +

-
If you suspect this is a bug, you can help us fix it by sending us a problem report:

-<% if api_error %> - Send a problem report right here. <%= link_to report_issue_popup_path(popup_type: 'report', current_location: request.url, action_method: 'post', api_error_request_url: api_error.request_url, api_error_response: api_error.api_response_s), - {class: 'btn btn-primary report-issue-modal-window', 'data-toggle' => "modal", 'data-target' => '#report-issue-modal-window', :remote => true, return_to: request.url} do %> - Report problem - <% end %> -<% else %> - Send a problem report right here. <%= link_to report_issue_popup_path(popup_type: 'report', current_location: request.url, action_method: 'post', error_message: error_message), - {class: 'btn btn-primary report-issue-modal-window', 'data-toggle' => "modal", 'data-target' => '#report-issue-modal-window', :remote => true, return_to: request.url} do %> - Report problem - <% end %> +<%= link_to(report_issue_popup_path(popup_params), + {class: 'btn btn-primary report-issue-modal-window', :remote => true, return_to: request.url}) do %> + Report problem <% end %> -<% support_email = Rails.configuration.support_email_address%> -

- If you prefer email, send to: <%=support_email%> + +or + +<%= mail_to(Rails.configuration.support_email_address, "email us", + subject: "Workbench problem report", + body: "Problem while viewing page #{request.url}") %> + +if you suspect this is a bug.