Rogee
|
e1f83ae469
|
feat: 重构 pkg/ast/provider 模块,优化代码组织逻辑和功能实现
## 主要改进
### 架构重构
- 将单体 provider.go 拆分为多个专门的模块文件
- 实现了清晰的职责分离和模块化设计
- 遵循 SOLID 原则,提高代码可维护性
### 新增功能
- **验证规则系统**: 实现了完整的 provider 验证框架
- **报告生成器**: 支持多种格式的验证报告 (JSON/HTML/Markdown/Text)
- **解析器优化**: 重新设计了解析流程,提高性能和可扩展性
- **错误处理**: 增强了错误处理和诊断能力
### 修复关键 Bug
- 修复 @provider(job) 注解缺失 __job 注入参数的问题
- 统一了 job 和 cronjob 模式的处理逻辑
- 确保了 provider 生成的正确性和一致性
### 代码质量提升
- 添加了完整的测试套件
- 引入了 golangci-lint 代码质量检查
- 优化了代码格式和结构
- 增加了详细的文档和规范
### 文件结构优化
```
pkg/ast/provider/
├── types.go # 类型定义
├── parser.go # 解析器实现
├── validator.go # 验证规则
├── report_generator.go # 报告生成
├── renderer.go # 渲染器
├── comment_parser.go # 注解解析
├── modes.go # 模式定义
├── errors.go # 错误处理
└── validator_test.go # 测试文件
```
### 兼容性
- 保持向后兼容性
- 支持现有的所有 provider 模式
- 优化了 API 设计和用户体验
This completes the implementation of T025-T029 tasks following TDD principles,
including validation rules implementation and critical bug fixes.
|
2025-09-19 18:58:30 +08:00 |
|
Rogee
|
82c94d5a29
|
complete route generator
|
2025-09-11 22:43:52 +08:00 |
|
Rogee
|
f2a8b9876e
|
update route
|
2025-09-11 22:40:00 +08:00 |
|
Rogee
|
76c7592f26
|
feat: 添加对 @Bind 注释中 model 字段的支持,优化路径参数绑定逻辑并更新文档
|
2025-09-11 20:10:24 +08:00 |
|
Rogee
|
b93c7726f2
|
feat: 更新 @Bind 注释语法,移除 table 参数,优化文档内容
|
2025-09-11 19:28:51 +08:00 |
|
Rogee
|
9c910b6ede
|
refactor: 统一代码格式,优化代码可读性
|
2025-09-11 19:22:47 +08:00 |
|
Rogee
|
344798163b
|
feat: 重构路由渲染逻辑,添加构建渲染数据和模板渲染功能,优化代码结构
|
2025-09-11 19:14:44 +08:00 |
|
Rogee
|
c0d8f070e4
|
feat: 重构事件处理,添加默认通道和发布逻辑,移除不必要的提供者
|
2025-09-11 14:51:40 +08:00 |
|
Rogee
|
384b723f51
|
feat: update
|
2025-09-10 15:55:51 +08:00 |
|
Rogee
|
0d05d70fb1
|
feat: 更新模块路径为 v2,修正文档和代码中的相关引用
|
2025-09-10 14:54:16 +08:00 |
|
Rogee
|
3759295afa
|
feat: update tools
|
2025-05-28 19:39:32 +08:00 |
|
Rogee
|
099bdfc7d9
|
feat: update tools
|
2025-05-28 19:38:03 +08:00 |
|
Rogee
|
3b902509f7
|
feat: update
|
2025-05-27 09:47:24 +08:00 |
|
Rogee
|
ec1fa93033
|
feat: update
|
2025-05-26 12:17:52 +08:00 |
|
Rogee
|
2b0ee0e61c
|
feat: add table vars to model provider
|
2025-05-26 10:13:30 +08:00 |
|
Rogee
|
906858dbd6
|
feat: update
|
2025-05-23 23:42:18 +08:00 |
|
Rogee
|
b4cc2347e5
|
feat: update
|
2025-05-23 22:59:18 +08:00 |
|
yanghao05
|
1147ca4733
|
feat: update
|
2025-05-23 22:47:15 +08:00 |
|
yanghao05
|
cd7c13e49d
|
feat: update
|
2025-05-23 22:46:39 +08:00 |
|
yanghao05
|
e5000bcc73
|
feat: update
|
2025-05-23 22:45:36 +08:00 |
|
yanghao05
|
9ddea39084
|
feat: add table functions
|
2025-05-23 22:27:15 +08:00 |
|
yanghao05
|
e83332ea6a
|
feat: support softdelete in table functions
|
2025-05-23 22:24:53 +08:00 |
|
yanghao05
|
ab36ea0e5d
|
feat: update
|
2025-05-23 22:21:28 +08:00 |
|
yanghao05
|
c6b1a1664c
|
feat: update
|
2025-05-23 22:07:26 +08:00 |
|
yanghao05
|
f9a32a9ecb
|
feat: update
|
2025-05-23 22:06:22 +08:00 |
|
yanghao05
|
56ec95e43a
|
feat: update
|
2025-05-23 22:03:33 +08:00 |
|
yanghao05
|
3617c68a91
|
feat: update
|
2025-05-23 22:02:36 +08:00 |
|
yanghao05
|
8277c79d23
|
feat: add table funcs
|
2025-05-23 22:00:54 +08:00 |
|
yanghao05
|
fb5115a1d4
|
feat: update
|
2025-05-23 21:35:50 +08:00 |
|
yanghao05
|
3340ce3521
|
feat: update
|
2025-05-23 21:35:00 +08:00 |
|
yanghao05
|
6762bea530
|
feat: update
|
2025-05-23 19:50:54 +08:00 |
|
yanghao05
|
0758badc81
|
feat: update gen_model to support provider
|
2025-05-23 19:31:34 +08:00 |
|
rogeecn
|
34c05d52a2
|
fix: model
|
2025-03-22 19:27:42 +08:00 |
|
rogeecn
|
501af58e66
|
feat: add transformer for model
|
2025-03-22 18:23:26 +08:00 |
|
rogeecn
|
0015e2eee2
|
fix: issues
|
2025-03-21 19:25:58 +08:00 |
|
Rogee
|
aeae94a7d2
|
feat: update cronjob
|
2025-03-15 21:23:41 +08:00 |
|
rogeecn
|
b7fcf2c3e6
|
feat: update cronjob ast
|
2025-03-11 09:59:36 +08:00 |
|
rogeecn
|
de2ddef3af
|
fix: job
|
2025-03-11 09:56:22 +08:00 |
|
rogeecn
|
ad7f1b2c47
|
feat: add db
|
2025-02-28 10:26:54 +08:00 |
|
Rogee
|
e2b09420a0
|
feat: remove module command
|
2025-02-13 18:44:23 +08:00 |
|
Rogee
|
fcae9f2e3f
|
feat: update pkg name
|
2025-02-11 15:53:14 +08:00 |
|
Rogee
|
0a420a2987
|
feat: modify pkg name
|
2025-02-11 15:38:59 +08:00 |
|
Rogee
|
266c2c4767
|
fix: issues
|
2025-02-10 15:10:39 +08:00 |
|
Rogee
|
1e03cf6038
|
feat: update route generate
|
2025-01-15 10:44:07 +08:00 |
|
Rogee
|
307c99b9e5
|
fix: issues
|
2025-01-14 11:10:16 +08:00 |
|
Rogee
|
36e52541dd
|
fix: param
|
2025-01-10 16:15:50 +08:00 |
|
Rogee
|
9d6edc60a9
|
fix: params order
|
2025-01-10 16:00:17 +08:00 |
|
Rogee
|
e66049da6c
|
fix: bind issues
|
2025-01-10 15:56:31 +08:00 |
|
Rogee
|
2eef4c35f4
|
fix: route issue
|
2025-01-10 14:27:40 +08:00 |
|
Rogee
|
bd6d6bc6e8
|
fix: provider generation issues
|
2025-01-09 11:05:03 +08:00 |
|