mirror of
https://github.com/internetee/registry.git
synced 2025-05-17 17:59:47 +02:00
Merge branch 'master' into 117226457-registrar_client_domain_view
This commit is contained in:
commit
cbe01bbcec
14 changed files with 67 additions and 26 deletions
|
@ -55,6 +55,10 @@ class ApplicationController < ActionController::Base
|
|||
end
|
||||
end
|
||||
|
||||
def info_for_paper_trail
|
||||
{ uuid: request.uuid }
|
||||
end
|
||||
|
||||
def user_for_paper_trail
|
||||
user_log_str(current_user)
|
||||
end
|
||||
|
|
|
@ -361,7 +361,7 @@ class EppController < ApplicationController
|
|||
if request_command == 'login' && frame.present?
|
||||
frame.gsub!(/pw>.+<\//, 'pw>[FILTERED]</')
|
||||
end
|
||||
trimmed_request = frame.gsub(/<eis:legalDocument([^>]+)>([^<])+<\/eis:legalDocument>/, "<eis:legalDocument>[FILTERED]</eis:legalDocument>")
|
||||
trimmed_request = frame.gsub(/<eis:legalDocument([^>]+)>([^<])+<\/eis:legalDocument>/, "<eis:legalDocument>[FILTERED]</eis:legalDocument>") if frame.present?
|
||||
|
||||
ApiLog::EppLog.create({
|
||||
request: trimmed_request,
|
||||
|
@ -371,7 +371,8 @@ class EppController < ApplicationController
|
|||
response: @response,
|
||||
api_user_name: @api_user.try(:username) || current_user.try(:username) || 'api-public',
|
||||
api_user_registrar: @api_user.try(:registrar).try(:to_s) || current_user.try(:registrar).try(:to_s),
|
||||
ip: request.ip
|
||||
ip: request.ip,
|
||||
uuid: request.uuid
|
||||
})
|
||||
end
|
||||
# rubocop: enable Metrics/CyclomaticComplexity
|
||||
|
|
|
@ -22,18 +22,18 @@ class Registrant::DomainDeleteConfirmsController < RegistrantController
|
|||
verification_token: params[:token])
|
||||
if params[:rejected]
|
||||
if @registrant_verification.domain_registrant_delete_reject!
|
||||
flash[:notice] = t(:registrant_domain_verification_rejected)
|
||||
flash[:notice] = t(:registrant_domain_delete_rejected)
|
||||
redirect_to registrant_domain_delete_confirm_path(@domain.id, rejected: true)
|
||||
else
|
||||
flash[:alert] = t(:registrant_domain_verification_rejected_failed)
|
||||
flash[:alert] = t(:registrant_domain_delete_rejected_failed)
|
||||
return render 'show'
|
||||
end
|
||||
elsif params[:confirmed]
|
||||
if @registrant_verification.domain_registrant_delete_confirm!
|
||||
flash[:notice] = t(:registrant_domain_verification_confirmed)
|
||||
flash[:notice] = t(:registrant_domain_delete_confirmed)
|
||||
redirect_to registrant_domain_delete_confirm_path(@domain.id, confirmed: true)
|
||||
else
|
||||
flash[:alert] = t(:registrant_domain_verification_confirmed_failed)
|
||||
flash[:alert] = t(:registrant_domain_delete_confirmed_failed)
|
||||
return render 'show'
|
||||
end
|
||||
end
|
||||
|
|
|
@ -81,7 +81,7 @@ class Contact < ActiveRecord::Base
|
|||
|
||||
ORG = 'org'
|
||||
PRIV = 'priv'
|
||||
BIRTHDAY = 'birthday'
|
||||
BIRTHDAY = 'birthday'.freeze
|
||||
PASSPORT = 'passport'
|
||||
|
||||
IDENT_TYPES = [
|
||||
|
@ -252,6 +252,8 @@ class Contact < ActiveRecord::Base
|
|||
if ident.size != 8 || !(ident =~/\A[0-9]{8}\z/)
|
||||
errors.add(:ident, err_msg)
|
||||
end
|
||||
when BIRTHDAY
|
||||
errors.add(:ident, err_msg) if id.blank? # only for create action right now. Later for all of them
|
||||
end
|
||||
end
|
||||
end
|
||||
|
@ -284,6 +286,10 @@ class Contact < ActiveRecord::Base
|
|||
!org?
|
||||
end
|
||||
|
||||
def birthday?
|
||||
ident_type == BIRTHDAY
|
||||
end
|
||||
|
||||
def generate_auth_info
|
||||
return if @generate_auth_info_disabled
|
||||
return if auth_info.present?
|
||||
|
|
|
@ -575,7 +575,7 @@ class Domain < ActiveRecord::Base
|
|||
statuses << DomainStatus::SERVER_MANUAL_INZONE
|
||||
end
|
||||
|
||||
self.force_delete_at = Time.zone.now + Setting.redemption_grace_period.days unless force_delete_at
|
||||
self.force_delete_at = (Time.zone.now + (Setting.redemption_grace_period.days + 1.day)).utc.beginning_of_day unless force_delete_at
|
||||
transaction do
|
||||
save!(validate: false)
|
||||
registrar.messages.create!(
|
||||
|
@ -604,7 +604,7 @@ class Domain < ActiveRecord::Base
|
|||
|
||||
def set_graceful_expired
|
||||
self.outzone_at = valid_to + Setting.expire_warning_period.days
|
||||
self.delete_at = outzone_at + Setting.redemption_grace_period.days
|
||||
self.delete_at = (outzone_at + (Setting.redemption_grace_period.days + 1.day)).utc.beginning_of_day
|
||||
self.statuses |= [DomainStatus::EXPIRED]
|
||||
end
|
||||
|
||||
|
@ -612,7 +612,7 @@ class Domain < ActiveRecord::Base
|
|||
# TODO: currently valid_to attribute update logic is open
|
||||
# self.valid_to = valid_from + self.class.convert_period_to_time(period, period_unit)
|
||||
self.outzone_at = Time.zone.now + Setting.expire_warning_period.days
|
||||
self.delete_at = Time.zone.now + Setting.redemption_grace_period.days
|
||||
self.delete_at = (Time.zone.now + (Setting.redemption_grace_period.days + 1.day)).utc.beginning_of_day
|
||||
statuses << DomainStatus::EXPIRED
|
||||
end
|
||||
|
||||
|
|
|
@ -173,6 +173,8 @@ class Epp::Contact < Contact
|
|||
elsif ident_type == "birthday" && !ident[/\A\d{4}-\d{2}-\d{2}\z/] && (Date.parse(ident) rescue false)
|
||||
at.merge!(ident: ident_frame.text)
|
||||
at.merge!(ident_country_code: ident_frame.attr('cc')) if ident_frame.attr('cc').present?
|
||||
elsif ident_type == "birthday" && ident_country_code.blank?
|
||||
at.merge!(ident_country_code: ident_frame.attr('cc'))
|
||||
elsif ident_type.blank? && ident_country_code.blank?
|
||||
at.merge!(ident_type: ident_frame.attr('type'))
|
||||
at.merge!(ident_country_code: ident_frame.attr('cc')) if ident_frame.attr('cc').present?
|
||||
|
|
|
@ -600,7 +600,7 @@ class Epp::Domain < Domain
|
|||
msg: I18n.t(:object_status_prohibits_operation)
|
||||
} unless pending_deletable?
|
||||
|
||||
self.delete_at = Time.zone.now + Setting.redemption_grace_period.days
|
||||
self.delete_at = (Time.zone.now + (Setting.redemption_grace_period.days + 1.day)).utc.beginning_of_day
|
||||
set_pending_delete
|
||||
set_server_hold if server_holdable?
|
||||
save(validate: false)
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
Tere <%= @contact.name %>
|
||||
<br><br>
|
||||
Kontakti <%= @contact.name %> eposti aadress on muudetud<br>
|
||||
Kontakti <%= @contact.name %> e-posti aadress on muudetud<br>
|
||||
endine aadress: <%= @old_email %><br>
|
||||
uus aadress: <%= @contact.email %>
|
||||
<br><br>
|
||||
Eposti aadressile saadetakse domeenidega seotud infot seal hulgas kinnitustaotluseid omaniku vahetuse ja domeeni kustutamise korral. Palun veenduge, et muudatus on korrektne ning probleemide korral pöörduga oma registripidaja poole. Teie registripidaja on <%= @contact.registrar.name %>
|
||||
E-posti aadressile saadetakse domeeni toimingutega seotud infot, seal hulgas kinnitustaotlused omanikuvahetuse ja domeeni kustutamise korral. Palun veenduge, et muudatus on korrektne ning probleemide korral pöörduge oma registripidaja poole. Teie registripidaja on <%= @contact.registrar.name %>
|
||||
<br><br>
|
||||
<% if @contact.related_domain_descriptions.present? %>
|
||||
Muudatusega seotud domeenid:<br>
|
||||
|
@ -16,7 +16,7 @@ Muudatusega seotud domeenid:<br>
|
|||
Kontaktandmed:<br>
|
||||
Nimi: <%= @contact.name %><br>
|
||||
Isikukood: <%= @contact.ident %><br>
|
||||
Epost: <%= @contact.email %><br>
|
||||
E-post: <%= @contact.email %><br>
|
||||
Tel: <%= @contact.phone %><br>
|
||||
Tänav: <%= @contact.street %><br>
|
||||
Linn: <%= @contact.city %><br>
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
Tere <%= @contact.name %>
|
||||
|
||||
Kontakti <%= @contact.name %> eposti aadress on muudetud
|
||||
Kontakti <%= @contact.name %> e-posti aadress on muudetud
|
||||
endine aadress: <%= @old_email %>
|
||||
uus aadress: <%= @contact.email %>
|
||||
|
||||
Eposti aadressile saadetakse domeenidega seotud infot seal hulgas kinnitustaotluseid omaniku vahetuse ja domeeni kustutamise korral. Palun veenduge, et muudatus on korrektne ning probleemide korral pöörduga oma registripidaja poole. Teie registripidaja on <%= @contact.registrar.name %>
|
||||
E-posti aadressile saadetakse domeeni toimingutega seotud infot, seal hulgas kinnitustaotlused omanikuvahetuse ja domeeni kustutamise korral. Palun veenduge, et muudatus on korrektne ning probleemide korral pöörduge oma registripidaja poole. Teie registripidaja on <%= @contact.registrar.name %>
|
||||
|
||||
<% if @contact.related_domain_descriptions.present? %>
|
||||
Muudatusega seotud domeenid:
|
||||
|
@ -16,7 +16,7 @@ Muudatusega seotud domeenid:
|
|||
Kontaktandmed:
|
||||
Nimi: <%= @contact.name %>
|
||||
Isikukood: <%= @contact.ident %>
|
||||
Epost: <%= @contact.email %>
|
||||
E-post: <%= @contact.email %>
|
||||
Tel: <%= @contact.phone %>
|
||||
Tänav: <%= @contact.street %>
|
||||
Linn: <%= @contact.city %>
|
||||
|
|
|
@ -15,9 +15,9 @@ Tänav: <%= @params[:registrant_street] %><br>
|
|||
Linn: <%= @params[:registrant_city] %><br>
|
||||
Riik: <%= @params[:registrant_country] %>
|
||||
<br><br>
|
||||
Juhime Teie tähelepanu asjaolule, et omanikuvahetuse protseduur viiaks lõpule vaid juhul, kui domeeni hetkel kehtiv registreerija <%= @params[:old_registrant_name] %> omanikuvahetuse tähtaegselt kinnitab.
|
||||
Juhime Teie tähelepanu asjaolule, et omanikuvahetuse protseduur viiakse lõpule vaid juhul, kui domeeni hetkel kehtiv registreerija <%= @params[:old_registrant_name] %> omanikuvahetuse tähtaegselt kinnitab.
|
||||
<br><br>
|
||||
Juhul kui <%= @params[:old_registrant_name] %> lükkab omanikuvahtuse taotluse tagasi või ei anna kinnitust enne <%= Setting.expire_pending_confirmation %> tundi, omanikuvahetuse protseduur tühistatakse.
|
||||
Juhul kui <%= @params[:old_registrant_name] %> lükkab omanikuvahetuse taotluse tagasi või ei anna kinnitust enne <%= Setting.expire_pending_confirmation %> tundi, omanikuvahetuse protseduur tühistatakse.
|
||||
<br><br>
|
||||
Küsimuste korral palun võtke ühendust registripidajaga <%= @params[:registrar_name] %>, kelle kontaktid leiate http://internet.ee/registripidajad/akrediteeritud-registripidajad
|
||||
<br><br>
|
||||
|
|
|
@ -15,9 +15,9 @@ Tänav: <%= @params[:registrant_street] %>
|
|||
Linn: <%= @params[:registrant_city] %>
|
||||
Riik: <%= @params[:registrant_country] %>
|
||||
|
||||
Juhime Teie tähelepanu asjaolule, et omanikuvahetuse protseduur viiaks lõpule vaid juhul, kui domeeni hetkel kehtiv registreerija <%= @params[:old_registrant_name] %> omanikuvahetuse tähtaegselt kinnitab.
|
||||
Juhime Teie tähelepanu asjaolule, et omanikuvahetuse protseduur viiakse lõpule vaid juhul, kui domeeni hetkel kehtiv registreerija <%= @params[:old_registrant_name] %> omanikuvahetuse tähtaegselt kinnitab.
|
||||
|
||||
Juhul kui <%= @params[:old_registrant_name] %> lükkab omanikuvahtuse taotluse tagasi või ei anna kinnitust enne <%= Setting.expire_pending_confirmation %> tundi, omanikuvahetuse protseduur tühistatakse.
|
||||
Juhul kui <%= @params[:old_registrant_name] %> lükkab omanikuvahetuse taotluse tagasi või ei anna kinnitust enne <%= Setting.expire_pending_confirmation %> tundi, omanikuvahetuse protseduur tühistatakse.
|
||||
|
||||
Küsimuste korral palun võtke ühendust registripidajaga <%= @params[:registrar_name] %>, kelle kontaktid leiate http://internet.ee/registripidajad/akrediteeritud-registripidajad
|
||||
|
||||
|
|
|
@ -827,16 +827,20 @@ en:
|
|||
domain_registrant_change_confirmed_body: 'You have successfully submitted domain registrant change confirmation. You will receive email confirmation.'
|
||||
registrant_domain_verification_confirmed: 'Domain registrant change has successfully received.'
|
||||
registrant_domain_verification_confirmed_failed: 'Something went wrong.'
|
||||
domain_registrant_change_rejected_title: 'Domain registrant change has been rejected'
|
||||
domain_registrant_change_rejected_body: 'You have rejected domain registrant change.'
|
||||
domain_registrant_change_rejected_title: 'Domain registrant change rejection has been received'
|
||||
domain_registrant_change_rejected_body: 'You have rejected domain registrant change. You will receive confirmation by email.'
|
||||
registrant_domain_verification_rejected: 'Domain registrant change has been rejected successfully.'
|
||||
registrant_domain_verification_rejected_failed: 'Something went wrong.'
|
||||
domain_delete_title: 'Please confirm or reject domain deletation'
|
||||
domain_delete_title: 'Please confirm or reject domain deletion'
|
||||
domain_delete_body: 'There is a request to delete a domain. Before doing it we need your confirmation.'
|
||||
registrant_domain_delete_confirmed: 'Setting the domain up for deletion...'
|
||||
registrant_domain_delete_confirmed_failed: 'Something went wrong.'
|
||||
domain_delete_confirmed_title: 'Domain deletion has been received successfully'
|
||||
domain_delete_confirmed_body: 'You have successfully submitted delete confirmation. You will receive registry final confirmation to email.'
|
||||
domain_delete_rejected_title: 'Domain deletion has been rejected successfully'
|
||||
domain_delete_rejected_body: 'You have rejected domain deletion.'
|
||||
registrant_domain_delete_rejected: 'Rejecting the domain deletion...'
|
||||
registrant_domain_delete_rejected_failed: 'Something went wrong.'
|
||||
domain_delete_rejected_title: 'Domain deletion rejection has been received successfully'
|
||||
domain_delete_rejected_body: 'You have rejected pending domain deletion. You will receive confirmation by email.'
|
||||
no_permission: 'No permission'
|
||||
access_denied: 'Access denied'
|
||||
common_name: 'Common name'
|
||||
|
|
15
db/migrate/20160411140719_add_matching_column.rb
Normal file
15
db/migrate/20160411140719_add_matching_column.rb
Normal file
|
@ -0,0 +1,15 @@
|
|||
class AddMatchingColumn < ActiveRecord::Migration
|
||||
|
||||
def change
|
||||
tables = [:log_account_activities, :log_accounts, :log_addresses, :log_api_users, :log_bank_statements,
|
||||
:log_bank_transactions, :log_blocked_domains, :log_certificates, :log_contact_statuses, :log_contacts,
|
||||
:log_countries, :log_dnskeys, :log_domain_contacts, :log_domain_statuses, :log_domain_transfers,
|
||||
:log_domains, :log_invoice_items, :log_invoices, :log_keyrelays, :log_messages, :log_nameservers,
|
||||
:log_pricelists, :log_registrars, :log_reserved_domains, :log_settings, :log_users, :log_white_ips,
|
||||
:log_zonefile_settings]
|
||||
|
||||
tables.each do |table|
|
||||
add_column table, :uuid, :string
|
||||
end
|
||||
end
|
||||
end
|
9
db/migrate/20160421074023_add_log_matching_column.rb
Normal file
9
db/migrate/20160421074023_add_log_matching_column.rb
Normal file
|
@ -0,0 +1,9 @@
|
|||
class AddLogMatchingColumn < ActiveRecord::Migration
|
||||
|
||||
def change
|
||||
|
||||
ApiLog::EppLog.connection.execute("ALTER TABLE epp_logs ADD COLUMN uuid varchar;")
|
||||
ApiLog::ReppLog.connection.execute("ALTER TABLE repp_logs ADD COLUMN uuid varchar;")
|
||||
|
||||
end
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue