@mseva/digit-ui-module-rentandlease 1.0.51-dev.1 → 1.0.51-dev.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +16 -15
- package/dist/index.modern.js.map +1 -1
- package/package.json +2 -2
package/dist/index.modern.js
CHANGED
|
@@ -7618,7 +7618,6 @@ const RALApplicationDetails = () => {
|
|
|
7618
7618
|
setLoader(false);
|
|
7619
7619
|
}
|
|
7620
7620
|
};
|
|
7621
|
-
console.log('applicationData', applicationData);
|
|
7622
7621
|
const {
|
|
7623
7622
|
data: reciept_data,
|
|
7624
7623
|
isLoading: recieptDataLoading
|
|
@@ -7721,7 +7720,6 @@ const RALApplicationDetails = () => {
|
|
|
7721
7720
|
return t(value);
|
|
7722
7721
|
};
|
|
7723
7722
|
const rawAdditionalDetails = (applicationData === null || applicationData === void 0 ? void 0 : applicationData.additionalDetails) || {};
|
|
7724
|
-
console.log("rawAdditionalDetails", rawAdditionalDetails);
|
|
7725
7723
|
const propertyDetails = Array.isArray(rawAdditionalDetails === null || rawAdditionalDetails === void 0 ? void 0 : rawAdditionalDetails.propertyDetails) ? rawAdditionalDetails === null || rawAdditionalDetails === void 0 ? void 0 : rawAdditionalDetails.propertyDetails[0] : rawAdditionalDetails === null || rawAdditionalDetails === void 0 ? void 0 : rawAdditionalDetails.propertyDetails;
|
|
7726
7724
|
const arrearDoc = rawAdditionalDetails !== null && rawAdditionalDetails !== void 0 && rawAdditionalDetails.arrearDoc ? [{
|
|
7727
7725
|
documentType: "Arrear Doc",
|
|
@@ -7809,7 +7807,7 @@ const RALApplicationDetails = () => {
|
|
|
7809
7807
|
}), (applicationData === null || applicationData === void 0 ? void 0 : applicationData.amountToBeDeducted) > 0 && /*#__PURE__*/React.createElement(Row, {
|
|
7810
7808
|
label: t("RAL_PROPERTY_PENALTY"),
|
|
7811
7809
|
text: tValue(applicationData === null || applicationData === void 0 ? void 0 : applicationData.amountToBeDeducted)
|
|
7812
|
-
}), /*#__PURE__*/React.createElement(Row, {
|
|
7810
|
+
}), (rawAdditionalDetails === null || rawAdditionalDetails === void 0 ? void 0 : rawAdditionalDetails.applicationType) !== "Legacy" && /*#__PURE__*/React.createElement(Row, {
|
|
7813
7811
|
label: t("SECURITY_DEPOSIT"),
|
|
7814
7812
|
text: tValue(propertyDetails === null || propertyDetails === void 0 ? void 0 : propertyDetails.securityDeposit)
|
|
7815
7813
|
}), (applicationData === null || applicationData === void 0 ? void 0 : applicationData.amountToBeDeducted) - (propertyDetails === null || propertyDetails === void 0 ? void 0 : propertyDetails.securityDeposit) > 0 && /*#__PURE__*/React.createElement(Row, {
|
|
@@ -9520,7 +9518,6 @@ const RALApplicationDetails$1 = () => {
|
|
|
9520
9518
|
});
|
|
9521
9519
|
}
|
|
9522
9520
|
};
|
|
9523
|
-
console.log("rawAdditionalDetails", rawAdditionalDetails);
|
|
9524
9521
|
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("div", {
|
|
9525
9522
|
className: "cardHeaderWithOptions ral-app-details-header"
|
|
9526
9523
|
}, /*#__PURE__*/React.createElement(Header, {
|
|
@@ -9600,7 +9597,7 @@ const RALApplicationDetails$1 = () => {
|
|
|
9600
9597
|
}), (applicationData === null || applicationData === void 0 ? void 0 : applicationData.amountToBeDeducted) > 0 && /*#__PURE__*/React.createElement(Row, {
|
|
9601
9598
|
label: t("RAL_PROPERTY_PENALTY"),
|
|
9602
9599
|
text: tValue(applicationData === null || applicationData === void 0 ? void 0 : applicationData.amountToBeDeducted)
|
|
9603
|
-
}), /*#__PURE__*/React.createElement(Row, {
|
|
9600
|
+
}), (rawAdditionalDetails === null || rawAdditionalDetails === void 0 ? void 0 : rawAdditionalDetails.applicationType) !== "Legacy" && /*#__PURE__*/React.createElement(Row, {
|
|
9604
9601
|
label: t("SECURITY_DEPOSIT"),
|
|
9605
9602
|
text: tValue(propertyDetails === null || propertyDetails === void 0 ? void 0 : propertyDetails.securityDeposit)
|
|
9606
9603
|
}), (applicationData === null || applicationData === void 0 ? void 0 : applicationData.amountToBeDeducted) - (propertyDetails === null || propertyDetails === void 0 ? void 0 : propertyDetails.securityDeposit) > 0 && /*#__PURE__*/React.createElement(Row, {
|
|
@@ -11313,7 +11310,6 @@ const ChallanDocuments = ({
|
|
|
11313
11310
|
};
|
|
11314
11311
|
useEffect(() => {
|
|
11315
11312
|
if (documents) onSelect(documents);
|
|
11316
|
-
console.log("documents", documents);
|
|
11317
11313
|
}, [documents]);
|
|
11318
11314
|
useEffect(() => {
|
|
11319
11315
|
var _formData$documents2;
|
|
@@ -11518,7 +11514,7 @@ const RentAndLeasePropertyDetails = ({
|
|
|
11518
11514
|
validateStep,
|
|
11519
11515
|
config
|
|
11520
11516
|
}) => {
|
|
11521
|
-
var _watch;
|
|
11517
|
+
var _watch, _watch2;
|
|
11522
11518
|
const dispatch = useDispatch();
|
|
11523
11519
|
const tenantId = window.localStorage.getItem("Employee.tenant-id");
|
|
11524
11520
|
const [documentsData, setDocumentsData] = useState([]);
|
|
@@ -11680,7 +11676,6 @@ const RentAndLeasePropertyDetails = ({
|
|
|
11680
11676
|
};
|
|
11681
11677
|
const onSubmit = async data => {
|
|
11682
11678
|
var _data$applicationType, _documentsData$;
|
|
11683
|
-
console.log("data", data);
|
|
11684
11679
|
const applicationType = data === null || data === void 0 ? void 0 : (_data$applicationType = data.applicationType) === null || _data$applicationType === void 0 ? void 0 : _data$applicationType.code;
|
|
11685
11680
|
if (applicationType === "Legacy" && (data === null || data === void 0 ? void 0 : data.arrear) > 0 && !(documentsData !== null && documentsData !== void 0 && (_documentsData$ = documentsData[0]) !== null && _documentsData$ !== void 0 && _documentsData$.filestoreId)) {
|
|
11686
11681
|
alert("Please upload arrear document");
|
|
@@ -11766,7 +11761,6 @@ const RentAndLeasePropertyDetails = ({
|
|
|
11766
11761
|
}
|
|
11767
11762
|
}, [isError, triggerToast]);
|
|
11768
11763
|
const handleDocumentsSelect = data => {
|
|
11769
|
-
console.log("data check", data);
|
|
11770
11764
|
setDocumentsData(data);
|
|
11771
11765
|
};
|
|
11772
11766
|
useEffect(() => {
|
|
@@ -12047,7 +12041,7 @@ const RentAndLeasePropertyDetails = ({
|
|
|
12047
12041
|
t: t,
|
|
12048
12042
|
disabled: true
|
|
12049
12043
|
})
|
|
12050
|
-
}))), errors.penaltyType && /*#__PURE__*/React.createElement(CardLabelError, null, getErrorMessage("penaltyType")), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, null, t("RAL_SECURITY_AMOUNT"), " ", /*#__PURE__*/React.createElement("span", {
|
|
12044
|
+
}))), errors.penaltyType && /*#__PURE__*/React.createElement(CardLabelError, null, getErrorMessage("penaltyType")), ((_watch = watch("applicationType")) === null || _watch === void 0 ? void 0 : _watch.code) != "Legacy" && /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, null, t("RAL_SECURITY_AMOUNT"), " ", /*#__PURE__*/React.createElement("span", {
|
|
12051
12045
|
className: "mandatory-asterisk"
|
|
12052
12046
|
}, "*")), /*#__PURE__*/React.createElement("div", {
|
|
12053
12047
|
className: "form-field"
|
|
@@ -12068,7 +12062,7 @@ const RentAndLeasePropertyDetails = ({
|
|
|
12068
12062
|
})
|
|
12069
12063
|
}))), errors.securityDeposit && /*#__PURE__*/React.createElement(CardLabelError, {
|
|
12070
12064
|
className: "ral-error-label"
|
|
12071
|
-
}, getErrorMessage("securityDeposit")), ((
|
|
12065
|
+
}, getErrorMessage("securityDeposit"))), ((_watch2 = watch("applicationType")) === null || _watch2 === void 0 ? void 0 : _watch2.code) == "Legacy" && /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, null, t("Arrears"), " ", /*#__PURE__*/React.createElement("span", {
|
|
12072
12066
|
className: "mandatory-asterisk"
|
|
12073
12067
|
}, "*")), /*#__PURE__*/React.createElement("div", {
|
|
12074
12068
|
className: "form-field"
|
|
@@ -12926,7 +12920,8 @@ const NewRentAndLeaseStepFormFour = ({
|
|
|
12926
12920
|
allotmentType: (updatedPropertyDetails === null || updatedPropertyDetails === void 0 ? void 0 : (_updatedPropertyDetai2 = updatedPropertyDetails.propertyType) === null || _updatedPropertyDetai2 === void 0 ? void 0 : _updatedPropertyDetai2.code) || (originalAdditionalDetails === null || originalAdditionalDetails === void 0 ? void 0 : originalAdditionalDetails.allotmentType),
|
|
12927
12921
|
propertyType: (updatedPropertyDetails === null || updatedPropertyDetails === void 0 ? void 0 : (_updatedPropertyDetai3 = updatedPropertyDetails.propertySpecific) === null || _updatedPropertyDetai3 === void 0 ? void 0 : _updatedPropertyDetai3.code) || (originalAdditionalDetails === null || originalAdditionalDetails === void 0 ? void 0 : originalAdditionalDetails.propertyType),
|
|
12928
12922
|
locationType: (updatedPropertyDetails === null || updatedPropertyDetails === void 0 ? void 0 : (_updatedPropertyDetai4 = updatedPropertyDetails.locationType) === null || _updatedPropertyDetai4 === void 0 ? void 0 : _updatedPropertyDetai4.code) || (originalAdditionalDetails === null || originalAdditionalDetails === void 0 ? void 0 : originalAdditionalDetails.locationType),
|
|
12929
|
-
applicationType: applicationType
|
|
12923
|
+
applicationType: applicationType,
|
|
12924
|
+
securityDeposit: null
|
|
12930
12925
|
} : null;
|
|
12931
12926
|
const allotmentIdForNewDocs = CreatedResponse === null || CreatedResponse === void 0 ? void 0 : (_CreatedResponse$Allo5 = CreatedResponse.AllotmentDetails) === null || _CreatedResponse$Allo5 === void 0 ? void 0 : (_CreatedResponse$Allo6 = _CreatedResponse$Allo5[0]) === null || _CreatedResponse$Allo6 === void 0 ? void 0 : _CreatedResponse$Allo6.id;
|
|
12932
12927
|
formData = {
|
|
@@ -12939,6 +12934,9 @@ const NewRentAndLeaseStepFormFour = ({
|
|
|
12939
12934
|
additionalDetails: additionalDetails
|
|
12940
12935
|
}),
|
|
12941
12936
|
propertyId: (updatedPropertyDetails === null || updatedPropertyDetails === void 0 ? void 0 : updatedPropertyDetails.propertyId) || (updatedPropertyDetails === null || updatedPropertyDetails === void 0 ? void 0 : (_updatedPropertyDetai6 = updatedPropertyDetails.selectedProperty) === null || _updatedPropertyDetai6 === void 0 ? void 0 : _updatedPropertyDetai6.propertyId),
|
|
12937
|
+
...(applicationType === "Legacy" && {
|
|
12938
|
+
securityDeposit: null
|
|
12939
|
+
}),
|
|
12942
12940
|
Document: updatedDocuments.map(doc => {
|
|
12943
12941
|
var _ref, _CreatedResponse$Allo12, _CreatedResponse$Allo13;
|
|
12944
12942
|
const originalDoc = ((_ref = (CreatedResponse === null || CreatedResponse === void 0 ? void 0 : (_CreatedResponse$Allo12 = CreatedResponse.AllotmentDetails) === null || _CreatedResponse$Allo12 === void 0 ? void 0 : (_CreatedResponse$Allo13 = _CreatedResponse$Allo12[0]) === null || _CreatedResponse$Allo13 === void 0 ? void 0 : _CreatedResponse$Allo13.Document) || []) === null || _ref === void 0 ? void 0 : _ref.find(d => d.documentUid === (doc === null || doc === void 0 ? void 0 : doc.documentUid) || d.fileStoreId === (doc === null || doc === void 0 ? void 0 : doc.fileStoreId) || d.documentType === (doc === null || doc === void 0 ? void 0 : doc.documentType))) || {};
|
|
@@ -13344,7 +13342,7 @@ function RentAndLeaseSelectDocument({
|
|
|
13344
13342
|
function RentAndLeaseSummary({
|
|
13345
13343
|
t
|
|
13346
13344
|
}) {
|
|
13347
|
-
var _formData$applicantDe, _formData$applicantDe2, _formData$applicantDe3, _formData$applicantDe4, _formData$documents, _formData$documents$d, _formData$documents2, _property$
|
|
13345
|
+
var _formData$applicantDe, _formData$applicantDe2, _formData$applicantDe3, _formData$applicantDe4, _formData$documents, _formData$documents$d, _formData$documents2, _property$application2, _property$arrearReaso, _property$arrearReaso2;
|
|
13348
13346
|
const formData = useSelector(state => {
|
|
13349
13347
|
var _state$rentAndLease, _state$rentAndLease$R;
|
|
13350
13348
|
return ((_state$rentAndLease = state.rentAndLease) === null || _state$rentAndLease === void 0 ? void 0 : (_state$rentAndLease$R = _state$rentAndLease.RentAndLeaseNewApplicationFormReducer) === null || _state$rentAndLease$R === void 0 ? void 0 : _state$rentAndLease$R.formData) || {};
|
|
@@ -13404,7 +13402,10 @@ function RentAndLeaseSummary({
|
|
|
13404
13402
|
className: "ral-summary-header-row"
|
|
13405
13403
|
}, /*#__PURE__*/React.createElement("h3", {
|
|
13406
13404
|
className: "ral-summary-heading"
|
|
13407
|
-
}, t("Properties Details"))), Object.entries(propertyLabels).
|
|
13405
|
+
}, t("Properties Details"))), Object.entries(propertyLabels).filter(([key]) => {
|
|
13406
|
+
var _property$application;
|
|
13407
|
+
return (property === null || property === void 0 ? void 0 : (_property$application = property.applicationType) === null || _property$application === void 0 ? void 0 : _property$application.code) !== "Legacy" || key !== "securityDeposit";
|
|
13408
|
+
}).map(([key, label]) => {
|
|
13408
13409
|
var _property$selectedPro, _value, _value2;
|
|
13409
13410
|
let value = (property === null || property === void 0 ? void 0 : (_property$selectedPro = property.selectedProperty) === null || _property$selectedPro === void 0 ? void 0 : _property$selectedPro[key]) || (property === null || property === void 0 ? void 0 : property[key]);
|
|
13410
13411
|
if ((_value = value) !== null && _value !== void 0 && _value.name) value = value.name;else if ((_value2 = value) !== null && _value2 !== void 0 && _value2.code) value = value.code;
|
|
@@ -13418,7 +13419,7 @@ function RentAndLeaseSummary({
|
|
|
13418
13419
|
value = Digit.DateUtils.ConvertEpochToDate(value);
|
|
13419
13420
|
}
|
|
13420
13421
|
return renderRow(label, value || "NA");
|
|
13421
|
-
}))), (property === null || property === void 0 ? void 0 : (_property$
|
|
13422
|
+
}))), (property === null || property === void 0 ? void 0 : (_property$application2 = property.applicationType) === null || _property$application2 === void 0 ? void 0 : _property$application2.code) === "Legacy" && /*#__PURE__*/React.createElement(Card, {
|
|
13422
13423
|
className: "summary-section"
|
|
13423
13424
|
}, /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("div", {
|
|
13424
13425
|
className: "ral-summary-header-row"
|