16 lines
420 B
Python
16 lines
420 B
Python
"""
|
|
Rutas base y resolución de paths para layouts (importación CSV, temp, errors).
|
|
"""
|
|
from pathlib import Path
|
|
|
|
# Raíz del backend (directorio que contiene api/, core/, etc.)
|
|
BASE_DIR = Path(__file__).resolve().parent.parent
|
|
|
|
|
|
def layout_path(*parts: str) -> str:
|
|
"""Construye una ruta absoluta bajo backend/layouts/."""
|
|
p = BASE_DIR / "layouts"
|
|
for part in parts:
|
|
p = p / part
|
|
return str(p)
|