refactor(myapp): 重命名查询参数类以统一命名风格

- 将 ApplicationQueryParams 改为 ApplicationQueryParam
- 同步更新相关导入和函数参数类型注解
- 修改 PaginationQueryParams 为 PaginationQueryParam

refactor(demo): 重命名查询参数类以统一命名风格

- 将 DemoQueryParams 改为 DemoQueryParam
- 同步更新相关导入和函数参数类型注解
- 修改 PaginationQueryParams 为 PaginationQueryParam

refactor(gencode): 优化代码生成模块的模型和服务层结构

- 统一模型名称后缀为 Schema,调整相关引用
- 规范 Pydantic schema 的命名和定义
- 删除无用的 Python DAO 模板文件
- 调整导入路径,统一使用 app 目录下的模块路径
- 改进服务层方法签名,添加返回类型注解
- 使用自定义异常 CustomException 替代旧异常
- 统一成功响应格式为 SuccessResponse
- 优化代码生成服务中的数据库操作 DAO 调用参数传递
- 优化代码生成业务表和字段模型的字段定义,添加注释和默认值
- 优化生成代码路径处理逻辑和异常信息提示
- 整合分页查询参数定义,统一分页模型
- 修正多个服务方法的参数类型和返回类型
- 删除无用的导入和多余注释,提升代码整洁度
This commit is contained in:
zhangtao
2025-09-18 01:51:41 +08:00
parent 035efcd796
commit 019bfdf57b
69 changed files with 663 additions and 531 deletions
@@ -9,9 +9,9 @@ from app.core.router_class import OperationLogRoute
from app.core.dependencies import AuthPermission
from app.core.base_schema import BatchSetAvailable
from app.core.logger import logger
from app.core.base_params import PaginationQueryParams
from app.core.base_params import PaginationQueryParam
from ..auth.schema import AuthSchema
from .param import DeptQueryParams
from .param import DeptQueryParam
from .service import DeptService
from .schema import (
DeptCreateSchema,
@@ -24,7 +24,7 @@ DeptRouter = APIRouter(route_class=OperationLogRoute, prefix="/dept", tags=["部
@DeptRouter.get("/tree", summary="查询部门树", description="查询部门树")
async def get_dept_tree_controller(
search: DeptQueryParams = Depends(),
search: DeptQueryParam = Depends(),
auth: AuthSchema = Depends(AuthPermission(permissions=["system:dept:query"]))
) -> JSONResponse:
result_dict_list = await DeptService.get_dept_tree_service(search=search, auth=auth)