This commit is contained in:
Kenneth Jannette
2024-02-01 16:51:13 -06:00
parent c29913b128
commit 01fa0316d0
2 changed files with 23 additions and 4 deletions

View File

@@ -18,8 +18,10 @@ import {
isFormDataHasErrors,
} from "../../Utils/Form";
import { objectMap } from "../../Utils/Object";
import { determinePlan } from "../../Utils/Miscutils";
import { signupFields } from "../../Constants/Fields/SignupFields";
import {
signupFields,
stateDataValues,
} from "../../Constants/Fields/SignupFields";
import { paymentfields } from "../../Constants/Fields/PaymentFields";
import { signupRadioFields } from "../../Constants/Fields/RadioFields";
import PaymentModal from "../Modals/PaymentModal";
@@ -152,8 +154,15 @@ const SignupPage = () => {
const fbAuthUid = authId;
const plan = selectedPlan;
const docsAllowed =
plan === "associate" ? 1 : plan === "partner" ? 3 : "unlimited";
plan === "associate"
? 1
: plan === "partner"
? 3
: plan === "unlimited"
? 4000
: 0;
const docsGenerated = 0;
const {
firstName,
lastName,
@@ -168,6 +177,10 @@ const SignupPage = () => {
email,
} = dataValues;
const userState = stateDataValues.filter((value) => {
if (value.name === state) return value;
});
const userData = {
docsAllowed,
docsGenerated,
@@ -180,7 +193,7 @@ const SignupPage = () => {
telephone,
streetAddress,
city,
state,
state: userState,
zipCode,
barNumber,
practiceArea,