fix: 公积金基数上下限独立于社保

问题:SocialYearStandard 只有一套 baseMin/baseMax,社保和公积金
共用,但公积金下限通常是最低工资标准(如北京2420),远低于社保
下限(如北京6326)。

修复:
- SocialYearStandard 新增 housingBaseMin/housingBaseMax 字段
- clampHousingFundBase 优先用公积金专用上下限,为0时回退到社保
- calcHousingFund 同样优先用公积金专用上下限
- 前端公积金年度标准表单加公积金基数上下限输入
- 前端公积金当前标准展示用公积金专用上下限

同时修复 blank_employees/blank_all 模式跳过试用期工资覆盖

Generated with [Devin](https://devin.ai)

Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
This commit is contained in:
selfrelease
2026-08-16 15:23:08 +08:00
parent 94959522df
commit c3ca2c9f50
5 changed files with 19 additions and 4 deletions
@@ -52,6 +52,7 @@ export function AccountCard({
// 公积金字段
accountType: account.accountType || 'BASIC',
housingOrg: 12, housingEmp: 12,
housingBaseMin: 0, housingBaseMax: 0,
})
// 查询当前年度标准(展开时才查询)
@@ -331,8 +332,8 @@ export function AccountCard({
)}
<div className="grid md:grid-cols-4 gap-3 text-sm">
<div className="flex justify-between border-b pb-1.5"><span className="text-gray-500"></span><span className="font-medium">{config.accountType === 'SUPPLEMENTARY' ? '补充公积金' : '基本公积金'}</span></div>
<div className="flex justify-between border-b pb-1.5"><span className="text-gray-500"></span><span className="font-medium">¥{fmt(config.baseMin)}</span></div>
<div className="flex justify-between border-b pb-1.5"><span className="text-gray-500"></span><span className="font-medium">¥{fmt(config.baseMax)}</span></div>
<div className="flex justify-between border-b pb-1.5"><span className="text-gray-500"></span><span className="font-medium">¥{fmt(config.housingBaseMin > 0 ? config.housingBaseMin : config.baseMin)}</span></div>
<div className="flex justify-between border-b pb-1.5"><span className="text-gray-500"></span><span className="font-medium">¥{fmt(config.housingBaseMax > 0 ? config.housingBaseMax : config.baseMax)}</span></div>
<div className="flex justify-between border-b pb-1.5"><span className="text-gray-500">()</span><span className="font-medium">{config.housingOrg}%</span></div>
<div className="flex justify-between border-b pb-1.5"><span className="text-gray-500">()</span><span className="font-medium">{config.housingEmp}%</span></div>
</div>
@@ -610,6 +611,8 @@ export function AccountCard({
</div>
<div><Label>(%)</Label><Input type="number" step="0.1" value={newVersion.housingOrg} onChange={(e) => setNewVersion({ ...newVersion, housingOrg: Number(e.target.value) })} /></div>
<div><Label>(%)</Label><Input type="number" step="0.1" value={newVersion.housingEmp} onChange={(e) => setNewVersion({ ...newVersion, housingEmp: Number(e.target.value) })} /></div>
<div><Label></Label><Input type="number" value={newVersion.housingBaseMin} onChange={(e) => setNewVersion({ ...newVersion, housingBaseMin: Number(e.target.value) })} placeholder="0=用社保下限" /><p className="text-xs text-gray-400 mt-1">0 使</p></div>
<div><Label></Label><Input type="number" value={newVersion.housingBaseMax} onChange={(e) => setNewVersion({ ...newVersion, housingBaseMax: Number(e.target.value) })} placeholder="0=用社保上限" /><p className="text-xs text-gray-400 mt-1">0 使</p></div>
</div>
</>
) : (