mirror of
https://github.com/redmine/redmine.git
synced 2024-08-18 14:10:15 +02:00
![Jean-Philippe Lang](/assets/img/avatar_default.png)
Patch by Denis Savitskiy. git-svn-id: http://svn.redmine.org/redmine/trunk@13920 e93f8b46-1217-0410-a6f0-8f06a7374b81
13 lines
428 B
Ruby
13 lines
428 B
Ruby
class RemoveIssueStatusesIsDefault < ActiveRecord::Migration
|
|
def up
|
|
remove_column :issue_statuses, :is_default
|
|
end
|
|
|
|
def down
|
|
add_column :issue_statuses, :is_default, :boolean, :null => false, :default => false
|
|
# Restores the first status as default
|
|
default_status_id = IssueStatus.order("position").pluck(:id).first
|
|
IssueStatus.where(:id => default_status_id).update_all(:is_default => true)
|
|
end
|
|
end
|