Skip to content

Commit

Permalink
Added BPAp2
Browse files Browse the repository at this point in the history
  • Loading branch information
Sriranjan Srivastava authored and Sriranjan Srivastava committed Mar 13, 2024
1 parent 4798816 commit 6041bfb
Show file tree
Hide file tree
Showing 3 changed files with 70 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -477,15 +477,15 @@ if(propertyData?.owners.length >0)

useEffect(()=>{
let propertyData =JSON.parse(sessionStorage.getItem("Digit_OBPS_PT"))
if(propertyData.owners.length == 1)
if(propertyData?.owners?.length == 1)
{let value ={
"code": "INDIVIDUAL.SINGLEOWNER",
"active": true,
"i18nKey": "COMMON_MASTERS_OWNERSHIPCATEGORY_INDIVIDUAL_SINGLEOWNER"
}
selectedValue(value);
}
else if(propertyData.owners.length > 1)
else if(propertyData?.owners?.length > 1)
{
let value={
"code": "INDIVIDUAL.MULTIPLEOWNERS",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,18 @@
import {
Card, CardHeader, CardSubHeader, CardText,
Card, CardHeader, CardSubHeader, CardText,TextInput,CardLabel,
CitizenInfoLabel, Header, LinkButton, Row, StatusTable, SubmitBar, Table, CardSectionHeader, EditIcon, PDFSvg, Loader
} from "@upyog/digit-ui-react-components";
import React,{ useMemo } from "react";
import React,{ useMemo, useState } from "react";
import { useTranslation } from "react-i18next";
import { useHistory, useRouteMatch } from "react-router-dom";
import Timeline from "../../../components/Timeline";
import { convertEpochToDateDMY, stringReplaceAll, getOrderDocuments } from "../../../utils";
import DocumentsPreview from "../../../../../templates/ApplicationDetails/components/DocumentsPreview";

const CheckPage = ({ onSubmit, value }) => {
const [development, setDevelopment] = useState()
const [otherCharges, setOtherCharges] = useState()
const [lessAdjusment, setLessAdjusment] = useState()
const { t } = useTranslation();
const history = useHistory();
const match = useRouteMatch();
Expand Down Expand Up @@ -324,16 +327,65 @@ import {
<Card style={{paddingRight:"16px"}}>
<CardSubHeader>{t("BPA_SUMMARY_FEE_EST")}</CardSubHeader>
<StatusTable>
{paymentDetails?.Bill[0]?.billDetails[0]?.billAccountDetails.map((bill,index)=>(
{/* {paymentDetails?.Bill[0]?.billDetails[0]?.billAccountDetails.map((bill,index)=>(
<div key={index}>
<Row className="border-none" label={t(`${bill.taxHeadCode}`)} text={`₹ ${bill?.amount}`} />
</div>
))}
<Row className="border-none" label={t(`BPA_COMMON_TOTAL_AMT`)} text={`₹ ${paymentDetails?.Bill?.[0]?.billDetails[0]?.amount || "0"}`} />
))} */}
{/* <Row className="border-none" label={t(`BPA_COMMON_TOTAL_AMT`)} text={`₹ ${paymentDetails?.Bill?.[0]?.billDetails[0]?.amount || "0"}`} /> */}
<CardSubHeader>{t("BPA_P1_SUMMARY_FEE_EST")}</CardSubHeader>
<Row className="border-none" label={t(`BPA_COMMON_P1_AMT`)} text={`₹ ${data?.boundaryWallLength*2.5 + 400 * 2.5}`} />
<CardSubHeader>{t("BPA_P2_SUMMARY_FEE_EST")}</CardSubHeader>

<Row className="border-none" label={t(`BPA_COMMON_MALBA_AMT`)} text={`₹ ${"100"}`} />
<Row className="border-none" label={t(`BPA_COMMON_LABOUR_AMT`)} text={`₹ ${"0"}`} />
<Row className="border-none" label={t(`BPA_COMMON_WATER_AMT`)} text={`₹ ${"50"}`} />
<Row className="border-none" label={t(`BPA_COMMON_GAUSHALA_AMT`)} text={`₹ ${"50"}`} />
<CardSubHeader>{t("BPA_P2_SUMMARY_FEE_EST_MANUAL")}</CardSubHeader>
<CardLabel>{t("BPA_COMMON_DEVELOPMENT_AMT")}</CardLabel>
<TextInput
t={t}
type={"text"}
isMandatory={false}
optionKey="i18nKey"
name="email"
value={development}
onChange={(e) => {setDevelopment(e.target.value),sessionStorage.setItem("development",e.target.value)}}
//disable={userInfo?.info?.emailId && !isOpenLinkFlow ? true : false}
//disable={editScreen}
//{...{ required: true, pattern: "[A-Za-z0-9._%+-]+@[a-z0-9.-]+\.[a-z]{2,4}$", type: "email", title: t("CORE_COMMON_APPLICANT_MOBILE_NUMBER_INVALID") }}
/>
<CardLabel>{t("BPA_COMMON_OTHER_AMT")}</CardLabel>
<TextInput
t={t}
type={"text"}
isMandatory={false}
optionKey="i18nKey"
name="email"
value={otherCharges}
onChange={(e) => {setOtherCharges(e.target.value),sessionStorage.setItem("otherCharges",e.target.value)}}
//disable={userInfo?.info?.emailId && !isOpenLinkFlow ? true : false}
//disable={editScreen}
//{...{ required: true, pattern: "[A-Za-z0-9._%+-]+@[a-z0-9.-]+\.[a-z]{2,4}$", type: "email", title: t("CORE_COMMON_APPLICANT_MOBILE_NUMBER_INVALID") }}
/>
<CardLabel>{t("BPA_COMMON_LESS_AMT")}</CardLabel>
<TextInput
t={t}
type={"text"}
isMandatory={false}
optionKey="i18nKey"
name="email"
value={lessAdjusment}
onChange={(e) => {setLessAdjusment(e.target.value),sessionStorage.setItem("lessAdjusment",e.target.value)}}
//disable={userInfo?.info?.emailId && !isOpenLinkFlow ? true : false}
//disable={editScreen}
//{...{ required: true, pattern: "[A-Za-z0-9._%+-]+@[a-z0-9.-]+\.[a-z]{2,4}$", type: "email", title: t("CORE_COMMON_APPLICANT_MOBILE_NUMBER_INVALID") }}
/>

</StatusTable>
<hr style={{color:"#cccccc",backgroundColor:"#cccccc",height:"2px",marginTop:"20px",marginBottom:"20px"}}/>
<CardHeader>{t("BPA_COMMON_TOTAL_AMT")}</CardHeader>
<CardHeader>{paymentDetails?.Bill?.[0]?.billDetails[0]?.amount || "0"}</CardHeader>
{/* <CardHeader>{t("BPA_COMMON_TOTAL_AMT")}</CardHeader>
<CardHeader>₹ {paymentDetails?.Bill?.[0]?.billDetails[0]?.amount || "0"}</CardHeader> */}
<SubmitBar label={t("BPA_SEND_TO_CITIZEN_LABEL")} onSubmit={onSubmit} />
</Card>
</React.Fragment>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -407,6 +407,15 @@ export const convertToBPAObject = (data, isOCBPA = false, isSendBackTOCitizen =
auditDetails: data?.auditDetails,
additionalDetails: {
...data?.additionalDetails,
selfCertificationCharges:[
{"BPA_MALBA_CHARGES" : 100},
{"BPA_LABOUR_CESS": 0},
{"BPA_WATER_CHARGES":50},
{"BPA_GAUSHALA_CHARGES_CESS":50},
{"BPA_LESS_ADJUSMENT_PLOT":sessionStorage.getItem("development")},
{"BPA_DEVELOPMENT_CHARGES":sessionStorage.getItem("lessAdjusment")},
{"BPA_OTHER_CHARGES":sessionStorage.getItem("otherCharges")}
],
GISPlaceName : data?.address?.placeName,
holdingNo: data?.data?.holdingNumber ? data?.data?.holdingNumber : data?.additionalDetails?.holdingNo,
boundaryWallLength:data?.data?.boundaryWallLength ? data?.data?.boundaryWallLength : data?.additionalDetails?.boundaryWallLength ,
Expand Down

0 comments on commit 6041bfb

Please sign in to comment.