Skip to content

Commit 55e7640

Browse files
committed
add enums test
1 parent 2e2bbce commit 55e7640

1 file changed

Lines changed: 7 additions & 1 deletion

File tree

lib/model/examples/test.js

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,12 @@
22

33
module.exports = {
44

5+
// 枚举配置
6+
enums: {
7+
role: ['admin', 'user'],
8+
status: ['active', 'inactive']
9+
},
10+
511
// 定义model
612
schema:(sc)=>{
713
return {
@@ -105,4 +111,4 @@ module.exports = {
105111

106112
// 自动索引 / 慢查询统计 → 全局 ORM 层统一管理
107113
// 恢复软删除 → 全局方法注入到每个启用 softDelete 的模型
108-
}
114+
}

0 commit comments

Comments
 (0)