This commit is contained in:
Kenneth Jannette
2024-01-31 11:19:03 -06:00
parent 5c111785db
commit 61c2407e51
2 changed files with 119 additions and 146 deletions

View File

@@ -337,7 +337,6 @@ const CreateModal = ({ setShowModal, caseData }) => {
}
/>
</Col>
<Col className="mb-3">
{isEditing ? (
<div className="edit-modal-label">Plaintiff(s)</div>
@@ -362,144 +361,6 @@ const CreateModal = ({ setShowModal, caseData }) => {
/>
</Col>
</Row>
<Row>
<Col className="mb-3">
{isEditing ? (
<div className="edit-modal-label">Contact name</div>
) : (
<></>
)}
<TextInput
key={"contactName"}
name={"contactName"}
value={data.contactName.value}
error={data.contactName.error}
message={data.contactName.message}
disabled={isBusy}
onChange={(e) => handleChangeInput(e, "contactName")}
label={
data.contactName.value.length === 0
? isEditing
? caseData.contactName
: "Contact Name"
: ""
}
/>
</Col>
<Col className="mb-3"></Col>
</Row>
<Row>
<Col className="mb-3">
{isEditing ? (
<div className="edit-modal-label">Case type</div>
) : (
<></>
)}
<TextInput
key={"caseType"}
name={"caseType"}
value={data.caseType.value}
error={data.caseType.error}
message={data.caseType.message}
disabled={isBusy}
onChange={(e) => handleChangeInput(e, "caseType")}
label={
data.caseType.value.length === 0
? isEditing
? caseData.caseType
: "Case Type"
: ""
}
/>
</Col>
<Col className="mb-3">
{isEditing ? (
<div className="edit-modal-label">Contact email</div>
) : (
<></>
)}
<TextInput
key={"contactEmail"}
name={"contactEmail"}
value={data.contactEmail.value}
error={data.contactEmail.error}
message={data.contactEmail.message}
disabled={isBusy}
onChange={(e) => handleChangeInput(e, "contactEmail")}
label={
data.contactEmail.value.length === 0
? isEditing
? caseData.contactEmail
: "Contact Email"
: ""
}
/>
</Col>
</Row>
<Row>
<Col>
<div className="radio-group-wrapper">
<Radiogroup
title="Client position"
options={radioOptions}
value={data.clientPosition.value}
disabled={isBusy}
onClick={(e) => handleChangeInput(e, "clientPosition")}
/>
</div>
</Col>
<Col className="mb-3">
{isEditing ? (
<div className="edit-modal-label">Billing code</div>
) : (
<></>
)}
<TextInput
key={"billingCode"}
name={"billingCode"}
value={data.billingCode.value}
error={data.billingCode.error}
message={data.billingCode.message}
disabled={isBusy}
onChange={(e) => handleChangeInput(e, "billingCode")}
label={
data.billingCode.value.length === 0
? isEditing
? caseData.billingCode
: "Billing Code"
: ""
}
/>
</Col>
</Row>
<Row>
<Col className="mb-3">
{isEditing ? (
<div className="edit-modal-label">Lead attorney</div>
) : (
<></>
)}
<TextInput
key={"leadAttorneys"}
name={"leadAttorneys"}
value={data.leadAttorneys.value}
error={data.leadAttorneys.error}
message={data.leadAttorneys.message}
disabled={isBusy}
onChange={(e) => handleChangeInput(e, "leadAttorneys")}
label={
data.leadAttorneys.value.length === 0
? isEditing
? caseData.leadAttorneys
: "Lead Attornery(s)"
: ""
}
/>
</Col>
<Col></Col>
</Row>
</Form>
</>
);
@@ -531,3 +392,114 @@ const CreateModal = ({ setShowModal, caseData }) => {
};
export default CreateModal;
/*
<Col className="mb-3">
{isEditing ? (
<div className="edit-modal-label">Contact name</div>
) : (
<></>
)}
<TextInput
key={"contactName"}
name={"contactName"}
value={data.contactName.value}
error={data.contactName.error}
message={data.contactName.message}
disabled={isBusy}
onChange={(e) => handleChangeInput(e, "contactName")}
label={
data.contactName.value.length === 0
? isEditing
? caseData.contactName
: "Contact Name"
: ""
}
/>
</Col>
<Col className="mb-3">
{isEditing ? (
<div className="edit-modal-label">Case type</div>
) : (
<></>
)}
<TextInput
key={"caseType"}
name={"caseType"}
value={data.caseType.value}
error={data.caseType.error}
message={data.caseType.message}
disabled={isBusy}
onChange={(e) => handleChangeInput(e, "caseType")}
label={
data.caseType.value.length === 0
? isEditing
? caseData.caseType
: "Case Type"
: ""
}
/>
</Col>
<Col>
<div className="radio-group-wrapper">
<Radiogroup
title="Client position"
options={radioOptions}
value={data.clientPosition.value}
disabled={isBusy}
onClick={(e) => handleChangeInput(e, "clientPosition")}
/>
</div>
</Col>
<Col className="mb-3">
{isEditing ? (
<div className="edit-modal-label">Billing code</div>
) : (
<></>
)}
<TextInput
key={"billingCode"}
name={"billingCode"}
value={data.billingCode.value}
error={data.billingCode.error}
message={data.billingCode.message}
disabled={isBusy}
onChange={(e) => handleChangeInput(e, "billingCode")}
label={
data.billingCode.value.length === 0
? isEditing
? caseData.billingCode
: "Billing Code"
: ""
}
/>
</Col>
<Col className="mb-3">
{isEditing ? (
<div className="edit-modal-label">Lead attorney</div>
) : (
<></>
)}
<TextInput
key={"leadAttorneys"}
name={"leadAttorneys"}
value={data.leadAttorneys.value}
error={data.leadAttorneys.error}
message={data.leadAttorneys.message}
disabled={isBusy}
onChange={(e) => handleChangeInput(e, "leadAttorneys")}
label={
data.leadAttorneys.value.length === 0
? isEditing
? caseData.leadAttorneys
: "Lead Attornery(s)"
: ""
}
/>
</Col>
*/