@@ -76,12 +76,12 class EnumerationsController < ApplicationController | |||
|
76 | 76 | @enumeration.destroy |
|
77 | 77 | redirect_to :action => 'index' |
|
78 | 78 | elsif params[:reassign_to_id] |
|
79 |
if reassign_to = |
|
|
79 | if reassign_to = @enumeration.class.find_by_id(params[:reassign_to_id]) | |
|
80 | 80 | @enumeration.destroy(reassign_to) |
|
81 | 81 | redirect_to :action => 'index' |
|
82 | 82 | end |
|
83 | 83 | end |
|
84 | @enumerations = Enumeration.find(:all, :conditions => ['type = (?)', @enumeration.type]) - [@enumeration] | |
|
84 | @enumerations = @enumeration.class.find(:all) - [@enumeration] | |
|
85 | 85 | #rescue |
|
86 | 86 | # flash[:error] = 'Unable to delete enumeration' |
|
87 | 87 | # redirect_to :action => 'index' |
General Comments 0
You need to be logged in to leave comments.
Login now