mirror of
https://github.com/internetee/registry.git
synced 2025-07-21 18:26:06 +02:00
All system now supports legacy CID format
This commit is contained in:
parent
1f504e08ea
commit
928ce24132
9 changed files with 137 additions and 56 deletions
|
@ -11,7 +11,7 @@ class Epp::ContactsController < EppController
|
|||
authorize! :check, Epp::Contact
|
||||
|
||||
ids = params[:parsed_frame].css('id').map(&:text)
|
||||
@results = Contact.check_availability(ids)
|
||||
@results = Epp::Contact.check_availability(ids)
|
||||
render_epp_response '/epp/contacts/check'
|
||||
end
|
||||
|
||||
|
@ -59,8 +59,9 @@ class Epp::ContactsController < EppController
|
|||
end
|
||||
|
||||
def find_contact
|
||||
code = params[:parsed_frame].css('id').text.strip.upcase
|
||||
@contact = Epp::Contact.find_by(code: code)
|
||||
code = params[:parsed_frame].css('id').text.strip.upcase.sub(/^CID:/, '')
|
||||
|
||||
@contact = Epp::Contact.find_by_epp_code(code)
|
||||
|
||||
if @contact.blank?
|
||||
epp_errors << {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue