|
<%= javascript_tag do %>
|
|
$(function () {
|
|
// basic http auth modal dialog setup
|
|
var button = $("#forward_auth_button")
|
|
var dialog = $("#forward_auth")
|
|
|
|
dialog.modal({
|
|
backdrop: 'static',
|
|
show: false
|
|
})
|
|
|
|
button.on('click', function () {
|
|
dialog.modal('show')
|
|
});
|
|
|
|
// filling the dialog with redhat_access credentials
|
|
var token = localStorage.getItem('rhAuthToken');
|
|
var rhUser = '';
|
|
var rhPass = '';
|
|
if (token) {
|
|
try {
|
|
decoded = atob(token);
|
|
colonPos = decoded.indexOf(':');
|
|
if (colonPos != -1) {
|
|
rhUser = decoded.substring(0, colonPos);
|
|
rhPass = decoded.substring(colonPos+1);
|
|
$("#redhat_access_alert_login").hide();
|
|
$("#redhat_access_alert_use").show();
|
|
}
|
|
} catch(err) {}
|
|
}
|
|
|
|
$("#redhat_access_fill").on('click', function (e) {
|
|
e.preventDefault();
|
|
$("#username").val(rhUser);
|
|
$("#password").val(rhPass);
|
|
});
|
|
});
|
|
<% end %>
|
|
|
|
<% title @abrt_report.host.to_s %>
|
|
|
|
<%= title_actions link_to(_('Host details'), @abrt_report.host),
|
|
link_to(_('Other reports for this host'), host_abrt_reports_path(@abrt_report.host)),
|
|
display_forward_button(@abrt_report),
|
|
display_delete_if_authorized(hash_for_abrt_report_path(:id => @abrt_report), :class => 'btn btn-danger')
|
|
%>
|
|
|
|
<div class="row">
|
|
<div class="col-md-12">
|
|
<table class="table table-bordered table-striped">
|
|
<tr>
|
|
<th><%= _('Reason') %></th>
|
|
<td><%= format_reason @abrt_report.reason %></td>
|
|
</tr>
|
|
<tr>
|
|
<th><%= _('First reported') %></th>
|
|
<td><%= @abrt_report.reported_at.getlocal %></td>
|
|
</tr>
|
|
<tr>
|
|
<th><%= _('Repeated') %></th>
|
|
<td><%= @abrt_report.count %></td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
|
|
<hr>
|
|
|
|
<% if @abrt_report.forwarded_at %>
|
|
<%= render :partial => 'show_response' %>
|
|
<% else %>
|
|
<div class="row">
|
|
<div class="col-md-12">
|
|
<p><%= _("The report hasn't been sent for analysis.") %></p>
|
|
</div>
|
|
</div>
|
|
<% end %>
|
|
|
|
<% if ask_for_auth? %>
|
|
<%= render :partial => 'basic_auth_modal' %>
|
|
<% end %>
|