fixed issues, pricebug, mappricing,
This commit is contained in:
@@ -251,6 +251,28 @@ export function ClaimForm({
|
|||||||
setForm({ ...form, serviceLines: updatedLines });
|
setForm({ ...form, serviceLines: updatedLines });
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// Map Price function
|
||||||
|
const mapPrices = () => {
|
||||||
|
const updatedLines = form.serviceLines.map((line) => {
|
||||||
|
if (line.procedureCode && line.procedureCode.trim() !== "") {
|
||||||
|
const normalizedCode = line.procedureCode.toUpperCase().trim();
|
||||||
|
const procedureInfo = procedureCodes.find(
|
||||||
|
(p) => p["Procedure Code"].toUpperCase().trim() === normalizedCode
|
||||||
|
);
|
||||||
|
|
||||||
|
if (procedureInfo && procedureInfo.Price) {
|
||||||
|
return {
|
||||||
|
...line,
|
||||||
|
totalBilled: new Decimal(parseFloat(procedureInfo.Price)),
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return line;
|
||||||
|
});
|
||||||
|
|
||||||
|
setForm({ ...form, serviceLines: updatedLines });
|
||||||
|
};
|
||||||
|
|
||||||
// FILE UPLOAD ZONE
|
// FILE UPLOAD ZONE
|
||||||
const [isUploading, setIsUploading] = useState(false);
|
const [isUploading, setIsUploading] = useState(false);
|
||||||
|
|
||||||
@@ -549,7 +571,11 @@ export function ClaimForm({
|
|||||||
placeholder="eg. D0120"
|
placeholder="eg. D0120"
|
||||||
value={line.procedureCode}
|
value={line.procedureCode}
|
||||||
onChange={(e) =>
|
onChange={(e) =>
|
||||||
updateServiceLine(i, "procedureCode", e.target.value)
|
updateServiceLine(
|
||||||
|
i,
|
||||||
|
"procedureCode",
|
||||||
|
e.target.value.toUpperCase()
|
||||||
|
)
|
||||||
}
|
}
|
||||||
/>
|
/>
|
||||||
|
|
||||||
@@ -676,7 +702,9 @@ export function ClaimForm({
|
|||||||
<Button variant="outline">Child Prophy Codes</Button>
|
<Button variant="outline">Child Prophy Codes</Button>
|
||||||
<Button variant="outline">Adult Prophy Codes</Button>
|
<Button variant="outline">Adult Prophy Codes</Button>
|
||||||
<Button variant="outline">Customized Group Codes</Button>
|
<Button variant="outline">Customized Group Codes</Button>
|
||||||
<Button variant="outline">Map Price</Button>
|
<Button variant="success" onClick={mapPrices}>
|
||||||
|
Map Price
|
||||||
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -711,7 +739,7 @@ export function ClaimForm({
|
|||||||
<div className="flex justify-between">
|
<div className="flex justify-between">
|
||||||
<Button
|
<Button
|
||||||
className="w-32"
|
className="w-32"
|
||||||
variant="outline"
|
variant="warning"
|
||||||
onClick={handleMHSubmit}
|
onClick={handleMHSubmit}
|
||||||
>
|
>
|
||||||
MH
|
MH
|
||||||
|
|||||||
@@ -180,10 +180,10 @@ class AutomationMassHealth:
|
|||||||
|
|
||||||
|
|
||||||
# Fill Fees if present
|
# Fill Fees if present
|
||||||
if proc.get("billedAmount"):
|
if proc.get("totalBilled"):
|
||||||
fees_xpath = "//input[@name='ProcedureFee']"
|
fees_xpath = "//input[@name='ProcedureFee']"
|
||||||
wait.until(EC.presence_of_element_located((By.XPATH, fees_xpath))).clear()
|
wait.until(EC.presence_of_element_located((By.XPATH, fees_xpath))).clear()
|
||||||
self.driver.find_element(By.XPATH, fees_xpath).send_keys(proc["billedAmount"])
|
self.driver.find_element(By.XPATH, fees_xpath).send_keys(proc["totalBilled"])
|
||||||
|
|
||||||
# Click "Add Procedure" button
|
# Click "Add Procedure" button
|
||||||
add_proc_xpath = "//input[@type='submit' and @value='Add Procedure']"
|
add_proc_xpath = "//input[@type='submit' and @value='Add Procedure']"
|
||||||
|
|||||||
Reference in New Issue
Block a user