mirror of
https://github.com/internetee/registry.git
synced 2025-07-24 03:30:33 +02:00
Merge branch 'story/118822101-epp-errors' into staging
This commit is contained in:
commit
33dfea7735
3 changed files with 14 additions and 4 deletions
|
@ -143,7 +143,7 @@ class Epp::Domain < Domain
|
|||
code = registrant_frame.try(:text)
|
||||
if code.present?
|
||||
if action == 'chg' && registrant_change_prohibited?
|
||||
add_epp_error('2304', nil, DomainStatus::SERVER_REGISTRANT_CHANGE_PROHIBITED, I18n.t(:object_status_prohibits_operation))
|
||||
add_epp_error('2304', "status", DomainStatus::SERVER_REGISTRANT_CHANGE_PROHIBITED, I18n.t(:object_status_prohibits_operation))
|
||||
end
|
||||
regt = Registrant.find_by(code: code)
|
||||
if regt
|
||||
|
|
|
@ -4,8 +4,18 @@ xml.epp_head do
|
|||
xml.result('code' => x[:code]) do
|
||||
xml.msg(x[:msg], 'lang' => 'en')
|
||||
|
||||
xml.value('xmlns:obj' => 'urn:ietf:params:xml:ns:obj') do
|
||||
xml.tag!("obj:#{x[:value][:obj]}", x[:value][:val])
|
||||
xml.value("xmlns:#{controller.controller_name}" => 'https://epp.tld.ee/schema/all-ee-1.0.xsd') do
|
||||
value = x[:value][:val]
|
||||
attrs = {}
|
||||
attrs["s"] = value if x[:value][:obj] == "status"
|
||||
|
||||
if (val = value).respond_to?(:each)
|
||||
val.each do |el|
|
||||
xml.tag!("#{controller.controller_name}:#{x[:value][:obj]}", el, attrs)
|
||||
end
|
||||
else
|
||||
xml.tag!("#{controller.controller_name}:#{x[:value][:obj]}", val, attrs)
|
||||
end
|
||||
end if x[:value]
|
||||
|
||||
x[:ext_values].each do |y|
|
||||
|
|
|
@ -134,7 +134,7 @@ describe 'EPP Domain', epp: true do
|
|||
|
||||
key = d.dnskeys.last
|
||||
|
||||
key.ds_alg.should == 3
|
||||
key.ds_alg.should == 5
|
||||
key.ds_key_tag.should_not be_blank
|
||||
|
||||
key.ds_digest_type.should == Setting.ds_algorithm
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue