Compare commits

...

2 commits

2 changed files with 26 additions and 6 deletions

View file

@ -0,0 +1,22 @@
# Generated by Django 4.1.4 on 2023-04-19 08:06
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
("main", "0025_alter_account_options_alter_invoice_options_and_more"),
]
operations = [
migrations.AlterField(
model_name="account",
name="uicon",
field=models.CharField(default="🏦", max_length=1, verbose_name="Icon"),
),
migrations.AlterField(
model_name="category",
name="uicon",
field=models.CharField(default="📂", max_length=1, verbose_name="Icon"),
),
]

View file

@ -43,10 +43,9 @@ def get_path(instance, filename):
class Account(CustomModel): class Account(CustomModel):
id = models.UUIDField(primary_key=True, default=uuid.uuid4, editable=False) id = models.UUIDField(primary_key=True, default=uuid.uuid4, editable=False)
name = models.CharField(max_length=64, default=_("Account"), verbose_name=_("Name")) name = models.CharField(max_length=64, default=_("Account"), verbose_name=_("Name"))
uicon = models.SlugField( uicon = models.CharField(
max_length=1, max_length=2,
default="🏦", default="🏦",
allow_unicode=True,
verbose_name=_("Icon"), verbose_name=_("Icon"),
) )
default = models.BooleanField(default=False, verbose_name=_("Default")) default = models.BooleanField(default=False, verbose_name=_("Default"))
@ -97,10 +96,9 @@ class Category(CustomModel):
name = models.CharField( name = models.CharField(
max_length=64, default=_("Category"), verbose_name=_("Name") max_length=64, default=_("Category"), verbose_name=_("Name")
) )
uicon = models.SlugField( uicon = models.CharField(
max_length=1, max_length=2,
default="📂", default="📂",
allow_unicode=True,
verbose_name=_("Icon"), verbose_name=_("Icon"),
) )
budget = models.BooleanField(default=True, verbose_name=_("Budget")) budget = models.BooleanField(default=True, verbose_name=_("Budget"))