Joget DX 8 Stable Released
The stable release for Joget DX 8 is now available, with a focus on UX and Governance.
Hi, if you intend to perform calculations, I would suggest to store the value directly as a number instead of a formatted string. Then only use formatting when displaying the output value.
Hi Anders, you are okay ?
In another cenario i´m to attempt to format output collumn in datalist with Bean sell script below:
String texto = String.format("%,.2f", value);
texto = texto.replace(",", "#");
texto = texto.replace(".", ",");
texto = texto.replace("#", ".");
return "<span style=\"color:green\">" + texto + "</span>";
------------------------------------------------------------------
But i´m getting this error message:
ERROR 07 Sep 2022 14:54:10 org.joget.plugin.enterprise.BeanShellFormatter - jwc_paulomnasc : Error executing script 9920 bsh.EvalError: Sourced file: inline evaluation of: ``String texto = String.format("%,.2f", value); texto = texto.replace(",", "#"); . . . '' : Typed variable declaration : Error in method invocation: Static method format( java.lang.String, java.lang.String ) not found in class'java.lang.String'
Observation: This code execute ok on java web editor www.jdoodle.com.
Any idea ?
failure to attempt to save a curency(money) value field
Hi guys,
i´m have a failure to attempt to save a curency(money) value field in this cenario:
1) Test cenario: Insert an value = U$ 1.000,00 in the transaction record to update store credit an another form.
1) The field value of my form is configured with:
a) Formatting Style: US Style
b) Number of Decimal : 2
c) Validator Type: Numeric
d) Mandatory : Checked
2) This form has a Post Processing update tool with a sql update command to store this field value to another table form.
SQL Command: "update app_fd_conta_contabil set c_saldo_conta = c_saldo_conta - FORMAT(#form.app_fd_transacao.id_valor_transacao#, 2)
where ID = '#form.app_fd_transacao.cboCtContabil#'"
3) Result: This update run without execution erros, but your result is the app to subtrac 1,00 otherwise 1.000,00
Any idea ?
Thanks,
Paulo Nascimento