目录重组:后端按core/domains分领域存放(仅移动与更新引用)

- 50个后端模块用git mv移入core/与domains/<领域>/,入口server.js、launch.js、restore.js及server/原位不动
- 所有require路径由脚本按新旧位置统一换算(后端、server/、测试)
- 新增test/app-paths.test.js,锁定默认数据目录、public目录与飞书配置文件的绝对位置
- 维护与部署.md补充目录说明并更新模块路径

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
黄健铭andClaude Opus 5.5 committed 2026-12-04 13:01:19 -08:00
1 parent 95c481c74a
commit 9ec37196d4
172 files changed
+458 -384

No files matched your search

+3 -3
View File
@@ -5,7 +5,7 @@ const { test } = require('node:test'),
fs = require('node:fs'),
os = require('node:os'),
path = require('node:path');
const { Ledger, today } = require('../ledger'),
const { Ledger, today } = require('../core/ledger'),
{ createApp } = require('../server');
const D = '2026-10-20',
D2 = '2026-10-21',
@@ -923,10 +923,10 @@ test('多商品差重合计只耗用一次料池,余料只生成一笔购料
const r = f.create(exchange({}, { products, cost_material: { mode: 'pool', poolId: D } }));
assert.equal(f.l.materialPoolDetail(D).usedMg, 10000);
assert.equal(f.l.detail(r.order_id).goodsCost, 900000);
const dto = require('../recoveries').publicDetail(f.l, r.id, f.actors.owner, f.l.businessEnv());
const dto = require('../domains/recoveries/recoveries').publicDetail(f.l, r.id, f.actors.owner, f.l.businessEnv());
assert.equal(dto.new_lines.length, 2);
assert.doesNotMatch(JSON.stringify(dto), /costLabor|laborPayer|pocket|materialCost/);
const html = require('../recovery-printing').exchangeCustomerPrintDocument(dto);
const html = require('../domains/printing/recovery-printing').exchangeCustomerPrintDocument(dto);
assert.match(html, /足金A/);
assert.match(html, /足金B/);
assert.doesNotMatch(html, /costLabor|laborPayer/);