gitlab-org--gitlab-foss/app/models/board.rb
2017-02-03 17:02:43 +03:00

11 lines
232 B
Ruby

class Board < ActiveRecord::Base
belongs_to :project
has_many :lists, -> { order(:list_type, :position) }, dependent: :delete_all
validates :project, presence: true
def done_list
lists.merge(List.done).take
end
end