2f1e339413
根因:socialInsBase || baseSalary 中 0 是 falsy,导致基数为0 的劳务协议/实习人员回退到基本工资计算社保。 修复:改为 nullish check(!= null),区分"明确设置为0" 和"未设置(null)": - socialInsBase = 0 → 用 0(劳务协议不交社保) - socialInsBase = null → 用 baseSalary(回退) - socialInsBase = 5000 → 用 5000(核定基数) 涉及文件: - payroll.service.ts calcBatchEntry + prePayrollCheck - payroll.routes.ts 旧版薪资计算 Generated with [Devin](https://devin.ai) Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>