feat(administrateur/procedure#create): allow admin to add a lien to the DPO, allow user to consult link to dpo. enhance spec on _procedure_footer.html

Update spec/views/users/_procedure_footer.html.haml_spec.rb

Co-authored-by: Pierre de La Morinerie <kemenaran@gmail.com>
This commit is contained in:
Martin 2022-04-25 17:38:30 +02:00 committed by mfo
parent c19222a994
commit be090a1bec
14 changed files with 149 additions and 17 deletions

View file

@ -28,6 +28,7 @@
# juridique_required :boolean default(TRUE)
# libelle :string
# lien_demarche :string
# lien_dpo :string
# lien_notice :string
# lien_site_web :string
# monavis_embed :text
@ -266,6 +267,7 @@ class Procedure < ApplicationRecord
validate :check_juridique
validates :path, presence: true, format: { with: /\A[a-z0-9_\-]{3,200}\z/ }, uniqueness: { scope: [:path, :closed_at, :hidden_at, :unpublished_at], case_sensitive: false }
validates :duree_conservation_dossiers_dans_ds, allow_nil: false, numericality: { only_integer: true, greater_than_or_equal_to: 1, less_than_or_equal_to: MAX_DUREE_CONSERVATION }
validates :lien_dpo, email_or_link: true, allow_nil: true
validates_with MonAvisEmbedValidator
FILE_MAX_SIZE = 20.megabytes