Skip to content

Commit

Permalink
Remove default from position
Browse files Browse the repository at this point in the history
  • Loading branch information
dombesz committed Nov 22, 2024
1 parent 1a9d77e commit 8b0bbbf
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 4 deletions.
2 changes: 0 additions & 2 deletions app/models/project/life_cycle_step.rb
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,6 @@ class Project::LifeCycleStep < ApplicationRecord

validates :type, inclusion: { in: %w[Project::Stage Project::Gate], message: :must_be_a_stage_or_gate }

acts_as_list

def initialize(*args)
if instance_of? Project::LifeCycleStep
# Do not allow directly instantiating this class
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ def change
create_table :project_life_cycle_step_definitions do |t|
t.string :type
t.string :name
t.integer :position, default: 1, null: true
t.integer :position, null: true
t.references :color, foreign_key: true

t.timestamps
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ def change
t.date :start_date
t.date :end_date
t.boolean :active, default: false, null: false
t.integer :position, default: 1, null: true
t.references :project, foreign_key: true
t.references :definition, foreign_key: { to_table: :project_life_cycle_step_definitions }

Expand Down

0 comments on commit 8b0bbbf

Please sign in to comment.