Compare commits

..
2 Commits
Author SHA1 Message Date
wc24 1f48a02083 test+chore: 修 stale 测试(_label→refs 新契约)+ bump 0.7.10
crudRegistry.test 还在断言已退场的 tagIds_label,改断言整页 refs 字典。
两端版本归一到 0.7.10。
2026-06-30 17:47:08 +08:00
wc24 0f2b4d6428 fix(pkg): 删掉 shrimp-server 对自身的 git 依赖(致 npm install OOM)
dependencies 误列了 shrimp-server 自引用(#v0.7.4)→ arborist 顺着自引用无限解析
依赖树、堆爆 OOM。真正依赖全在 peerDependencies,该块整体删除。含 0.7.6 的
isEmptyValue 递归判空。
2026-06-30 17:22:39 +08:00
2 changed files with 3 additions and 5 deletions
+1 -4
View File
@@ -1,6 +1,6 @@
{
"name": "shrimp-server",
"version": "0.7.6",
"version": "0.7.10",
"description": "Shrimp 框架后端 — 声明式字段驱动的 Node.js 管理后台框架(Express + Mongoose + JWT)",
"main": "dist/main/index.js",
"types": "dist/main/index.d.ts",
@@ -55,8 +55,5 @@
"tsx": "^4.7.0",
"typescript": "^5.3.0",
"vitest": "^1.4.0"
},
"dependencies": {
"shrimp-server": "git+http://git.zeromvc.com/wc24/shrimp-server.git#v0.7.4"
}
}
+2 -1
View File
@@ -34,6 +34,7 @@ describe("crudRegistry 自动登记", () => {
await productCrud.add({ code: "P001", tagIds: [t1._id, t2._id] } as any)
const result = await productModule.list({})
expect((result.list[0] as any).tagIds_label).toEqual(["热门", "促销"])
// _label 逐行机制已退场:relation 显示名走整页 refs 字典(refs[moduleKey][id])
expect((result as any).refs?.tag).toEqual({ [t1._id]: "热门", [t2._id]: "促销" })
})
})