test(db): 添加 OR 条件处理的单元测试并修复 WHERE 子句逻辑
- 添加了 TestWhereWithORCondition 测试函数验证 OR 条件的括号包裹 - 修复了 where.go 中条件计数变量名称从 normalCondCount 改为 condCount - 实现了 OR/AND 组条件的括号包裹逻辑确保 SQL 语法正确 - 添加了空条件检查避免生成无效的 SQL 片段 - 更新了 .gitignore 文件添加日志文件忽略规则
This commit is contained in:
+2
-1
@@ -2,4 +2,5 @@
|
||||
.idea
|
||||
/example/tpt/demo/
|
||||
*.exe
|
||||
/example/config
|
||||
/example/config
|
||||
/.cursor/*.log
|
||||
|
||||
Reference in New Issue
Block a user