fix(audit-20261019): T1-T9 审计修复、存储归属与审计日志列宽
- T1 资金/库存/报价/自采 P1(BIZ-1/2/3/4/10/13/14) - T2 主系统反向事件墓碑/改派/孤儿处理(BIZ-6/8/9) - T3 选分公司 ticket、trust proxy、角色权限收口(SEC-2/3/4) - T4 缺列/RLS/tenant 名单/FK/迁移执行器(DATA-1..8) - T5 401 登出/分页/映射口径/blob/ZIP 中文名(FE-1..4/BIZ-15) - T6 测试脚本目标守卫/config fail-fast/容器配置(OPS-2..8) - T7 前后端测试与 lint 门禁清零 - T8 应付卡片按关联订单日(口径 A) - T9 存储对象全链路归属校验、敏感列禁写、审计 target_id 超长修复
This commit is contained in:
@@ -17,7 +17,7 @@ import { ensureCustomerStatementAfterOrderComplete, ensureSupplierStatementsForO
|
||||
import { postProcessingLaborCost } from './operationCostPostingService';
|
||||
import { finalizeInspectionPhotosToResultFolder } from './storageUploadService';
|
||||
import { getStorageProvider } from './storageProvider';
|
||||
import { buildSignedStoragePath } from './storageSignedUrl';
|
||||
import { buildSignedStoragePathForCtxChecked } from './storageObjectOwnership';
|
||||
import { loadArchivedPhotoMap } from './inspectionPhotoArchiveService';
|
||||
import { orderCodeActiveExistsSql } from './orderTrashScope';
|
||||
import { isOrderCodeSearch } from '../utils/orderCodeQuery';
|
||||
@@ -59,14 +59,19 @@ async function signedExistingProcessingPhotos(
|
||||
: new Map();
|
||||
|
||||
const out: Array<{ path: string; url: string; archived?: boolean; archive_month?: string }> = [];
|
||||
paths.forEach((path, index) => {
|
||||
for (const [index, path] of paths.entries()) {
|
||||
if (existsFlags[index]) {
|
||||
out.push({ path, url: buildSignedStoragePath(PROCESSING_INSPECTION_PHOTO_BUCKET, path) });
|
||||
return;
|
||||
// T9F-5:旧 key 先异步反查归属再签;跨租户 key 不返回 URL
|
||||
try {
|
||||
out.push({ path, url: await buildSignedStoragePathForCtxChecked(undefined, PROCESSING_INSPECTION_PHOTO_BUCKET, path) });
|
||||
} catch {
|
||||
out.push({ path, url: '' });
|
||||
}
|
||||
continue;
|
||||
}
|
||||
const archived = archivedMap.get(path);
|
||||
if (archived) out.push({ path, url: '', archived: true, archive_month: archived.ym });
|
||||
});
|
||||
}
|
||||
return out;
|
||||
}
|
||||
|
||||
@@ -1117,6 +1122,7 @@ export async function submitProcessingInspection(input: {
|
||||
photos: existingPhotos,
|
||||
productName: row.item_name || row.sku_code,
|
||||
skuCode: row.sku_code,
|
||||
ctx: { branchCode: row.branch_code },
|
||||
})
|
||||
: null;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user