feat(project): add Project entity and ProjectRepository interface

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
openclaw 2026-03-23 16:03:03 +00:00
parent c4b33850fb
commit a4b7e1ca7a
2 changed files with 32 additions and 0 deletions

View File

@ -0,0 +1,11 @@
from dataclasses import dataclass
from datetime import datetime
@dataclass
class Project:
id: str
name: str
design_dir: str
code_dir: str | None
created_at: datetime

View File

@ -0,0 +1,21 @@
from abc import ABC, abstractmethod
from app.modules.project.domain.entities import Project
class ProjectRepository(ABC):
@abstractmethod
def list_all(self) -> list[Project]:
...
@abstractmethod
def get_by_id(self, project_id: str) -> Project | None:
...
@abstractmethod
def save(self, project: Project) -> None:
...
@abstractmethod
def delete(self, project_id: str) -> None:
...