fix: render pipeline + multi-tenancy bugs (B-Fix-1 through B-Fix-9)
- Remove worker-thumbnail (no Blender, was competing on thumbnail_rendering) - Move render_order_line_task to thumbnail_rendering queue (render-worker) - Restore template_service.py real implementation (fix circular import shim) - Thread tenant_id through STEP upload, Excel import, product create - Make system tables (output_types, materials, etc.) tenant_id nullable - Fix tenants frontend 307-redirect: use trailing slash /tenants/ - Remove Flamenco + Three.js from Admin UI (unsupported) - Set all output_types render_backend to celery (was flamenco) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -345,6 +345,7 @@ async def create_order(
|
||||
created_by=user.id,
|
||||
source_excel=body.source_excel,
|
||||
notes=body.notes,
|
||||
tenant_id=getattr(user, 'tenant_id', None),
|
||||
)
|
||||
db.add(order)
|
||||
await db.flush()
|
||||
@@ -364,6 +365,7 @@ async def create_order(
|
||||
lagertyp=item_data.lagertyp,
|
||||
medias_rendering=item_data.medias_rendering,
|
||||
components=[c.model_dump() for c in item_data.components],
|
||||
tenant_id=getattr(user, 'tenant_id', None),
|
||||
)
|
||||
db.add(item)
|
||||
|
||||
@@ -381,6 +383,7 @@ async def create_order(
|
||||
render_position_id=line_data.render_position_id,
|
||||
gewuenschte_bildnummer=line_data.gewuenschte_bildnummer,
|
||||
notes=line_data.notes,
|
||||
tenant_id=getattr(user, 'tenant_id', None),
|
||||
)
|
||||
db.add(line)
|
||||
|
||||
@@ -565,6 +568,7 @@ async def split_missing_step(
|
||||
created_by=order.created_by,
|
||||
source_excel=order.source_excel,
|
||||
notes=f"Split from {order.order_number} — awaiting STEP files",
|
||||
tenant_id=order.tenant_id,
|
||||
)
|
||||
db.add(new_order)
|
||||
await db.flush()
|
||||
@@ -665,6 +669,7 @@ async def generate_lines_from_items(
|
||||
product_id=product.id,
|
||||
output_type_id=type_id,
|
||||
gewuenschte_bildnummer=item.gewuenschte_bildnummer,
|
||||
tenant_id=getattr(user, 'tenant_id', None),
|
||||
)
|
||||
db.add(line)
|
||||
existing_pairs.add(pair)
|
||||
@@ -807,6 +812,7 @@ async def add_order_line(
|
||||
render_position_id=body.render_position_id,
|
||||
gewuenschte_bildnummer=body.gewuenschte_bildnummer,
|
||||
notes=body.notes,
|
||||
tenant_id=getattr(user, 'tenant_id', None),
|
||||
)
|
||||
db.add(line)
|
||||
try:
|
||||
|
||||
Reference in New Issue
Block a user