mirror of
https://github.com/internetee/registry.git
synced 2025-07-04 10:13:34 +02:00
Use app time zone when calculating valid_to, outzone_at and delete_at domain attributes
#235
This commit is contained in:
parent
8dc65a370f
commit
1cc780f3ce
4 changed files with 86 additions and 15 deletions
|
@ -53,6 +53,9 @@ class Epp::Domain < Domain
|
|||
domain = Epp::Domain.new
|
||||
domain.attributes = domain.attrs_from(frame, current_user)
|
||||
domain.attach_default_contacts
|
||||
domain.registered_at = Time.zone.now
|
||||
domain.valid_from = Time.zone.now
|
||||
domain.valid_to = domain.valid_from.beginning_of_day + convert_period_to_time(domain.period, domain.period_unit) + 1.day
|
||||
domain
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue