diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index 8871fff..218660a 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -4,7 +4,10 @@
-
+
+
+
+
@@ -86,7 +89,7 @@
1709421008833
-
+
diff --git a/products/models.py b/products/models.py
index 71a8362..bf4740c 100644
--- a/products/models.py
+++ b/products/models.py
@@ -1,3 +1,32 @@
from django.db import models
-# Create your models here.
+
+class Brand(models.Model):
+ name = models.CharField(max_length=100)
+ description = models.TextField(blank=True)
+
+ def __str__(self):
+ return f"{self.name}"
+
+
+class Supplier(models.Model):
+ name = models.CharField(max_length=100)
+ email = models.EmailField()
+ phone = models.CharField(max_length=20)
+
+ def __str__(self):
+ return f"{self.name}"
+
+
+class Product(models.Model):
+ name = models.CharField(max_length=100)
+ description = models.TextField()
+ sku = models.CharField(max_length=50)
+ price = models.DecimalField(max_digits=10, decimal_places=2)
+ quantity = models.IntegerField(default=0)
+ barcode = models.CharField(max_length=100, blank=True, null=True)
+ brand = models.ForeignKey(Brand, models.DO_NOTHING)
+ supplier = models.ForeignKey(Supplier, models.DO_NOTHING)
+
+ def __str__(self):
+ return f"{self.name}"