mirror of
https://github.com/internetee/registry.git
synced 2025-08-04 00:42:04 +02:00
Updated contact name data type in schemas
This commit is contained in:
parent
9e63e3d0bd
commit
c7d3788a36
12 changed files with 109 additions and 45 deletions
|
@ -46,6 +46,7 @@ class Contact < ApplicationRecord
|
|||
[\u005B-\u005F\u007B-\u007E\u2040-\u206F\u20A0-\u20BF\u2100-\u218F])/x
|
||||
|
||||
validates :name, :email, presence: true
|
||||
validates :name, length: { maximum: 255, message: :too_long_contact_name }
|
||||
validates :name, format: { without: NAME_REGEXP, message: :invalid }, if: -> { priv? }
|
||||
|
||||
validates :street, :city, :zip, :country_code, presence: true, if: lambda {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue