Commit edac1826 authored by Florent Chehab's avatar Florent Chehab

Currency model updated

parent 42c0b031
# Generated by Django 2.0.3 on 2018-09-01 09:34
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('backend', '0002_auto_20180901_1000'),
]
operations = [
migrations.RenameField(
model_name='currency',
old_name='one_USD_in_this_currency',
new_name='one_EUR_in_this_currency',
),
]
# Generated by Django 2.0.3 on 2018-09-01 12:29
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('backend', '0003_auto_20180901_1134'),
]
operations = [
migrations.AlterField(
model_name='currency',
name='symbol',
field=models.CharField(blank=True, max_length=30, null=True),
),
]
......@@ -7,8 +7,8 @@ from backend.models.my_model import MyModel, MyModelSerializer, MyModelViewSet
class Currency(MyModel):
code = models.CharField(primary_key=True, max_length=15)
name = models.CharField(max_length=100)
symbol = models.CharField(max_length=5)
one_USD_in_this_currency = models.DecimalField(
symbol = models.CharField(null=True, blank=True, max_length=30)
one_EUR_in_this_currency = models.DecimalField(
max_digits=20,
decimal_places=6,
validators=[MinValueValidator(0)]
......
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