Add function to relocate theme files in storage

Introduce `_relocate_theme_file` to handle moving files to theme-specific directories in the storage system. This ensures better organization of uploaded files by associating them with a theme ID and file type, improving maintainability and structure.
This commit is contained in:
2025-03-12 21:16:42 +01:00
parent 2993d0942c
commit 9fdf8971e3
2 changed files with 45 additions and 2 deletions

View File

@@ -11,7 +11,7 @@ from app.core.config import settings
class StorageProvider(ABC):
"""Base abstract class for storage providers."""
upload_folder: Path
@abstractmethod
async def save_file(self, file: UploadFile, destination: str) -> str:
"""Save a file to storage and return the relative path."""