diff --git a/apps/admin-web/src/pages/AdminMembershipPlanPage.tsx b/apps/admin-web/src/pages/AdminMembershipPlanPage.tsx index f32e02c72..0f00bdf3d 100644 --- a/apps/admin-web/src/pages/AdminMembershipPlanPage.tsx +++ b/apps/admin-web/src/pages/AdminMembershipPlanPage.tsx @@ -110,11 +110,16 @@ export function AdminMembershipPlanPage({ const normalizedYearPriceCents = parsePositiveInteger(yearPriceCents); const normalizedConcurrentJobLimit = parsePositiveInteger(concurrentJobLimit); + const normalizedPeriodPoints = parsePositiveInteger(periodPoints); if (plan !== 'normal') { if (!normalizedMonthPriceCents || !normalizedYearPriceCents) { setErrorMessage('月价与年价必须是大于 0 的整数分'); return; } + if (!normalizedPeriodPoints) { + setErrorMessage('每期泥点必须是大于 0 的整数'); + return; + } if (!normalizedConcurrentJobLimit) { setErrorMessage( `并发上限必须是大于 0 的整数;${UNLIMITED_CONCURRENT_JOB_LIMIT} 表示不设上限`, @@ -138,7 +143,7 @@ export function AdminMembershipPlanPage({ title: title.trim(), monthPriceCents: normalizedMonthPriceCents, yearPriceCents: normalizedYearPriceCents, - periodPoints: parsePositiveInteger(periodPoints), + periodPoints: normalizedPeriodPoints, modelAccess, concurrentJobLimit: normalizedConcurrentJobLimit, enabled,