mirror of
https://github.com/internetee/registry.git
synced 2025-08-05 09:21:43 +02:00
Debit account on domain create #2741
This commit is contained in:
parent
e2374f9702
commit
98439b896c
7 changed files with 47 additions and 8 deletions
|
@ -372,6 +372,12 @@ class Domain < ActiveRecord::Base
|
|||
DomainMailer.pending_deleted(self).deliver_now
|
||||
end
|
||||
|
||||
def price(operation)
|
||||
zone = name.split('.').drop(1).join('.')
|
||||
p = "#{self.period}year"
|
||||
Pricelist.price_for(zone, operation, p)
|
||||
end
|
||||
|
||||
### VALIDATIONS ###
|
||||
|
||||
def validate_nameserver_ips
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue