fix: 公积金账户下拉只显示基本公积金,补充公积金下拉只显示补充

添加员工表单中:
- 公积金账户下拉:只显示 accountType !== 'SUPPLEMENTARY' 的基本公积金账户
- 补充公积金下拉:只显示 accountType === 'SUPPLEMENTARY' 的补充公积金账户

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-17 12:35:51 +08:00
parent ef685663ac
commit 61873b2581
+3 -1
View File
@@ -760,6 +760,8 @@ export function AddEmployeeModal({ onClose, onSubmit, loading, error }: {
})
// 补充公积金账户(accountType=SUPPLEMENTARY
const supplementaryHousingAccounts = allHousingAccounts.filter((a: any) => a.accountType === 'SUPPLEMENTARY')
// 基本公积金账户(accountType 非 SUPPLEMENTARY
const basicHousingAccounts = allHousingAccounts.filter((a: any) => a.accountType !== 'SUPPLEMENTARY')
// 入职日期变更 → 同步合同开始日期 + 重算结束日期
const handleHireDateChange = (hireDate: string) => {
@@ -1074,7 +1076,7 @@ export function AddEmployeeModal({ onClose, onSubmit, loading, error }: {
<Label></Label>
<Select value={manualHousingAccountId} onChange={(e) => setManualHousingAccountId(e.target.value)} disabled={!form.departmentId}>
<option value="">{form.departmentId ? '未选择' : '请先选择部门'}</option>
{allHousingAccounts.map((a: any) => (
{basicHousingAccounts.map((a: any) => (
<option key={a.id} value={a.id}>{a.name}{a.city}</option>
))}
</Select>