- fixed issue with new table skips decimals;
This commit is contained in:
@@ -46,6 +46,7 @@ import { Dialog } from 'primereact/dialog';
|
||||
import FileuploadApplicationSignedPdf from '../../components/FileuploadApplicationSignedPdf';
|
||||
|
||||
import { defaultMaxFileSize } from '../../configData';
|
||||
import parseCommaDecimal from '../../helpers/parseCommaDecimal';
|
||||
|
||||
const BandoApplication = () => {
|
||||
const chosenCompanyId = useStore().main.chosenCompanyId();
|
||||
@@ -541,9 +542,10 @@ const BandoApplication = () => {
|
||||
context = getTokens(formula.value)
|
||||
.filter(v => !['false', 'null', 'true'].includes(v))
|
||||
.reduce((acc, cur) => {
|
||||
acc[cur] = isNil(context[cur]) ? 0 : parseFloat(context[cur]);
|
||||
acc[cur] = isNil(context[cur]) ? 0 : parseCommaDecimal(context[cur]);
|
||||
return acc;
|
||||
}, context);
|
||||
|
||||
const mathFormula = renderWithDataVars(formula.value, context);
|
||||
try {
|
||||
updatedFormValues[o.id] = evaluate(mathFormula);
|
||||
|
||||
Reference in New Issue
Block a user