Phasing out Product model
Signed-off-by: Nico Schottelius <nico@nico-notebook.schottelius.org>
This commit is contained in:
parent
1aead50170
commit
c6bacab35a
12 changed files with 227 additions and 26 deletions
37
uncloud_service/migrations/0006_auto_20200928_1858.py
Normal file
37
uncloud_service/migrations/0006_auto_20200928_1858.py
Normal file
|
|
@ -0,0 +1,37 @@
|
|||
# Generated by Django 3.1 on 2020-09-28 18:58
|
||||
|
||||
from django.db import migrations
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('uncloud_service', '0005_auto_20200928_1844'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.RemoveField(
|
||||
model_name='genericserviceproduct',
|
||||
name='extra_data',
|
||||
),
|
||||
migrations.RemoveField(
|
||||
model_name='genericserviceproduct',
|
||||
name='owner',
|
||||
),
|
||||
migrations.RemoveField(
|
||||
model_name='genericserviceproduct',
|
||||
name='status',
|
||||
),
|
||||
migrations.RemoveField(
|
||||
model_name='matrixserviceproduct',
|
||||
name='extra_data',
|
||||
),
|
||||
migrations.RemoveField(
|
||||
model_name='matrixserviceproduct',
|
||||
name='owner',
|
||||
),
|
||||
migrations.RemoveField(
|
||||
model_name='matrixserviceproduct',
|
||||
name='status',
|
||||
),
|
||||
]
|
||||
|
|
@ -3,7 +3,7 @@ from uncloud_pay.models import Product, RecurringPeriod, AMOUNT_MAX_DIGITS, AMOU
|
|||
from uncloud_vm.models import VMProduct, VMDiskImageProduct
|
||||
from django.core.validators import MinValueValidator
|
||||
|
||||
class MatrixServiceProduct(Product):
|
||||
class MatrixServiceProduct(models.Model):
|
||||
monthly_managment_fee = 20
|
||||
|
||||
description = "Managed Matrix HomeServer"
|
||||
|
|
@ -34,7 +34,7 @@ class MatrixServiceProduct(Product):
|
|||
def one_time_price(self):
|
||||
return 30
|
||||
|
||||
class GenericServiceProduct(Product):
|
||||
class GenericServiceProduct(models.Model):
|
||||
custom_description = models.TextField()
|
||||
custom_recurring_price = models.DecimalField(default=0.0,
|
||||
max_digits=AMOUNT_MAX_DIGITS,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue