Commit 15535433 authored by Nico Schottelius's avatar Nico Schottelius

begin to change to day based differences

Signed-off-by: default avatarNico Schottelius <nico@nico-notebook.schottelius.org>
parent 18b862c2
Pipeline #1534 failed with stage
in 42 seconds
......@@ -173,7 +173,7 @@ class VPNNetwork(Product):
wireguard_public_key = models.CharField(max_length=48)
default_recurring_period = RecurringPeriod.PER_YEAR
default_recurring_period = RecurringPeriod.PER_365D
@property
def recurring_price(self):
......
This diff is collapsed.
......@@ -17,7 +17,7 @@ class MatrixServiceProduct(Product):
domain = models.CharField(max_length=255, default='domain.tld')
# Default recurring price is PER_MONT, see Product class.
def recurring_price(self, recurring_period=RecurringPeriod.PER_MONTH):
def recurring_price(self, recurring_period=RecurringPeriod.PER_30D):
return self.monthly_managment_fee
@staticmethod
......@@ -28,7 +28,7 @@ class MatrixServiceProduct(Product):
@staticmethod
def allowed_recurring_periods():
return list(filter(
lambda pair: pair[0] in [RecurringPeriod.PER_MONTH],
lambda pair: pair[0] in [RecurringPeriod.PER_30D],
RecurringPeriod.choices))
@property
......
......@@ -88,8 +88,8 @@ class VMProduct(Product):
@staticmethod
def allowed_recurring_periods():
return list(filter(
lambda pair: pair[0] in [RecurringPeriod.PER_YEAR,
RecurringPeriod.PER_MONTH, RecurringPeriod.PER_HOUR],
lambda pair: pair[0] in [RecurringPeriod.PER_365D,
RecurringPeriod.PER_30D, RecurringPeriod.PER_HOUR],
RecurringPeriod.choices))
def __str__(self):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment