USD has a format of #,##0.00
whereas KWD has a format of #,##0.000
and yes the third decimal is very critical and important given the currency’s high exchange value. I’m sure there are also currencies where the whole number after the decimal is not even wanted.
As below sample grep output shows, there is a lot of hard-coded formatting (250+) all over the place. Wouldn’t it make more sense to switch moqui behavior to parameterize currency formatting perhaps with some defaults. And if yes, which entity can hold this information best?
framework/src/main/groovy/org/moqui/impl/screen/ScreenForm.groovy: attrs = [format:"#,##0.00"]
framework/src/main/groovy/org/moqui/impl/screen/ScreenForm.groovy: attrs = [format:"#,##0.000"]
runtime/component/SimpleScreens/screen/SimpleScreens/Party/PaymentMethod/PaymentMethodFiles.xml: <default-field><display format="#,##0.00"/></default-field></field>
runtime/component/SimpleScreens/screen/SimpleScreens/Party/PaymentMethod/PaymentMethodFiles.xml: <default-field><display format="#,##0.00"/></default-field></field>
runtime/component/SimpleScreens/screen/SimpleScreens/Accounting/Budget/BudgetReport.xml: <default-field title="Actual Year"><display format="#,##0.00" text-format="0.00"/></default-field></field>
runtime/component/SimpleScreens/screen/SimpleScreens/Accounting/Budget/BudgetReport.xml: <display format="#,##0.00" text-format="0.00"/></default-field></field>
runtime/component/SimpleScreens/screen/SimpleScreens/Accounting/Budget/BudgetReport.xml: <default-field title="Act P1"><display format="#,##0.0 " text-format="0.00"/></default-field></field>
runtime/component/SimpleScreens/screen/SimpleScreens/Accounting/Budget/BudgetReport.xml: <display format="#,##0.00" text-format="0.00"/></default-field></field>
runtime/component/SimpleScreens/screen/SimpleScreens/Accounting/Budget/BudgetReport.xml: <default-field title="Act P2"><display format="#,##0.0 " text-format="0.00"/></default-field></field>
runtime/component/SimpleScreens/screen/SimpleScreens/Accounting/Budget/BudgetReport.xml: <display format="#,##0.00" text-format="0.00"/></default-field></field>
runtime/component/SimpleScreens/screen/SimpleScreens/Accounting/Budget/BudgetReport.xml: <default-field title="Act P3"><display format="#,##0.0 " text-format="0.00"/></default-field></field>
runtime/component/SimpleScreens/screen/SimpleScreens/Accounting/Budget/BudgetReport.xml: <display format="#,##0.00" text-format="0.00"/></default-field></field>
runtime/component/SimpleScreens/screen/SimpleScreens/Accounting/Reports/SalesInvoiceAnalysis.xml: <field name="minAmount" align="right" show-total="min"><default-field title="Min"><display format="#,##0.00"/></default-field></field>
runtime/component/SimpleScreens/screen/SimpleScreens/Accounting/Reports/SalesInvoiceAnalysis.xml: <field name="maxAmount" align="right" show-total="max"><default-field title="Max"><display format="#,##0.00"/></default-field></field>
runtime/component/SimpleScreens/screen/SimpleScreens/Accounting/Reports/SalesInvoiceAnalysis.xml: <field name="avgAmount" align="right" show-total="avg"><default-field title="Avg"><display format="#,##0.00"/></default-field></field>
runtime/component/SimpleScreens/screen/SimpleScreens/Accounting/Reports/SalesInvoiceAnalysis.xml: <default-field><display format="#,##0.00"/></default-field></field>
runtime/component/SimpleScreens/screen/SimpleScreens/Accounting/Reports/SalesInvoiceAnalysis.xml: <field name="averageCost" align="right" show-total="avg"><default-field title="Avg Cost"><display format="#,##0.00"/></default-field></field>
runtime/component/SimpleScreens/screen/SimpleScreens/Accounting/Reports/SalesInvoiceAnalysis.xml: <default-field><display format="#,##0.00"/></default-field></field>
runtime/component/SimpleScreens/screen/SimpleScreens/Accounting/Reports/SalesInvoiceAnalysis.xml: <default-field title="Margin"><display format="#,##0.00"/></default-field></field>