chore: 基线提交(重构前快照)
重构前保存现有 apps/ 结构基线,供后续各阶段回滚。 Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
from typing import Optional
|
||||
|
||||
from pydantic import BaseModel, Field
|
||||
|
||||
|
||||
# 配置项表单验证
|
||||
class ConfigItemForm(BaseModel):
|
||||
id: Optional[int] = Field(None, description="配置项ID")
|
||||
title: str = Field(..., min_length=1, max_length=150, description="配置项标题")
|
||||
code: str = Field(..., min_length=1, max_length=150, description="配置项编码")
|
||||
value: str = Field(..., min_length=1, max_length=1000, description="配置项值")
|
||||
options: Optional[str] = Field(None, max_length=1000, description="配置选项")
|
||||
config_id: int = Field(..., ge=0, description="配置ID")
|
||||
type: str = Field(..., min_length=1, max_length=150, description="配置类型")
|
||||
sort: int = Field(..., ge=0, le=99999, description="配置项排序")
|
||||
note: Optional[str] = Field(None, max_length=255, description="配置项备注")
|
||||
|
||||
|
||||
# 设置状态表单
|
||||
class ConfigItemStatusForm(BaseModel):
|
||||
id: int = Field(..., gt=0, description="配置项ID")
|
||||
status: int = Field(..., ge=1, le=2, description="配置项状态")
|
||||
Reference in New Issue
Block a user