[Fix #3692] Ensure SIRET is correct on server
This commit is contained in:
parent
7ed1e5ac82
commit
71e0969bc0
2 changed files with 31 additions and 0 deletions
|
@ -2,4 +2,8 @@ class Champs::SiretChamp < Champ
|
|||
def search_terms
|
||||
etablissement.present? ? etablissement.search_terms : [value]
|
||||
end
|
||||
|
||||
def mandatory_and_blank?
|
||||
mandatory? && Siret.new(siret: value).invalid?
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue