Skip to content

Commit

Permalink
Merge pull request #1054 from Puli-shilpa/Dev-2.0
Browse files Browse the repository at this point in the history
 enabled fsm submit button after filling all mandatory fields
  • Loading branch information
sriranjan-s authored Apr 12, 2024
2 parents 98b7399 + 53e6012 commit 0f8f5b3
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -44,20 +44,24 @@ export const NewApplication = ({ parentUrl, heading }) => {
const onFormValueChange = (setValue, formData) => {
console.log("ProID", formData)
if (

formData?.pitType!==undefined &&
formData?.tripData?.vehicleType &&
formData?.tripData?.roadWidth!==undefined &&
formData?.tripData?.distancefromroad!==undefined &&
formData?. address?.street &&
formData?.address?.doorNo &&
formData?.propertyType &&
formData?.subtype &&
formData?.address?.locality?.code || formData?.cpt?.details?.address?.locality?.code &&
formData?.tripData?.vehicleType &&
formData?.channel &&
formData?.pitType &&
formData?.tripData?.roadWidth &&
formData?.tripData?.distancefromroad &&
formData?. address?.street &&
formData?.address?.doorNo &&


(formData?.tripData?.amountPerTrip || formData?.tripData?.amountPerTrip === 0 || formData?.tripData?.undefined?.amountPerTrip)
) {
setSubmitValve(true);
console.log("cansub", canSubmit)
const pitDetailValues = formData?.pitDetail ? Object.values(formData?.pitDetail).filter((value) => value > 0) : null;
let max = Digit.SessionStorage.get("total_amount");
let min = Digit.SessionStorage.get("advance_amount");
Expand Down Expand Up @@ -162,6 +166,7 @@ export const NewApplication = ({ parentUrl, heading }) => {
},
workflow: null,
};
console.log("formdataa", formData)

window.Digit.SessionStorage.set("propertyType", null);
window.Digit.SessionStorage.set("subType", null);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -842,7 +842,7 @@ class ShowField extends Component {
return (
<thead>
<tr className="report-table-header">
<th key={"S. No."} className="report-header-cell">
<th key={"S. No."} className="report-header-cell" style={{width:"50px"}}>
<Label className="report-header-row-label" labelStyle={{ wordWrap: "unset", wordBreak: "unset", fontWeight: "bold" }} label={"RT_SNO"} />
</th>
{metaData && metaData.reportDetails && metaData.reportDetails.selectiveDownload && (
Expand All @@ -854,7 +854,7 @@ class ShowField extends Component {
reportResult.reportHeader.map((item, i) => {
if (item.showColumn) {
return (
<th key={i} className="report-header-cell" data-orderable={item && item.label && item.label.includes("date") ? "false" : "true"}>
<th key={i} style={{width:"200px"}} className="report-header-cell" data-orderable={item && item.label && item.label.includes("date") ? "false" : "true"}>
<Label
className="report-header-row-label"
labelStyle={{ wordWrap: "unset", wordBreak: "unset", fontWeight: "bold" }}
Expand Down Expand Up @@ -1276,11 +1276,12 @@ class ShowField extends Component {
let self = this;
const viewTabel = () => {
return (
<div>
<div style={{ width:"100%", overflowX:"auto"}}>
<table
id="reportTable"
style={{
width: "100%",
tableLayout:"fixed"
}}
className="table table-striped table-bordered"
>
Expand All @@ -1301,9 +1302,9 @@ class ShowField extends Component {
/>
</div>
) : (
""
<br/>
)}
<br />

</div>
);
};
Expand Down

0 comments on commit 0f8f5b3

Please sign in to comment.