Skip to content

Commit

Permalink
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion app/views/issues/_action_menu.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
:onclick => 'showAndScrollToAddNotes(); return false;',
:class => 'icon icon-add' if @issue.editable? %>
<%= link_to l(:button_edit), edit_issue_path(@issue),
:onclick => 'showAndScrollTo("update", "issue_notes"); return false;',
:onclick => 'showAndScrollToEditIssue("update", "issue_notes"); return false;',
:class => 'icon icon-edit', :accesskey => accesskey(:edit) if @issue.editable? %>
<%= link_to l(:button_log_time), new_issue_time_entry_path(@issue),
:class => 'icon icon-time-add' if User.current.allowed_to?(:log_time, @project) %>
Expand Down
2 changes: 1 addition & 1 deletion app/views/issues/_edit.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@
<%= submit_tag l(:button_submit) %>
<%= link_to(
l(:button_cancel), issue_path(id: @issue.id),
:onclick => params[:action] == 'show' ? "$('#update').hide(); return false;" : ''
:onclick => params[:action] == 'show' ? "window.location.reload();" : ''
) %>
<%= hidden_field_tag 'prev_issue_id', @prev_issue_id if @prev_issue_id %>
<%= hidden_field_tag 'next_issue_id', @next_issue_id if @next_issue_id %>
Expand Down
8 changes: 4 additions & 4 deletions public/javascripts/application.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,15 +29,15 @@ function showAndScrollTo(id, focus) {

function showAndScrollToEditIssue() {
$('#update h3').show();
$('#attributes').show();
$('#log_time').show();
$('#attributes').show(); $('#attributes input, #attributes select').prop('disabled', false)
$('#log_time').show(); $('#log_time input, #log_time select').prop('disabled', false)
showAndScrollTo('update', 'issue_notes');
}

function showAndScrollToAddNotes() {
$('#update h3').hide();
$('#attributes').hide();
$('#log_time').hide();
$('#attributes').hide();$('#attributes input, #attributes select').prop('disabled', true)
$('#log_time').hide();$('#log_time input, #log_time select').prop('disabled', true)
showAndScrollTo('update', 'issue_notes');
}

Expand Down

0 comments on commit 6f4d356

Please sign in to comment.