[Fix #835] Enable asking for multiple avis at the same time
This commit is contained in:
parent
31ca0552ab
commit
c7358a8f53
6 changed files with 33 additions and 12 deletions
|
@ -19,6 +19,10 @@ class Avis < ApplicationRecord
|
|||
scope :by_latest, -> { order(updated_at: :desc) }
|
||||
scope :updated_since?, -> (date) { where('avis.updated_at > ?', date) }
|
||||
|
||||
# The form allows subtmitting avis requests to several emails at once,
|
||||
# hence this virtual attribute.
|
||||
attr_accessor :emails
|
||||
|
||||
def email_to_display
|
||||
gestionnaire&.email || email
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue