Description:
fix destroy button link
Commit status:
[Not Reviewed]
References:
Diff options:
Comments:
0 Commit comments
0 Inline Comments
Unresolved TODOs:
There are no unresolved TODOs
r604:d67de62d9a94 - - 2 files changed: 2 inserted, 2 deleted
@@ -36,15 +36,15 | |||
|
36 | 36 | %td= problem.name #in_place_editor_field :problem, :name, {}, :rows=>1 |
|
37 | 37 | %td= problem.full_name #in_place_editor_field :problem, :full_name, {}, :rows=>1 |
|
38 | 38 | %td.text-right= problem.full_score #in_place_editor_field :problem, :full_score, {}, :rows=>1 |
|
39 | 39 | %td= problem.date_added |
|
40 | 40 | %td= toggle_button(@problem.available?, toggle_problem_path(@problem), "problem-avail-#{@problem.id}") |
|
41 | 41 | %td= toggle_button(@problem.test_allowed?, toggle_test_problem_path(@problem), "problem-test-#{@problem.id}") |
|
42 | 42 | - if GraderConfiguration.multicontests? |
|
43 | 43 | %td |
|
44 | 44 | = problem.contests.collect { |c| c.name }.join(', ') |
|
45 | 45 | %td= link_to 'Stat', {:action => 'stat', :id => problem.id}, class: 'btn btn-info btn-xs btn-block' |
|
46 | 46 | %td= link_to 'Show', {:action => 'show', :id => problem}, class: 'btn btn-info btn-xs btn-block' |
|
47 | 47 | %td= link_to 'Edit', {:action => 'edit', :id => problem}, class: 'btn btn-info btn-xs btn-block' |
|
48 |
- %td= link_to 'Destroy', { :action => 'destroy', :id => problem }, :confirm => 'Are you sure?', :method => : |
|
|
48 | + %td= link_to 'Destroy', { :action => 'destroy', :id => problem }, :confirm => 'Are you sure?', :method => :delete, class: 'btn btn-danger btn-xs btn-block' | |
|
49 | 49 | %br/ |
|
50 | 50 | = link_to '[New problem]', :action => 'new' |
@@ -85,16 +85,16 | |||
|
85 | 85 | - for user in @users |
|
86 | 86 | %tr |
|
87 | 87 | %td= link_to user.login, controller: :users, :action => 'profile', :id => user |
|
88 | 88 | %td= user.full_name |
|
89 | 89 | %td= user.email |
|
90 | 90 | %td= user.remark |
|
91 | 91 | %td= toggle_button(user.activated?, toggle_activate_user_path(user),"toggle_activate_user_#{user.id}") |
|
92 | 92 | %td= toggle_button(user.enabled?, toggle_enable_user_path(user),"toggle_enable_user_#{user.id}") |
|
93 | 93 | %td= user.last_ip |
|
94 | 94 | %td= link_to 'Clear IP', {:action => 'clear_last_ip', :id => user, :page=>params[:page]}, :confirm => 'This will reset last logging in ip of the user, are you sure?', class: 'btn btn-default btn-xs btn-block' |
|
95 | 95 | %td= link_to 'Show', {:action => 'show', :id => user}, class: 'btn btn-default btn-xs btn-block' |
|
96 | 96 | %td= link_to 'Edit', {:action => 'edit', :id => user}, class: 'btn btn-default btn-xs btn-block' |
|
97 |
- %td= link_to 'Destroy', { :action => 'destroy', :id => user }, :confirm => 'Are you sure?', :method => : |
|
|
97 | + %td= link_to 'Destroy', { :action => 'destroy', :id => user }, :confirm => 'Are you sure?', :method => :delete, class: 'btn btn-danger btn-xs btn-block' | |
|
98 | 98 | %br/ |
|
99 | 99 | = link_to '+ New user', { :action => 'new' }, { class: 'btn btn-success '} |
|
100 | 100 | = link_to '+ New list of users', { :action => 'new_list' }, { class: 'btn btn-success '} |
You need to be logged in to leave comments.
Login now