Conditional reporting in Invoices module?

Posted by: Samuel Kopstick

Conditional reporting in Invoices module? - 04/22/19 09:30 AM

Is there any way to display a value on an Invoice Spec from a field based on a condition?

e.g. If (Report Group=”States”, “USD”, “”)

We would like to display the text “USD” when the Report Group has “States”, otherwise leave the display blank.
(No, we are not using multi-currency.)
Posted by: Steve Schwartz

Re: Conditional reporting in Invoices module? - 04/22/19 10:43 AM

Hi Samuel

No. Version 9.3A of Invoices is the first module to allow for calculated fields on a spec:

(from the Release notes)
Added calculated numeric fields on invoices using formulas in the Specification Designer to do math (add, subtract, multiply, divide) on specification codes and constants. Added new Formulas, Numeric section to Specification Designer with new codes: X001..X005 Calculated Amount 1..5

But no module has if/then/else functionality.

Someone will certainly chime in and say that this can be done using PrintBoss.

Steve
Posted by: Bruce Gardner

Re: Conditional reporting in Invoices module? - 04/22/19 11:15 AM

Hi Samuel:

In the absence of If/Else logic, three approaches come to mind (you may have already considered these):

1) Have 2 versions of the invoice spec file, one for USD and one for CAD, then assign the USD spec to the USD Customers.

2) Print an Optional field on the spec file and enter "USD Dollars" on the Customer profile but leave it blank for CAD Customers.

3) Since the Customers are likely in 2 different Control Account Sets, make the Description of the USD Account Set = "USD Dollars" and print it on the invoice (spec code = E052). The Description of the CAD Account Set would either have to be blank or say "CAD Dollars".

The third option only requires one spec file and probably comes as close as you can get to the simplicity of the If/Else option.
Posted by: Samuel Kopstick

Re: Conditional reporting in Invoices module? - 04/23/19 08:51 AM

Thanks Steve & Bruce,

Steve – yes, I am familiar with the new code for calculated numeric values in Invoice.
I was just wondering if anyone may have come up with some work around that I have not thought of.
But as you state, there is no logic fields (yet) in the specs.

Bruce – your third option is the way that we are going. We will either use the Control Account, or an optional string field that we will call “Currency”. This way, we will be able to still manage with just the one spec file.