fix(frontend): pass string ID to adminCompaniesApi.updateStatus

This commit is contained in:
Tiago Yamamoto 2025-12-25 21:00:01 -03:00
parent 59df524ed5
commit 39fde338b4

View file

@ -104,7 +104,7 @@ export default function AdminCompaniesPage() {
setCompanies(companies.map(c => c.id === company.id ? { ...c, [field]: newValue } : c))
try {
await adminCompaniesApi.updateStatus(Number(company.id), { [field]: newValue })
await adminCompaniesApi.updateStatus(company.id, { [field]: newValue })
toast.success(`Company ${field} updated`)
} catch (error) {
toast.error(`Failed to update ${field}`)