add video filed to product model

This commit is contained in:
Parsa Nazer
2025-01-27 19:14:28 +03:30
parent 67afffae96
commit f72b5b2d0e
2 changed files with 2 additions and 0 deletions
+1
View File
@@ -1,5 +1,6 @@
# Byte-compiled / optimized / DLL files # Byte-compiled / optimized / DLL files
__pycache__/ __pycache__/
migrations/
*.py[cod] *.py[cod]
*$py.class *$py.class
+1
View File
@@ -78,6 +78,7 @@ class ProductModel(models.Model):
image1 = models.ImageField(upload_to='product_images/') image1 = models.ImageField(upload_to='product_images/')
image2 = models.ImageField(upload_to='product_images/', blank=True, null=True) image2 = models.ImageField(upload_to='product_images/', blank=True, null=True)
image3 = models.ImageField(upload_to='product_images/', blank=True, null=True) image3 = models.ImageField(upload_to='product_images/', blank=True, null=True)
video = models.FileField(upload_to='product_videos/', blank=True, null=True)
rating = models.PositiveIntegerField(default=0) rating = models.PositiveIntegerField(default=0)
view = models.IntegerField(default=0, verbose_name='بازدید') view = models.IntegerField(default=0, verbose_name='بازدید')
sell = models.IntegerField(default=0, verbose_name='فروش') sell = models.IntegerField(default=0, verbose_name='فروش')