mirror of
https://github.com/internetee/registry.git
synced 2025-05-17 09:57:23 +02:00
Story#109368800 update validation that contact code may have underscore
This commit is contained in:
parent
1de2992ce2
commit
a5adbca28b
1 changed files with 1 additions and 1 deletions
|
@ -26,7 +26,7 @@ class Contact < ActiveRecord::Base
|
|||
validates :ident_country_code, presence: true, if: proc { |c| %w(org priv).include? c.ident_type }, on: :create
|
||||
validates :code,
|
||||
uniqueness: { message: :epp_id_taken },
|
||||
format: { with: /\A[\w\-\:\.]*\z/i, message: :invalid },
|
||||
format: { with: /\A[\w\-\:\.\_]*\z/i, message: :invalid },
|
||||
length: { maximum: 100, message: :too_long_contact_code }
|
||||
validate :ident_valid_format?
|
||||
validate :uniq_statuses?
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue