feat: added brand model

This commit is contained in:
Pablo Moreno
2024-05-19 20:05:09 +02:00
parent 6ec60227b4
commit 26c2fded92
11 changed files with 256 additions and 32 deletions
+19 -2
View File
@@ -1,5 +1,15 @@
from django.contrib import admin
from shop.models import Product, ProductPrice, OrderLine, Order, Tax, Customer, Provider, Tag, ProductBatch
from shop.models import (
Product,
ProductPrice,
OrderLine,
Order,
Tax,
Customer,
Provider,
Tag,
ProductBatch, Brand,
)
from unfold.admin import ModelAdmin
@@ -76,6 +86,14 @@ class TagAdmin(ModelAdmin):
)
@admin.register(Brand)
class BrandAdmin(ModelAdmin):
list_display = (
"id",
"name",
)
@admin.register(ProductBatch)
class ProductBatchAdmin(ModelAdmin):
list_display = (
@@ -84,4 +102,3 @@ class ProductBatchAdmin(ModelAdmin):
"quantity",
"provider",
)