Class: Effective::CommitteeFile

Inherits:
ActiveRecord::Base
  • Object
show all
Defined in:
app/models/effective/committee_file.rb

Instance Method Summary collapse

Instance Method Details

#parentsObject



54
55
56
57
# File 'app/models/effective/committee_file.rb', line 54

def parents
  return [] if committee_folder.blank?
  committee_folder.parents + [committee_folder]
end

#to_sObject



50
51
52
# File 'app/models/effective/committee_file.rb', line 50

def to_s
  title.presence || file&.filename.to_s.presence || 'file'
end