sync
Raz 8 months ago
parent 47db5854d0
commit 5f0d4bbb12
  1. 107
      shop/management/commands/create_initial_shop_data.py
  2. 2
      shop/static/shop/css/shop.css
  3. BIN
      shop/static/shop/images/products/PS_K473_WHITE.png.avif
  4. BIN
      shop/static/shop/images/products/PS_K476_WHITE.png.avif
  5. BIN
      shop/static/shop/images/products/PS_PA1030_WHITE-SPORTYNAVY.png.avif
  6. BIN
      shop/static/shop/images/products/PS_PA1031_WHITE-SPORTYNAVY.png.avif
  7. BIN
      shop/static/shop/images/products/PS_PA4030_SPORTYNAVY-WHITE.png.avif
  8. BIN
      shop/static/shop/images/products/PS_PA4031_WHITE-SPORTYNAVY.png.avif
  9. BIN
      shop/static/shop/images/products/hoodie_h.jpeg

@ -9,15 +9,16 @@ class Command(BaseCommand):
# Create colors
self.stdout.write('Creating colors...')
colors = [
{'name': 'Black', 'hex': '#000000', 'secondary_hex': None},
{'name': 'White', 'hex': '#FFFFFF', 'secondary_hex': None},
{'name': 'Red', 'hex': '#FF0000', 'secondary_hex': None},
{'name': 'Blue', 'hex': '#0000FF', 'secondary_hex': None},
{'name': 'Green', 'hex': '#00FF00', 'secondary_hex': None},
{'name': 'Yellow', 'hex': '#FFFF00', 'secondary_hex': None},
{'name': 'Black/White', 'hex': '#000000', 'secondary_hex': '#FFFFFF'},
{'name': 'Red/Blue', 'hex': '#FF0000', 'secondary_hex': '#0000FF'},
{'name': 'Green/Yellow', 'hex': '#00FF00', 'secondary_hex': '#FFFF00'}
{'name': 'Noir', 'hex': '#333333', 'secondary_hex': None},
{'name': 'Noir / Gris Foncé Chiné', 'hex': '#000000', 'secondary_hex': '#4D4D4D'},
{'name': 'Bleu Sport', 'hex': '#112B44', 'secondary_hex': None},
{'name': 'Bleu Sport / Bleu Sport Chiné', 'hex': '#112B44', 'secondary_hex': '#16395A'},
{'name': 'Bleu Sport / Blanc', 'hex': '#112B44', 'secondary_hex': '#FFFFFF'},
{'name': 'Blanc / Gris Clair', 'hex': '#FFFFFF', 'secondary_hex': '#D3D3D3'},
{'name': 'Fuchsia', 'hex': '#C1366B', 'secondary_hex': None},
{'name': 'Corail / Noir', 'hex': '#FF7F50', 'secondary_hex': '#000000'},
{'name': 'Blanc / Bleu Sport', 'hex': '#FFFFFF', 'secondary_hex': '#112B44'},
{'name': 'Blanc', 'hex': '#FFFFFF', 'secondary_hex': None},
]
color_objects = {}
@ -44,7 +45,7 @@ class Command(BaseCommand):
# Create sizes
self.stdout.write('Creating sizes...')
sizes = ['XS', 'S', 'M', 'L', 'XL', 'XXL']
sizes = ['XS', 'S', 'M', 'L', 'XL', 'XXL', '3XL', '4XL']
size_objects = {}
for name in sizes:
@ -60,37 +61,81 @@ class Command(BaseCommand):
products = [
{
'sku': 'PC001',
'title': 'Tennis Racket Pro',
'description': 'Professional grade tennis racket with advanced stability control.',
'price': 99.99,
'title': 'Padel Club Cap',
'description': 'Casquette logo centre',
'price': 25.00,
'ordering_value': 1,
'cut': 2, # Men
'colors': ['Black/White'],
'sizes': ['M', 'L', 'XL'],
'cut': 0, # Unisex
'colors': ['Blanc', 'Bleu Sport', 'Noir'],
'sizes': [],
'image_filename': 'hat.jpg'
},
{
'sku': 'PC002',
'title': 'Sports T-Shirt',
'description': 'Breathable sports t-shirt made with moisture-wicking fabric.',
'price': 29.99,
'sku': 'PC002',
'title': 'Padel Club Hoodie F',
'description': 'Hoodie femme logo cœur et dos',
'price': 50.00,
'ordering_value': 1,
'cut': 1,
'colors': ['Blanc', 'Bleu Sport', 'Noir', 'Fuchsia'],
'sizes': ['XS', 'S', 'M', 'L', 'XL', 'XXL'],
'image_filename': 'PS_K473_WHITE.png.avif'
},
{
'sku': 'PC003',
'title': 'Padel Club Hoodie H',
'description': 'Hoodie homme logo cœur et dos',
'price': 50.00,
'ordering_value': 2,
'cut': 2,
'colors': ['Blanc', 'Bleu Sport', 'Noir', 'Fuchsia'],
'sizes': ['XS', 'S', 'M', 'L', 'XL', 'XXL', '3XL', '4XL'],
'image_filename': 'PS_K476_WHITE.png.avif'
},
{
'sku': 'PC004',
'title': 'Débardeur F',
'description': 'Débardeur femme avec logo coeur.',
'price': 20.00,
'ordering_value': 2,
'cut': 1, # Women
'colors': ['Black', 'White', 'Blue', 'Red', 'Red/Blue'],
'colors': ['Blanc / Bleu Sport', 'Noir', 'Noir / Gris Foncé Chiné'],
'sizes': ['XS', 'S', 'M', 'L', 'XL'],
'image_filename': 'tshirt.jpg'
'image_filename': 'PS_PA4031_WHITE-SPORTYNAVY.png.avif'
},
{
'sku': 'PC005',
'title': 'Jupe bicolore F',
'description': 'Avec short intégré logo jambe (sauf corail)',
'price': 30.00,
'ordering_value': 3,
'cut': 1, # Women
'colors': ['Blanc / Bleu Sport', 'Bleu Sport / Blanc', 'Corail / Noir', 'Noir / Gris Foncé Chiné'],
'sizes': ['XS', 'S', 'M', 'L', 'XL'],
'image_filename': 'PS_PA1031_WHITE-SPORTYNAVY.png.avif'
},
{
'sku': 'PC003',
'title': 'Kids Tennis Shorts',
'description': 'Comfortable tennis shorts for kids with elastic waistband.',
'price': 19.99,
'sku': 'PC006',
'title': 'T-shirt Bicolore H',
'description': 'T-shirt bicolore avec logo coeur.',
'price': 25.00,
'ordering_value': 1,
'cut': 2, # Men
'colors': ['Blanc / Bleu Sport', 'Noir', 'Noir / Gris Foncé Chiné'],
'sizes': ['S', 'M', 'L', 'XL', 'XXL', '3XL'],
'image_filename': 'tshirt_h.png'
},
{
'sku': 'PC007',
'title': 'Short Bicolore H',
'description': 'Short bicolore avec logo jambe.',
'price': 30.00,
'ordering_value': 3,
'cut': 3, # Kids
'colors': ['Blue', 'White', 'Green/Yellow'],
'sizes': ['XS', 'S', 'M'],
'image_filename': 'kids_shorts.jpg'
}
'cut': 2, # Men
'colors': ['Blanc / Bleu Sport', 'Noir', 'Noir / Gris Foncé Chiné'],
'sizes': ['S', 'M', 'L', 'XL', 'XXL', '3XL'],
'image_filename': 'PS_PA1030_WHITE-SPORTYNAVY.png.avif'
},
]
for product_data in products:

@ -10,7 +10,7 @@
height: 240px;
width: 100%;
object-fit: contain; /* This will maintain the aspect ratio of the image */
background-color: black;
background-color: white;
border-radius: 12px;
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 162 KiB

Loading…
Cancel
Save