Improve public pages

This commit is contained in:
Urtzi Alfaro
2025-10-17 18:14:28 +02:00
parent d4060962e4
commit 7e089b80cf
46 changed files with 5734 additions and 1084 deletions

View File

@@ -112,7 +112,7 @@ async def create_stock_batches_for_ingredient(
base_date: datetime
) -> list:
"""
Create 3-5 stock batches for a single ingredient with varied properties
Create 1-2 stock batches for a single ingredient (optimized for demo performance)
Args:
db: Database session
@@ -124,7 +124,7 @@ async def create_stock_batches_for_ingredient(
List of created Stock instances
"""
stocks = []
num_batches = random.randint(3, 5)
num_batches = random.randint(1, 2) # Reduced from 3-5 for faster demo loading
for i in range(num_batches):
# Calculate expiration days offset