simple refactoring
This commit is contained in:
parent
a635b9da97
commit
df7c52489a
21 changed files with 276 additions and 264 deletions
|
@ -4,7 +4,8 @@ class Milestone < ActiveRecord::Base
|
|||
belongs_to :project
|
||||
has_many :issues
|
||||
|
||||
validates_presence_of :title, :project_id
|
||||
validates :title, presence: true
|
||||
validates :project, presence: true
|
||||
|
||||
def self.active
|
||||
where("due_date > ? OR due_date IS NULL", Date.today)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue