mirror of
https://github.com/internetee/registry.git
synced 2025-08-04 00:42:04 +02:00
Domain form has now domain_contact part
This commit is contained in:
parent
4fef7e94c8
commit
d3e3c9e8b0
6 changed files with 41 additions and 12 deletions
|
@ -4,7 +4,8 @@ class Domain < ActiveRecord::Base
|
|||
belongs_to :registrar
|
||||
belongs_to :owner_contact, class_name: 'Contact'
|
||||
|
||||
has_many :domain_contacts, dependent: :delete_all, autosave: true
|
||||
has_many :domain_contacts, dependent: :delete_all
|
||||
accepts_nested_attributes_for :domain_contacts, allow_destroy: true
|
||||
|
||||
has_many :tech_contacts, -> do
|
||||
where(domain_contacts: { contact_type: DomainContact::TECH })
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue