cockpit/Schemas/ProjectSchemas.py

45 lines
741 B
Python
Raw Normal View History

2023-02-23 15:39:47 +08:00
from enum import Enum, unique
2023-02-24 15:27:19 +08:00
from pydantic import BaseModel
2023-02-23 15:39:47 +08:00
@unique
class WorkStatusEnum(Enum):
enum01 = "正常"
enum02 = "出差"
enum03 = "休息"
@unique
class ProjectStatusEnum(Enum):
enum01 = "进行"
enum02 = "完成"
enum03 = "终止"
2023-02-24 15:27:19 +08:00
class EditProjectInfo(BaseModel):
project: str
client: str
client_labels: str
master: str
participants: str
departments: str
project_type: str
project_labels: str
project_status: str
start_date: str
finish_date: str
amount: str
remarks: str
class QueryProjectByDepartment(BaseModel):
department: str
page: int = 1
pagesize: int = 10
class QueryProjectByType(BaseModel):
type: str
year: str