demarches-normaliennes/app/models/notification.rb

15 lines
311 B
Ruby
Raw Normal View History

2016-12-21 17:26:31 +01:00
class Notification < ActiveRecord::Base
enum type_notif: {
2017-05-26 21:32:43 +02:00
commentaire: 'commentaire',
cerfa: 'cerfa',
piece_justificative: 'piece_justificative',
champs: 'champs',
submitted: 'submitted',
avis: 'avis'
}
belongs_to :dossier
scope :unread, -> { where(already_read: false) }
2016-12-21 17:26:31 +01:00
end