Browse Source

📝 docs(rules): update comment for relations option in generic crud

- add note that relations option supports nested associations like ['relatedEntity.client']
yourname 8 months ago
parent
commit
8d6845d4a5
1 changed files with 1 additions and 1 deletions
  1. 1 1
      .roo/rules/12-generic-crud.md

+ 1 - 1
.roo/rules/12-generic-crud.md

@@ -73,7 +73,7 @@ const yourEntityRoutes = createCrudRoutes({
   getSchema: YourEntitySchema,
   listSchema: YourEntitySchema,
   searchFields: ['name', 'description'], // 可选,指定搜索字段
-  relations: ['relatedEntity'], // 可选,指定关联查询关系
+  relations: ['relatedEntity'], // 可选,指定关联查询关系(支持嵌套关联,如 ['relatedEntity.client'])
   middleware: [authMiddleware] // 可选,添加中间件
 });