Restoroo/core/models/billing.py
2022-08-04 17:58:57 +02:00

22 lines
676 B
Python

from django.db import models
from django.utils.translation import gettext as _
class ExpenseTypeChoices(models.IntegerChoices):
MONTHLY_FEE = (0, _("Monthly Fee"))
SUPPORT = (1, _("Support"))
DEVELOPMENT = (2, _("Custom Development"))
COMMISSION = (3, _("Commission"))
CONTRIBUTION = (4, _("Contribution"))
class RelatedModelChoices(models.IntegerChoices):
CHAIN = (0, _("Chain"))
RESTAURANT = (1, _("Restaurant"))
ROOM = (2, _("Room"))
TABLE = (3, _("Table"))
class Expense(models.Model):
expense_type = models.IntegerField(choices=ExpenseTypeChoices.choices(), null=True, blank=True)
text = models.CharField(max_length=256)