mirror of
https://github.com/welton89/RRBEC.git
synced 2026-04-05 13:35:42 +00:00
criado metodo de mais vendidos no comandas.models | limitar lista de products a 15 itens
This commit is contained in:
@@ -2,6 +2,7 @@ from django.db import models
|
||||
|
||||
from categories.models import Categories
|
||||
|
||||
|
||||
# Create your models here.
|
||||
class Product(models.Model):
|
||||
id = models.AutoField(primary_key=True)
|
||||
@@ -15,4 +16,4 @@ class Product(models.Model):
|
||||
active = models.BooleanField(default=True)
|
||||
|
||||
def __str__(self) -> str:
|
||||
return f"{self.id} - {self.name} - {self.price} - {self.category} - {self.cuisine} - {self.active} "
|
||||
return f"{self.id} - {self.name} - {self.price} - {self.category} - {self.cuisine} - {self.active} "
|
||||
|
||||
Reference in New Issue
Block a user